axe-core 4.7.1 → 4.7.2-canary.03f2771
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/README.md +4 -0
- package/axe.js +1739 -1689
- package/axe.min.js +2 -2
- package/locales/_template.json +4 -0
- package/package.json +3 -2
- package/sri-history.json +357 -349
package/axe.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! axe v4.7.
|
|
1
|
+
/*! axe v4.7.2-canary.03f2771
|
|
2
2
|
* Copyright (c) 2023 Deque Systems, Inc.
|
|
3
3
|
*
|
|
4
4
|
* Your use of this Source Code Form is subject to the terms of the Mozilla Public
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
}, _typeof(obj);
|
|
23
23
|
}
|
|
24
24
|
var axe = axe || {};
|
|
25
|
-
axe.version = '4.7.
|
|
25
|
+
axe.version = '4.7.2-canary.03f2771';
|
|
26
26
|
if (typeof define === 'function' && define.amd) {
|
|
27
27
|
define('axe-core', [], function() {
|
|
28
28
|
return axe;
|
|
@@ -532,879 +532,258 @@
|
|
|
532
532
|
__defNormalProp(obj, _typeof(key) !== 'symbol' ? key + '' : key, value);
|
|
533
533
|
return value;
|
|
534
534
|
};
|
|
535
|
-
var
|
|
535
|
+
var require_noop = __commonJS(function(exports, module) {
|
|
536
536
|
'use strict';
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
var i = 0;
|
|
556
|
-
while (i < len) {
|
|
557
|
-
var chr = s.charAt(i);
|
|
558
|
-
if (exports.identSpecialChars[chr]) {
|
|
559
|
-
result += '\\' + chr;
|
|
560
|
-
} else {
|
|
561
|
-
if (!(chr === '_' || chr === '-' || chr >= 'A' && chr <= 'Z' || chr >= 'a' && chr <= 'z' || i !== 0 && chr >= '0' && chr <= '9')) {
|
|
562
|
-
var charCode = chr.charCodeAt(0);
|
|
563
|
-
if ((charCode & 63488) === 55296) {
|
|
564
|
-
var extraCharCode = s.charCodeAt(i++);
|
|
565
|
-
if ((charCode & 64512) !== 55296 || (extraCharCode & 64512) !== 56320) {
|
|
566
|
-
throw Error('UCS-2(decode): illegal sequence');
|
|
567
|
-
}
|
|
568
|
-
charCode = ((charCode & 1023) << 10) + (extraCharCode & 1023) + 65536;
|
|
569
|
-
}
|
|
570
|
-
result += '\\' + charCode.toString(16) + ' ';
|
|
571
|
-
} else {
|
|
572
|
-
result += chr;
|
|
573
|
-
}
|
|
574
|
-
}
|
|
575
|
-
i++;
|
|
537
|
+
module.exports = function() {};
|
|
538
|
+
});
|
|
539
|
+
var require_is_value = __commonJS(function(exports, module) {
|
|
540
|
+
'use strict';
|
|
541
|
+
var _undefined = require_noop()();
|
|
542
|
+
module.exports = function(val) {
|
|
543
|
+
return val !== _undefined && val !== null;
|
|
544
|
+
};
|
|
545
|
+
});
|
|
546
|
+
var require_normalize_options = __commonJS(function(exports, module) {
|
|
547
|
+
'use strict';
|
|
548
|
+
var isValue = require_is_value();
|
|
549
|
+
var forEach = Array.prototype.forEach;
|
|
550
|
+
var create = Object.create;
|
|
551
|
+
var process2 = function process2(src, obj) {
|
|
552
|
+
var key;
|
|
553
|
+
for (key in src) {
|
|
554
|
+
obj[key] = src[key];
|
|
576
555
|
}
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
var i = 0;
|
|
584
|
-
var replacement;
|
|
585
|
-
while (i < len) {
|
|
586
|
-
var chr = s.charAt(i);
|
|
587
|
-
if (chr === '"') {
|
|
588
|
-
chr = '\\"';
|
|
589
|
-
} else if (chr === '\\') {
|
|
590
|
-
chr = '\\\\';
|
|
591
|
-
} else if ((replacement = exports.strReplacementsRev[chr]) !== void 0) {
|
|
592
|
-
chr = replacement;
|
|
556
|
+
};
|
|
557
|
+
module.exports = function(opts1) {
|
|
558
|
+
var result = create(null);
|
|
559
|
+
forEach.call(arguments, function(options) {
|
|
560
|
+
if (!isValue(options)) {
|
|
561
|
+
return;
|
|
593
562
|
}
|
|
594
|
-
result
|
|
595
|
-
|
|
563
|
+
process2(Object(options), result);
|
|
564
|
+
});
|
|
565
|
+
return result;
|
|
566
|
+
};
|
|
567
|
+
});
|
|
568
|
+
var require_is_implemented = __commonJS(function(exports, module) {
|
|
569
|
+
'use strict';
|
|
570
|
+
module.exports = function() {
|
|
571
|
+
var sign = Math.sign;
|
|
572
|
+
if (typeof sign !== 'function') {
|
|
573
|
+
return false;
|
|
596
574
|
}
|
|
597
|
-
return
|
|
598
|
-
}
|
|
599
|
-
exports.escapeStr = escapeStr;
|
|
600
|
-
exports.identSpecialChars = {
|
|
601
|
-
'!': true,
|
|
602
|
-
'"': true,
|
|
603
|
-
'#': true,
|
|
604
|
-
$: true,
|
|
605
|
-
'%': true,
|
|
606
|
-
'&': true,
|
|
607
|
-
'\'': true,
|
|
608
|
-
'(': true,
|
|
609
|
-
')': true,
|
|
610
|
-
'*': true,
|
|
611
|
-
'+': true,
|
|
612
|
-
',': true,
|
|
613
|
-
'.': true,
|
|
614
|
-
'/': true,
|
|
615
|
-
';': true,
|
|
616
|
-
'<': true,
|
|
617
|
-
'=': true,
|
|
618
|
-
'>': true,
|
|
619
|
-
'?': true,
|
|
620
|
-
'@': true,
|
|
621
|
-
'[': true,
|
|
622
|
-
'\\': true,
|
|
623
|
-
']': true,
|
|
624
|
-
'^': true,
|
|
625
|
-
'`': true,
|
|
626
|
-
'{': true,
|
|
627
|
-
'|': true,
|
|
628
|
-
'}': true,
|
|
629
|
-
'~': true
|
|
575
|
+
return sign(10) === 1 && sign(-20) === -1;
|
|
630
576
|
};
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
577
|
+
});
|
|
578
|
+
var require_shim = __commonJS(function(exports, module) {
|
|
579
|
+
'use strict';
|
|
580
|
+
module.exports = function(value) {
|
|
581
|
+
value = Number(value);
|
|
582
|
+
if (isNaN(value) || value === 0) {
|
|
583
|
+
return value;
|
|
584
|
+
}
|
|
585
|
+
return value > 0 ? 1 : -1;
|
|
637
586
|
};
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
587
|
+
});
|
|
588
|
+
var require_sign = __commonJS(function(exports, module) {
|
|
589
|
+
'use strict';
|
|
590
|
+
module.exports = require_is_implemented()() ? Math.sign : require_shim();
|
|
591
|
+
});
|
|
592
|
+
var require_to_integer = __commonJS(function(exports, module) {
|
|
593
|
+
'use strict';
|
|
594
|
+
var sign = require_sign();
|
|
595
|
+
var abs = Math.abs;
|
|
596
|
+
var floor = Math.floor;
|
|
597
|
+
module.exports = function(value) {
|
|
598
|
+
if (isNaN(value)) {
|
|
599
|
+
return 0;
|
|
600
|
+
}
|
|
601
|
+
value = Number(value);
|
|
602
|
+
if (value === 0 || !isFinite(value)) {
|
|
603
|
+
return value;
|
|
604
|
+
}
|
|
605
|
+
return sign(value) * floor(abs(value));
|
|
645
606
|
};
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
607
|
+
});
|
|
608
|
+
var require_to_pos_integer = __commonJS(function(exports, module) {
|
|
609
|
+
'use strict';
|
|
610
|
+
var toInteger = require_to_integer();
|
|
611
|
+
var max2 = Math.max;
|
|
612
|
+
module.exports = function(value) {
|
|
613
|
+
return max2(0, toInteger(value));
|
|
653
614
|
};
|
|
654
615
|
});
|
|
655
|
-
var
|
|
616
|
+
var require_resolve_length = __commonJS(function(exports, module) {
|
|
656
617
|
'use strict';
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
function getStr(quote, escapeTable) {
|
|
665
|
-
var result = '';
|
|
666
|
-
pos++;
|
|
667
|
-
chr = str.charAt(pos);
|
|
668
|
-
while (pos < l) {
|
|
669
|
-
if (chr === quote) {
|
|
670
|
-
pos++;
|
|
671
|
-
return result;
|
|
672
|
-
} else if (chr === '\\') {
|
|
673
|
-
pos++;
|
|
674
|
-
chr = str.charAt(pos);
|
|
675
|
-
var esc = void 0;
|
|
676
|
-
if (chr === quote) {
|
|
677
|
-
result += quote;
|
|
678
|
-
} else if ((esc = escapeTable[chr]) !== void 0) {
|
|
679
|
-
result += esc;
|
|
680
|
-
} else if (utils_1.isHex(chr)) {
|
|
681
|
-
var hex = chr;
|
|
682
|
-
pos++;
|
|
683
|
-
chr = str.charAt(pos);
|
|
684
|
-
while (utils_1.isHex(chr)) {
|
|
685
|
-
hex += chr;
|
|
686
|
-
pos++;
|
|
687
|
-
chr = str.charAt(pos);
|
|
688
|
-
}
|
|
689
|
-
if (chr === ' ') {
|
|
690
|
-
pos++;
|
|
691
|
-
chr = str.charAt(pos);
|
|
692
|
-
}
|
|
693
|
-
result += String.fromCharCode(parseInt(hex, 16));
|
|
694
|
-
continue;
|
|
695
|
-
} else {
|
|
696
|
-
result += chr;
|
|
697
|
-
}
|
|
698
|
-
} else {
|
|
699
|
-
result += chr;
|
|
700
|
-
}
|
|
701
|
-
pos++;
|
|
702
|
-
chr = str.charAt(pos);
|
|
618
|
+
var toPosInt = require_to_pos_integer();
|
|
619
|
+
module.exports = function(optsLength, fnLength, isAsync) {
|
|
620
|
+
var length;
|
|
621
|
+
if (isNaN(optsLength)) {
|
|
622
|
+
length = fnLength;
|
|
623
|
+
if (!(length >= 0)) {
|
|
624
|
+
return 1;
|
|
703
625
|
}
|
|
704
|
-
|
|
626
|
+
if (isAsync && length) {
|
|
627
|
+
return length - 1;
|
|
628
|
+
}
|
|
629
|
+
return length;
|
|
705
630
|
}
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
chr = str.charAt(pos);
|
|
709
|
-
while (pos < l) {
|
|
710
|
-
if (utils_1.isIdent(chr)) {
|
|
711
|
-
result += chr;
|
|
712
|
-
} else if (chr === '\\') {
|
|
713
|
-
pos++;
|
|
714
|
-
if (pos >= l) {
|
|
715
|
-
throw Error('Expected symbol but end of file reached.');
|
|
716
|
-
}
|
|
717
|
-
chr = str.charAt(pos);
|
|
718
|
-
if (utils_1.identSpecialChars[chr]) {
|
|
719
|
-
result += chr;
|
|
720
|
-
} else if (utils_1.isHex(chr)) {
|
|
721
|
-
var hex = chr;
|
|
722
|
-
pos++;
|
|
723
|
-
chr = str.charAt(pos);
|
|
724
|
-
while (utils_1.isHex(chr)) {
|
|
725
|
-
hex += chr;
|
|
726
|
-
pos++;
|
|
727
|
-
chr = str.charAt(pos);
|
|
728
|
-
}
|
|
729
|
-
if (chr === ' ') {
|
|
730
|
-
pos++;
|
|
731
|
-
chr = str.charAt(pos);
|
|
732
|
-
}
|
|
733
|
-
result += String.fromCharCode(parseInt(hex, 16));
|
|
734
|
-
continue;
|
|
735
|
-
} else {
|
|
736
|
-
result += chr;
|
|
737
|
-
}
|
|
738
|
-
} else {
|
|
739
|
-
return result;
|
|
740
|
-
}
|
|
741
|
-
pos++;
|
|
742
|
-
chr = str.charAt(pos);
|
|
743
|
-
}
|
|
744
|
-
return result;
|
|
631
|
+
if (optsLength === false) {
|
|
632
|
+
return false;
|
|
745
633
|
}
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
return result;
|
|
634
|
+
return toPosInt(optsLength);
|
|
635
|
+
};
|
|
636
|
+
});
|
|
637
|
+
var require_valid_callable = __commonJS(function(exports, module) {
|
|
638
|
+
'use strict';
|
|
639
|
+
module.exports = function(fn) {
|
|
640
|
+
if (typeof fn !== 'function') {
|
|
641
|
+
throw new TypeError(fn + ' is not a function');
|
|
755
642
|
}
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
643
|
+
return fn;
|
|
644
|
+
};
|
|
645
|
+
});
|
|
646
|
+
var require_valid_value = __commonJS(function(exports, module) {
|
|
647
|
+
'use strict';
|
|
648
|
+
var isValue = require_is_value();
|
|
649
|
+
module.exports = function(value) {
|
|
650
|
+
if (!isValue(value)) {
|
|
651
|
+
throw new TypeError('Cannot use null or undefined');
|
|
762
652
|
}
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
653
|
+
return value;
|
|
654
|
+
};
|
|
655
|
+
});
|
|
656
|
+
var require_iterate = __commonJS(function(exports, module) {
|
|
657
|
+
'use strict';
|
|
658
|
+
var callable = require_valid_callable();
|
|
659
|
+
var value = require_valid_value();
|
|
660
|
+
var bind = Function.prototype.bind;
|
|
661
|
+
var call = Function.prototype.call;
|
|
662
|
+
var keys = Object.keys;
|
|
663
|
+
var objPropertyIsEnumerable = Object.prototype.propertyIsEnumerable;
|
|
664
|
+
module.exports = function(method, defVal) {
|
|
665
|
+
return function(obj, cb) {
|
|
666
|
+
var list, thisArg = arguments[2], compareFn = arguments[3];
|
|
667
|
+
obj = Object(value(obj));
|
|
668
|
+
callable(cb);
|
|
669
|
+
list = keys(obj);
|
|
670
|
+
if (compareFn) {
|
|
671
|
+
list.sort(typeof compareFn === 'function' ? bind.call(compareFn, obj) : void 0);
|
|
767
672
|
}
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
res = {
|
|
775
|
-
type: 'selectors',
|
|
776
|
-
selectors: [ selector ]
|
|
777
|
-
};
|
|
673
|
+
if (typeof method !== 'function') {
|
|
674
|
+
method = list[method];
|
|
675
|
+
}
|
|
676
|
+
return call.call(method, list, function(key, index) {
|
|
677
|
+
if (!objPropertyIsEnumerable.call(obj, key)) {
|
|
678
|
+
return defVal;
|
|
778
679
|
}
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
680
|
+
return call.call(cb, thisArg, obj[key], key, obj, index);
|
|
681
|
+
});
|
|
682
|
+
};
|
|
683
|
+
};
|
|
684
|
+
});
|
|
685
|
+
var require_for_each = __commonJS(function(exports, module) {
|
|
686
|
+
'use strict';
|
|
687
|
+
module.exports = require_iterate()('forEach');
|
|
688
|
+
});
|
|
689
|
+
var require_registered_extensions = __commonJS(function() {
|
|
690
|
+
'use strict';
|
|
691
|
+
});
|
|
692
|
+
var require_is_implemented2 = __commonJS(function(exports, module) {
|
|
693
|
+
'use strict';
|
|
694
|
+
module.exports = function() {
|
|
695
|
+
var assign = Object.assign, obj;
|
|
696
|
+
if (typeof assign !== 'function') {
|
|
697
|
+
return false;
|
|
698
|
+
}
|
|
699
|
+
obj = {
|
|
700
|
+
foo: 'raz'
|
|
701
|
+
};
|
|
702
|
+
assign(obj, {
|
|
703
|
+
bar: 'dwa'
|
|
704
|
+
}, {
|
|
705
|
+
trzy: 'trzy'
|
|
706
|
+
});
|
|
707
|
+
return obj.foo + obj.bar + obj.trzy === 'razdwatrzy';
|
|
708
|
+
};
|
|
709
|
+
});
|
|
710
|
+
var require_is_implemented3 = __commonJS(function(exports, module) {
|
|
711
|
+
'use strict';
|
|
712
|
+
module.exports = function() {
|
|
713
|
+
try {
|
|
714
|
+
Object.keys('primitive');
|
|
715
|
+
return true;
|
|
716
|
+
} catch (e) {
|
|
717
|
+
return false;
|
|
718
|
+
}
|
|
719
|
+
};
|
|
720
|
+
});
|
|
721
|
+
var require_shim2 = __commonJS(function(exports, module) {
|
|
722
|
+
'use strict';
|
|
723
|
+
var isValue = require_is_value();
|
|
724
|
+
var keys = Object.keys;
|
|
725
|
+
module.exports = function(object) {
|
|
726
|
+
return keys(isValue(object) ? Object(object) : object);
|
|
727
|
+
};
|
|
728
|
+
});
|
|
729
|
+
var require_keys = __commonJS(function(exports, module) {
|
|
730
|
+
'use strict';
|
|
731
|
+
module.exports = require_is_implemented3()() ? Object.keys : require_shim2();
|
|
732
|
+
});
|
|
733
|
+
var require_shim3 = __commonJS(function(exports, module) {
|
|
734
|
+
'use strict';
|
|
735
|
+
var keys = require_keys();
|
|
736
|
+
var value = require_valid_value();
|
|
737
|
+
var max2 = Math.max;
|
|
738
|
+
module.exports = function(dest, src) {
|
|
739
|
+
var error, i, length = max2(arguments.length, 2), assign;
|
|
740
|
+
dest = Object(value(dest));
|
|
741
|
+
assign = function assign(key) {
|
|
742
|
+
try {
|
|
743
|
+
dest[key] = src[key];
|
|
744
|
+
} catch (e) {
|
|
745
|
+
if (!error) {
|
|
746
|
+
error = e;
|
|
782
747
|
}
|
|
783
|
-
res.selectors.push(selector);
|
|
784
748
|
}
|
|
785
|
-
|
|
749
|
+
};
|
|
750
|
+
for (i = 1; i < length; ++i) {
|
|
751
|
+
src = arguments[i];
|
|
752
|
+
keys(src).forEach(assign);
|
|
786
753
|
}
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
}
|
|
821
|
-
}
|
|
822
|
-
return selector;
|
|
823
|
-
}
|
|
824
|
-
function parseRule() {
|
|
825
|
-
var rule = null;
|
|
826
|
-
while (pos < l) {
|
|
827
|
-
chr = str.charAt(pos);
|
|
828
|
-
if (chr === '*') {
|
|
829
|
-
pos++;
|
|
830
|
-
(rule = rule || {}).tagName = '*';
|
|
831
|
-
} else if (utils_1.isIdentStart(chr) || chr === '\\') {
|
|
832
|
-
(rule = rule || {}).tagName = getIdent();
|
|
833
|
-
} else if (chr === '.') {
|
|
834
|
-
pos++;
|
|
835
|
-
rule = rule || {};
|
|
836
|
-
(rule.classNames = rule.classNames || []).push(getIdent());
|
|
837
|
-
} else if (chr === '#') {
|
|
838
|
-
pos++;
|
|
839
|
-
(rule = rule || {}).id = getIdent();
|
|
840
|
-
} else if (chr === '[') {
|
|
841
|
-
pos++;
|
|
842
|
-
skipWhitespace();
|
|
843
|
-
var attr = {
|
|
844
|
-
name: getIdent()
|
|
845
|
-
};
|
|
846
|
-
skipWhitespace();
|
|
847
|
-
if (chr === ']') {
|
|
848
|
-
pos++;
|
|
849
|
-
} else {
|
|
850
|
-
var operator = '';
|
|
851
|
-
if (attrEqualityMods[chr]) {
|
|
852
|
-
operator = chr;
|
|
853
|
-
pos++;
|
|
854
|
-
chr = str.charAt(pos);
|
|
855
|
-
}
|
|
856
|
-
if (pos >= l) {
|
|
857
|
-
throw Error('Expected "=" but end of file reached.');
|
|
858
|
-
}
|
|
859
|
-
if (chr !== '=') {
|
|
860
|
-
throw Error('Expected "=" but "' + chr + '" found.');
|
|
861
|
-
}
|
|
862
|
-
attr.operator = operator + '=';
|
|
863
|
-
pos++;
|
|
864
|
-
skipWhitespace();
|
|
865
|
-
var attrValue = '';
|
|
866
|
-
attr.valueType = 'string';
|
|
867
|
-
if (chr === '"') {
|
|
868
|
-
attrValue = getStr('"', utils_1.doubleQuotesEscapeChars);
|
|
869
|
-
} else if (chr === '\'') {
|
|
870
|
-
attrValue = getStr('\'', utils_1.singleQuoteEscapeChars);
|
|
871
|
-
} else if (substitutesEnabled && chr === '$') {
|
|
872
|
-
pos++;
|
|
873
|
-
attrValue = getIdent();
|
|
874
|
-
attr.valueType = 'substitute';
|
|
875
|
-
} else {
|
|
876
|
-
while (pos < l) {
|
|
877
|
-
if (chr === ']') {
|
|
878
|
-
break;
|
|
879
|
-
}
|
|
880
|
-
attrValue += chr;
|
|
881
|
-
pos++;
|
|
882
|
-
chr = str.charAt(pos);
|
|
883
|
-
}
|
|
884
|
-
attrValue = attrValue.trim();
|
|
885
|
-
}
|
|
886
|
-
skipWhitespace();
|
|
887
|
-
if (pos >= l) {
|
|
888
|
-
throw Error('Expected "]" but end of file reached.');
|
|
889
|
-
}
|
|
890
|
-
if (chr !== ']') {
|
|
891
|
-
throw Error('Expected "]" but "' + chr + '" found.');
|
|
892
|
-
}
|
|
893
|
-
pos++;
|
|
894
|
-
attr.value = attrValue;
|
|
895
|
-
}
|
|
896
|
-
rule = rule || {};
|
|
897
|
-
(rule.attrs = rule.attrs || []).push(attr);
|
|
898
|
-
} else if (chr === ':') {
|
|
899
|
-
pos++;
|
|
900
|
-
var pseudoName = getIdent();
|
|
901
|
-
var pseudo = {
|
|
902
|
-
name: pseudoName
|
|
903
|
-
};
|
|
904
|
-
if (chr === '(') {
|
|
905
|
-
pos++;
|
|
906
|
-
var value = '';
|
|
907
|
-
skipWhitespace();
|
|
908
|
-
if (pseudos[pseudoName] === 'selector') {
|
|
909
|
-
pseudo.valueType = 'selector';
|
|
910
|
-
value = parseSelector();
|
|
911
|
-
} else {
|
|
912
|
-
pseudo.valueType = pseudos[pseudoName] || 'string';
|
|
913
|
-
if (chr === '"') {
|
|
914
|
-
value = getStr('"', utils_1.doubleQuotesEscapeChars);
|
|
915
|
-
} else if (chr === '\'') {
|
|
916
|
-
value = getStr('\'', utils_1.singleQuoteEscapeChars);
|
|
917
|
-
} else if (substitutesEnabled && chr === '$') {
|
|
918
|
-
pos++;
|
|
919
|
-
value = getIdent();
|
|
920
|
-
pseudo.valueType = 'substitute';
|
|
921
|
-
} else {
|
|
922
|
-
while (pos < l) {
|
|
923
|
-
if (chr === ')') {
|
|
924
|
-
break;
|
|
925
|
-
}
|
|
926
|
-
value += chr;
|
|
927
|
-
pos++;
|
|
928
|
-
chr = str.charAt(pos);
|
|
929
|
-
}
|
|
930
|
-
value = value.trim();
|
|
931
|
-
}
|
|
932
|
-
skipWhitespace();
|
|
933
|
-
}
|
|
934
|
-
if (pos >= l) {
|
|
935
|
-
throw Error('Expected ")" but end of file reached.');
|
|
936
|
-
}
|
|
937
|
-
if (chr !== ')') {
|
|
938
|
-
throw Error('Expected ")" but "' + chr + '" found.');
|
|
939
|
-
}
|
|
940
|
-
pos++;
|
|
941
|
-
pseudo.value = value;
|
|
942
|
-
}
|
|
943
|
-
rule = rule || {};
|
|
944
|
-
(rule.pseudos = rule.pseudos || []).push(pseudo);
|
|
945
|
-
} else {
|
|
946
|
-
break;
|
|
947
|
-
}
|
|
948
|
-
}
|
|
949
|
-
return rule;
|
|
950
|
-
}
|
|
951
|
-
return parse3();
|
|
952
|
-
}
|
|
953
|
-
exports.parseCssSelector = parseCssSelector;
|
|
954
|
-
});
|
|
955
|
-
var require_render = __commonJS(function(exports) {
|
|
956
|
-
'use strict';
|
|
957
|
-
Object.defineProperty(exports, '__esModule', {
|
|
958
|
-
value: true
|
|
959
|
-
});
|
|
960
|
-
var utils_1 = require_utils();
|
|
961
|
-
function renderEntity(entity) {
|
|
962
|
-
var res = '';
|
|
963
|
-
switch (entity.type) {
|
|
964
|
-
case 'ruleSet':
|
|
965
|
-
var currentEntity = entity.rule;
|
|
966
|
-
var parts = [];
|
|
967
|
-
while (currentEntity) {
|
|
968
|
-
if (currentEntity.nestingOperator) {
|
|
969
|
-
parts.push(currentEntity.nestingOperator);
|
|
970
|
-
}
|
|
971
|
-
parts.push(renderEntity(currentEntity));
|
|
972
|
-
currentEntity = currentEntity.rule;
|
|
973
|
-
}
|
|
974
|
-
res = parts.join(' ');
|
|
975
|
-
break;
|
|
976
|
-
|
|
977
|
-
case 'selectors':
|
|
978
|
-
res = entity.selectors.map(renderEntity).join(', ');
|
|
979
|
-
break;
|
|
980
|
-
|
|
981
|
-
case 'rule':
|
|
982
|
-
if (entity.tagName) {
|
|
983
|
-
if (entity.tagName === '*') {
|
|
984
|
-
res = '*';
|
|
985
|
-
} else {
|
|
986
|
-
res = utils_1.escapeIdentifier(entity.tagName);
|
|
987
|
-
}
|
|
988
|
-
}
|
|
989
|
-
if (entity.id) {
|
|
990
|
-
res += '#' + utils_1.escapeIdentifier(entity.id);
|
|
991
|
-
}
|
|
992
|
-
if (entity.classNames) {
|
|
993
|
-
res += entity.classNames.map(function(cn) {
|
|
994
|
-
return '.' + utils_1.escapeIdentifier(cn);
|
|
995
|
-
}).join('');
|
|
996
|
-
}
|
|
997
|
-
if (entity.attrs) {
|
|
998
|
-
res += entity.attrs.map(function(attr) {
|
|
999
|
-
if ('operator' in attr) {
|
|
1000
|
-
if (attr.valueType === 'substitute') {
|
|
1001
|
-
return '[' + utils_1.escapeIdentifier(attr.name) + attr.operator + '$' + attr.value + ']';
|
|
1002
|
-
} else {
|
|
1003
|
-
return '[' + utils_1.escapeIdentifier(attr.name) + attr.operator + utils_1.escapeStr(attr.value) + ']';
|
|
1004
|
-
}
|
|
1005
|
-
} else {
|
|
1006
|
-
return '[' + utils_1.escapeIdentifier(attr.name) + ']';
|
|
1007
|
-
}
|
|
1008
|
-
}).join('');
|
|
1009
|
-
}
|
|
1010
|
-
if (entity.pseudos) {
|
|
1011
|
-
res += entity.pseudos.map(function(pseudo) {
|
|
1012
|
-
if (pseudo.valueType) {
|
|
1013
|
-
if (pseudo.valueType === 'selector') {
|
|
1014
|
-
return ':' + utils_1.escapeIdentifier(pseudo.name) + '(' + renderEntity(pseudo.value) + ')';
|
|
1015
|
-
} else if (pseudo.valueType === 'substitute') {
|
|
1016
|
-
return ':' + utils_1.escapeIdentifier(pseudo.name) + '($' + pseudo.value + ')';
|
|
1017
|
-
} else if (pseudo.valueType === 'numeric') {
|
|
1018
|
-
return ':' + utils_1.escapeIdentifier(pseudo.name) + '(' + pseudo.value + ')';
|
|
1019
|
-
} else {
|
|
1020
|
-
return ':' + utils_1.escapeIdentifier(pseudo.name) + '(' + utils_1.escapeIdentifier(pseudo.value) + ')';
|
|
1021
|
-
}
|
|
1022
|
-
} else {
|
|
1023
|
-
return ':' + utils_1.escapeIdentifier(pseudo.name);
|
|
1024
|
-
}
|
|
1025
|
-
}).join('');
|
|
1026
|
-
}
|
|
1027
|
-
break;
|
|
1028
|
-
|
|
1029
|
-
default:
|
|
1030
|
-
throw Error('Unknown entity type: "' + entity.type + '".');
|
|
1031
|
-
}
|
|
1032
|
-
return res;
|
|
1033
|
-
}
|
|
1034
|
-
exports.renderEntity = renderEntity;
|
|
1035
|
-
});
|
|
1036
|
-
var require_lib = __commonJS(function(exports) {
|
|
1037
|
-
'use strict';
|
|
1038
|
-
Object.defineProperty(exports, '__esModule', {
|
|
1039
|
-
value: true
|
|
1040
|
-
});
|
|
1041
|
-
var parser_context_1 = require_parser_context();
|
|
1042
|
-
var render_1 = require_render();
|
|
1043
|
-
var CssSelectorParser3 = function() {
|
|
1044
|
-
function CssSelectorParser4() {
|
|
1045
|
-
this.pseudos = {};
|
|
1046
|
-
this.attrEqualityMods = {};
|
|
1047
|
-
this.ruleNestingOperators = {};
|
|
1048
|
-
this.substitutesEnabled = false;
|
|
1049
|
-
}
|
|
1050
|
-
CssSelectorParser4.prototype.registerSelectorPseudos = function() {
|
|
1051
|
-
var pseudos = [];
|
|
1052
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
|
1053
|
-
pseudos[_i] = arguments[_i];
|
|
1054
|
-
}
|
|
1055
|
-
for (var _a = 0, pseudos_1 = pseudos; _a < pseudos_1.length; _a++) {
|
|
1056
|
-
var pseudo = pseudos_1[_a];
|
|
1057
|
-
this.pseudos[pseudo] = 'selector';
|
|
1058
|
-
}
|
|
1059
|
-
return this;
|
|
1060
|
-
};
|
|
1061
|
-
CssSelectorParser4.prototype.unregisterSelectorPseudos = function() {
|
|
1062
|
-
var pseudos = [];
|
|
1063
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
|
1064
|
-
pseudos[_i] = arguments[_i];
|
|
1065
|
-
}
|
|
1066
|
-
for (var _a = 0, pseudos_2 = pseudos; _a < pseudos_2.length; _a++) {
|
|
1067
|
-
var pseudo = pseudos_2[_a];
|
|
1068
|
-
delete this.pseudos[pseudo];
|
|
1069
|
-
}
|
|
1070
|
-
return this;
|
|
1071
|
-
};
|
|
1072
|
-
CssSelectorParser4.prototype.registerNumericPseudos = function() {
|
|
1073
|
-
var pseudos = [];
|
|
1074
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
|
1075
|
-
pseudos[_i] = arguments[_i];
|
|
1076
|
-
}
|
|
1077
|
-
for (var _a = 0, pseudos_3 = pseudos; _a < pseudos_3.length; _a++) {
|
|
1078
|
-
var pseudo = pseudos_3[_a];
|
|
1079
|
-
this.pseudos[pseudo] = 'numeric';
|
|
1080
|
-
}
|
|
1081
|
-
return this;
|
|
1082
|
-
};
|
|
1083
|
-
CssSelectorParser4.prototype.unregisterNumericPseudos = function() {
|
|
1084
|
-
var pseudos = [];
|
|
1085
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
|
1086
|
-
pseudos[_i] = arguments[_i];
|
|
1087
|
-
}
|
|
1088
|
-
for (var _a = 0, pseudos_4 = pseudos; _a < pseudos_4.length; _a++) {
|
|
1089
|
-
var pseudo = pseudos_4[_a];
|
|
1090
|
-
delete this.pseudos[pseudo];
|
|
1091
|
-
}
|
|
1092
|
-
return this;
|
|
1093
|
-
};
|
|
1094
|
-
CssSelectorParser4.prototype.registerNestingOperators = function() {
|
|
1095
|
-
var operators = [];
|
|
1096
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
|
1097
|
-
operators[_i] = arguments[_i];
|
|
1098
|
-
}
|
|
1099
|
-
for (var _a = 0, operators_1 = operators; _a < operators_1.length; _a++) {
|
|
1100
|
-
var operator = operators_1[_a];
|
|
1101
|
-
this.ruleNestingOperators[operator] = true;
|
|
1102
|
-
}
|
|
1103
|
-
return this;
|
|
1104
|
-
};
|
|
1105
|
-
CssSelectorParser4.prototype.unregisterNestingOperators = function() {
|
|
1106
|
-
var operators = [];
|
|
1107
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
|
1108
|
-
operators[_i] = arguments[_i];
|
|
1109
|
-
}
|
|
1110
|
-
for (var _a = 0, operators_2 = operators; _a < operators_2.length; _a++) {
|
|
1111
|
-
var operator = operators_2[_a];
|
|
1112
|
-
delete this.ruleNestingOperators[operator];
|
|
1113
|
-
}
|
|
1114
|
-
return this;
|
|
1115
|
-
};
|
|
1116
|
-
CssSelectorParser4.prototype.registerAttrEqualityMods = function() {
|
|
1117
|
-
var mods = [];
|
|
1118
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
|
1119
|
-
mods[_i] = arguments[_i];
|
|
1120
|
-
}
|
|
1121
|
-
for (var _a = 0, mods_1 = mods; _a < mods_1.length; _a++) {
|
|
1122
|
-
var mod = mods_1[_a];
|
|
1123
|
-
this.attrEqualityMods[mod] = true;
|
|
1124
|
-
}
|
|
1125
|
-
return this;
|
|
1126
|
-
};
|
|
1127
|
-
CssSelectorParser4.prototype.unregisterAttrEqualityMods = function() {
|
|
1128
|
-
var mods = [];
|
|
1129
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
|
1130
|
-
mods[_i] = arguments[_i];
|
|
1131
|
-
}
|
|
1132
|
-
for (var _a = 0, mods_2 = mods; _a < mods_2.length; _a++) {
|
|
1133
|
-
var mod = mods_2[_a];
|
|
1134
|
-
delete this.attrEqualityMods[mod];
|
|
1135
|
-
}
|
|
1136
|
-
return this;
|
|
1137
|
-
};
|
|
1138
|
-
CssSelectorParser4.prototype.enableSubstitutes = function() {
|
|
1139
|
-
this.substitutesEnabled = true;
|
|
1140
|
-
return this;
|
|
1141
|
-
};
|
|
1142
|
-
CssSelectorParser4.prototype.disableSubstitutes = function() {
|
|
1143
|
-
this.substitutesEnabled = false;
|
|
1144
|
-
return this;
|
|
1145
|
-
};
|
|
1146
|
-
CssSelectorParser4.prototype.parse = function(str) {
|
|
1147
|
-
return parser_context_1.parseCssSelector(str, 0, this.pseudos, this.attrEqualityMods, this.ruleNestingOperators, this.substitutesEnabled);
|
|
1148
|
-
};
|
|
1149
|
-
CssSelectorParser4.prototype.render = function(path) {
|
|
1150
|
-
return render_1.renderEntity(path).trim();
|
|
1151
|
-
};
|
|
1152
|
-
return CssSelectorParser4;
|
|
1153
|
-
}();
|
|
1154
|
-
exports.CssSelectorParser = CssSelectorParser3;
|
|
1155
|
-
});
|
|
1156
|
-
var require_noop = __commonJS(function(exports, module) {
|
|
1157
|
-
'use strict';
|
|
1158
|
-
module.exports = function() {};
|
|
1159
|
-
});
|
|
1160
|
-
var require_is_value = __commonJS(function(exports, module) {
|
|
1161
|
-
'use strict';
|
|
1162
|
-
var _undefined = require_noop()();
|
|
1163
|
-
module.exports = function(val) {
|
|
1164
|
-
return val !== _undefined && val !== null;
|
|
1165
|
-
};
|
|
1166
|
-
});
|
|
1167
|
-
var require_normalize_options = __commonJS(function(exports, module) {
|
|
1168
|
-
'use strict';
|
|
1169
|
-
var isValue = require_is_value();
|
|
1170
|
-
var forEach = Array.prototype.forEach;
|
|
1171
|
-
var create = Object.create;
|
|
1172
|
-
var process2 = function process2(src, obj) {
|
|
1173
|
-
var key;
|
|
1174
|
-
for (key in src) {
|
|
1175
|
-
obj[key] = src[key];
|
|
1176
|
-
}
|
|
1177
|
-
};
|
|
1178
|
-
module.exports = function(opts1) {
|
|
1179
|
-
var result = create(null);
|
|
1180
|
-
forEach.call(arguments, function(options) {
|
|
1181
|
-
if (!isValue(options)) {
|
|
1182
|
-
return;
|
|
1183
|
-
}
|
|
1184
|
-
process2(Object(options), result);
|
|
1185
|
-
});
|
|
1186
|
-
return result;
|
|
1187
|
-
};
|
|
1188
|
-
});
|
|
1189
|
-
var require_is_implemented = __commonJS(function(exports, module) {
|
|
1190
|
-
'use strict';
|
|
1191
|
-
module.exports = function() {
|
|
1192
|
-
var sign = Math.sign;
|
|
1193
|
-
if (typeof sign !== 'function') {
|
|
1194
|
-
return false;
|
|
1195
|
-
}
|
|
1196
|
-
return sign(10) === 1 && sign(-20) === -1;
|
|
1197
|
-
};
|
|
1198
|
-
});
|
|
1199
|
-
var require_shim = __commonJS(function(exports, module) {
|
|
1200
|
-
'use strict';
|
|
1201
|
-
module.exports = function(value) {
|
|
1202
|
-
value = Number(value);
|
|
1203
|
-
if (isNaN(value) || value === 0) {
|
|
1204
|
-
return value;
|
|
1205
|
-
}
|
|
1206
|
-
return value > 0 ? 1 : -1;
|
|
1207
|
-
};
|
|
1208
|
-
});
|
|
1209
|
-
var require_sign = __commonJS(function(exports, module) {
|
|
1210
|
-
'use strict';
|
|
1211
|
-
module.exports = require_is_implemented()() ? Math.sign : require_shim();
|
|
1212
|
-
});
|
|
1213
|
-
var require_to_integer = __commonJS(function(exports, module) {
|
|
1214
|
-
'use strict';
|
|
1215
|
-
var sign = require_sign();
|
|
1216
|
-
var abs = Math.abs;
|
|
1217
|
-
var floor = Math.floor;
|
|
1218
|
-
module.exports = function(value) {
|
|
1219
|
-
if (isNaN(value)) {
|
|
1220
|
-
return 0;
|
|
1221
|
-
}
|
|
1222
|
-
value = Number(value);
|
|
1223
|
-
if (value === 0 || !isFinite(value)) {
|
|
1224
|
-
return value;
|
|
1225
|
-
}
|
|
1226
|
-
return sign(value) * floor(abs(value));
|
|
1227
|
-
};
|
|
1228
|
-
});
|
|
1229
|
-
var require_to_pos_integer = __commonJS(function(exports, module) {
|
|
1230
|
-
'use strict';
|
|
1231
|
-
var toInteger = require_to_integer();
|
|
1232
|
-
var max2 = Math.max;
|
|
1233
|
-
module.exports = function(value) {
|
|
1234
|
-
return max2(0, toInteger(value));
|
|
1235
|
-
};
|
|
1236
|
-
});
|
|
1237
|
-
var require_resolve_length = __commonJS(function(exports, module) {
|
|
1238
|
-
'use strict';
|
|
1239
|
-
var toPosInt = require_to_pos_integer();
|
|
1240
|
-
module.exports = function(optsLength, fnLength, isAsync) {
|
|
1241
|
-
var length;
|
|
1242
|
-
if (isNaN(optsLength)) {
|
|
1243
|
-
length = fnLength;
|
|
1244
|
-
if (!(length >= 0)) {
|
|
1245
|
-
return 1;
|
|
1246
|
-
}
|
|
1247
|
-
if (isAsync && length) {
|
|
1248
|
-
return length - 1;
|
|
1249
|
-
}
|
|
1250
|
-
return length;
|
|
1251
|
-
}
|
|
1252
|
-
if (optsLength === false) {
|
|
1253
|
-
return false;
|
|
1254
|
-
}
|
|
1255
|
-
return toPosInt(optsLength);
|
|
1256
|
-
};
|
|
1257
|
-
});
|
|
1258
|
-
var require_valid_callable = __commonJS(function(exports, module) {
|
|
1259
|
-
'use strict';
|
|
1260
|
-
module.exports = function(fn) {
|
|
1261
|
-
if (typeof fn !== 'function') {
|
|
1262
|
-
throw new TypeError(fn + ' is not a function');
|
|
1263
|
-
}
|
|
1264
|
-
return fn;
|
|
1265
|
-
};
|
|
1266
|
-
});
|
|
1267
|
-
var require_valid_value = __commonJS(function(exports, module) {
|
|
1268
|
-
'use strict';
|
|
1269
|
-
var isValue = require_is_value();
|
|
1270
|
-
module.exports = function(value) {
|
|
1271
|
-
if (!isValue(value)) {
|
|
1272
|
-
throw new TypeError('Cannot use null or undefined');
|
|
1273
|
-
}
|
|
1274
|
-
return value;
|
|
1275
|
-
};
|
|
1276
|
-
});
|
|
1277
|
-
var require_iterate = __commonJS(function(exports, module) {
|
|
1278
|
-
'use strict';
|
|
1279
|
-
var callable = require_valid_callable();
|
|
1280
|
-
var value = require_valid_value();
|
|
1281
|
-
var bind = Function.prototype.bind;
|
|
1282
|
-
var call = Function.prototype.call;
|
|
1283
|
-
var keys = Object.keys;
|
|
1284
|
-
var objPropertyIsEnumerable = Object.prototype.propertyIsEnumerable;
|
|
1285
|
-
module.exports = function(method, defVal) {
|
|
1286
|
-
return function(obj, cb) {
|
|
1287
|
-
var list, thisArg = arguments[2], compareFn = arguments[3];
|
|
1288
|
-
obj = Object(value(obj));
|
|
1289
|
-
callable(cb);
|
|
1290
|
-
list = keys(obj);
|
|
1291
|
-
if (compareFn) {
|
|
1292
|
-
list.sort(typeof compareFn === 'function' ? bind.call(compareFn, obj) : void 0);
|
|
1293
|
-
}
|
|
1294
|
-
if (typeof method !== 'function') {
|
|
1295
|
-
method = list[method];
|
|
1296
|
-
}
|
|
1297
|
-
return call.call(method, list, function(key, index) {
|
|
1298
|
-
if (!objPropertyIsEnumerable.call(obj, key)) {
|
|
1299
|
-
return defVal;
|
|
1300
|
-
}
|
|
1301
|
-
return call.call(cb, thisArg, obj[key], key, obj, index);
|
|
1302
|
-
});
|
|
1303
|
-
};
|
|
1304
|
-
};
|
|
1305
|
-
});
|
|
1306
|
-
var require_for_each = __commonJS(function(exports, module) {
|
|
1307
|
-
'use strict';
|
|
1308
|
-
module.exports = require_iterate()('forEach');
|
|
1309
|
-
});
|
|
1310
|
-
var require_registered_extensions = __commonJS(function() {
|
|
1311
|
-
'use strict';
|
|
1312
|
-
});
|
|
1313
|
-
var require_is_implemented2 = __commonJS(function(exports, module) {
|
|
1314
|
-
'use strict';
|
|
1315
|
-
module.exports = function() {
|
|
1316
|
-
var assign = Object.assign, obj;
|
|
1317
|
-
if (typeof assign !== 'function') {
|
|
1318
|
-
return false;
|
|
1319
|
-
}
|
|
1320
|
-
obj = {
|
|
1321
|
-
foo: 'raz'
|
|
1322
|
-
};
|
|
1323
|
-
assign(obj, {
|
|
1324
|
-
bar: 'dwa'
|
|
1325
|
-
}, {
|
|
1326
|
-
trzy: 'trzy'
|
|
1327
|
-
});
|
|
1328
|
-
return obj.foo + obj.bar + obj.trzy === 'razdwatrzy';
|
|
1329
|
-
};
|
|
1330
|
-
});
|
|
1331
|
-
var require_is_implemented3 = __commonJS(function(exports, module) {
|
|
1332
|
-
'use strict';
|
|
1333
|
-
module.exports = function() {
|
|
1334
|
-
try {
|
|
1335
|
-
Object.keys('primitive');
|
|
1336
|
-
return true;
|
|
1337
|
-
} catch (e) {
|
|
1338
|
-
return false;
|
|
1339
|
-
}
|
|
1340
|
-
};
|
|
1341
|
-
});
|
|
1342
|
-
var require_shim2 = __commonJS(function(exports, module) {
|
|
1343
|
-
'use strict';
|
|
1344
|
-
var isValue = require_is_value();
|
|
1345
|
-
var keys = Object.keys;
|
|
1346
|
-
module.exports = function(object) {
|
|
1347
|
-
return keys(isValue(object) ? Object(object) : object);
|
|
1348
|
-
};
|
|
1349
|
-
});
|
|
1350
|
-
var require_keys = __commonJS(function(exports, module) {
|
|
1351
|
-
'use strict';
|
|
1352
|
-
module.exports = require_is_implemented3()() ? Object.keys : require_shim2();
|
|
1353
|
-
});
|
|
1354
|
-
var require_shim3 = __commonJS(function(exports, module) {
|
|
1355
|
-
'use strict';
|
|
1356
|
-
var keys = require_keys();
|
|
1357
|
-
var value = require_valid_value();
|
|
1358
|
-
var max2 = Math.max;
|
|
1359
|
-
module.exports = function(dest, src) {
|
|
1360
|
-
var error, i, length = max2(arguments.length, 2), assign;
|
|
1361
|
-
dest = Object(value(dest));
|
|
1362
|
-
assign = function assign(key) {
|
|
1363
|
-
try {
|
|
1364
|
-
dest[key] = src[key];
|
|
1365
|
-
} catch (e) {
|
|
1366
|
-
if (!error) {
|
|
1367
|
-
error = e;
|
|
1368
|
-
}
|
|
1369
|
-
}
|
|
1370
|
-
};
|
|
1371
|
-
for (i = 1; i < length; ++i) {
|
|
1372
|
-
src = arguments[i];
|
|
1373
|
-
keys(src).forEach(assign);
|
|
1374
|
-
}
|
|
1375
|
-
if (error !== void 0) {
|
|
1376
|
-
throw error;
|
|
1377
|
-
}
|
|
1378
|
-
return dest;
|
|
1379
|
-
};
|
|
1380
|
-
});
|
|
1381
|
-
var require_assign = __commonJS(function(exports, module) {
|
|
1382
|
-
'use strict';
|
|
1383
|
-
module.exports = require_is_implemented2()() ? Object.assign : require_shim3();
|
|
1384
|
-
});
|
|
1385
|
-
var require_is_object = __commonJS(function(exports, module) {
|
|
1386
|
-
'use strict';
|
|
1387
|
-
var isValue = require_is_value();
|
|
1388
|
-
var map = {
|
|
1389
|
-
function: true,
|
|
1390
|
-
object: true
|
|
1391
|
-
};
|
|
1392
|
-
module.exports = function(value) {
|
|
1393
|
-
return isValue(value) && map[_typeof(value)] || false;
|
|
1394
|
-
};
|
|
1395
|
-
});
|
|
1396
|
-
var require_custom = __commonJS(function(exports, module) {
|
|
1397
|
-
'use strict';
|
|
1398
|
-
var assign = require_assign();
|
|
1399
|
-
var isObject = require_is_object();
|
|
1400
|
-
var isValue = require_is_value();
|
|
1401
|
-
var captureStackTrace = Error.captureStackTrace;
|
|
1402
|
-
module.exports = function(message) {
|
|
1403
|
-
var err2 = new Error(message), code = arguments[1], ext = arguments[2];
|
|
1404
|
-
if (!isValue(ext)) {
|
|
1405
|
-
if (isObject(code)) {
|
|
1406
|
-
ext = code;
|
|
1407
|
-
code = null;
|
|
754
|
+
if (error !== void 0) {
|
|
755
|
+
throw error;
|
|
756
|
+
}
|
|
757
|
+
return dest;
|
|
758
|
+
};
|
|
759
|
+
});
|
|
760
|
+
var require_assign = __commonJS(function(exports, module) {
|
|
761
|
+
'use strict';
|
|
762
|
+
module.exports = require_is_implemented2()() ? Object.assign : require_shim3();
|
|
763
|
+
});
|
|
764
|
+
var require_is_object = __commonJS(function(exports, module) {
|
|
765
|
+
'use strict';
|
|
766
|
+
var isValue = require_is_value();
|
|
767
|
+
var map = {
|
|
768
|
+
function: true,
|
|
769
|
+
object: true
|
|
770
|
+
};
|
|
771
|
+
module.exports = function(value) {
|
|
772
|
+
return isValue(value) && map[_typeof(value)] || false;
|
|
773
|
+
};
|
|
774
|
+
});
|
|
775
|
+
var require_custom = __commonJS(function(exports, module) {
|
|
776
|
+
'use strict';
|
|
777
|
+
var assign = require_assign();
|
|
778
|
+
var isObject = require_is_object();
|
|
779
|
+
var isValue = require_is_value();
|
|
780
|
+
var captureStackTrace = Error.captureStackTrace;
|
|
781
|
+
module.exports = function(message) {
|
|
782
|
+
var err2 = new Error(message), code = arguments[1], ext = arguments[2];
|
|
783
|
+
if (!isValue(ext)) {
|
|
784
|
+
if (isObject(code)) {
|
|
785
|
+
ext = code;
|
|
786
|
+
code = null;
|
|
1408
787
|
}
|
|
1409
788
|
}
|
|
1410
789
|
if (isValue(ext)) {
|
|
@@ -1707,21 +1086,21 @@
|
|
|
1707
1086
|
var descriptors;
|
|
1708
1087
|
var base;
|
|
1709
1088
|
on = function on(type2, listener) {
|
|
1710
|
-
var
|
|
1089
|
+
var data;
|
|
1711
1090
|
callable(listener);
|
|
1712
1091
|
if (!hasOwnProperty2.call(this, '__ee__')) {
|
|
1713
|
-
|
|
1092
|
+
data = descriptor.value = create(null);
|
|
1714
1093
|
defineProperty(this, '__ee__', descriptor);
|
|
1715
1094
|
descriptor.value = null;
|
|
1716
1095
|
} else {
|
|
1717
|
-
|
|
1096
|
+
data = this.__ee__;
|
|
1718
1097
|
}
|
|
1719
|
-
if (!
|
|
1720
|
-
|
|
1721
|
-
} else if (_typeof(
|
|
1722
|
-
|
|
1098
|
+
if (!data[type2]) {
|
|
1099
|
+
data[type2] = listener;
|
|
1100
|
+
} else if (_typeof(data[type2]) === 'object') {
|
|
1101
|
+
data[type2].push(listener);
|
|
1723
1102
|
} else {
|
|
1724
|
-
|
|
1103
|
+
data[type2] = [ data[type2], listener ];
|
|
1725
1104
|
}
|
|
1726
1105
|
return this;
|
|
1727
1106
|
};
|
|
@@ -1737,21 +1116,21 @@
|
|
|
1737
1116
|
return this;
|
|
1738
1117
|
};
|
|
1739
1118
|
off = function off(type2, listener) {
|
|
1740
|
-
var
|
|
1119
|
+
var data, listeners, candidate, i;
|
|
1741
1120
|
callable(listener);
|
|
1742
1121
|
if (!hasOwnProperty2.call(this, '__ee__')) {
|
|
1743
1122
|
return this;
|
|
1744
1123
|
}
|
|
1745
|
-
|
|
1746
|
-
if (!
|
|
1124
|
+
data = this.__ee__;
|
|
1125
|
+
if (!data[type2]) {
|
|
1747
1126
|
return this;
|
|
1748
1127
|
}
|
|
1749
|
-
listeners =
|
|
1128
|
+
listeners = data[type2];
|
|
1750
1129
|
if (_typeof(listeners) === 'object') {
|
|
1751
1130
|
for (i = 0; candidate = listeners[i]; ++i) {
|
|
1752
1131
|
if (candidate === listener || candidate.__eeOnceListener__ === listener) {
|
|
1753
1132
|
if (listeners.length === 2) {
|
|
1754
|
-
|
|
1133
|
+
data[type2] = listeners[i ? 0 : 1];
|
|
1755
1134
|
} else {
|
|
1756
1135
|
listeners.splice(i, 1);
|
|
1757
1136
|
}
|
|
@@ -1759,7 +1138,7 @@
|
|
|
1759
1138
|
}
|
|
1760
1139
|
} else {
|
|
1761
1140
|
if (listeners === listener || listeners.__eeOnceListener__ === listener) {
|
|
1762
|
-
delete
|
|
1141
|
+
delete data[type2];
|
|
1763
1142
|
}
|
|
1764
1143
|
}
|
|
1765
1144
|
return this;
|
|
@@ -2986,11 +2365,11 @@
|
|
|
2986
2365
|
args = currentArgs;
|
|
2987
2366
|
currentCallback = currentContext = currentArgs = null;
|
|
2988
2367
|
nextTick(function() {
|
|
2989
|
-
var
|
|
2368
|
+
var data;
|
|
2990
2369
|
if (hasOwnProperty.call(cache2, id)) {
|
|
2991
|
-
|
|
2370
|
+
data = cache2[id];
|
|
2992
2371
|
conf.emit('getasync', id, args, context);
|
|
2993
|
-
apply.call(cb,
|
|
2372
|
+
apply.call(cb, data.context, data.args);
|
|
2994
2373
|
} else {
|
|
2995
2374
|
currentCallback = cb;
|
|
2996
2375
|
currentContext = context;
|
|
@@ -3011,615 +2390,1236 @@
|
|
|
3011
2390
|
nextTick(apply.bind(self2, this, arguments));
|
|
3012
2391
|
return void 0;
|
|
3013
2392
|
}
|
|
3014
|
-
delete self2.id;
|
|
3015
|
-
cb2 = waiting[id];
|
|
2393
|
+
delete self2.id;
|
|
2394
|
+
cb2 = waiting[id];
|
|
2395
|
+
delete waiting[id];
|
|
2396
|
+
if (!cb2) {
|
|
2397
|
+
return void 0;
|
|
2398
|
+
}
|
|
2399
|
+
args2 = aFrom(arguments);
|
|
2400
|
+
if (conf.has(id)) {
|
|
2401
|
+
if (err2) {
|
|
2402
|
+
conf['delete'](id);
|
|
2403
|
+
} else {
|
|
2404
|
+
cache2[id] = {
|
|
2405
|
+
context: this,
|
|
2406
|
+
args: args2
|
|
2407
|
+
};
|
|
2408
|
+
conf.emit('setasync', id, typeof cb2 === 'function' ? 1 : cb2.length);
|
|
2409
|
+
}
|
|
2410
|
+
}
|
|
2411
|
+
if (typeof cb2 === 'function') {
|
|
2412
|
+
result = apply.call(cb2, this, args2);
|
|
2413
|
+
} else {
|
|
2414
|
+
cb2.forEach(function(cb3) {
|
|
2415
|
+
result = apply.call(cb3, this, args2);
|
|
2416
|
+
}, this);
|
|
2417
|
+
}
|
|
2418
|
+
return result;
|
|
2419
|
+
};
|
|
2420
|
+
origCb = currentCallback;
|
|
2421
|
+
currentCallback = currentContext = currentArgs = null;
|
|
2422
|
+
args.push(cb);
|
|
2423
|
+
result = apply.call(original, this, args);
|
|
2424
|
+
cb.cb = origCb;
|
|
2425
|
+
currentCallback = cb;
|
|
2426
|
+
return result;
|
|
2427
|
+
};
|
|
2428
|
+
conf.on('set', function(id) {
|
|
2429
|
+
if (!currentCallback) {
|
|
2430
|
+
conf['delete'](id);
|
|
2431
|
+
return;
|
|
2432
|
+
}
|
|
2433
|
+
if (waiting[id]) {
|
|
2434
|
+
if (typeof waiting[id] === 'function') {
|
|
2435
|
+
waiting[id] = [ waiting[id], currentCallback.cb ];
|
|
2436
|
+
} else {
|
|
2437
|
+
waiting[id].push(currentCallback.cb);
|
|
2438
|
+
}
|
|
2439
|
+
} else {
|
|
2440
|
+
waiting[id] = currentCallback.cb;
|
|
2441
|
+
}
|
|
2442
|
+
delete currentCallback.cb;
|
|
2443
|
+
currentCallback.id = id;
|
|
2444
|
+
currentCallback = null;
|
|
2445
|
+
});
|
|
2446
|
+
conf.on('delete', function(id) {
|
|
2447
|
+
var result;
|
|
2448
|
+
if (hasOwnProperty.call(waiting, id)) {
|
|
2449
|
+
return;
|
|
2450
|
+
}
|
|
2451
|
+
if (!cache2[id]) {
|
|
2452
|
+
return;
|
|
2453
|
+
}
|
|
2454
|
+
result = cache2[id];
|
|
2455
|
+
delete cache2[id];
|
|
2456
|
+
conf.emit('deleteasync', id, slice.call(result.args, 1));
|
|
2457
|
+
});
|
|
2458
|
+
conf.on('clear', function() {
|
|
2459
|
+
var oldCache = cache2;
|
|
2460
|
+
cache2 = create(null);
|
|
2461
|
+
conf.emit('clearasync', objectMap(oldCache, function(data) {
|
|
2462
|
+
return slice.call(data.args, 1);
|
|
2463
|
+
}));
|
|
2464
|
+
});
|
|
2465
|
+
};
|
|
2466
|
+
});
|
|
2467
|
+
var require_primitive_set = __commonJS(function(exports, module) {
|
|
2468
|
+
'use strict';
|
|
2469
|
+
var forEach = Array.prototype.forEach;
|
|
2470
|
+
var create = Object.create;
|
|
2471
|
+
module.exports = function(arg) {
|
|
2472
|
+
var set2 = create(null);
|
|
2473
|
+
forEach.call(arguments, function(name) {
|
|
2474
|
+
set2[name] = true;
|
|
2475
|
+
});
|
|
2476
|
+
return set2;
|
|
2477
|
+
};
|
|
2478
|
+
});
|
|
2479
|
+
var require_is_callable = __commonJS(function(exports, module) {
|
|
2480
|
+
'use strict';
|
|
2481
|
+
module.exports = function(obj) {
|
|
2482
|
+
return typeof obj === 'function';
|
|
2483
|
+
};
|
|
2484
|
+
});
|
|
2485
|
+
var require_validate_stringifiable = __commonJS(function(exports, module) {
|
|
2486
|
+
'use strict';
|
|
2487
|
+
var isCallable = require_is_callable();
|
|
2488
|
+
module.exports = function(stringifiable) {
|
|
2489
|
+
try {
|
|
2490
|
+
if (stringifiable && isCallable(stringifiable.toString)) {
|
|
2491
|
+
return stringifiable.toString();
|
|
2492
|
+
}
|
|
2493
|
+
return String(stringifiable);
|
|
2494
|
+
} catch (e) {
|
|
2495
|
+
throw new TypeError('Passed argument cannot be stringifed');
|
|
2496
|
+
}
|
|
2497
|
+
};
|
|
2498
|
+
});
|
|
2499
|
+
var require_validate_stringifiable_value = __commonJS(function(exports, module) {
|
|
2500
|
+
'use strict';
|
|
2501
|
+
var ensureValue = require_valid_value();
|
|
2502
|
+
var stringifiable = require_validate_stringifiable();
|
|
2503
|
+
module.exports = function(value) {
|
|
2504
|
+
return stringifiable(ensureValue(value));
|
|
2505
|
+
};
|
|
2506
|
+
});
|
|
2507
|
+
var require_safe_to_string = __commonJS(function(exports, module) {
|
|
2508
|
+
'use strict';
|
|
2509
|
+
var isCallable = require_is_callable();
|
|
2510
|
+
module.exports = function(value) {
|
|
2511
|
+
try {
|
|
2512
|
+
if (value && isCallable(value.toString)) {
|
|
2513
|
+
return value.toString();
|
|
2514
|
+
}
|
|
2515
|
+
return String(value);
|
|
2516
|
+
} catch (e) {
|
|
2517
|
+
return '<Non-coercible to string value>';
|
|
2518
|
+
}
|
|
2519
|
+
};
|
|
2520
|
+
});
|
|
2521
|
+
var require_to_short_string_representation = __commonJS(function(exports, module) {
|
|
2522
|
+
'use strict';
|
|
2523
|
+
var safeToString = require_safe_to_string();
|
|
2524
|
+
var reNewLine = /[\n\r\u2028\u2029]/g;
|
|
2525
|
+
module.exports = function(value) {
|
|
2526
|
+
var string = safeToString(value);
|
|
2527
|
+
if (string.length > 100) {
|
|
2528
|
+
string = string.slice(0, 99) + '\u2026';
|
|
2529
|
+
}
|
|
2530
|
+
string = string.replace(reNewLine, function(_char) {
|
|
2531
|
+
return JSON.stringify(_char).slice(1, -1);
|
|
2532
|
+
});
|
|
2533
|
+
return string;
|
|
2534
|
+
};
|
|
2535
|
+
});
|
|
2536
|
+
var require_is_promise = __commonJS(function(exports, module) {
|
|
2537
|
+
module.exports = isPromise;
|
|
2538
|
+
module.exports['default'] = isPromise;
|
|
2539
|
+
function isPromise(obj) {
|
|
2540
|
+
return !!obj && (_typeof(obj) === 'object' || typeof obj === 'function') && typeof obj.then === 'function';
|
|
2541
|
+
}
|
|
2542
|
+
});
|
|
2543
|
+
var require_promise = __commonJS(function() {
|
|
2544
|
+
'use strict';
|
|
2545
|
+
var objectMap = require_map();
|
|
2546
|
+
var primitiveSet = require_primitive_set();
|
|
2547
|
+
var ensureString = require_validate_stringifiable_value();
|
|
2548
|
+
var toShortString = require_to_short_string_representation();
|
|
2549
|
+
var isPromise = require_is_promise();
|
|
2550
|
+
var nextTick = require_next_tick();
|
|
2551
|
+
var create = Object.create;
|
|
2552
|
+
var supportedModes = primitiveSet('then', 'then:finally', 'done', 'done:finally');
|
|
2553
|
+
require_registered_extensions().promise = function(mode, conf) {
|
|
2554
|
+
var waiting = create(null), cache2 = create(null), promises = create(null);
|
|
2555
|
+
if (mode === true) {
|
|
2556
|
+
mode = null;
|
|
2557
|
+
} else {
|
|
2558
|
+
mode = ensureString(mode);
|
|
2559
|
+
if (!supportedModes[mode]) {
|
|
2560
|
+
throw new TypeError('\'' + toShortString(mode) + '\' is not valid promise mode');
|
|
2561
|
+
}
|
|
2562
|
+
}
|
|
2563
|
+
conf.on('set', function(id, ignore, promise) {
|
|
2564
|
+
var isFailed = false;
|
|
2565
|
+
if (!isPromise(promise)) {
|
|
2566
|
+
cache2[id] = promise;
|
|
2567
|
+
conf.emit('setasync', id, 1);
|
|
2568
|
+
return;
|
|
2569
|
+
}
|
|
2570
|
+
waiting[id] = 1;
|
|
2571
|
+
promises[id] = promise;
|
|
2572
|
+
var onSuccess = function onSuccess(result) {
|
|
2573
|
+
var count = waiting[id];
|
|
2574
|
+
if (isFailed) {
|
|
2575
|
+
throw new Error('Memoizee error: Detected unordered then|done & finally resolution, which in turn makes proper detection of success/failure impossible (when in \'done:finally\' mode)\nConsider to rely on \'then\' or \'done\' mode instead.');
|
|
2576
|
+
}
|
|
2577
|
+
if (!count) {
|
|
2578
|
+
return;
|
|
2579
|
+
}
|
|
2580
|
+
delete waiting[id];
|
|
2581
|
+
cache2[id] = result;
|
|
2582
|
+
conf.emit('setasync', id, count);
|
|
2583
|
+
};
|
|
2584
|
+
var onFailure = function onFailure() {
|
|
2585
|
+
isFailed = true;
|
|
2586
|
+
if (!waiting[id]) {
|
|
2587
|
+
return;
|
|
2588
|
+
}
|
|
3016
2589
|
delete waiting[id];
|
|
3017
|
-
|
|
3018
|
-
|
|
2590
|
+
delete promises[id];
|
|
2591
|
+
conf['delete'](id);
|
|
2592
|
+
};
|
|
2593
|
+
var resolvedMode = mode;
|
|
2594
|
+
if (!resolvedMode) {
|
|
2595
|
+
resolvedMode = 'then';
|
|
2596
|
+
}
|
|
2597
|
+
if (resolvedMode === 'then') {
|
|
2598
|
+
var nextTickFailure = function nextTickFailure() {
|
|
2599
|
+
nextTick(onFailure);
|
|
2600
|
+
};
|
|
2601
|
+
promise = promise.then(function(result) {
|
|
2602
|
+
nextTick(onSuccess.bind(this, result));
|
|
2603
|
+
}, nextTickFailure);
|
|
2604
|
+
if (typeof promise['finally'] === 'function') {
|
|
2605
|
+
promise['finally'](nextTickFailure);
|
|
3019
2606
|
}
|
|
3020
|
-
|
|
3021
|
-
if (
|
|
3022
|
-
|
|
3023
|
-
conf['delete'](id);
|
|
3024
|
-
} else {
|
|
3025
|
-
cache2[id] = {
|
|
3026
|
-
context: this,
|
|
3027
|
-
args: args2
|
|
3028
|
-
};
|
|
3029
|
-
conf.emit('setasync', id, typeof cb2 === 'function' ? 1 : cb2.length);
|
|
3030
|
-
}
|
|
2607
|
+
} else if (resolvedMode === 'done') {
|
|
2608
|
+
if (typeof promise.done !== 'function') {
|
|
2609
|
+
throw new Error('Memoizee error: Retrieved promise does not implement \'done\' in \'done\' mode');
|
|
3031
2610
|
}
|
|
3032
|
-
|
|
3033
|
-
|
|
3034
|
-
|
|
3035
|
-
|
|
3036
|
-
result = apply.call(cb3, this, args2);
|
|
3037
|
-
}, this);
|
|
2611
|
+
promise.done(onSuccess, onFailure);
|
|
2612
|
+
} else if (resolvedMode === 'done:finally') {
|
|
2613
|
+
if (typeof promise.done !== 'function') {
|
|
2614
|
+
throw new Error('Memoizee error: Retrieved promise does not implement \'done\' in \'done:finally\' mode');
|
|
3038
2615
|
}
|
|
3039
|
-
|
|
3040
|
-
|
|
3041
|
-
|
|
3042
|
-
|
|
3043
|
-
|
|
3044
|
-
result = apply.call(original, this, args);
|
|
3045
|
-
cb.cb = origCb;
|
|
3046
|
-
currentCallback = cb;
|
|
3047
|
-
return result;
|
|
3048
|
-
};
|
|
3049
|
-
conf.on('set', function(id) {
|
|
3050
|
-
if (!currentCallback) {
|
|
3051
|
-
conf['delete'](id);
|
|
3052
|
-
return;
|
|
2616
|
+
if (typeof promise['finally'] !== 'function') {
|
|
2617
|
+
throw new Error('Memoizee error: Retrieved promise does not implement \'finally\' in \'done:finally\' mode');
|
|
2618
|
+
}
|
|
2619
|
+
promise.done(onSuccess);
|
|
2620
|
+
promise['finally'](onFailure);
|
|
3053
2621
|
}
|
|
2622
|
+
});
|
|
2623
|
+
conf.on('get', function(id, args, context) {
|
|
2624
|
+
var promise;
|
|
3054
2625
|
if (waiting[id]) {
|
|
3055
|
-
|
|
3056
|
-
|
|
2626
|
+
++waiting[id];
|
|
2627
|
+
return;
|
|
2628
|
+
}
|
|
2629
|
+
promise = promises[id];
|
|
2630
|
+
var emit = function emit() {
|
|
2631
|
+
conf.emit('getasync', id, args, context);
|
|
2632
|
+
};
|
|
2633
|
+
if (isPromise(promise)) {
|
|
2634
|
+
if (typeof promise.done === 'function') {
|
|
2635
|
+
promise.done(emit);
|
|
3057
2636
|
} else {
|
|
3058
|
-
|
|
2637
|
+
promise.then(function() {
|
|
2638
|
+
nextTick(emit);
|
|
2639
|
+
});
|
|
3059
2640
|
}
|
|
3060
2641
|
} else {
|
|
3061
|
-
|
|
2642
|
+
emit();
|
|
3062
2643
|
}
|
|
3063
|
-
delete currentCallback.cb;
|
|
3064
|
-
currentCallback.id = id;
|
|
3065
|
-
currentCallback = null;
|
|
3066
2644
|
});
|
|
3067
2645
|
conf.on('delete', function(id) {
|
|
3068
|
-
|
|
3069
|
-
if (
|
|
2646
|
+
delete promises[id];
|
|
2647
|
+
if (waiting[id]) {
|
|
2648
|
+
delete waiting[id];
|
|
3070
2649
|
return;
|
|
3071
2650
|
}
|
|
3072
|
-
if (!cache2
|
|
2651
|
+
if (!hasOwnProperty.call(cache2, id)) {
|
|
3073
2652
|
return;
|
|
3074
2653
|
}
|
|
3075
|
-
result = cache2[id];
|
|
2654
|
+
var result = cache2[id];
|
|
3076
2655
|
delete cache2[id];
|
|
3077
|
-
conf.emit('deleteasync', id,
|
|
2656
|
+
conf.emit('deleteasync', id, [ result ]);
|
|
3078
2657
|
});
|
|
3079
2658
|
conf.on('clear', function() {
|
|
3080
2659
|
var oldCache = cache2;
|
|
3081
2660
|
cache2 = create(null);
|
|
3082
|
-
|
|
3083
|
-
|
|
2661
|
+
waiting = create(null);
|
|
2662
|
+
promises = create(null);
|
|
2663
|
+
conf.emit('clearasync', objectMap(oldCache, function(data) {
|
|
2664
|
+
return [ data ];
|
|
3084
2665
|
}));
|
|
3085
2666
|
});
|
|
3086
2667
|
};
|
|
3087
2668
|
});
|
|
3088
|
-
var
|
|
2669
|
+
var require_dispose = __commonJS(function() {
|
|
3089
2670
|
'use strict';
|
|
3090
|
-
var
|
|
3091
|
-
var
|
|
3092
|
-
|
|
3093
|
-
|
|
3094
|
-
|
|
3095
|
-
|
|
2671
|
+
var callable = require_valid_callable();
|
|
2672
|
+
var forEach = require_for_each();
|
|
2673
|
+
var extensions = require_registered_extensions();
|
|
2674
|
+
var apply = Function.prototype.apply;
|
|
2675
|
+
extensions.dispose = function(dispose, conf, options) {
|
|
2676
|
+
var del;
|
|
2677
|
+
callable(dispose);
|
|
2678
|
+
if (options.async && extensions.async || options.promise && extensions.promise) {
|
|
2679
|
+
conf.on('deleteasync', del = function del(id, resultArray) {
|
|
2680
|
+
apply.call(dispose, null, resultArray);
|
|
2681
|
+
});
|
|
2682
|
+
conf.on('clearasync', function(cache2) {
|
|
2683
|
+
forEach(cache2, function(result, id) {
|
|
2684
|
+
del(id, result);
|
|
2685
|
+
});
|
|
2686
|
+
});
|
|
2687
|
+
return;
|
|
2688
|
+
}
|
|
2689
|
+
conf.on('delete', del = function del(id, result) {
|
|
2690
|
+
dispose(result);
|
|
2691
|
+
});
|
|
2692
|
+
conf.on('clear', function(cache2) {
|
|
2693
|
+
forEach(cache2, function(result, id) {
|
|
2694
|
+
del(id, result);
|
|
2695
|
+
});
|
|
3096
2696
|
});
|
|
3097
|
-
return set2;
|
|
3098
|
-
};
|
|
3099
|
-
});
|
|
3100
|
-
var require_is_callable = __commonJS(function(exports, module) {
|
|
3101
|
-
'use strict';
|
|
3102
|
-
module.exports = function(obj) {
|
|
3103
|
-
return typeof obj === 'function';
|
|
3104
2697
|
};
|
|
3105
2698
|
});
|
|
3106
|
-
var
|
|
2699
|
+
var require_max_timeout = __commonJS(function(exports, module) {
|
|
3107
2700
|
'use strict';
|
|
3108
|
-
|
|
3109
|
-
module.exports = function(stringifiable) {
|
|
3110
|
-
try {
|
|
3111
|
-
if (stringifiable && isCallable(stringifiable.toString)) {
|
|
3112
|
-
return stringifiable.toString();
|
|
3113
|
-
}
|
|
3114
|
-
return String(stringifiable);
|
|
3115
|
-
} catch (e) {
|
|
3116
|
-
throw new TypeError('Passed argument cannot be stringifed');
|
|
3117
|
-
}
|
|
3118
|
-
};
|
|
2701
|
+
module.exports = 2147483647;
|
|
3119
2702
|
});
|
|
3120
|
-
var
|
|
2703
|
+
var require_valid_timeout = __commonJS(function(exports, module) {
|
|
3121
2704
|
'use strict';
|
|
3122
|
-
var
|
|
3123
|
-
var
|
|
2705
|
+
var toPosInt = require_to_pos_integer();
|
|
2706
|
+
var maxTimeout = require_max_timeout();
|
|
3124
2707
|
module.exports = function(value) {
|
|
3125
|
-
|
|
2708
|
+
value = toPosInt(value);
|
|
2709
|
+
if (value > maxTimeout) {
|
|
2710
|
+
throw new TypeError(value + ' exceeds maximum possible timeout');
|
|
2711
|
+
}
|
|
2712
|
+
return value;
|
|
3126
2713
|
};
|
|
3127
2714
|
});
|
|
3128
|
-
var
|
|
2715
|
+
var require_max_age = __commonJS(function() {
|
|
3129
2716
|
'use strict';
|
|
3130
|
-
var
|
|
3131
|
-
|
|
3132
|
-
|
|
3133
|
-
|
|
3134
|
-
|
|
2717
|
+
var aFrom = require_from();
|
|
2718
|
+
var forEach = require_for_each();
|
|
2719
|
+
var nextTick = require_next_tick();
|
|
2720
|
+
var isPromise = require_is_promise();
|
|
2721
|
+
var timeout = require_valid_timeout();
|
|
2722
|
+
var extensions = require_registered_extensions();
|
|
2723
|
+
var noop3 = Function.prototype;
|
|
2724
|
+
var max2 = Math.max;
|
|
2725
|
+
var min = Math.min;
|
|
2726
|
+
var create = Object.create;
|
|
2727
|
+
extensions.maxAge = function(maxAge, conf, options) {
|
|
2728
|
+
var timeouts, postfix, preFetchAge, preFetchTimeouts;
|
|
2729
|
+
maxAge = timeout(maxAge);
|
|
2730
|
+
if (!maxAge) {
|
|
2731
|
+
return;
|
|
2732
|
+
}
|
|
2733
|
+
timeouts = create(null);
|
|
2734
|
+
postfix = options.async && extensions.async || options.promise && extensions.promise ? 'async' : '';
|
|
2735
|
+
conf.on('set' + postfix, function(id) {
|
|
2736
|
+
timeouts[id] = setTimeout(function() {
|
|
2737
|
+
conf['delete'](id);
|
|
2738
|
+
}, maxAge);
|
|
2739
|
+
if (typeof timeouts[id].unref === 'function') {
|
|
2740
|
+
timeouts[id].unref();
|
|
2741
|
+
}
|
|
2742
|
+
if (!preFetchTimeouts) {
|
|
2743
|
+
return;
|
|
2744
|
+
}
|
|
2745
|
+
if (preFetchTimeouts[id]) {
|
|
2746
|
+
if (preFetchTimeouts[id] !== 'nextTick') {
|
|
2747
|
+
clearTimeout(preFetchTimeouts[id]);
|
|
2748
|
+
}
|
|
2749
|
+
}
|
|
2750
|
+
preFetchTimeouts[id] = setTimeout(function() {
|
|
2751
|
+
delete preFetchTimeouts[id];
|
|
2752
|
+
}, preFetchAge);
|
|
2753
|
+
if (typeof preFetchTimeouts[id].unref === 'function') {
|
|
2754
|
+
preFetchTimeouts[id].unref();
|
|
2755
|
+
}
|
|
2756
|
+
});
|
|
2757
|
+
conf.on('delete' + postfix, function(id) {
|
|
2758
|
+
clearTimeout(timeouts[id]);
|
|
2759
|
+
delete timeouts[id];
|
|
2760
|
+
if (!preFetchTimeouts) {
|
|
2761
|
+
return;
|
|
2762
|
+
}
|
|
2763
|
+
if (preFetchTimeouts[id] !== 'nextTick') {
|
|
2764
|
+
clearTimeout(preFetchTimeouts[id]);
|
|
2765
|
+
}
|
|
2766
|
+
delete preFetchTimeouts[id];
|
|
2767
|
+
});
|
|
2768
|
+
if (options.preFetch) {
|
|
2769
|
+
if (options.preFetch === true || isNaN(options.preFetch)) {
|
|
2770
|
+
preFetchAge = .333;
|
|
2771
|
+
} else {
|
|
2772
|
+
preFetchAge = max2(min(Number(options.preFetch), 1), 0);
|
|
2773
|
+
}
|
|
2774
|
+
if (preFetchAge) {
|
|
2775
|
+
preFetchTimeouts = {};
|
|
2776
|
+
preFetchAge = (1 - preFetchAge) * maxAge;
|
|
2777
|
+
conf.on('get' + postfix, function(id, args, context) {
|
|
2778
|
+
if (!preFetchTimeouts[id]) {
|
|
2779
|
+
preFetchTimeouts[id] = 'nextTick';
|
|
2780
|
+
nextTick(function() {
|
|
2781
|
+
var result;
|
|
2782
|
+
if (preFetchTimeouts[id] !== 'nextTick') {
|
|
2783
|
+
return;
|
|
2784
|
+
}
|
|
2785
|
+
delete preFetchTimeouts[id];
|
|
2786
|
+
conf['delete'](id);
|
|
2787
|
+
if (options.async) {
|
|
2788
|
+
args = aFrom(args);
|
|
2789
|
+
args.push(noop3);
|
|
2790
|
+
}
|
|
2791
|
+
result = conf.memoized.apply(context, args);
|
|
2792
|
+
if (options.promise) {
|
|
2793
|
+
if (isPromise(result)) {
|
|
2794
|
+
if (typeof result.done === 'function') {
|
|
2795
|
+
result.done(noop3, noop3);
|
|
2796
|
+
} else {
|
|
2797
|
+
result.then(noop3, noop3);
|
|
2798
|
+
}
|
|
2799
|
+
}
|
|
2800
|
+
}
|
|
2801
|
+
});
|
|
2802
|
+
}
|
|
2803
|
+
});
|
|
3135
2804
|
}
|
|
3136
|
-
return String(value);
|
|
3137
|
-
} catch (e) {
|
|
3138
|
-
return '<Non-coercible to string value>';
|
|
3139
|
-
}
|
|
3140
|
-
};
|
|
3141
|
-
});
|
|
3142
|
-
var require_to_short_string_representation = __commonJS(function(exports, module) {
|
|
3143
|
-
'use strict';
|
|
3144
|
-
var safeToString = require_safe_to_string();
|
|
3145
|
-
var reNewLine = /[\n\r\u2028\u2029]/g;
|
|
3146
|
-
module.exports = function(value) {
|
|
3147
|
-
var string = safeToString(value);
|
|
3148
|
-
if (string.length > 100) {
|
|
3149
|
-
string = string.slice(0, 99) + '\u2026';
|
|
3150
2805
|
}
|
|
3151
|
-
|
|
3152
|
-
|
|
2806
|
+
conf.on('clear' + postfix, function() {
|
|
2807
|
+
forEach(timeouts, function(id) {
|
|
2808
|
+
clearTimeout(id);
|
|
2809
|
+
});
|
|
2810
|
+
timeouts = {};
|
|
2811
|
+
if (preFetchTimeouts) {
|
|
2812
|
+
forEach(preFetchTimeouts, function(id) {
|
|
2813
|
+
if (id !== 'nextTick') {
|
|
2814
|
+
clearTimeout(id);
|
|
2815
|
+
}
|
|
2816
|
+
});
|
|
2817
|
+
preFetchTimeouts = {};
|
|
2818
|
+
}
|
|
3153
2819
|
});
|
|
3154
|
-
return string;
|
|
3155
2820
|
};
|
|
3156
2821
|
});
|
|
3157
|
-
var
|
|
3158
|
-
module.exports = isPromise;
|
|
3159
|
-
module.exports['default'] = isPromise;
|
|
3160
|
-
function isPromise(obj) {
|
|
3161
|
-
return !!obj && (_typeof(obj) === 'object' || typeof obj === 'function') && typeof obj.then === 'function';
|
|
3162
|
-
}
|
|
3163
|
-
});
|
|
3164
|
-
var require_promise = __commonJS(function() {
|
|
2822
|
+
var require_lru_queue = __commonJS(function(exports, module) {
|
|
3165
2823
|
'use strict';
|
|
3166
|
-
var
|
|
3167
|
-
var primitiveSet = require_primitive_set();
|
|
3168
|
-
var ensureString = require_validate_stringifiable_value();
|
|
3169
|
-
var toShortString = require_to_short_string_representation();
|
|
3170
|
-
var isPromise = require_is_promise();
|
|
3171
|
-
var nextTick = require_next_tick();
|
|
2824
|
+
var toPosInt = require_to_pos_integer();
|
|
3172
2825
|
var create = Object.create;
|
|
3173
|
-
var
|
|
3174
|
-
|
|
3175
|
-
var
|
|
3176
|
-
|
|
3177
|
-
|
|
3178
|
-
|
|
3179
|
-
|
|
3180
|
-
|
|
3181
|
-
|
|
3182
|
-
|
|
3183
|
-
|
|
3184
|
-
|
|
3185
|
-
|
|
3186
|
-
|
|
3187
|
-
|
|
3188
|
-
|
|
3189
|
-
|
|
3190
|
-
}
|
|
3191
|
-
waiting[id] = 1;
|
|
3192
|
-
promises[id] = promise;
|
|
3193
|
-
var onSuccess = function onSuccess(result) {
|
|
3194
|
-
var count = waiting[id];
|
|
3195
|
-
if (isFailed) {
|
|
3196
|
-
throw new Error('Memoizee error: Detected unordered then|done & finally resolution, which in turn makes proper detection of success/failure impossible (when in \'done:finally\' mode)\nConsider to rely on \'then\' or \'done\' mode instead.');
|
|
2826
|
+
var hasOwnProperty2 = Object.prototype.hasOwnProperty;
|
|
2827
|
+
module.exports = function(limit) {
|
|
2828
|
+
var size = 0, base = 1, queue2 = create(null), map = create(null), index = 0, del;
|
|
2829
|
+
limit = toPosInt(limit);
|
|
2830
|
+
return {
|
|
2831
|
+
hit: function hit(id) {
|
|
2832
|
+
var oldIndex = map[id], nuIndex = ++index;
|
|
2833
|
+
queue2[nuIndex] = id;
|
|
2834
|
+
map[id] = nuIndex;
|
|
2835
|
+
if (!oldIndex) {
|
|
2836
|
+
++size;
|
|
2837
|
+
if (size <= limit) {
|
|
2838
|
+
return;
|
|
2839
|
+
}
|
|
2840
|
+
id = queue2[base];
|
|
2841
|
+
del(id);
|
|
2842
|
+
return id;
|
|
3197
2843
|
}
|
|
3198
|
-
|
|
2844
|
+
delete queue2[oldIndex];
|
|
2845
|
+
if (base !== oldIndex) {
|
|
3199
2846
|
return;
|
|
3200
2847
|
}
|
|
3201
|
-
|
|
3202
|
-
|
|
3203
|
-
conf.emit('setasync', id, count);
|
|
3204
|
-
};
|
|
3205
|
-
var onFailure = function onFailure() {
|
|
3206
|
-
isFailed = true;
|
|
3207
|
-
if (!waiting[id]) {
|
|
3208
|
-
return;
|
|
2848
|
+
while (!hasOwnProperty2.call(queue2, ++base)) {
|
|
2849
|
+
continue;
|
|
3209
2850
|
}
|
|
3210
|
-
|
|
3211
|
-
|
|
3212
|
-
|
|
3213
|
-
|
|
3214
|
-
|
|
3215
|
-
if (!resolvedMode) {
|
|
3216
|
-
resolvedMode = 'then';
|
|
3217
|
-
}
|
|
3218
|
-
if (resolvedMode === 'then') {
|
|
3219
|
-
var nextTickFailure = function nextTickFailure() {
|
|
3220
|
-
nextTick(onFailure);
|
|
3221
|
-
};
|
|
3222
|
-
promise = promise.then(function(result) {
|
|
3223
|
-
nextTick(onSuccess.bind(this, result));
|
|
3224
|
-
}, nextTickFailure);
|
|
3225
|
-
if (typeof promise['finally'] === 'function') {
|
|
3226
|
-
promise['finally'](nextTickFailure);
|
|
2851
|
+
},
|
|
2852
|
+
delete: del = function del(id) {
|
|
2853
|
+
var oldIndex = map[id];
|
|
2854
|
+
if (!oldIndex) {
|
|
2855
|
+
return;
|
|
3227
2856
|
}
|
|
3228
|
-
|
|
3229
|
-
|
|
3230
|
-
|
|
2857
|
+
delete queue2[oldIndex];
|
|
2858
|
+
delete map[id];
|
|
2859
|
+
--size;
|
|
2860
|
+
if (base !== oldIndex) {
|
|
2861
|
+
return;
|
|
3231
2862
|
}
|
|
3232
|
-
|
|
3233
|
-
|
|
3234
|
-
|
|
3235
|
-
|
|
2863
|
+
if (!size) {
|
|
2864
|
+
index = 0;
|
|
2865
|
+
base = 1;
|
|
2866
|
+
return;
|
|
3236
2867
|
}
|
|
3237
|
-
|
|
3238
|
-
|
|
2868
|
+
while (!hasOwnProperty2.call(queue2, ++base)) {
|
|
2869
|
+
continue;
|
|
3239
2870
|
}
|
|
3240
|
-
|
|
3241
|
-
|
|
2871
|
+
},
|
|
2872
|
+
clear: function clear() {
|
|
2873
|
+
size = 0;
|
|
2874
|
+
base = 1;
|
|
2875
|
+
queue2 = create(null);
|
|
2876
|
+
map = create(null);
|
|
2877
|
+
index = 0;
|
|
3242
2878
|
}
|
|
3243
|
-
}
|
|
3244
|
-
|
|
3245
|
-
|
|
3246
|
-
|
|
3247
|
-
|
|
2879
|
+
};
|
|
2880
|
+
};
|
|
2881
|
+
});
|
|
2882
|
+
var require_max = __commonJS(function() {
|
|
2883
|
+
'use strict';
|
|
2884
|
+
var toPosInteger = require_to_pos_integer();
|
|
2885
|
+
var lruQueue = require_lru_queue();
|
|
2886
|
+
var extensions = require_registered_extensions();
|
|
2887
|
+
extensions.max = function(max2, conf, options) {
|
|
2888
|
+
var postfix, queue2, hit;
|
|
2889
|
+
max2 = toPosInteger(max2);
|
|
2890
|
+
if (!max2) {
|
|
2891
|
+
return;
|
|
2892
|
+
}
|
|
2893
|
+
queue2 = lruQueue(max2);
|
|
2894
|
+
postfix = options.async && extensions.async || options.promise && extensions.promise ? 'async' : '';
|
|
2895
|
+
conf.on('set' + postfix, hit = function hit(id) {
|
|
2896
|
+
id = queue2.hit(id);
|
|
2897
|
+
if (id === void 0) {
|
|
3248
2898
|
return;
|
|
3249
2899
|
}
|
|
3250
|
-
|
|
3251
|
-
var emit = function emit() {
|
|
3252
|
-
conf.emit('getasync', id, args, context);
|
|
3253
|
-
};
|
|
3254
|
-
if (isPromise(promise)) {
|
|
3255
|
-
if (typeof promise.done === 'function') {
|
|
3256
|
-
promise.done(emit);
|
|
3257
|
-
} else {
|
|
3258
|
-
promise.then(function() {
|
|
3259
|
-
nextTick(emit);
|
|
3260
|
-
});
|
|
3261
|
-
}
|
|
3262
|
-
} else {
|
|
3263
|
-
emit();
|
|
3264
|
-
}
|
|
2900
|
+
conf['delete'](id);
|
|
3265
2901
|
});
|
|
3266
|
-
conf.on('
|
|
3267
|
-
|
|
3268
|
-
|
|
3269
|
-
|
|
3270
|
-
|
|
3271
|
-
|
|
3272
|
-
|
|
3273
|
-
|
|
3274
|
-
|
|
3275
|
-
|
|
2902
|
+
conf.on('get' + postfix, hit);
|
|
2903
|
+
conf.on('delete' + postfix, queue2['delete']);
|
|
2904
|
+
conf.on('clear' + postfix, queue2.clear);
|
|
2905
|
+
};
|
|
2906
|
+
});
|
|
2907
|
+
var require_ref_counter = __commonJS(function() {
|
|
2908
|
+
'use strict';
|
|
2909
|
+
var d2 = require_d();
|
|
2910
|
+
var extensions = require_registered_extensions();
|
|
2911
|
+
var create = Object.create;
|
|
2912
|
+
var defineProperties = Object.defineProperties;
|
|
2913
|
+
extensions.refCounter = function(ignore, conf, options) {
|
|
2914
|
+
var cache2, postfix;
|
|
2915
|
+
cache2 = create(null);
|
|
2916
|
+
postfix = options.async && extensions.async || options.promise && extensions.promise ? 'async' : '';
|
|
2917
|
+
conf.on('set' + postfix, function(id, length) {
|
|
2918
|
+
cache2[id] = length || 1;
|
|
2919
|
+
});
|
|
2920
|
+
conf.on('get' + postfix, function(id) {
|
|
2921
|
+
++cache2[id];
|
|
2922
|
+
});
|
|
2923
|
+
conf.on('delete' + postfix, function(id) {
|
|
3276
2924
|
delete cache2[id];
|
|
3277
|
-
conf.emit('deleteasync', id, [ result ]);
|
|
3278
2925
|
});
|
|
3279
|
-
conf.on('clear', function() {
|
|
3280
|
-
|
|
3281
|
-
|
|
3282
|
-
|
|
3283
|
-
|
|
3284
|
-
|
|
3285
|
-
|
|
3286
|
-
|
|
2926
|
+
conf.on('clear' + postfix, function() {
|
|
2927
|
+
cache2 = {};
|
|
2928
|
+
});
|
|
2929
|
+
defineProperties(conf.memoized, {
|
|
2930
|
+
deleteRef: d2(function() {
|
|
2931
|
+
var id = conf.get(arguments);
|
|
2932
|
+
if (id === null) {
|
|
2933
|
+
return null;
|
|
2934
|
+
}
|
|
2935
|
+
if (!cache2[id]) {
|
|
2936
|
+
return null;
|
|
2937
|
+
}
|
|
2938
|
+
if (!--cache2[id]) {
|
|
2939
|
+
conf['delete'](id);
|
|
2940
|
+
return true;
|
|
2941
|
+
}
|
|
2942
|
+
return false;
|
|
2943
|
+
}),
|
|
2944
|
+
getRefCount: d2(function() {
|
|
2945
|
+
var id = conf.get(arguments);
|
|
2946
|
+
if (id === null) {
|
|
2947
|
+
return 0;
|
|
2948
|
+
}
|
|
2949
|
+
if (!cache2[id]) {
|
|
2950
|
+
return 0;
|
|
2951
|
+
}
|
|
2952
|
+
return cache2[id];
|
|
2953
|
+
})
|
|
3287
2954
|
});
|
|
3288
2955
|
};
|
|
3289
2956
|
});
|
|
3290
|
-
var
|
|
2957
|
+
var require_memoizee = __commonJS(function(exports, module) {
|
|
3291
2958
|
'use strict';
|
|
3292
|
-
var
|
|
3293
|
-
var
|
|
3294
|
-
var
|
|
3295
|
-
|
|
3296
|
-
|
|
3297
|
-
|
|
3298
|
-
|
|
3299
|
-
|
|
3300
|
-
|
|
3301
|
-
|
|
3302
|
-
|
|
3303
|
-
|
|
3304
|
-
|
|
3305
|
-
|
|
3306
|
-
})
|
|
3307
|
-
|
|
3308
|
-
|
|
2959
|
+
var normalizeOpts = require_normalize_options();
|
|
2960
|
+
var resolveLength = require_resolve_length();
|
|
2961
|
+
var plain = require_plain();
|
|
2962
|
+
module.exports = function(fn) {
|
|
2963
|
+
var options = normalizeOpts(arguments[1]), length;
|
|
2964
|
+
if (!options.normalizer) {
|
|
2965
|
+
length = options.length = resolveLength(options.length, fn.length, options.async);
|
|
2966
|
+
if (length !== 0) {
|
|
2967
|
+
if (options.primitive) {
|
|
2968
|
+
if (length === false) {
|
|
2969
|
+
options.normalizer = require_primitive();
|
|
2970
|
+
} else if (length > 1) {
|
|
2971
|
+
options.normalizer = require_get_primitive_fixed()(length);
|
|
2972
|
+
}
|
|
2973
|
+
} else if (length === false) {
|
|
2974
|
+
options.normalizer = require_get()();
|
|
2975
|
+
} else if (length === 1) {
|
|
2976
|
+
options.normalizer = require_get_1()();
|
|
2977
|
+
} else {
|
|
2978
|
+
options.normalizer = require_get_fixed()(length);
|
|
2979
|
+
}
|
|
2980
|
+
}
|
|
3309
2981
|
}
|
|
3310
|
-
|
|
3311
|
-
|
|
3312
|
-
}
|
|
3313
|
-
|
|
3314
|
-
|
|
3315
|
-
|
|
3316
|
-
|
|
3317
|
-
|
|
2982
|
+
if (options.async) {
|
|
2983
|
+
require_async();
|
|
2984
|
+
}
|
|
2985
|
+
if (options.promise) {
|
|
2986
|
+
require_promise();
|
|
2987
|
+
}
|
|
2988
|
+
if (options.dispose) {
|
|
2989
|
+
require_dispose();
|
|
2990
|
+
}
|
|
2991
|
+
if (options.maxAge) {
|
|
2992
|
+
require_max_age();
|
|
2993
|
+
}
|
|
2994
|
+
if (options.max) {
|
|
2995
|
+
require_max();
|
|
2996
|
+
}
|
|
2997
|
+
if (options.refCounter) {
|
|
2998
|
+
require_ref_counter();
|
|
2999
|
+
}
|
|
3000
|
+
return plain(fn, options);
|
|
3318
3001
|
};
|
|
3319
3002
|
});
|
|
3320
|
-
var
|
|
3321
|
-
'use strict';
|
|
3322
|
-
module.exports = 2147483647;
|
|
3323
|
-
});
|
|
3324
|
-
var require_valid_timeout = __commonJS(function(exports, module) {
|
|
3003
|
+
var require_utils = __commonJS(function(exports) {
|
|
3325
3004
|
'use strict';
|
|
3326
|
-
|
|
3327
|
-
|
|
3328
|
-
|
|
3329
|
-
|
|
3330
|
-
|
|
3331
|
-
|
|
3005
|
+
Object.defineProperty(exports, '__esModule', {
|
|
3006
|
+
value: true
|
|
3007
|
+
});
|
|
3008
|
+
function isIdentStart(c4) {
|
|
3009
|
+
return c4 >= 'a' && c4 <= 'z' || c4 >= 'A' && c4 <= 'Z' || c4 === '-' || c4 === '_';
|
|
3010
|
+
}
|
|
3011
|
+
exports.isIdentStart = isIdentStart;
|
|
3012
|
+
function isIdent(c4) {
|
|
3013
|
+
return c4 >= 'a' && c4 <= 'z' || c4 >= 'A' && c4 <= 'Z' || c4 >= '0' && c4 <= '9' || c4 === '-' || c4 === '_';
|
|
3014
|
+
}
|
|
3015
|
+
exports.isIdent = isIdent;
|
|
3016
|
+
function isHex(c4) {
|
|
3017
|
+
return c4 >= 'a' && c4 <= 'f' || c4 >= 'A' && c4 <= 'F' || c4 >= '0' && c4 <= '9';
|
|
3018
|
+
}
|
|
3019
|
+
exports.isHex = isHex;
|
|
3020
|
+
function escapeIdentifier(s) {
|
|
3021
|
+
var len = s.length;
|
|
3022
|
+
var result = '';
|
|
3023
|
+
var i = 0;
|
|
3024
|
+
while (i < len) {
|
|
3025
|
+
var chr = s.charAt(i);
|
|
3026
|
+
if (exports.identSpecialChars[chr]) {
|
|
3027
|
+
result += '\\' + chr;
|
|
3028
|
+
} else {
|
|
3029
|
+
if (!(chr === '_' || chr === '-' || chr >= 'A' && chr <= 'Z' || chr >= 'a' && chr <= 'z' || i !== 0 && chr >= '0' && chr <= '9')) {
|
|
3030
|
+
var charCode = chr.charCodeAt(0);
|
|
3031
|
+
if ((charCode & 63488) === 55296) {
|
|
3032
|
+
var extraCharCode = s.charCodeAt(i++);
|
|
3033
|
+
if ((charCode & 64512) !== 55296 || (extraCharCode & 64512) !== 56320) {
|
|
3034
|
+
throw Error('UCS-2(decode): illegal sequence');
|
|
3035
|
+
}
|
|
3036
|
+
charCode = ((charCode & 1023) << 10) + (extraCharCode & 1023) + 65536;
|
|
3037
|
+
}
|
|
3038
|
+
result += '\\' + charCode.toString(16) + ' ';
|
|
3039
|
+
} else {
|
|
3040
|
+
result += chr;
|
|
3041
|
+
}
|
|
3042
|
+
}
|
|
3043
|
+
i++;
|
|
3332
3044
|
}
|
|
3333
|
-
return
|
|
3045
|
+
return result;
|
|
3046
|
+
}
|
|
3047
|
+
exports.escapeIdentifier = escapeIdentifier;
|
|
3048
|
+
function escapeStr(s) {
|
|
3049
|
+
var len = s.length;
|
|
3050
|
+
var result = '';
|
|
3051
|
+
var i = 0;
|
|
3052
|
+
var replacement;
|
|
3053
|
+
while (i < len) {
|
|
3054
|
+
var chr = s.charAt(i);
|
|
3055
|
+
if (chr === '"') {
|
|
3056
|
+
chr = '\\"';
|
|
3057
|
+
} else if (chr === '\\') {
|
|
3058
|
+
chr = '\\\\';
|
|
3059
|
+
} else if ((replacement = exports.strReplacementsRev[chr]) !== void 0) {
|
|
3060
|
+
chr = replacement;
|
|
3061
|
+
}
|
|
3062
|
+
result += chr;
|
|
3063
|
+
i++;
|
|
3064
|
+
}
|
|
3065
|
+
return '"' + result + '"';
|
|
3066
|
+
}
|
|
3067
|
+
exports.escapeStr = escapeStr;
|
|
3068
|
+
exports.identSpecialChars = {
|
|
3069
|
+
'!': true,
|
|
3070
|
+
'"': true,
|
|
3071
|
+
'#': true,
|
|
3072
|
+
$: true,
|
|
3073
|
+
'%': true,
|
|
3074
|
+
'&': true,
|
|
3075
|
+
'\'': true,
|
|
3076
|
+
'(': true,
|
|
3077
|
+
')': true,
|
|
3078
|
+
'*': true,
|
|
3079
|
+
'+': true,
|
|
3080
|
+
',': true,
|
|
3081
|
+
'.': true,
|
|
3082
|
+
'/': true,
|
|
3083
|
+
';': true,
|
|
3084
|
+
'<': true,
|
|
3085
|
+
'=': true,
|
|
3086
|
+
'>': true,
|
|
3087
|
+
'?': true,
|
|
3088
|
+
'@': true,
|
|
3089
|
+
'[': true,
|
|
3090
|
+
'\\': true,
|
|
3091
|
+
']': true,
|
|
3092
|
+
'^': true,
|
|
3093
|
+
'`': true,
|
|
3094
|
+
'{': true,
|
|
3095
|
+
'|': true,
|
|
3096
|
+
'}': true,
|
|
3097
|
+
'~': true
|
|
3098
|
+
};
|
|
3099
|
+
exports.strReplacementsRev = {
|
|
3100
|
+
'\n': '\\n',
|
|
3101
|
+
'\r': '\\r',
|
|
3102
|
+
'\t': '\\t',
|
|
3103
|
+
'\f': '\\f',
|
|
3104
|
+
'\v': '\\v'
|
|
3105
|
+
};
|
|
3106
|
+
exports.singleQuoteEscapeChars = {
|
|
3107
|
+
n: '\n',
|
|
3108
|
+
r: '\r',
|
|
3109
|
+
t: '\t',
|
|
3110
|
+
f: '\f',
|
|
3111
|
+
'\\': '\\',
|
|
3112
|
+
'\'': '\''
|
|
3113
|
+
};
|
|
3114
|
+
exports.doubleQuotesEscapeChars = {
|
|
3115
|
+
n: '\n',
|
|
3116
|
+
r: '\r',
|
|
3117
|
+
t: '\t',
|
|
3118
|
+
f: '\f',
|
|
3119
|
+
'\\': '\\',
|
|
3120
|
+
'"': '"'
|
|
3334
3121
|
};
|
|
3335
3122
|
});
|
|
3336
|
-
var
|
|
3123
|
+
var require_parser_context = __commonJS(function(exports) {
|
|
3337
3124
|
'use strict';
|
|
3338
|
-
|
|
3339
|
-
|
|
3340
|
-
|
|
3341
|
-
var
|
|
3342
|
-
|
|
3343
|
-
|
|
3344
|
-
|
|
3345
|
-
|
|
3346
|
-
|
|
3347
|
-
|
|
3348
|
-
|
|
3349
|
-
|
|
3350
|
-
|
|
3351
|
-
|
|
3352
|
-
|
|
3125
|
+
Object.defineProperty(exports, '__esModule', {
|
|
3126
|
+
value: true
|
|
3127
|
+
});
|
|
3128
|
+
var utils_1 = require_utils();
|
|
3129
|
+
function parseCssSelector(str, pos, pseudos, attrEqualityMods, ruleNestingOperators, substitutesEnabled) {
|
|
3130
|
+
var l = str.length;
|
|
3131
|
+
var chr = '';
|
|
3132
|
+
function getStr(quote, escapeTable) {
|
|
3133
|
+
var result = '';
|
|
3134
|
+
pos++;
|
|
3135
|
+
chr = str.charAt(pos);
|
|
3136
|
+
while (pos < l) {
|
|
3137
|
+
if (chr === quote) {
|
|
3138
|
+
pos++;
|
|
3139
|
+
return result;
|
|
3140
|
+
} else if (chr === '\\') {
|
|
3141
|
+
pos++;
|
|
3142
|
+
chr = str.charAt(pos);
|
|
3143
|
+
var esc = void 0;
|
|
3144
|
+
if (chr === quote) {
|
|
3145
|
+
result += quote;
|
|
3146
|
+
} else if ((esc = escapeTable[chr]) !== void 0) {
|
|
3147
|
+
result += esc;
|
|
3148
|
+
} else if (utils_1.isHex(chr)) {
|
|
3149
|
+
var hex = chr;
|
|
3150
|
+
pos++;
|
|
3151
|
+
chr = str.charAt(pos);
|
|
3152
|
+
while (utils_1.isHex(chr)) {
|
|
3153
|
+
hex += chr;
|
|
3154
|
+
pos++;
|
|
3155
|
+
chr = str.charAt(pos);
|
|
3156
|
+
}
|
|
3157
|
+
if (chr === ' ') {
|
|
3158
|
+
pos++;
|
|
3159
|
+
chr = str.charAt(pos);
|
|
3160
|
+
}
|
|
3161
|
+
result += String.fromCharCode(parseInt(hex, 16));
|
|
3162
|
+
continue;
|
|
3163
|
+
} else {
|
|
3164
|
+
result += chr;
|
|
3165
|
+
}
|
|
3166
|
+
} else {
|
|
3167
|
+
result += chr;
|
|
3168
|
+
}
|
|
3169
|
+
pos++;
|
|
3170
|
+
chr = str.charAt(pos);
|
|
3171
|
+
}
|
|
3172
|
+
return result;
|
|
3353
3173
|
}
|
|
3354
|
-
|
|
3355
|
-
|
|
3356
|
-
|
|
3357
|
-
|
|
3358
|
-
|
|
3359
|
-
|
|
3360
|
-
|
|
3361
|
-
|
|
3174
|
+
function getIdent() {
|
|
3175
|
+
var result = '';
|
|
3176
|
+
chr = str.charAt(pos);
|
|
3177
|
+
while (pos < l) {
|
|
3178
|
+
if (utils_1.isIdent(chr)) {
|
|
3179
|
+
result += chr;
|
|
3180
|
+
} else if (chr === '\\') {
|
|
3181
|
+
pos++;
|
|
3182
|
+
if (pos >= l) {
|
|
3183
|
+
throw Error('Expected symbol but end of file reached.');
|
|
3184
|
+
}
|
|
3185
|
+
chr = str.charAt(pos);
|
|
3186
|
+
if (utils_1.identSpecialChars[chr]) {
|
|
3187
|
+
result += chr;
|
|
3188
|
+
} else if (utils_1.isHex(chr)) {
|
|
3189
|
+
var hex = chr;
|
|
3190
|
+
pos++;
|
|
3191
|
+
chr = str.charAt(pos);
|
|
3192
|
+
while (utils_1.isHex(chr)) {
|
|
3193
|
+
hex += chr;
|
|
3194
|
+
pos++;
|
|
3195
|
+
chr = str.charAt(pos);
|
|
3196
|
+
}
|
|
3197
|
+
if (chr === ' ') {
|
|
3198
|
+
pos++;
|
|
3199
|
+
chr = str.charAt(pos);
|
|
3200
|
+
}
|
|
3201
|
+
result += String.fromCharCode(parseInt(hex, 16));
|
|
3202
|
+
continue;
|
|
3203
|
+
} else {
|
|
3204
|
+
result += chr;
|
|
3205
|
+
}
|
|
3206
|
+
} else {
|
|
3207
|
+
return result;
|
|
3208
|
+
}
|
|
3209
|
+
pos++;
|
|
3210
|
+
chr = str.charAt(pos);
|
|
3362
3211
|
}
|
|
3363
|
-
|
|
3364
|
-
|
|
3212
|
+
return result;
|
|
3213
|
+
}
|
|
3214
|
+
function skipWhitespace() {
|
|
3215
|
+
chr = str.charAt(pos);
|
|
3216
|
+
var result = false;
|
|
3217
|
+
while (chr === ' ' || chr === '\t' || chr === '\n' || chr === '\r' || chr === '\f') {
|
|
3218
|
+
result = true;
|
|
3219
|
+
pos++;
|
|
3220
|
+
chr = str.charAt(pos);
|
|
3365
3221
|
}
|
|
3366
|
-
|
|
3367
|
-
|
|
3368
|
-
|
|
3369
|
-
|
|
3222
|
+
return result;
|
|
3223
|
+
}
|
|
3224
|
+
function parse3() {
|
|
3225
|
+
var res = parseSelector();
|
|
3226
|
+
if (pos < l) {
|
|
3227
|
+
throw Error('Rule expected but "' + str.charAt(pos) + '" found.');
|
|
3370
3228
|
}
|
|
3371
|
-
|
|
3372
|
-
|
|
3373
|
-
|
|
3374
|
-
|
|
3375
|
-
|
|
3229
|
+
return res;
|
|
3230
|
+
}
|
|
3231
|
+
function parseSelector() {
|
|
3232
|
+
var selector = parseSingleSelector();
|
|
3233
|
+
if (!selector) {
|
|
3234
|
+
return null;
|
|
3376
3235
|
}
|
|
3377
|
-
|
|
3378
|
-
|
|
3379
|
-
|
|
3380
|
-
|
|
3381
|
-
|
|
3382
|
-
|
|
3236
|
+
var res = selector;
|
|
3237
|
+
chr = str.charAt(pos);
|
|
3238
|
+
while (chr === ',') {
|
|
3239
|
+
pos++;
|
|
3240
|
+
skipWhitespace();
|
|
3241
|
+
if (res.type !== 'selectors') {
|
|
3242
|
+
res = {
|
|
3243
|
+
type: 'selectors',
|
|
3244
|
+
selectors: [ selector ]
|
|
3245
|
+
};
|
|
3246
|
+
}
|
|
3247
|
+
selector = parseSingleSelector();
|
|
3248
|
+
if (!selector) {
|
|
3249
|
+
throw Error('Rule expected after ",".');
|
|
3250
|
+
}
|
|
3251
|
+
res.selectors.push(selector);
|
|
3383
3252
|
}
|
|
3384
|
-
|
|
3385
|
-
|
|
3253
|
+
return res;
|
|
3254
|
+
}
|
|
3255
|
+
function parseSingleSelector() {
|
|
3256
|
+
skipWhitespace();
|
|
3257
|
+
var selector = {
|
|
3258
|
+
type: 'ruleSet'
|
|
3259
|
+
};
|
|
3260
|
+
var rule = parseRule();
|
|
3261
|
+
if (!rule) {
|
|
3262
|
+
return null;
|
|
3386
3263
|
}
|
|
3387
|
-
|
|
3388
|
-
|
|
3389
|
-
|
|
3390
|
-
|
|
3391
|
-
|
|
3392
|
-
|
|
3393
|
-
|
|
3264
|
+
var currentRule = selector;
|
|
3265
|
+
while (rule) {
|
|
3266
|
+
rule.type = 'rule';
|
|
3267
|
+
currentRule.rule = rule;
|
|
3268
|
+
currentRule = rule;
|
|
3269
|
+
skipWhitespace();
|
|
3270
|
+
chr = str.charAt(pos);
|
|
3271
|
+
if (pos >= l || chr === ',' || chr === ')') {
|
|
3272
|
+
break;
|
|
3273
|
+
}
|
|
3274
|
+
if (ruleNestingOperators[chr]) {
|
|
3275
|
+
var op = chr;
|
|
3276
|
+
pos++;
|
|
3277
|
+
skipWhitespace();
|
|
3278
|
+
rule = parseRule();
|
|
3279
|
+
if (!rule) {
|
|
3280
|
+
throw Error('Rule expected after "' + op + '".');
|
|
3281
|
+
}
|
|
3282
|
+
rule.nestingOperator = op;
|
|
3283
|
+
} else {
|
|
3284
|
+
rule = parseRule();
|
|
3285
|
+
if (rule) {
|
|
3286
|
+
rule.nestingOperator = null;
|
|
3287
|
+
}
|
|
3288
|
+
}
|
|
3394
3289
|
}
|
|
3395
|
-
|
|
3396
|
-
|
|
3397
|
-
|
|
3398
|
-
|
|
3399
|
-
|
|
3400
|
-
|
|
3401
|
-
|
|
3402
|
-
|
|
3403
|
-
|
|
3404
|
-
|
|
3405
|
-
|
|
3406
|
-
|
|
3407
|
-
|
|
3408
|
-
|
|
3409
|
-
|
|
3410
|
-
|
|
3290
|
+
return selector;
|
|
3291
|
+
}
|
|
3292
|
+
function parseRule() {
|
|
3293
|
+
var rule = null;
|
|
3294
|
+
while (pos < l) {
|
|
3295
|
+
chr = str.charAt(pos);
|
|
3296
|
+
if (chr === '*') {
|
|
3297
|
+
pos++;
|
|
3298
|
+
(rule = rule || {}).tagName = '*';
|
|
3299
|
+
} else if (utils_1.isIdentStart(chr) || chr === '\\') {
|
|
3300
|
+
(rule = rule || {}).tagName = getIdent();
|
|
3301
|
+
} else if (chr === '.') {
|
|
3302
|
+
pos++;
|
|
3303
|
+
rule = rule || {};
|
|
3304
|
+
(rule.classNames = rule.classNames || []).push(getIdent());
|
|
3305
|
+
} else if (chr === '#') {
|
|
3306
|
+
pos++;
|
|
3307
|
+
(rule = rule || {}).id = getIdent();
|
|
3308
|
+
} else if (chr === '[') {
|
|
3309
|
+
pos++;
|
|
3310
|
+
skipWhitespace();
|
|
3311
|
+
var attr = {
|
|
3312
|
+
name: getIdent()
|
|
3313
|
+
};
|
|
3314
|
+
skipWhitespace();
|
|
3315
|
+
if (chr === ']') {
|
|
3316
|
+
pos++;
|
|
3317
|
+
} else {
|
|
3318
|
+
var operator = '';
|
|
3319
|
+
if (attrEqualityMods[chr]) {
|
|
3320
|
+
operator = chr;
|
|
3321
|
+
pos++;
|
|
3322
|
+
chr = str.charAt(pos);
|
|
3323
|
+
}
|
|
3324
|
+
if (pos >= l) {
|
|
3325
|
+
throw Error('Expected "=" but end of file reached.');
|
|
3326
|
+
}
|
|
3327
|
+
if (chr !== '=') {
|
|
3328
|
+
throw Error('Expected "=" but "' + chr + '" found.');
|
|
3329
|
+
}
|
|
3330
|
+
attr.operator = operator + '=';
|
|
3331
|
+
pos++;
|
|
3332
|
+
skipWhitespace();
|
|
3333
|
+
var attrValue = '';
|
|
3334
|
+
attr.valueType = 'string';
|
|
3335
|
+
if (chr === '"') {
|
|
3336
|
+
attrValue = getStr('"', utils_1.doubleQuotesEscapeChars);
|
|
3337
|
+
} else if (chr === '\'') {
|
|
3338
|
+
attrValue = getStr('\'', utils_1.singleQuoteEscapeChars);
|
|
3339
|
+
} else if (substitutesEnabled && chr === '$') {
|
|
3340
|
+
pos++;
|
|
3341
|
+
attrValue = getIdent();
|
|
3342
|
+
attr.valueType = 'substitute';
|
|
3343
|
+
} else {
|
|
3344
|
+
while (pos < l) {
|
|
3345
|
+
if (chr === ']') {
|
|
3346
|
+
break;
|
|
3347
|
+
}
|
|
3348
|
+
attrValue += chr;
|
|
3349
|
+
pos++;
|
|
3350
|
+
chr = str.charAt(pos);
|
|
3411
3351
|
}
|
|
3412
|
-
|
|
3413
|
-
|
|
3414
|
-
|
|
3415
|
-
|
|
3416
|
-
|
|
3417
|
-
|
|
3418
|
-
|
|
3352
|
+
attrValue = attrValue.trim();
|
|
3353
|
+
}
|
|
3354
|
+
skipWhitespace();
|
|
3355
|
+
if (pos >= l) {
|
|
3356
|
+
throw Error('Expected "]" but end of file reached.');
|
|
3357
|
+
}
|
|
3358
|
+
if (chr !== ']') {
|
|
3359
|
+
throw Error('Expected "]" but "' + chr + '" found.');
|
|
3360
|
+
}
|
|
3361
|
+
pos++;
|
|
3362
|
+
attr.value = attrValue;
|
|
3363
|
+
}
|
|
3364
|
+
rule = rule || {};
|
|
3365
|
+
(rule.attrs = rule.attrs || []).push(attr);
|
|
3366
|
+
} else if (chr === ':') {
|
|
3367
|
+
pos++;
|
|
3368
|
+
var pseudoName = getIdent();
|
|
3369
|
+
var pseudo = {
|
|
3370
|
+
name: pseudoName
|
|
3371
|
+
};
|
|
3372
|
+
if (chr === '(') {
|
|
3373
|
+
pos++;
|
|
3374
|
+
var value = '';
|
|
3375
|
+
skipWhitespace();
|
|
3376
|
+
if (pseudos[pseudoName] === 'selector') {
|
|
3377
|
+
pseudo.valueType = 'selector';
|
|
3378
|
+
value = parseSelector();
|
|
3379
|
+
} else {
|
|
3380
|
+
pseudo.valueType = pseudos[pseudoName] || 'string';
|
|
3381
|
+
if (chr === '"') {
|
|
3382
|
+
value = getStr('"', utils_1.doubleQuotesEscapeChars);
|
|
3383
|
+
} else if (chr === '\'') {
|
|
3384
|
+
value = getStr('\'', utils_1.singleQuoteEscapeChars);
|
|
3385
|
+
} else if (substitutesEnabled && chr === '$') {
|
|
3386
|
+
pos++;
|
|
3387
|
+
value = getIdent();
|
|
3388
|
+
pseudo.valueType = 'substitute';
|
|
3389
|
+
} else {
|
|
3390
|
+
while (pos < l) {
|
|
3391
|
+
if (chr === ')') {
|
|
3392
|
+
break;
|
|
3419
3393
|
}
|
|
3394
|
+
value += chr;
|
|
3395
|
+
pos++;
|
|
3396
|
+
chr = str.charAt(pos);
|
|
3420
3397
|
}
|
|
3398
|
+
value = value.trim();
|
|
3421
3399
|
}
|
|
3422
|
-
|
|
3400
|
+
skipWhitespace();
|
|
3401
|
+
}
|
|
3402
|
+
if (pos >= l) {
|
|
3403
|
+
throw Error('Expected ")" but end of file reached.');
|
|
3404
|
+
}
|
|
3405
|
+
if (chr !== ')') {
|
|
3406
|
+
throw Error('Expected ")" but "' + chr + '" found.');
|
|
3407
|
+
}
|
|
3408
|
+
pos++;
|
|
3409
|
+
pseudo.value = value;
|
|
3423
3410
|
}
|
|
3424
|
-
|
|
3411
|
+
rule = rule || {};
|
|
3412
|
+
(rule.pseudos = rule.pseudos || []).push(pseudo);
|
|
3413
|
+
} else {
|
|
3414
|
+
break;
|
|
3415
|
+
}
|
|
3425
3416
|
}
|
|
3417
|
+
return rule;
|
|
3426
3418
|
}
|
|
3427
|
-
|
|
3428
|
-
|
|
3429
|
-
|
|
3430
|
-
});
|
|
3431
|
-
timeouts = {};
|
|
3432
|
-
if (preFetchTimeouts) {
|
|
3433
|
-
forEach(preFetchTimeouts, function(id) {
|
|
3434
|
-
if (id !== 'nextTick') {
|
|
3435
|
-
clearTimeout(id);
|
|
3436
|
-
}
|
|
3437
|
-
});
|
|
3438
|
-
preFetchTimeouts = {};
|
|
3439
|
-
}
|
|
3440
|
-
});
|
|
3441
|
-
};
|
|
3419
|
+
return parse3();
|
|
3420
|
+
}
|
|
3421
|
+
exports.parseCssSelector = parseCssSelector;
|
|
3442
3422
|
});
|
|
3443
|
-
var
|
|
3423
|
+
var require_render = __commonJS(function(exports) {
|
|
3444
3424
|
'use strict';
|
|
3445
|
-
|
|
3446
|
-
|
|
3447
|
-
|
|
3448
|
-
|
|
3449
|
-
|
|
3450
|
-
|
|
3451
|
-
|
|
3452
|
-
|
|
3453
|
-
|
|
3454
|
-
|
|
3455
|
-
|
|
3456
|
-
if (
|
|
3457
|
-
|
|
3458
|
-
if (size <= limit) {
|
|
3459
|
-
return;
|
|
3460
|
-
}
|
|
3461
|
-
id = queue2[base];
|
|
3462
|
-
del(id);
|
|
3463
|
-
return id;
|
|
3464
|
-
}
|
|
3465
|
-
delete queue2[oldIndex];
|
|
3466
|
-
if (base !== oldIndex) {
|
|
3467
|
-
return;
|
|
3468
|
-
}
|
|
3469
|
-
while (!hasOwnProperty2.call(queue2, ++base)) {
|
|
3470
|
-
continue;
|
|
3471
|
-
}
|
|
3472
|
-
},
|
|
3473
|
-
delete: del = function del(id) {
|
|
3474
|
-
var oldIndex = map[id];
|
|
3475
|
-
if (!oldIndex) {
|
|
3476
|
-
return;
|
|
3477
|
-
}
|
|
3478
|
-
delete queue2[oldIndex];
|
|
3479
|
-
delete map[id];
|
|
3480
|
-
--size;
|
|
3481
|
-
if (base !== oldIndex) {
|
|
3482
|
-
return;
|
|
3483
|
-
}
|
|
3484
|
-
if (!size) {
|
|
3485
|
-
index = 0;
|
|
3486
|
-
base = 1;
|
|
3487
|
-
return;
|
|
3425
|
+
Object.defineProperty(exports, '__esModule', {
|
|
3426
|
+
value: true
|
|
3427
|
+
});
|
|
3428
|
+
var utils_1 = require_utils();
|
|
3429
|
+
function renderEntity(entity) {
|
|
3430
|
+
var res = '';
|
|
3431
|
+
switch (entity.type) {
|
|
3432
|
+
case 'ruleSet':
|
|
3433
|
+
var currentEntity = entity.rule;
|
|
3434
|
+
var parts = [];
|
|
3435
|
+
while (currentEntity) {
|
|
3436
|
+
if (currentEntity.nestingOperator) {
|
|
3437
|
+
parts.push(currentEntity.nestingOperator);
|
|
3488
3438
|
}
|
|
3489
|
-
|
|
3490
|
-
|
|
3439
|
+
parts.push(renderEntity(currentEntity));
|
|
3440
|
+
currentEntity = currentEntity.rule;
|
|
3441
|
+
}
|
|
3442
|
+
res = parts.join(' ');
|
|
3443
|
+
break;
|
|
3444
|
+
|
|
3445
|
+
case 'selectors':
|
|
3446
|
+
res = entity.selectors.map(renderEntity).join(', ');
|
|
3447
|
+
break;
|
|
3448
|
+
|
|
3449
|
+
case 'rule':
|
|
3450
|
+
if (entity.tagName) {
|
|
3451
|
+
if (entity.tagName === '*') {
|
|
3452
|
+
res = '*';
|
|
3453
|
+
} else {
|
|
3454
|
+
res = utils_1.escapeIdentifier(entity.tagName);
|
|
3491
3455
|
}
|
|
3492
|
-
},
|
|
3493
|
-
clear: function clear() {
|
|
3494
|
-
size = 0;
|
|
3495
|
-
base = 1;
|
|
3496
|
-
queue2 = create(null);
|
|
3497
|
-
map = create(null);
|
|
3498
|
-
index = 0;
|
|
3499
3456
|
}
|
|
3500
|
-
|
|
3501
|
-
|
|
3502
|
-
});
|
|
3503
|
-
var require_max = __commonJS(function() {
|
|
3504
|
-
'use strict';
|
|
3505
|
-
var toPosInteger = require_to_pos_integer();
|
|
3506
|
-
var lruQueue = require_lru_queue();
|
|
3507
|
-
var extensions = require_registered_extensions();
|
|
3508
|
-
extensions.max = function(max2, conf, options) {
|
|
3509
|
-
var postfix, queue2, hit;
|
|
3510
|
-
max2 = toPosInteger(max2);
|
|
3511
|
-
if (!max2) {
|
|
3512
|
-
return;
|
|
3513
|
-
}
|
|
3514
|
-
queue2 = lruQueue(max2);
|
|
3515
|
-
postfix = options.async && extensions.async || options.promise && extensions.promise ? 'async' : '';
|
|
3516
|
-
conf.on('set' + postfix, hit = function hit(id) {
|
|
3517
|
-
id = queue2.hit(id);
|
|
3518
|
-
if (id === void 0) {
|
|
3519
|
-
return;
|
|
3457
|
+
if (entity.id) {
|
|
3458
|
+
res += '#' + utils_1.escapeIdentifier(entity.id);
|
|
3520
3459
|
}
|
|
3521
|
-
|
|
3522
|
-
|
|
3523
|
-
|
|
3524
|
-
|
|
3525
|
-
|
|
3526
|
-
|
|
3527
|
-
|
|
3528
|
-
|
|
3529
|
-
|
|
3530
|
-
|
|
3531
|
-
|
|
3532
|
-
|
|
3533
|
-
|
|
3534
|
-
|
|
3535
|
-
|
|
3536
|
-
cache2 = create(null);
|
|
3537
|
-
postfix = options.async && extensions.async || options.promise && extensions.promise ? 'async' : '';
|
|
3538
|
-
conf.on('set' + postfix, function(id, length) {
|
|
3539
|
-
cache2[id] = length || 1;
|
|
3540
|
-
});
|
|
3541
|
-
conf.on('get' + postfix, function(id) {
|
|
3542
|
-
++cache2[id];
|
|
3543
|
-
});
|
|
3544
|
-
conf.on('delete' + postfix, function(id) {
|
|
3545
|
-
delete cache2[id];
|
|
3546
|
-
});
|
|
3547
|
-
conf.on('clear' + postfix, function() {
|
|
3548
|
-
cache2 = {};
|
|
3549
|
-
});
|
|
3550
|
-
defineProperties(conf.memoized, {
|
|
3551
|
-
deleteRef: d2(function() {
|
|
3552
|
-
var id = conf.get(arguments);
|
|
3553
|
-
if (id === null) {
|
|
3554
|
-
return null;
|
|
3555
|
-
}
|
|
3556
|
-
if (!cache2[id]) {
|
|
3557
|
-
return null;
|
|
3558
|
-
}
|
|
3559
|
-
if (!--cache2[id]) {
|
|
3560
|
-
conf['delete'](id);
|
|
3561
|
-
return true;
|
|
3562
|
-
}
|
|
3563
|
-
return false;
|
|
3564
|
-
}),
|
|
3565
|
-
getRefCount: d2(function() {
|
|
3566
|
-
var id = conf.get(arguments);
|
|
3567
|
-
if (id === null) {
|
|
3568
|
-
return 0;
|
|
3569
|
-
}
|
|
3570
|
-
if (!cache2[id]) {
|
|
3571
|
-
return 0;
|
|
3572
|
-
}
|
|
3573
|
-
return cache2[id];
|
|
3574
|
-
})
|
|
3575
|
-
});
|
|
3576
|
-
};
|
|
3577
|
-
});
|
|
3578
|
-
var require_memoizee = __commonJS(function(exports, module) {
|
|
3579
|
-
'use strict';
|
|
3580
|
-
var normalizeOpts = require_normalize_options();
|
|
3581
|
-
var resolveLength = require_resolve_length();
|
|
3582
|
-
var plain = require_plain();
|
|
3583
|
-
module.exports = function(fn) {
|
|
3584
|
-
var options = normalizeOpts(arguments[1]), length;
|
|
3585
|
-
if (!options.normalizer) {
|
|
3586
|
-
length = options.length = resolveLength(options.length, fn.length, options.async);
|
|
3587
|
-
if (length !== 0) {
|
|
3588
|
-
if (options.primitive) {
|
|
3589
|
-
if (length === false) {
|
|
3590
|
-
options.normalizer = require_primitive();
|
|
3591
|
-
} else if (length > 1) {
|
|
3592
|
-
options.normalizer = require_get_primitive_fixed()(length);
|
|
3460
|
+
if (entity.classNames) {
|
|
3461
|
+
res += entity.classNames.map(function(cn) {
|
|
3462
|
+
return '.' + utils_1.escapeIdentifier(cn);
|
|
3463
|
+
}).join('');
|
|
3464
|
+
}
|
|
3465
|
+
if (entity.attrs) {
|
|
3466
|
+
res += entity.attrs.map(function(attr) {
|
|
3467
|
+
if ('operator' in attr) {
|
|
3468
|
+
if (attr.valueType === 'substitute') {
|
|
3469
|
+
return '[' + utils_1.escapeIdentifier(attr.name) + attr.operator + '$' + attr.value + ']';
|
|
3470
|
+
} else {
|
|
3471
|
+
return '[' + utils_1.escapeIdentifier(attr.name) + attr.operator + utils_1.escapeStr(attr.value) + ']';
|
|
3472
|
+
}
|
|
3473
|
+
} else {
|
|
3474
|
+
return '[' + utils_1.escapeIdentifier(attr.name) + ']';
|
|
3593
3475
|
}
|
|
3594
|
-
}
|
|
3595
|
-
options.normalizer = require_get()();
|
|
3596
|
-
} else if (length === 1) {
|
|
3597
|
-
options.normalizer = require_get_1()();
|
|
3598
|
-
} else {
|
|
3599
|
-
options.normalizer = require_get_fixed()(length);
|
|
3600
|
-
}
|
|
3476
|
+
}).join('');
|
|
3601
3477
|
}
|
|
3478
|
+
if (entity.pseudos) {
|
|
3479
|
+
res += entity.pseudos.map(function(pseudo) {
|
|
3480
|
+
if (pseudo.valueType) {
|
|
3481
|
+
if (pseudo.valueType === 'selector') {
|
|
3482
|
+
return ':' + utils_1.escapeIdentifier(pseudo.name) + '(' + renderEntity(pseudo.value) + ')';
|
|
3483
|
+
} else if (pseudo.valueType === 'substitute') {
|
|
3484
|
+
return ':' + utils_1.escapeIdentifier(pseudo.name) + '($' + pseudo.value + ')';
|
|
3485
|
+
} else if (pseudo.valueType === 'numeric') {
|
|
3486
|
+
return ':' + utils_1.escapeIdentifier(pseudo.name) + '(' + pseudo.value + ')';
|
|
3487
|
+
} else {
|
|
3488
|
+
return ':' + utils_1.escapeIdentifier(pseudo.name) + '(' + utils_1.escapeIdentifier(pseudo.value) + ')';
|
|
3489
|
+
}
|
|
3490
|
+
} else {
|
|
3491
|
+
return ':' + utils_1.escapeIdentifier(pseudo.name);
|
|
3492
|
+
}
|
|
3493
|
+
}).join('');
|
|
3494
|
+
}
|
|
3495
|
+
break;
|
|
3496
|
+
|
|
3497
|
+
default:
|
|
3498
|
+
throw Error('Unknown entity type: "' + entity.type + '".');
|
|
3602
3499
|
}
|
|
3603
|
-
|
|
3604
|
-
|
|
3605
|
-
|
|
3606
|
-
|
|
3607
|
-
|
|
3608
|
-
|
|
3609
|
-
|
|
3610
|
-
|
|
3611
|
-
|
|
3612
|
-
|
|
3613
|
-
|
|
3614
|
-
|
|
3615
|
-
|
|
3616
|
-
|
|
3617
|
-
|
|
3618
|
-
|
|
3619
|
-
|
|
3500
|
+
return res;
|
|
3501
|
+
}
|
|
3502
|
+
exports.renderEntity = renderEntity;
|
|
3503
|
+
});
|
|
3504
|
+
var require_lib = __commonJS(function(exports) {
|
|
3505
|
+
'use strict';
|
|
3506
|
+
Object.defineProperty(exports, '__esModule', {
|
|
3507
|
+
value: true
|
|
3508
|
+
});
|
|
3509
|
+
var parser_context_1 = require_parser_context();
|
|
3510
|
+
var render_1 = require_render();
|
|
3511
|
+
var CssSelectorParser3 = function() {
|
|
3512
|
+
function CssSelectorParser4() {
|
|
3513
|
+
this.pseudos = {};
|
|
3514
|
+
this.attrEqualityMods = {};
|
|
3515
|
+
this.ruleNestingOperators = {};
|
|
3516
|
+
this.substitutesEnabled = false;
|
|
3620
3517
|
}
|
|
3621
|
-
|
|
3622
|
-
|
|
3518
|
+
CssSelectorParser4.prototype.registerSelectorPseudos = function() {
|
|
3519
|
+
var pseudos = [];
|
|
3520
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
3521
|
+
pseudos[_i] = arguments[_i];
|
|
3522
|
+
}
|
|
3523
|
+
for (var _a = 0, pseudos_1 = pseudos; _a < pseudos_1.length; _a++) {
|
|
3524
|
+
var pseudo = pseudos_1[_a];
|
|
3525
|
+
this.pseudos[pseudo] = 'selector';
|
|
3526
|
+
}
|
|
3527
|
+
return this;
|
|
3528
|
+
};
|
|
3529
|
+
CssSelectorParser4.prototype.unregisterSelectorPseudos = function() {
|
|
3530
|
+
var pseudos = [];
|
|
3531
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
3532
|
+
pseudos[_i] = arguments[_i];
|
|
3533
|
+
}
|
|
3534
|
+
for (var _a = 0, pseudos_2 = pseudos; _a < pseudos_2.length; _a++) {
|
|
3535
|
+
var pseudo = pseudos_2[_a];
|
|
3536
|
+
delete this.pseudos[pseudo];
|
|
3537
|
+
}
|
|
3538
|
+
return this;
|
|
3539
|
+
};
|
|
3540
|
+
CssSelectorParser4.prototype.registerNumericPseudos = function() {
|
|
3541
|
+
var pseudos = [];
|
|
3542
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
3543
|
+
pseudos[_i] = arguments[_i];
|
|
3544
|
+
}
|
|
3545
|
+
for (var _a = 0, pseudos_3 = pseudos; _a < pseudos_3.length; _a++) {
|
|
3546
|
+
var pseudo = pseudos_3[_a];
|
|
3547
|
+
this.pseudos[pseudo] = 'numeric';
|
|
3548
|
+
}
|
|
3549
|
+
return this;
|
|
3550
|
+
};
|
|
3551
|
+
CssSelectorParser4.prototype.unregisterNumericPseudos = function() {
|
|
3552
|
+
var pseudos = [];
|
|
3553
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
3554
|
+
pseudos[_i] = arguments[_i];
|
|
3555
|
+
}
|
|
3556
|
+
for (var _a = 0, pseudos_4 = pseudos; _a < pseudos_4.length; _a++) {
|
|
3557
|
+
var pseudo = pseudos_4[_a];
|
|
3558
|
+
delete this.pseudos[pseudo];
|
|
3559
|
+
}
|
|
3560
|
+
return this;
|
|
3561
|
+
};
|
|
3562
|
+
CssSelectorParser4.prototype.registerNestingOperators = function() {
|
|
3563
|
+
var operators = [];
|
|
3564
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
3565
|
+
operators[_i] = arguments[_i];
|
|
3566
|
+
}
|
|
3567
|
+
for (var _a = 0, operators_1 = operators; _a < operators_1.length; _a++) {
|
|
3568
|
+
var operator = operators_1[_a];
|
|
3569
|
+
this.ruleNestingOperators[operator] = true;
|
|
3570
|
+
}
|
|
3571
|
+
return this;
|
|
3572
|
+
};
|
|
3573
|
+
CssSelectorParser4.prototype.unregisterNestingOperators = function() {
|
|
3574
|
+
var operators = [];
|
|
3575
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
3576
|
+
operators[_i] = arguments[_i];
|
|
3577
|
+
}
|
|
3578
|
+
for (var _a = 0, operators_2 = operators; _a < operators_2.length; _a++) {
|
|
3579
|
+
var operator = operators_2[_a];
|
|
3580
|
+
delete this.ruleNestingOperators[operator];
|
|
3581
|
+
}
|
|
3582
|
+
return this;
|
|
3583
|
+
};
|
|
3584
|
+
CssSelectorParser4.prototype.registerAttrEqualityMods = function() {
|
|
3585
|
+
var mods = [];
|
|
3586
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
3587
|
+
mods[_i] = arguments[_i];
|
|
3588
|
+
}
|
|
3589
|
+
for (var _a = 0, mods_1 = mods; _a < mods_1.length; _a++) {
|
|
3590
|
+
var mod = mods_1[_a];
|
|
3591
|
+
this.attrEqualityMods[mod] = true;
|
|
3592
|
+
}
|
|
3593
|
+
return this;
|
|
3594
|
+
};
|
|
3595
|
+
CssSelectorParser4.prototype.unregisterAttrEqualityMods = function() {
|
|
3596
|
+
var mods = [];
|
|
3597
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
3598
|
+
mods[_i] = arguments[_i];
|
|
3599
|
+
}
|
|
3600
|
+
for (var _a = 0, mods_2 = mods; _a < mods_2.length; _a++) {
|
|
3601
|
+
var mod = mods_2[_a];
|
|
3602
|
+
delete this.attrEqualityMods[mod];
|
|
3603
|
+
}
|
|
3604
|
+
return this;
|
|
3605
|
+
};
|
|
3606
|
+
CssSelectorParser4.prototype.enableSubstitutes = function() {
|
|
3607
|
+
this.substitutesEnabled = true;
|
|
3608
|
+
return this;
|
|
3609
|
+
};
|
|
3610
|
+
CssSelectorParser4.prototype.disableSubstitutes = function() {
|
|
3611
|
+
this.substitutesEnabled = false;
|
|
3612
|
+
return this;
|
|
3613
|
+
};
|
|
3614
|
+
CssSelectorParser4.prototype.parse = function(str) {
|
|
3615
|
+
return parser_context_1.parseCssSelector(str, 0, this.pseudos, this.attrEqualityMods, this.ruleNestingOperators, this.substitutesEnabled);
|
|
3616
|
+
};
|
|
3617
|
+
CssSelectorParser4.prototype.render = function(path) {
|
|
3618
|
+
return render_1.renderEntity(path).trim();
|
|
3619
|
+
};
|
|
3620
|
+
return CssSelectorParser4;
|
|
3621
|
+
}();
|
|
3622
|
+
exports.CssSelectorParser = CssSelectorParser3;
|
|
3623
3623
|
});
|
|
3624
3624
|
var require_doT = __commonJS(function(exports, module) {
|
|
3625
3625
|
(function() {
|
|
@@ -5084,7 +5084,7 @@
|
|
|
5084
5084
|
return check_helper_default;
|
|
5085
5085
|
},
|
|
5086
5086
|
clone: function clone() {
|
|
5087
|
-
return
|
|
5087
|
+
return _clone;
|
|
5088
5088
|
},
|
|
5089
5089
|
closest: function closest() {
|
|
5090
5090
|
return closest_default;
|
|
@@ -5162,7 +5162,7 @@
|
|
|
5162
5162
|
return get_rule_default;
|
|
5163
5163
|
},
|
|
5164
5164
|
getScroll: function getScroll() {
|
|
5165
|
-
return
|
|
5165
|
+
return get_scroll_default;
|
|
5166
5166
|
},
|
|
5167
5167
|
getScrollState: function getScrollState() {
|
|
5168
5168
|
return get_scroll_state_default;
|
|
@@ -5649,12 +5649,20 @@
|
|
|
5649
5649
|
};
|
|
5650
5650
|
}();
|
|
5651
5651
|
var element_matches_default = matchesSelector;
|
|
5652
|
-
|
|
5653
|
-
|
|
5652
|
+
var import_memoizee = __toModule(require_memoizee());
|
|
5653
|
+
axe._memoizedFns = [];
|
|
5654
|
+
function memoizeImplementation(fn) {
|
|
5655
|
+
var memoized = (0, import_memoizee['default'])(fn);
|
|
5656
|
+
axe._memoizedFns.push(memoized);
|
|
5657
|
+
return memoized;
|
|
5658
|
+
}
|
|
5659
|
+
var memoize_default = memoizeImplementation;
|
|
5660
|
+
var isXHTML = memoize_default(function(doc) {
|
|
5661
|
+
if (!(doc !== null && doc !== void 0 && doc.createElement)) {
|
|
5654
5662
|
return false;
|
|
5655
5663
|
}
|
|
5656
5664
|
return doc.createElement('A').localName === 'A';
|
|
5657
|
-
}
|
|
5665
|
+
});
|
|
5658
5666
|
var is_xhtml_default = isXHTML;
|
|
5659
5667
|
function getShadowSelector(generateSelector2, elm) {
|
|
5660
5668
|
var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
@@ -5687,7 +5695,6 @@
|
|
|
5687
5695
|
});
|
|
5688
5696
|
}
|
|
5689
5697
|
var get_shadow_selector_default = getShadowSelector;
|
|
5690
|
-
var xhtml;
|
|
5691
5698
|
var ignoredAttributes = [ 'class', 'style', 'id', 'selected', 'checked', 'disabled', 'tabindex', 'aria-checked', 'aria-selected', 'aria-invalid', 'aria-activedescendant', 'aria-busy', 'aria-disabled', 'aria-expanded', 'aria-grabbed', 'aria-pressed', 'aria-valuenow' ];
|
|
5692
5699
|
var MAXATTRIBUTELENGTH = 31;
|
|
5693
5700
|
var attrCharsRegex = /([\\"])/g;
|
|
@@ -5717,7 +5724,7 @@
|
|
|
5717
5724
|
return !ignoredAttributes.includes(at.name) && at.name.indexOf(':') === -1 && (!at.value || at.value.length < MAXATTRIBUTELENGTH);
|
|
5718
5725
|
}
|
|
5719
5726
|
function _getSelectorData(domTree) {
|
|
5720
|
-
var
|
|
5727
|
+
var data = {
|
|
5721
5728
|
classes: {},
|
|
5722
5729
|
tags: {},
|
|
5723
5730
|
attributes: {}
|
|
@@ -5730,18 +5737,18 @@
|
|
|
5730
5737
|
var node = current.actualNode;
|
|
5731
5738
|
if (!!node.querySelectorAll) {
|
|
5732
5739
|
var tag = node.nodeName;
|
|
5733
|
-
if (
|
|
5734
|
-
|
|
5740
|
+
if (data.tags[tag]) {
|
|
5741
|
+
data.tags[tag]++;
|
|
5735
5742
|
} else {
|
|
5736
|
-
|
|
5743
|
+
data.tags[tag] = 1;
|
|
5737
5744
|
}
|
|
5738
5745
|
if (node.classList) {
|
|
5739
5746
|
Array.from(node.classList).forEach(function(cl) {
|
|
5740
5747
|
var ind = escape_selector_default(cl);
|
|
5741
|
-
if (
|
|
5742
|
-
|
|
5748
|
+
if (data.classes[ind]) {
|
|
5749
|
+
data.classes[ind]++;
|
|
5743
5750
|
} else {
|
|
5744
|
-
|
|
5751
|
+
data.classes[ind] = 1;
|
|
5745
5752
|
}
|
|
5746
5753
|
});
|
|
5747
5754
|
}
|
|
@@ -5749,10 +5756,10 @@
|
|
|
5749
5756
|
Array.from(get_node_attributes_default(node)).filter(filterAttributes).forEach(function(at) {
|
|
5750
5757
|
var atnv = getAttributeNameValue(node, at);
|
|
5751
5758
|
if (atnv) {
|
|
5752
|
-
if (
|
|
5753
|
-
|
|
5759
|
+
if (data.attributes[atnv]) {
|
|
5760
|
+
data.attributes[atnv]++;
|
|
5754
5761
|
} else {
|
|
5755
|
-
|
|
5762
|
+
data.attributes[atnv] = 1;
|
|
5756
5763
|
}
|
|
5757
5764
|
}
|
|
5758
5765
|
});
|
|
@@ -5769,7 +5776,7 @@
|
|
|
5769
5776
|
while (currentLevel.length) {
|
|
5770
5777
|
_loop2();
|
|
5771
5778
|
}
|
|
5772
|
-
return
|
|
5779
|
+
return data;
|
|
5773
5780
|
}
|
|
5774
5781
|
function uncommonClasses(node, selectorData) {
|
|
5775
5782
|
var retVal = [];
|
|
@@ -5812,9 +5819,7 @@
|
|
|
5812
5819
|
}
|
|
5813
5820
|
}
|
|
5814
5821
|
function getBaseSelector(elm) {
|
|
5815
|
-
|
|
5816
|
-
xhtml = is_xhtml_default(document);
|
|
5817
|
-
}
|
|
5822
|
+
var xhtml = is_xhtml_default(document);
|
|
5818
5823
|
return escape_selector_default(xhtml ? elm.localName : elm.nodeName.toLowerCase());
|
|
5819
5824
|
}
|
|
5820
5825
|
function uncommonAttributes(node, selectorData) {
|
|
@@ -6123,48 +6128,61 @@
|
|
|
6123
6128
|
}
|
|
6124
6129
|
};
|
|
6125
6130
|
},
|
|
6126
|
-
data: function data(
|
|
6127
|
-
checkResult.data =
|
|
6131
|
+
data: function data(_data) {
|
|
6132
|
+
checkResult.data = _data;
|
|
6128
6133
|
},
|
|
6129
6134
|
relatedNodes: function relatedNodes(nodes) {
|
|
6130
6135
|
if (!window.Node) {
|
|
6131
6136
|
return;
|
|
6132
6137
|
}
|
|
6133
|
-
|
|
6134
|
-
|
|
6135
|
-
|
|
6136
|
-
|
|
6137
|
-
return;
|
|
6138
|
+
if (nodes instanceof window.Node || nodes instanceof abstract_virtual_node_default) {
|
|
6139
|
+
nodes = [ nodes ];
|
|
6140
|
+
} else {
|
|
6141
|
+
nodes = to_array_default(nodes);
|
|
6138
6142
|
}
|
|
6139
|
-
checkResult.relatedNodes =
|
|
6140
|
-
|
|
6143
|
+
checkResult.relatedNodes = [];
|
|
6144
|
+
nodes.forEach(function(node) {
|
|
6145
|
+
if (node instanceof abstract_virtual_node_default) {
|
|
6146
|
+
node = node.actualNode;
|
|
6147
|
+
}
|
|
6148
|
+
if (node instanceof window.Node) {
|
|
6149
|
+
var dqElm = new dq_element_default(node, options);
|
|
6150
|
+
checkResult.relatedNodes.push(dqElm);
|
|
6151
|
+
}
|
|
6141
6152
|
});
|
|
6142
6153
|
}
|
|
6143
6154
|
};
|
|
6144
6155
|
}
|
|
6145
6156
|
var check_helper_default = checkHelper;
|
|
6146
|
-
function
|
|
6157
|
+
function _clone(obj) {
|
|
6158
|
+
return cloneRecused(obj, new Map());
|
|
6159
|
+
}
|
|
6160
|
+
function cloneRecused(obj, seen) {
|
|
6147
6161
|
var _window, _window2;
|
|
6148
|
-
|
|
6149
|
-
if ((_window = window) !== null && _window !== void 0 && _window.Node && obj instanceof window.Node || (_window2 = window) !== null && _window2 !== void 0 && _window2.HTMLCollection && obj instanceof window.HTMLCollection) {
|
|
6162
|
+
if (obj === null || _typeof(obj) !== 'object') {
|
|
6150
6163
|
return obj;
|
|
6151
6164
|
}
|
|
6152
|
-
if (
|
|
6153
|
-
|
|
6154
|
-
|
|
6155
|
-
|
|
6156
|
-
|
|
6157
|
-
|
|
6158
|
-
|
|
6159
|
-
|
|
6160
|
-
|
|
6161
|
-
|
|
6162
|
-
|
|
6163
|
-
}
|
|
6165
|
+
if ((_window = window) !== null && _window !== void 0 && _window.Node && obj instanceof window.Node || (_window2 = window) !== null && _window2 !== void 0 && _window2.HTMLCollection && obj instanceof window.HTMLCollection || 'nodeName' in obj && 'nodeType' in obj && 'ownerDocument' in obj) {
|
|
6166
|
+
return obj;
|
|
6167
|
+
}
|
|
6168
|
+
if (seen.has(obj)) {
|
|
6169
|
+
return seen.get(obj);
|
|
6170
|
+
}
|
|
6171
|
+
if (Array.isArray(obj)) {
|
|
6172
|
+
var out2 = [];
|
|
6173
|
+
seen.set(obj, out2);
|
|
6174
|
+
obj.forEach(function(value) {
|
|
6175
|
+
out2.push(cloneRecused(value, seen));
|
|
6176
|
+
});
|
|
6177
|
+
return out2;
|
|
6178
|
+
}
|
|
6179
|
+
var out = {};
|
|
6180
|
+
seen.set(obj, out);
|
|
6181
|
+
for (var key in obj) {
|
|
6182
|
+
out[key] = cloneRecused(obj[key], seen);
|
|
6164
6183
|
}
|
|
6165
6184
|
return out;
|
|
6166
6185
|
}
|
|
6167
|
-
var clone_default = clone;
|
|
6168
6186
|
var import_css_selector_parser = __toModule(require_lib());
|
|
6169
6187
|
var parser = new import_css_selector_parser.CssSelectorParser();
|
|
6170
6188
|
parser.registerSelectorPseudos('not');
|
|
@@ -6597,7 +6615,7 @@
|
|
|
6597
6615
|
var errorTypes = Object.freeze([ 'EvalError', 'RangeError', 'ReferenceError', 'SyntaxError', 'TypeError', 'URIError' ]);
|
|
6598
6616
|
function stringifyMessage(_ref2) {
|
|
6599
6617
|
var topic = _ref2.topic, channelId = _ref2.channelId, message = _ref2.message, messageId = _ref2.messageId, keepalive = _ref2.keepalive;
|
|
6600
|
-
var
|
|
6618
|
+
var data = {
|
|
6601
6619
|
channelId: channelId,
|
|
6602
6620
|
topic: topic,
|
|
6603
6621
|
messageId: messageId,
|
|
@@ -6605,28 +6623,28 @@
|
|
|
6605
6623
|
source: getSource2()
|
|
6606
6624
|
};
|
|
6607
6625
|
if (message instanceof Error) {
|
|
6608
|
-
|
|
6626
|
+
data.error = {
|
|
6609
6627
|
name: message.name,
|
|
6610
6628
|
message: message.message,
|
|
6611
6629
|
stack: message.stack
|
|
6612
6630
|
};
|
|
6613
6631
|
} else {
|
|
6614
|
-
|
|
6632
|
+
data.payload = message;
|
|
6615
6633
|
}
|
|
6616
|
-
return JSON.stringify(
|
|
6634
|
+
return JSON.stringify(data);
|
|
6617
6635
|
}
|
|
6618
6636
|
function parseMessage(dataString) {
|
|
6619
|
-
var
|
|
6637
|
+
var data;
|
|
6620
6638
|
try {
|
|
6621
|
-
|
|
6639
|
+
data = JSON.parse(dataString);
|
|
6622
6640
|
} catch (e) {
|
|
6623
6641
|
return;
|
|
6624
6642
|
}
|
|
6625
|
-
if (!isRespondableMessage(
|
|
6643
|
+
if (!isRespondableMessage(data)) {
|
|
6626
6644
|
return;
|
|
6627
6645
|
}
|
|
6628
|
-
var
|
|
6629
|
-
var message = _typeof(
|
|
6646
|
+
var _data2 = data, topic = _data2.topic, channelId = _data2.channelId, messageId = _data2.messageId, keepalive = _data2.keepalive;
|
|
6647
|
+
var message = _typeof(data.error) === 'object' ? buildErrorObject(data.error) : data.payload;
|
|
6630
6648
|
return {
|
|
6631
6649
|
topic: topic,
|
|
6632
6650
|
message: message,
|
|
@@ -6700,22 +6718,22 @@
|
|
|
6700
6718
|
messageIds.push(uuid2);
|
|
6701
6719
|
return true;
|
|
6702
6720
|
}
|
|
6703
|
-
function postMessage(win,
|
|
6704
|
-
if (typeof replyHandler === 'function') {
|
|
6705
|
-
storeReplyHandler(data2.channelId, replyHandler, sendToParent);
|
|
6706
|
-
}
|
|
6721
|
+
function postMessage(win, data, sendToParent, replyHandler) {
|
|
6707
6722
|
sendToParent ? assertIsParentWindow(win) : assertIsFrameWindow(win);
|
|
6708
|
-
if (
|
|
6709
|
-
axe.log(
|
|
6723
|
+
if (data.message instanceof Error && !sendToParent) {
|
|
6724
|
+
axe.log(data.message);
|
|
6710
6725
|
return false;
|
|
6711
6726
|
}
|
|
6712
6727
|
var dataString = stringifyMessage(_extends({
|
|
6713
6728
|
messageId: createMessageId()
|
|
6714
|
-
},
|
|
6729
|
+
}, data));
|
|
6715
6730
|
var allowedOrigins = axe._audit.allowedOrigins;
|
|
6716
6731
|
if (!allowedOrigins || !allowedOrigins.length) {
|
|
6717
6732
|
return false;
|
|
6718
6733
|
}
|
|
6734
|
+
if (typeof replyHandler === 'function') {
|
|
6735
|
+
storeReplyHandler(data.channelId, replyHandler, sendToParent);
|
|
6736
|
+
}
|
|
6719
6737
|
allowedOrigins.forEach(function(origin) {
|
|
6720
6738
|
try {
|
|
6721
6739
|
win.postMessage(dataString, origin);
|
|
@@ -6747,12 +6765,12 @@
|
|
|
6747
6765
|
function createResponder(win, channelId) {
|
|
6748
6766
|
var sendToParent = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
|
|
6749
6767
|
return function respond(message, keepalive, replyHandler) {
|
|
6750
|
-
var
|
|
6768
|
+
var data = {
|
|
6751
6769
|
channelId: channelId,
|
|
6752
6770
|
message: message,
|
|
6753
6771
|
keepalive: keepalive
|
|
6754
6772
|
};
|
|
6755
|
-
postMessage(win,
|
|
6773
|
+
postMessage(win, data, sendToParent, replyHandler);
|
|
6756
6774
|
};
|
|
6757
6775
|
}
|
|
6758
6776
|
function originIsAllowed(origin) {
|
|
@@ -6762,8 +6780,8 @@
|
|
|
6762
6780
|
function messageHandler(_ref3, topicHandler) {
|
|
6763
6781
|
var origin = _ref3.origin, dataString = _ref3.data, win = _ref3.source;
|
|
6764
6782
|
try {
|
|
6765
|
-
var
|
|
6766
|
-
var channelId =
|
|
6783
|
+
var data = parseMessage(dataString) || {};
|
|
6784
|
+
var channelId = data.channelId, message = data.message, messageId = data.messageId;
|
|
6767
6785
|
if (!originIsAllowed(origin) || !isNewMessage(messageId)) {
|
|
6768
6786
|
return;
|
|
6769
6787
|
}
|
|
@@ -6772,12 +6790,12 @@
|
|
|
6772
6790
|
return false;
|
|
6773
6791
|
}
|
|
6774
6792
|
try {
|
|
6775
|
-
if (
|
|
6793
|
+
if (data.topic) {
|
|
6776
6794
|
var responder = createResponder(win, channelId);
|
|
6777
6795
|
assertIsParentWindow(win);
|
|
6778
|
-
topicHandler(
|
|
6796
|
+
topicHandler(data, responder);
|
|
6779
6797
|
} else {
|
|
6780
|
-
callReplyHandler(win,
|
|
6798
|
+
callReplyHandler(win, data);
|
|
6781
6799
|
}
|
|
6782
6800
|
} catch (error) {
|
|
6783
6801
|
processError(win, error, channelId);
|
|
@@ -6787,8 +6805,8 @@
|
|
|
6787
6805
|
return false;
|
|
6788
6806
|
}
|
|
6789
6807
|
}
|
|
6790
|
-
function callReplyHandler(win,
|
|
6791
|
-
var channelId =
|
|
6808
|
+
function callReplyHandler(win, data) {
|
|
6809
|
+
var channelId = data.channelId, message = data.message, keepalive = data.keepalive;
|
|
6792
6810
|
var _ref4 = getReplyHandler(channelId) || {}, replyHandler = _ref4.replyHandler, sendToParent = _ref4.sendToParent;
|
|
6793
6811
|
if (!replyHandler) {
|
|
6794
6812
|
return;
|
|
@@ -6818,11 +6836,11 @@
|
|
|
6818
6836
|
window.removeEventListener('message', handler, false);
|
|
6819
6837
|
};
|
|
6820
6838
|
},
|
|
6821
|
-
post: function post(win,
|
|
6839
|
+
post: function post(win, data, replyHandler) {
|
|
6822
6840
|
if (typeof window.addEventListener !== 'function') {
|
|
6823
6841
|
return false;
|
|
6824
6842
|
}
|
|
6825
|
-
return postMessage(win,
|
|
6843
|
+
return postMessage(win, data, false, replyHandler);
|
|
6826
6844
|
}
|
|
6827
6845
|
};
|
|
6828
6846
|
function setDefaultFrameMessenger(respondable2) {
|
|
@@ -6832,16 +6850,16 @@
|
|
|
6832
6850
|
var postMessage2;
|
|
6833
6851
|
var topicHandlers = {};
|
|
6834
6852
|
function _respondable(win, topic, message, keepalive, replyHandler) {
|
|
6835
|
-
var
|
|
6853
|
+
var data = {
|
|
6836
6854
|
topic: topic,
|
|
6837
6855
|
message: message,
|
|
6838
6856
|
channelId: ''.concat(v4(), ':').concat(v4()),
|
|
6839
6857
|
keepalive: keepalive
|
|
6840
6858
|
};
|
|
6841
|
-
return postMessage2(win,
|
|
6859
|
+
return postMessage2(win, data, replyHandler);
|
|
6842
6860
|
}
|
|
6843
|
-
function messageListener(
|
|
6844
|
-
var topic =
|
|
6861
|
+
function messageListener(data, responder) {
|
|
6862
|
+
var topic = data.topic, message = data.message, keepalive = data.keepalive;
|
|
6845
6863
|
var topicHandler = topicHandlers[topic];
|
|
6846
6864
|
if (!topicHandler) {
|
|
6847
6865
|
return;
|
|
@@ -6913,12 +6931,12 @@
|
|
|
6913
6931
|
var timeout = setTimeout(function collectResultFramesTimeout() {
|
|
6914
6932
|
reject(err('Axe in frame timed out', node));
|
|
6915
6933
|
}, frameWaitTime);
|
|
6916
|
-
_respondable(win, 'axe.start', parameters, void 0, function(
|
|
6934
|
+
_respondable(win, 'axe.start', parameters, void 0, function(data) {
|
|
6917
6935
|
clearTimeout(timeout);
|
|
6918
|
-
if (
|
|
6919
|
-
resolve(
|
|
6936
|
+
if (data instanceof Error === false) {
|
|
6937
|
+
resolve(data);
|
|
6920
6938
|
} else {
|
|
6921
|
-
reject(
|
|
6939
|
+
reject(data);
|
|
6922
6940
|
}
|
|
6923
6941
|
});
|
|
6924
6942
|
}
|
|
@@ -6937,7 +6955,7 @@
|
|
|
6937
6955
|
function findBy(array, key, value) {
|
|
6938
6956
|
if (Array.isArray(array)) {
|
|
6939
6957
|
return array.find(function(obj) {
|
|
6940
|
-
return _typeof(obj) === 'object' && obj[key] === value;
|
|
6958
|
+
return obj !== null && _typeof(obj) === 'object' && Object.hasOwn(obj, key) && obj[key] === value;
|
|
6941
6959
|
});
|
|
6942
6960
|
}
|
|
6943
6961
|
}
|
|
@@ -7060,8 +7078,8 @@
|
|
|
7060
7078
|
_sendCommandToFrame(frameElement, params, callback, rej);
|
|
7061
7079
|
});
|
|
7062
7080
|
});
|
|
7063
|
-
q.then(function(
|
|
7064
|
-
resolve(merge_results_default(
|
|
7081
|
+
q.then(function(data) {
|
|
7082
|
+
resolve(merge_results_default(data, options));
|
|
7065
7083
|
})['catch'](reject);
|
|
7066
7084
|
}
|
|
7067
7085
|
function _contains(vNode, otherVNode) {
|
|
@@ -7319,14 +7337,6 @@
|
|
|
7319
7337
|
return find_up_virtual_default(get_node_from_tree_default(element), target);
|
|
7320
7338
|
}
|
|
7321
7339
|
var find_up_default = findUp;
|
|
7322
|
-
var import_memoizee = __toModule(require_memoizee());
|
|
7323
|
-
axe._memoizedFns = [];
|
|
7324
|
-
function memoizeImplementation(fn) {
|
|
7325
|
-
var memoized = (0, import_memoizee['default'])(fn);
|
|
7326
|
-
axe._memoizedFns.push(memoized);
|
|
7327
|
-
return memoized;
|
|
7328
|
-
}
|
|
7329
|
-
var memoize_default = memoizeImplementation;
|
|
7330
7340
|
function _rectsOverlap(rect1, rect2) {
|
|
7331
7341
|
return (rect1.left | 0) < (rect2.right | 0) && (rect1.right | 0) > (rect2.left | 0) && (rect1.top | 0) < (rect2.bottom | 0) && (rect1.bottom | 0) > (rect2.top | 0);
|
|
7332
7342
|
}
|
|
@@ -7368,7 +7378,7 @@
|
|
|
7368
7378
|
return vNode.getComputedStylePropertyValue('opacity') === '0';
|
|
7369
7379
|
}
|
|
7370
7380
|
function scrollHidden(vNode) {
|
|
7371
|
-
var scroll =
|
|
7381
|
+
var scroll = get_scroll_default(vNode.actualNode);
|
|
7372
7382
|
var elHeight = parseInt(vNode.getComputedStylePropertyValue('height'));
|
|
7373
7383
|
var elWidth = parseInt(vNode.getComputedStylePropertyValue('width'));
|
|
7374
7384
|
return !!scroll && (elHeight === 0 || elWidth === 0);
|
|
@@ -7661,7 +7671,7 @@
|
|
|
7661
7671
|
vNode._stackingOrder = [ createContext(ROOT_ORDER, null) ];
|
|
7662
7672
|
(_rootGrid = rootGrid) !== null && _rootGrid !== void 0 ? _rootGrid : rootGrid = new Grid();
|
|
7663
7673
|
addNodeToGrid(rootGrid, vNode);
|
|
7664
|
-
if (
|
|
7674
|
+
if (get_scroll_default(vNode.actualNode)) {
|
|
7665
7675
|
var subGrid = new Grid(vNode);
|
|
7666
7676
|
vNode._subGrid = subGrid;
|
|
7667
7677
|
}
|
|
@@ -7685,7 +7695,7 @@
|
|
|
7685
7695
|
_vNode._stackingOrder = createStackingOrder(_vNode, parentVNode, nodeIndex++);
|
|
7686
7696
|
var scrollRegionParent = findScrollRegionParent(_vNode, parentVNode);
|
|
7687
7697
|
var grid = scrollRegionParent ? scrollRegionParent._subGrid : rootGrid;
|
|
7688
|
-
if (
|
|
7698
|
+
if (get_scroll_default(_vNode.actualNode)) {
|
|
7689
7699
|
var _subGrid = new Grid(_vNode);
|
|
7690
7700
|
_vNode._subGrid = _subGrid;
|
|
7691
7701
|
}
|
|
@@ -7816,7 +7826,7 @@
|
|
|
7816
7826
|
var scrollRegionParent = null;
|
|
7817
7827
|
var checkedNodes = [ vNode ];
|
|
7818
7828
|
while (parentVNode) {
|
|
7819
|
-
if (
|
|
7829
|
+
if (get_scroll_default(parentVNode.actualNode)) {
|
|
7820
7830
|
scrollRegionParent = parentVNode;
|
|
7821
7831
|
break;
|
|
7822
7832
|
}
|
|
@@ -9299,7 +9309,7 @@
|
|
|
9299
9309
|
slider: {
|
|
9300
9310
|
type: 'widget',
|
|
9301
9311
|
requiredAttrs: [ 'aria-valuenow' ],
|
|
9302
|
-
allowedAttrs: [ 'aria-valuemax', 'aria-valuemin', 'aria-orientation', 'aria-readonly', 'aria-valuetext' ],
|
|
9312
|
+
allowedAttrs: [ 'aria-valuemax', 'aria-valuemin', 'aria-orientation', 'aria-readonly', 'aria-required', 'aria-valuetext' ],
|
|
9303
9313
|
superclassRole: [ 'input', 'range' ],
|
|
9304
9314
|
accessibleNameRequired: true,
|
|
9305
9315
|
childrenPresentational: true
|
|
@@ -9337,7 +9347,7 @@
|
|
|
9337
9347
|
switch: {
|
|
9338
9348
|
type: 'widget',
|
|
9339
9349
|
requiredAttrs: [ 'aria-checked' ],
|
|
9340
|
-
allowedAttrs: [ 'aria-readonly' ],
|
|
9350
|
+
allowedAttrs: [ 'aria-readonly', 'aria-required' ],
|
|
9341
9351
|
superclassRole: [ 'checkbox' ],
|
|
9342
9352
|
accessibleNameRequired: true,
|
|
9343
9353
|
nameFromContent: true,
|
|
@@ -9951,7 +9961,7 @@
|
|
|
9951
9961
|
}, {
|
|
9952
9962
|
hasAccessibleName: true
|
|
9953
9963
|
} ],
|
|
9954
|
-
allowedRoles: [ 'button', 'checkbox', 'link', 'menuitem', 'menuitemcheckbox', 'menuitemradio', 'option', 'progressbar', 'radio', 'scrollbar', 'separator', 'slider', 'switch', 'tab', 'treeitem', 'doc-cover' ]
|
|
9964
|
+
allowedRoles: [ 'button', 'checkbox', 'link', 'menuitem', 'menuitemcheckbox', 'menuitemradio', 'meter', 'option', 'progressbar', 'radio', 'scrollbar', 'separator', 'slider', 'switch', 'tab', 'treeitem', 'doc-cover' ]
|
|
9955
9965
|
},
|
|
9956
9966
|
usemap: {
|
|
9957
9967
|
matches: '[usemap]',
|
|
@@ -10747,9 +10757,13 @@
|
|
|
10747
10757
|
}
|
|
10748
10758
|
return false;
|
|
10749
10759
|
}
|
|
10750
|
-
var
|
|
10751
|
-
return ''
|
|
10752
|
-
|
|
10760
|
+
var getSectioningElementSelector = function getSectioningElementSelector() {
|
|
10761
|
+
return cache_default.get('sectioningElementSelector', function() {
|
|
10762
|
+
return get_elements_by_content_type_default('sectioning').map(function(nodeName2) {
|
|
10763
|
+
return ''.concat(nodeName2, ':not([role])');
|
|
10764
|
+
}).join(', ') + ' , main:not([role]), [role=article], [role=complementary], [role=main], [role=navigation], [role=region]';
|
|
10765
|
+
});
|
|
10766
|
+
};
|
|
10753
10767
|
function hasAccessibleName(vNode) {
|
|
10754
10768
|
var ariaLabelledby = sanitize_default(arialabelledby_text_default(vNode));
|
|
10755
10769
|
var ariaLabel = sanitize_default(_arialabelText(vNode));
|
|
@@ -10775,7 +10789,7 @@
|
|
|
10775
10789
|
fieldset: 'group',
|
|
10776
10790
|
figure: 'figure',
|
|
10777
10791
|
footer: function footer(vNode) {
|
|
10778
|
-
var sectioningElement = closest_default(vNode,
|
|
10792
|
+
var sectioningElement = closest_default(vNode, getSectioningElementSelector());
|
|
10779
10793
|
return !sectioningElement ? 'contentinfo' : null;
|
|
10780
10794
|
},
|
|
10781
10795
|
form: function form(vNode) {
|
|
@@ -10788,7 +10802,7 @@
|
|
|
10788
10802
|
h5: 'heading',
|
|
10789
10803
|
h6: 'heading',
|
|
10790
10804
|
header: function header(vNode) {
|
|
10791
|
-
var sectioningElement = closest_default(vNode,
|
|
10805
|
+
var sectioningElement = closest_default(vNode, getSectioningElementSelector());
|
|
10792
10806
|
return !sectioningElement ? 'banner' : null;
|
|
10793
10807
|
},
|
|
10794
10808
|
hr: 'separator',
|
|
@@ -12255,22 +12269,26 @@
|
|
|
12255
12269
|
return element instanceof window.Node;
|
|
12256
12270
|
}
|
|
12257
12271
|
var is_node_default = isNode;
|
|
12258
|
-
var
|
|
12272
|
+
var cacheKey = 'color.incompleteData';
|
|
12259
12273
|
var incompleteData = {
|
|
12260
12274
|
set: function set(key, reason) {
|
|
12261
12275
|
if (typeof key !== 'string') {
|
|
12262
12276
|
throw new Error('Incomplete data: key must be a string');
|
|
12263
12277
|
}
|
|
12278
|
+
var data = cache_default.get(cacheKey, function() {
|
|
12279
|
+
return {};
|
|
12280
|
+
});
|
|
12264
12281
|
if (reason) {
|
|
12265
12282
|
data[key] = reason;
|
|
12266
12283
|
}
|
|
12267
12284
|
return data[key];
|
|
12268
12285
|
},
|
|
12269
12286
|
get: function get(key) {
|
|
12270
|
-
|
|
12287
|
+
var data = cache_default.get(cacheKey);
|
|
12288
|
+
return data === null || data === void 0 ? void 0 : data[key];
|
|
12271
12289
|
},
|
|
12272
12290
|
clear: function clear() {
|
|
12273
|
-
|
|
12291
|
+
cache_default.set(cacheKey, {});
|
|
12274
12292
|
}
|
|
12275
12293
|
};
|
|
12276
12294
|
var incomplete_data_default = incompleteData;
|
|
@@ -15667,7 +15685,7 @@
|
|
|
15667
15685
|
}
|
|
15668
15686
|
var elHeight = parseInt(style.getPropertyValue('height'));
|
|
15669
15687
|
var elWidth = parseInt(style.getPropertyValue('width'));
|
|
15670
|
-
var scroll =
|
|
15688
|
+
var scroll = get_scroll_default(el);
|
|
15671
15689
|
var scrollableWithZeroHeight = scroll && elHeight === 0;
|
|
15672
15690
|
var scrollableWithZeroWidth = scroll && elWidth === 0;
|
|
15673
15691
|
var posAbsoluteOverflowHiddenAndSmall = style.getPropertyValue('position') === 'absolute' && (elHeight < 2 || elWidth < 2) && style.getPropertyValue('overflow') === 'hidden';
|
|
@@ -15722,7 +15740,7 @@
|
|
|
15722
15740
|
var vNode = get_node_from_tree_default(node);
|
|
15723
15741
|
var ancestor = vNode.parent;
|
|
15724
15742
|
while (ancestor) {
|
|
15725
|
-
if (
|
|
15743
|
+
if (get_scroll_default(ancestor.actualNode)) {
|
|
15726
15744
|
return ancestor.actualNode;
|
|
15727
15745
|
}
|
|
15728
15746
|
ancestor = ancestor.parent;
|
|
@@ -15867,7 +15885,6 @@
|
|
|
15867
15885
|
return true;
|
|
15868
15886
|
}
|
|
15869
15887
|
var visually_overlaps_default = visuallyOverlaps;
|
|
15870
|
-
var isXHTMLGlobal;
|
|
15871
15888
|
var nodeIndex2 = 0;
|
|
15872
15889
|
var VirtualNode = function(_abstract_virtual_nod) {
|
|
15873
15890
|
_inherits(VirtualNode, _abstract_virtual_nod);
|
|
@@ -15886,10 +15903,7 @@
|
|
|
15886
15903
|
_this4.nodeIndex = nodeIndex2++;
|
|
15887
15904
|
_this4._isHidden = null;
|
|
15888
15905
|
_this4._cache = {};
|
|
15889
|
-
|
|
15890
|
-
isXHTMLGlobal = is_xhtml_default(node.ownerDocument);
|
|
15891
|
-
}
|
|
15892
|
-
_this4._isXHTML = isXHTMLGlobal;
|
|
15906
|
+
_this4._isXHTML = is_xhtml_default(node.ownerDocument);
|
|
15893
15907
|
if (node.nodeName.toLowerCase() === 'input') {
|
|
15894
15908
|
var type2 = node.getAttribute('type');
|
|
15895
15909
|
type2 = _this4._isXHTML ? type2 : (type2 || '').toLowerCase();
|
|
@@ -16054,7 +16068,7 @@
|
|
|
16054
16068
|
} else {
|
|
16055
16069
|
if (exp.id) {
|
|
16056
16070
|
var _selectorMap$idsKey$e;
|
|
16057
|
-
if (!selectorMap[idsKey] || !((_selectorMap$idsKey$e = selectorMap[idsKey][exp.id]) !== null && _selectorMap$idsKey$e !== void 0 && _selectorMap$idsKey$e.length)) {
|
|
16071
|
+
if (!selectorMap[idsKey] || !Object.hasOwn(selectorMap[idsKey], exp.id) || !((_selectorMap$idsKey$e = selectorMap[idsKey][exp.id]) !== null && _selectorMap$idsKey$e !== void 0 && _selectorMap$idsKey$e.length)) {
|
|
16058
16072
|
return;
|
|
16059
16073
|
}
|
|
16060
16074
|
nodes = selectorMap[idsKey][exp.id].filter(function(node) {
|
|
@@ -16106,7 +16120,9 @@
|
|
|
16106
16120
|
});
|
|
16107
16121
|
}
|
|
16108
16122
|
function cacheSelector(key, vNode, map) {
|
|
16109
|
-
map
|
|
16123
|
+
if (!Object.hasOwn(map, key)) {
|
|
16124
|
+
map[key] = [];
|
|
16125
|
+
}
|
|
16110
16126
|
map[key].push(vNode);
|
|
16111
16127
|
}
|
|
16112
16128
|
function cacheNodeSelectors(vNode, selectorMap) {
|
|
@@ -16331,46 +16347,46 @@
|
|
|
16331
16347
|
}
|
|
16332
16348
|
var process_aggregate_default = processAggregate;
|
|
16333
16349
|
var dataRegex = /\$\{\s?data\s?\}/g;
|
|
16334
|
-
function substitute(str,
|
|
16335
|
-
if (typeof
|
|
16336
|
-
return str.replace(dataRegex,
|
|
16350
|
+
function substitute(str, data) {
|
|
16351
|
+
if (typeof data === 'string') {
|
|
16352
|
+
return str.replace(dataRegex, data);
|
|
16337
16353
|
}
|
|
16338
|
-
for (var prop in
|
|
16339
|
-
if (
|
|
16354
|
+
for (var prop in data) {
|
|
16355
|
+
if (data.hasOwnProperty(prop)) {
|
|
16340
16356
|
var regex = new RegExp('\\${\\s?data\\.' + prop + '\\s?}', 'g');
|
|
16341
|
-
var replace = typeof
|
|
16357
|
+
var replace = typeof data[prop] === 'undefined' ? '' : String(data[prop]);
|
|
16342
16358
|
str = str.replace(regex, replace);
|
|
16343
16359
|
}
|
|
16344
16360
|
}
|
|
16345
16361
|
return str;
|
|
16346
16362
|
}
|
|
16347
|
-
function processMessage(message,
|
|
16363
|
+
function processMessage(message, data) {
|
|
16348
16364
|
if (!message) {
|
|
16349
16365
|
return;
|
|
16350
16366
|
}
|
|
16351
|
-
if (Array.isArray(
|
|
16352
|
-
|
|
16367
|
+
if (Array.isArray(data)) {
|
|
16368
|
+
data.values = data.join(', ');
|
|
16353
16369
|
if (typeof message.singular === 'string' && typeof message.plural === 'string') {
|
|
16354
|
-
var str2 =
|
|
16355
|
-
return substitute(str2,
|
|
16370
|
+
var str2 = data.length === 1 ? message.singular : message.plural;
|
|
16371
|
+
return substitute(str2, data);
|
|
16356
16372
|
}
|
|
16357
|
-
return substitute(message,
|
|
16373
|
+
return substitute(message, data);
|
|
16358
16374
|
}
|
|
16359
16375
|
if (typeof message === 'string') {
|
|
16360
|
-
return substitute(message,
|
|
16376
|
+
return substitute(message, data);
|
|
16361
16377
|
}
|
|
16362
|
-
if (typeof
|
|
16363
|
-
var _str = message[
|
|
16364
|
-
return substitute(_str,
|
|
16378
|
+
if (typeof data === 'string') {
|
|
16379
|
+
var _str = message[data];
|
|
16380
|
+
return substitute(_str, data);
|
|
16365
16381
|
}
|
|
16366
16382
|
var str = message['default'] || incompleteFallbackMessage();
|
|
16367
|
-
if (
|
|
16368
|
-
str = message[
|
|
16383
|
+
if (data && data.messageKey && message[data.messageKey]) {
|
|
16384
|
+
str = message[data.messageKey];
|
|
16369
16385
|
}
|
|
16370
|
-
return processMessage(str,
|
|
16386
|
+
return processMessage(str, data);
|
|
16371
16387
|
}
|
|
16372
16388
|
var process_message_default = processMessage;
|
|
16373
|
-
function getCheckMessage(checkId, type2,
|
|
16389
|
+
function getCheckMessage(checkId, type2, data) {
|
|
16374
16390
|
var check = axe._audit.data.checks[checkId];
|
|
16375
16391
|
if (!check) {
|
|
16376
16392
|
throw new Error('Cannot get message for unknown check: '.concat(checkId, '.'));
|
|
@@ -16378,7 +16394,7 @@
|
|
|
16378
16394
|
if (!check.messages[type2]) {
|
|
16379
16395
|
throw new Error('Check "'.concat(checkId, '"" does not have a "').concat(type2, '" message.'));
|
|
16380
16396
|
}
|
|
16381
|
-
return process_message_default(check.messages[type2],
|
|
16397
|
+
return process_message_default(check.messages[type2], data);
|
|
16382
16398
|
}
|
|
16383
16399
|
var get_check_message_default = getCheckMessage;
|
|
16384
16400
|
function getCheckOption(check, ruleID, options) {
|
|
@@ -16654,7 +16670,7 @@
|
|
|
16654
16670
|
}
|
|
16655
16671
|
function Context(spec, flatTree) {
|
|
16656
16672
|
var _spec, _spec2, _spec3, _spec4, _this5 = this;
|
|
16657
|
-
spec =
|
|
16673
|
+
spec = _clone(spec);
|
|
16658
16674
|
this.frames = [];
|
|
16659
16675
|
this.page = typeof ((_spec = spec) === null || _spec === void 0 ? void 0 : _spec.page) === 'boolean' ? spec.page : void 0;
|
|
16660
16676
|
this.initiator = typeof ((_spec2 = spec) === null || _spec2 === void 0 ? void 0 : _spec2.initiator) === 'boolean' ? spec.initiator : true;
|
|
@@ -16739,7 +16755,7 @@
|
|
|
16739
16755
|
return rule;
|
|
16740
16756
|
}
|
|
16741
16757
|
var get_rule_default = getRule;
|
|
16742
|
-
function
|
|
16758
|
+
function getScroll(elm) {
|
|
16743
16759
|
var buffer = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
|
|
16744
16760
|
var overflowX = elm.scrollWidth > elm.clientWidth + buffer;
|
|
16745
16761
|
var overflowY = elm.scrollHeight > elm.clientHeight + buffer;
|
|
@@ -16761,9 +16777,10 @@
|
|
|
16761
16777
|
var overflowProp = style.getPropertyValue(prop);
|
|
16762
16778
|
return [ 'scroll', 'auto' ].includes(overflowProp);
|
|
16763
16779
|
}
|
|
16780
|
+
var get_scroll_default = memoize_default(getScroll);
|
|
16764
16781
|
function getElmScrollRecursive(root) {
|
|
16765
16782
|
return Array.from(root.children || root.childNodes || []).reduce(function(scrolls, elm) {
|
|
16766
|
-
var scroll =
|
|
16783
|
+
var scroll = get_scroll_default(elm);
|
|
16767
16784
|
if (scroll) {
|
|
16768
16785
|
scrolls.push(scroll);
|
|
16769
16786
|
}
|
|
@@ -16786,20 +16803,20 @@
|
|
|
16786
16803
|
}
|
|
16787
16804
|
var get_scroll_state_default = getScrollState;
|
|
16788
16805
|
function _getStandards() {
|
|
16789
|
-
return
|
|
16806
|
+
return _clone(standards_default);
|
|
16790
16807
|
}
|
|
16791
16808
|
function getStyleSheetFactory(dynamicDoc) {
|
|
16792
16809
|
if (!dynamicDoc) {
|
|
16793
16810
|
throw new Error('axe.utils.getStyleSheetFactory should be invoked with an argument');
|
|
16794
16811
|
}
|
|
16795
16812
|
return function(options) {
|
|
16796
|
-
var
|
|
16813
|
+
var data = options.data, _options$isCrossOrigi = options.isCrossOrigin, isCrossOrigin = _options$isCrossOrigi === void 0 ? false : _options$isCrossOrigi, shadowId = options.shadowId, root = options.root, priority = options.priority, _options$isLink = options.isLink, isLink = _options$isLink === void 0 ? false : _options$isLink;
|
|
16797
16814
|
var style = dynamicDoc.createElement('style');
|
|
16798
16815
|
if (isLink) {
|
|
16799
|
-
var text = dynamicDoc.createTextNode('@import "'.concat(
|
|
16816
|
+
var text = dynamicDoc.createTextNode('@import "'.concat(data.href, '"'));
|
|
16800
16817
|
style.appendChild(text);
|
|
16801
16818
|
} else {
|
|
16802
|
-
style.appendChild(dynamicDoc.createTextNode(
|
|
16819
|
+
style.appendChild(dynamicDoc.createTextNode(data));
|
|
16803
16820
|
}
|
|
16804
16821
|
dynamicDoc.head.appendChild(style);
|
|
16805
16822
|
return {
|
|
@@ -17030,9 +17047,9 @@
|
|
|
17030
17047
|
reject(request.responseText);
|
|
17031
17048
|
});
|
|
17032
17049
|
request.send();
|
|
17033
|
-
}).then(function(
|
|
17050
|
+
}).then(function(data) {
|
|
17034
17051
|
var result = options.convertDataToStylesheet({
|
|
17035
|
-
data:
|
|
17052
|
+
data: data,
|
|
17036
17053
|
isCrossOrigin: isCrossOrigin,
|
|
17037
17054
|
priority: priority,
|
|
17038
17055
|
root: options.rootNode,
|
|
@@ -17376,8 +17393,10 @@
|
|
|
17376
17393
|
retVal.parentShadowId = parentShadowId;
|
|
17377
17394
|
return retVal;
|
|
17378
17395
|
}
|
|
17379
|
-
var recycledLocalVariables = [];
|
|
17380
17396
|
function matchExpressions(domTree, expressions, filter) {
|
|
17397
|
+
var recycledLocalVariables = cache_default.get('qsa.recycledLocalVariables', function() {
|
|
17398
|
+
return [];
|
|
17399
|
+
});
|
|
17381
17400
|
var stack = [];
|
|
17382
17401
|
var vNodes = Array.isArray(domTree) ? domTree : [ domTree ];
|
|
17383
17402
|
var currentLevel = createLocalVariables(vNodes, expressions, null, domTree[0].shadowId, recycledLocalVariables.pop());
|
|
@@ -17505,10 +17524,10 @@
|
|
|
17505
17524
|
function getStylesheetsFromDocumentFragment(rootNode, convertDataToStylesheet) {
|
|
17506
17525
|
return Array.from(rootNode.children).filter(filerStyleAndLinkAttributesInDocumentFragment).reduce(function(out, node) {
|
|
17507
17526
|
var nodeName2 = node.nodeName.toUpperCase();
|
|
17508
|
-
var
|
|
17527
|
+
var data = nodeName2 === 'STYLE' ? node.textContent : node;
|
|
17509
17528
|
var isLink = nodeName2 === 'LINK';
|
|
17510
17529
|
var stylesheet = convertDataToStylesheet({
|
|
17511
|
-
data:
|
|
17530
|
+
data: data,
|
|
17512
17531
|
isLink: isLink,
|
|
17513
17532
|
root: rootNode
|
|
17514
17533
|
});
|
|
@@ -17684,29 +17703,29 @@
|
|
|
17684
17703
|
return function(check) {
|
|
17685
17704
|
var sourceData = checksData[check.id] || {};
|
|
17686
17705
|
var messages = sourceData.messages || {};
|
|
17687
|
-
var
|
|
17688
|
-
delete
|
|
17706
|
+
var data = Object.assign({}, sourceData);
|
|
17707
|
+
delete data.messages;
|
|
17689
17708
|
if (!rule.reviewOnFail && check.result === void 0) {
|
|
17690
17709
|
if (_typeof(messages.incomplete) === 'object' && !Array.isArray(check.data)) {
|
|
17691
|
-
|
|
17710
|
+
data.message = getIncompleteReason(check.data, messages);
|
|
17692
17711
|
}
|
|
17693
|
-
if (!
|
|
17694
|
-
|
|
17712
|
+
if (!data.message) {
|
|
17713
|
+
data.message = messages.incomplete;
|
|
17695
17714
|
}
|
|
17696
17715
|
} else {
|
|
17697
|
-
|
|
17716
|
+
data.message = check.result === shouldBeTrue ? messages.pass : messages.fail;
|
|
17698
17717
|
}
|
|
17699
|
-
if (typeof
|
|
17700
|
-
|
|
17718
|
+
if (typeof data.message !== 'function') {
|
|
17719
|
+
data.message = process_message_default(data.message, check.data);
|
|
17701
17720
|
}
|
|
17702
|
-
extend_meta_data_default(check,
|
|
17721
|
+
extend_meta_data_default(check, data);
|
|
17703
17722
|
};
|
|
17704
17723
|
}
|
|
17705
17724
|
function publishMetaData(ruleResult) {
|
|
17706
17725
|
var checksData = axe._audit.data.checks || {};
|
|
17707
17726
|
var rulesData = axe._audit.data.rules || {};
|
|
17708
17727
|
var rule = find_by_default(axe._audit.rules, 'id', ruleResult.id) || {};
|
|
17709
|
-
ruleResult.tags =
|
|
17728
|
+
ruleResult.tags = _clone(rule.tags || []);
|
|
17710
17729
|
var shouldBeTrue = extender(checksData, true, rule);
|
|
17711
17730
|
var shouldBeFalse = extender(checksData, false, rule);
|
|
17712
17731
|
ruleResult.nodes.forEach(function(detail) {
|
|
@@ -17714,7 +17733,7 @@
|
|
|
17714
17733
|
detail.all.forEach(shouldBeTrue);
|
|
17715
17734
|
detail.none.forEach(shouldBeFalse);
|
|
17716
17735
|
});
|
|
17717
|
-
extend_meta_data_default(ruleResult,
|
|
17736
|
+
extend_meta_data_default(ruleResult, _clone(rulesData[ruleResult.id] || {}));
|
|
17718
17737
|
}
|
|
17719
17738
|
var publish_metadata_default = publishMetaData;
|
|
17720
17739
|
function querySelectorAll(domTree, selector) {
|
|
@@ -18316,8 +18335,11 @@
|
|
|
18316
18335
|
if (node.hasAttribute) {
|
|
18317
18336
|
if (node.nodeName.toUpperCase() === 'LABEL' && node.hasAttribute('for')) {
|
|
18318
18337
|
var _id2 = node.getAttribute('for');
|
|
18319
|
-
|
|
18320
|
-
|
|
18338
|
+
if (!idRefs.has(_id2)) {
|
|
18339
|
+
idRefs.set(_id2, [ node ]);
|
|
18340
|
+
} else {
|
|
18341
|
+
idRefs.get(_id2).push(node);
|
|
18342
|
+
}
|
|
18321
18343
|
}
|
|
18322
18344
|
for (var _i27 = 0; _i27 < refAttrs.length; ++_i27) {
|
|
18323
18345
|
var attr = refAttrs[_i27];
|
|
@@ -18325,10 +18347,20 @@
|
|
|
18325
18347
|
if (!attrValue) {
|
|
18326
18348
|
continue;
|
|
18327
18349
|
}
|
|
18328
|
-
var
|
|
18329
|
-
|
|
18330
|
-
|
|
18331
|
-
|
|
18350
|
+
var _iterator13 = _createForOfIteratorHelper(token_list_default(attrValue)), _step13;
|
|
18351
|
+
try {
|
|
18352
|
+
for (_iterator13.s(); !(_step13 = _iterator13.n()).done; ) {
|
|
18353
|
+
var token = _step13.value;
|
|
18354
|
+
if (!idRefs.has(token)) {
|
|
18355
|
+
idRefs.set(token, [ node ]);
|
|
18356
|
+
} else {
|
|
18357
|
+
idRefs.get(token).push(node);
|
|
18358
|
+
}
|
|
18359
|
+
}
|
|
18360
|
+
} catch (err) {
|
|
18361
|
+
_iterator13.e(err);
|
|
18362
|
+
} finally {
|
|
18363
|
+
_iterator13.f();
|
|
18332
18364
|
}
|
|
18333
18365
|
}
|
|
18334
18366
|
}
|
|
@@ -18339,15 +18371,16 @@
|
|
|
18339
18371
|
}
|
|
18340
18372
|
}
|
|
18341
18373
|
function getAccessibleRefs(node) {
|
|
18374
|
+
var _idRefs$get;
|
|
18342
18375
|
node = node.actualNode || node;
|
|
18343
18376
|
var root = get_root_node_default2(node);
|
|
18344
18377
|
root = root.documentElement || root;
|
|
18345
18378
|
var idRefsByRoot = cache_default.get('idRefsByRoot', function() {
|
|
18346
|
-
return new
|
|
18379
|
+
return new Map();
|
|
18347
18380
|
});
|
|
18348
18381
|
var idRefs = idRefsByRoot.get(root);
|
|
18349
18382
|
if (!idRefs) {
|
|
18350
|
-
idRefs =
|
|
18383
|
+
idRefs = new Map();
|
|
18351
18384
|
idRefsByRoot.set(root, idRefs);
|
|
18352
18385
|
var refAttrs = Object.keys(standards_default.ariaAttrs).filter(function(attr) {
|
|
18353
18386
|
var type2 = standards_default.ariaAttrs[attr].type;
|
|
@@ -18355,7 +18388,7 @@
|
|
|
18355
18388
|
});
|
|
18356
18389
|
cacheIdRefs(root, idRefs, refAttrs);
|
|
18357
18390
|
}
|
|
18358
|
-
return idRefs
|
|
18391
|
+
return (_idRefs$get = idRefs.get(node.id)) !== null && _idRefs$get !== void 0 ? _idRefs$get : [];
|
|
18359
18392
|
}
|
|
18360
18393
|
var get_accessible_refs_default = getAccessibleRefs;
|
|
18361
18394
|
function isAriaRoleAllowedOnElement(node, role) {
|
|
@@ -20286,7 +20319,7 @@
|
|
|
20286
20319
|
var implicit = null;
|
|
20287
20320
|
var roles = lookup_table_default.role[role];
|
|
20288
20321
|
if (roles && roles.implicit) {
|
|
20289
|
-
implicit =
|
|
20322
|
+
implicit = _clone(roles.implicit);
|
|
20290
20323
|
}
|
|
20291
20324
|
return implicit;
|
|
20292
20325
|
}
|
|
@@ -20434,18 +20467,18 @@
|
|
|
20434
20467
|
if (Array.isArray(options[role])) {
|
|
20435
20468
|
allowed = unique_array_default(options[role].concat(allowed));
|
|
20436
20469
|
}
|
|
20437
|
-
var
|
|
20470
|
+
var _iterator14 = _createForOfIteratorHelper(virtualNode.attrNames), _step14;
|
|
20438
20471
|
try {
|
|
20439
|
-
for (
|
|
20440
|
-
var attrName =
|
|
20472
|
+
for (_iterator14.s(); !(_step14 = _iterator14.n()).done; ) {
|
|
20473
|
+
var attrName = _step14.value;
|
|
20441
20474
|
if (validate_attr_default(attrName) && !allowed.includes(attrName)) {
|
|
20442
20475
|
invalid.push(attrName);
|
|
20443
20476
|
}
|
|
20444
20477
|
}
|
|
20445
20478
|
} catch (err) {
|
|
20446
|
-
|
|
20479
|
+
_iterator14.e(err);
|
|
20447
20480
|
} finally {
|
|
20448
|
-
|
|
20481
|
+
_iterator14.f();
|
|
20449
20482
|
}
|
|
20450
20483
|
if (!invalid.length) {
|
|
20451
20484
|
return true;
|
|
@@ -21805,11 +21838,11 @@
|
|
|
21805
21838
|
return fgColor;
|
|
21806
21839
|
}
|
|
21807
21840
|
function findNodeInContexts(contexts, node) {
|
|
21808
|
-
var
|
|
21841
|
+
var _iterator15 = _createForOfIteratorHelper(contexts), _step15;
|
|
21809
21842
|
try {
|
|
21810
|
-
for (
|
|
21843
|
+
for (_iterator15.s(); !(_step15 = _iterator15.n()).done; ) {
|
|
21811
21844
|
var _context$vNode;
|
|
21812
|
-
var context =
|
|
21845
|
+
var context = _step15.value;
|
|
21813
21846
|
if (((_context$vNode = context.vNode) === null || _context$vNode === void 0 ? void 0 : _context$vNode.actualNode) === node) {
|
|
21814
21847
|
return context;
|
|
21815
21848
|
}
|
|
@@ -21819,9 +21852,9 @@
|
|
|
21819
21852
|
}
|
|
21820
21853
|
}
|
|
21821
21854
|
} catch (err) {
|
|
21822
|
-
|
|
21855
|
+
_iterator15.e(err);
|
|
21823
21856
|
} finally {
|
|
21824
|
-
|
|
21857
|
+
_iterator15.f();
|
|
21825
21858
|
}
|
|
21826
21859
|
}
|
|
21827
21860
|
function hasValidContrastRatio(bg, fg, fontSize, isBold) {
|
|
@@ -22717,8 +22750,8 @@
|
|
|
22717
22750
|
return (value || '').trim() !== '';
|
|
22718
22751
|
}
|
|
22719
22752
|
function hasLangEvaluate(node, options, virtualNode) {
|
|
22720
|
-
var
|
|
22721
|
-
if (options.attributes.includes('xml:lang') && options.attributes.includes('lang') && hasValue(virtualNode.attr('xml:lang')) && !hasValue(virtualNode.attr('lang')) && !
|
|
22753
|
+
var xhtml = typeof document !== 'undefined' ? is_xhtml_default(document) : false;
|
|
22754
|
+
if (options.attributes.includes('xml:lang') && options.attributes.includes('lang') && hasValue(virtualNode.attr('xml:lang')) && !hasValue(virtualNode.attr('lang')) && !xhtml) {
|
|
22722
22755
|
this.data({
|
|
22723
22756
|
messageKey: 'noXHTML'
|
|
22724
22757
|
});
|
|
@@ -23276,10 +23309,10 @@
|
|
|
23276
23309
|
var minOffset = (options === null || options === void 0 ? void 0 : options.minOffset) || 24;
|
|
23277
23310
|
var closeNeighbors = [];
|
|
23278
23311
|
var closestOffset = minOffset;
|
|
23279
|
-
var
|
|
23312
|
+
var _iterator16 = _createForOfIteratorHelper(_findNearbyElms(vNode, minOffset)), _step16;
|
|
23280
23313
|
try {
|
|
23281
|
-
for (
|
|
23282
|
-
var vNeighbor =
|
|
23314
|
+
for (_iterator16.s(); !(_step16 = _iterator16.n()).done; ) {
|
|
23315
|
+
var vNeighbor = _step16.value;
|
|
23283
23316
|
if (get_role_type_default(vNeighbor) !== 'widget' || !_isFocusable(vNeighbor)) {
|
|
23284
23317
|
continue;
|
|
23285
23318
|
}
|
|
@@ -23291,9 +23324,9 @@
|
|
|
23291
23324
|
closeNeighbors.push(vNeighbor);
|
|
23292
23325
|
}
|
|
23293
23326
|
} catch (err) {
|
|
23294
|
-
|
|
23327
|
+
_iterator16.e(err);
|
|
23295
23328
|
} finally {
|
|
23296
|
-
|
|
23329
|
+
_iterator16.f();
|
|
23297
23330
|
}
|
|
23298
23331
|
if (closeNeighbors.length === 0) {
|
|
23299
23332
|
this.data({
|
|
@@ -23381,10 +23414,10 @@
|
|
|
23381
23414
|
function filterByElmsOverlap(vNode, nearbyElms) {
|
|
23382
23415
|
var fullyObscuringElms = [];
|
|
23383
23416
|
var partialObscuringElms = [];
|
|
23384
|
-
var
|
|
23417
|
+
var _iterator17 = _createForOfIteratorHelper(nearbyElms), _step17;
|
|
23385
23418
|
try {
|
|
23386
|
-
for (
|
|
23387
|
-
var vNeighbor =
|
|
23419
|
+
for (_iterator17.s(); !(_step17 = _iterator17.n()).done; ) {
|
|
23420
|
+
var vNeighbor = _step17.value;
|
|
23388
23421
|
if (!isDescendantNotInTabOrder(vNode, vNeighbor) && _hasVisualOverlap(vNode, vNeighbor) && getCssPointerEvents(vNeighbor) !== 'none') {
|
|
23389
23422
|
if (isEnclosedRect(vNode, vNeighbor)) {
|
|
23390
23423
|
fullyObscuringElms.push(vNeighbor);
|
|
@@ -23394,9 +23427,9 @@
|
|
|
23394
23427
|
}
|
|
23395
23428
|
}
|
|
23396
23429
|
} catch (err) {
|
|
23397
|
-
|
|
23430
|
+
_iterator17.e(err);
|
|
23398
23431
|
} finally {
|
|
23399
|
-
|
|
23432
|
+
_iterator17.f();
|
|
23400
23433
|
}
|
|
23401
23434
|
return {
|
|
23402
23435
|
fullyObscuringElms: fullyObscuringElms,
|
|
@@ -23617,12 +23650,12 @@
|
|
|
23617
23650
|
return 'continue';
|
|
23618
23651
|
}
|
|
23619
23652
|
var sameNameResults = incompleteResults.filter(function(_ref129, resultNum) {
|
|
23620
|
-
var
|
|
23621
|
-
return
|
|
23653
|
+
var data = _ref129.data;
|
|
23654
|
+
return data.name === name && resultNum !== index;
|
|
23622
23655
|
});
|
|
23623
23656
|
var isSameUrl = sameNameResults.every(function(_ref130) {
|
|
23624
|
-
var
|
|
23625
|
-
return isIdenticalObject(
|
|
23657
|
+
var data = _ref130.data;
|
|
23658
|
+
return isIdenticalObject(data.urlProps, urlProps);
|
|
23626
23659
|
});
|
|
23627
23660
|
if (sameNameResults.length && !isSameUrl) {
|
|
23628
23661
|
currentResult.result = void 0;
|
|
@@ -24152,19 +24185,19 @@
|
|
|
24152
24185
|
return;
|
|
24153
24186
|
}
|
|
24154
24187
|
var frameAncestry = r.node.ancestry.slice(0, -1);
|
|
24155
|
-
var
|
|
24188
|
+
var _iterator18 = _createForOfIteratorHelper(iframeResults), _step18;
|
|
24156
24189
|
try {
|
|
24157
|
-
for (
|
|
24158
|
-
var iframeResult =
|
|
24190
|
+
for (_iterator18.s(); !(_step18 = _iterator18.n()).done; ) {
|
|
24191
|
+
var iframeResult = _step18.value;
|
|
24159
24192
|
if (match_ancestry_default(frameAncestry, iframeResult.node.ancestry)) {
|
|
24160
24193
|
r.result = iframeResult.result;
|
|
24161
24194
|
break;
|
|
24162
24195
|
}
|
|
24163
24196
|
}
|
|
24164
24197
|
} catch (err) {
|
|
24165
|
-
|
|
24198
|
+
_iterator18.e(err);
|
|
24166
24199
|
} finally {
|
|
24167
|
-
|
|
24200
|
+
_iterator18.f();
|
|
24168
24201
|
}
|
|
24169
24202
|
});
|
|
24170
24203
|
iframeResults.forEach(function(r) {
|
|
@@ -24175,7 +24208,6 @@
|
|
|
24175
24208
|
return results;
|
|
24176
24209
|
}
|
|
24177
24210
|
var region_after_default = regionAfter;
|
|
24178
|
-
var landmarkRoles2 = get_aria_roles_by_type_default('landmark');
|
|
24179
24211
|
var implicitAriaLiveRoles = [ 'alert', 'log', 'status' ];
|
|
24180
24212
|
function regionEvaluate(node, options, virtualNode) {
|
|
24181
24213
|
this.data({
|
|
@@ -24226,6 +24258,7 @@
|
|
|
24226
24258
|
var node = virtualNode.actualNode;
|
|
24227
24259
|
var role = get_role_default(virtualNode);
|
|
24228
24260
|
var ariaLive = (node.getAttribute('aria-live') || '').toLowerCase().trim();
|
|
24261
|
+
var landmarkRoles2 = get_aria_roles_by_type_default('landmark');
|
|
24229
24262
|
if ([ 'assertive', 'polite' ].includes(ariaLive) || implicitAriaLiveRoles.includes(role)) {
|
|
24230
24263
|
return true;
|
|
24231
24264
|
}
|
|
@@ -24336,18 +24369,18 @@
|
|
|
24336
24369
|
if (!noImportant && node.style.getPropertyPriority(cssProperty) !== 'important' || multiLineOnly && !_isMultiline(node)) {
|
|
24337
24370
|
return true;
|
|
24338
24371
|
}
|
|
24339
|
-
var
|
|
24372
|
+
var data = {};
|
|
24340
24373
|
if (typeof minValue === 'number') {
|
|
24341
|
-
|
|
24374
|
+
data.minValue = minValue;
|
|
24342
24375
|
}
|
|
24343
24376
|
if (typeof maxValue === 'number') {
|
|
24344
|
-
|
|
24377
|
+
data.maxValue = maxValue;
|
|
24345
24378
|
}
|
|
24346
24379
|
var declaredPropValue = node.style.getPropertyValue(cssProperty);
|
|
24347
24380
|
if ([ 'inherit', 'unset', 'revert', 'revert-layer' ].includes(declaredPropValue)) {
|
|
24348
24381
|
this.data(_extends({
|
|
24349
24382
|
value: declaredPropValue
|
|
24350
|
-
},
|
|
24383
|
+
}, data));
|
|
24351
24384
|
return true;
|
|
24352
24385
|
}
|
|
24353
24386
|
var value = getNumberValue(node, {
|
|
@@ -24357,7 +24390,7 @@
|
|
|
24357
24390
|
});
|
|
24358
24391
|
this.data(_extends({
|
|
24359
24392
|
value: value
|
|
24360
|
-
},
|
|
24393
|
+
}, data));
|
|
24361
24394
|
if (typeof value !== 'number') {
|
|
24362
24395
|
return void 0;
|
|
24363
24396
|
}
|
|
@@ -24970,7 +25003,7 @@
|
|
|
24970
25003
|
}
|
|
24971
25004
|
function isLandmarkVirtual(virtualNode2) {
|
|
24972
25005
|
var actualNode = virtualNode2.actualNode;
|
|
24973
|
-
var
|
|
25006
|
+
var landmarkRoles2 = get_aria_roles_by_type_default('landmark');
|
|
24974
25007
|
var role = get_role_default(actualNode);
|
|
24975
25008
|
if (!role) {
|
|
24976
25009
|
return false;
|
|
@@ -24983,7 +25016,7 @@
|
|
|
24983
25016
|
var accessibleText2 = accessible_text_virtual_default(virtualNode2);
|
|
24984
25017
|
return !!accessibleText2;
|
|
24985
25018
|
}
|
|
24986
|
-
return
|
|
25019
|
+
return landmarkRoles2.indexOf(role) >= 0 || role === 'region';
|
|
24987
25020
|
}
|
|
24988
25021
|
return isLandmarkVirtual(virtualNode) && _isVisibleToScreenReaders(node);
|
|
24989
25022
|
}
|
|
@@ -25111,7 +25144,7 @@
|
|
|
25111
25144
|
}
|
|
25112
25145
|
var presentation_role_conflict_matches_default = presentationRoleConflictMatches;
|
|
25113
25146
|
function scrollableRegionFocusableMatches(node, virtualNode) {
|
|
25114
|
-
return
|
|
25147
|
+
return get_scroll_default(node, 13) !== void 0 && _isComboboxPopup(virtualNode) === false && isNoneEmptyElement(virtualNode);
|
|
25115
25148
|
}
|
|
25116
25149
|
function isNoneEmptyElement(vNode) {
|
|
25117
25150
|
return query_selector_all_default(vNode, '*').some(function(elm) {
|
|
@@ -25766,8 +25799,8 @@
|
|
|
25766
25799
|
var ruleID = this.id;
|
|
25767
25800
|
afterChecks.forEach(function(check) {
|
|
25768
25801
|
var beforeResults = findCheckResults(result.nodes, check.id);
|
|
25769
|
-
var
|
|
25770
|
-
var afterResults = check.after(beforeResults,
|
|
25802
|
+
var checkOption = get_check_option_default(check, ruleID, options);
|
|
25803
|
+
var afterResults = check.after(beforeResults, checkOption.options);
|
|
25771
25804
|
if (_this12.reviewOnFail) {
|
|
25772
25805
|
afterResults.forEach(function(checkResult) {
|
|
25773
25806
|
var changeAnyAllResults = (_this12.any.includes(checkResult.id) || _this12.all.includes(checkResult.id)) && checkResult.result === false;
|
|
@@ -25840,7 +25873,7 @@
|
|
|
25840
25873
|
function getDefaultConfiguration(audit) {
|
|
25841
25874
|
var config;
|
|
25842
25875
|
if (audit) {
|
|
25843
|
-
config =
|
|
25876
|
+
config = _clone(audit);
|
|
25844
25877
|
config.commons = audit.commons;
|
|
25845
25878
|
} else {
|
|
25846
25879
|
config = {};
|
|
@@ -26034,10 +26067,10 @@
|
|
|
26034
26067
|
value: function setAllowedOrigins(allowedOrigins) {
|
|
26035
26068
|
var defaultOrigin = getDefaultOrigin();
|
|
26036
26069
|
this.allowedOrigins = [];
|
|
26037
|
-
var
|
|
26070
|
+
var _iterator19 = _createForOfIteratorHelper(allowedOrigins), _step19;
|
|
26038
26071
|
try {
|
|
26039
|
-
for (
|
|
26040
|
-
var origin =
|
|
26072
|
+
for (_iterator19.s(); !(_step19 = _iterator19.n()).done; ) {
|
|
26073
|
+
var origin = _step19.value;
|
|
26041
26074
|
if (origin === constants_default.allOrigins) {
|
|
26042
26075
|
this.allowedOrigins = [ '*' ];
|
|
26043
26076
|
return;
|
|
@@ -26048,9 +26081,9 @@
|
|
|
26048
26081
|
}
|
|
26049
26082
|
}
|
|
26050
26083
|
} catch (err) {
|
|
26051
|
-
|
|
26084
|
+
_iterator19.e(err);
|
|
26052
26085
|
} finally {
|
|
26053
|
-
|
|
26086
|
+
_iterator19.f();
|
|
26054
26087
|
}
|
|
26055
26088
|
}
|
|
26056
26089
|
}, {
|
|
@@ -26417,12 +26450,12 @@
|
|
|
26417
26450
|
q.defer(function(res, rej) {
|
|
26418
26451
|
audit.run(context, options, res, rej);
|
|
26419
26452
|
});
|
|
26420
|
-
q.then(function(
|
|
26453
|
+
q.then(function(data) {
|
|
26421
26454
|
try {
|
|
26422
26455
|
if (options.performanceTimer) {
|
|
26423
26456
|
performance_timer_default.auditEnd();
|
|
26424
26457
|
}
|
|
26425
|
-
var results = merge_results_default(
|
|
26458
|
+
var results = merge_results_default(data.map(function(results2) {
|
|
26426
26459
|
return {
|
|
26427
26460
|
results: results2
|
|
26428
26461
|
};
|
|
@@ -26448,7 +26481,7 @@
|
|
|
26448
26481
|
});
|
|
26449
26482
|
}
|
|
26450
26483
|
var run_rules_default = runRules;
|
|
26451
|
-
function runCommand(
|
|
26484
|
+
function runCommand(data, keepalive, callback) {
|
|
26452
26485
|
var resolve = callback;
|
|
26453
26486
|
var reject = function reject2(err2) {
|
|
26454
26487
|
if (err2 instanceof Error === false) {
|
|
@@ -26456,12 +26489,12 @@
|
|
|
26456
26489
|
}
|
|
26457
26490
|
callback(err2);
|
|
26458
26491
|
};
|
|
26459
|
-
var context =
|
|
26492
|
+
var context = data && data.context || {};
|
|
26460
26493
|
if (context.hasOwnProperty('include') && !context.include.length) {
|
|
26461
26494
|
context.include = [ document ];
|
|
26462
26495
|
}
|
|
26463
|
-
var options =
|
|
26464
|
-
switch (
|
|
26496
|
+
var options = data && data.options || {};
|
|
26497
|
+
switch (data.command) {
|
|
26465
26498
|
case 'rules':
|
|
26466
26499
|
return run_rules_default(context, options, function(results, cleanup3) {
|
|
26467
26500
|
resolve(results);
|
|
@@ -26472,14 +26505,14 @@
|
|
|
26472
26505
|
return cleanup_default(resolve, reject);
|
|
26473
26506
|
|
|
26474
26507
|
default:
|
|
26475
|
-
if (axe._audit && axe._audit.commands && axe._audit.commands[
|
|
26476
|
-
return axe._audit.commands[
|
|
26508
|
+
if (axe._audit && axe._audit.commands && axe._audit.commands[data.command]) {
|
|
26509
|
+
return axe._audit.commands[data.command](data, callback);
|
|
26477
26510
|
}
|
|
26478
26511
|
}
|
|
26479
26512
|
}
|
|
26480
26513
|
if (window.top !== window) {
|
|
26481
26514
|
_respondable.subscribe('axe.start', runCommand);
|
|
26482
|
-
_respondable.subscribe('axe.ping', function(
|
|
26515
|
+
_respondable.subscribe('axe.ping', function(data, keepalive, respond) {
|
|
26483
26516
|
respond({
|
|
26484
26517
|
axe: true
|
|
26485
26518
|
});
|
|
@@ -26590,7 +26623,7 @@
|
|
|
26590
26623
|
if (typeof callback !== 'function' && callback !== void 0) {
|
|
26591
26624
|
throw typeErr;
|
|
26592
26625
|
}
|
|
26593
|
-
options =
|
|
26626
|
+
options = _clone(options);
|
|
26594
26627
|
options.reporter = (_ref139 = (_options$reporter = options.reporter) !== null && _options$reporter !== void 0 ? _options$reporter : (_axe$_audit = axe._audit) === null || _axe$_audit === void 0 ? void 0 : _axe$_audit.reporter) !== null && _ref139 !== void 0 ? _ref139 : 'v1';
|
|
26595
26628
|
return {
|
|
26596
26629
|
context: context,
|
|
@@ -26742,7 +26775,7 @@
|
|
|
26742
26775
|
function finishRun(partialResults) {
|
|
26743
26776
|
var _ref145, _options$reporter2, _axe$_audit2;
|
|
26744
26777
|
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
26745
|
-
options =
|
|
26778
|
+
options = _clone(options);
|
|
26746
26779
|
var _ref144 = partialResults.find(function(r) {
|
|
26747
26780
|
return r.environmentData;
|
|
26748
26781
|
}) || {}, environmentData = _ref144.environmentData;
|
|
@@ -26759,10 +26792,10 @@
|
|
|
26759
26792
|
}
|
|
26760
26793
|
function setFrameSpec(partialResults) {
|
|
26761
26794
|
var frameStack = [];
|
|
26762
|
-
var
|
|
26795
|
+
var _iterator20 = _createForOfIteratorHelper(partialResults), _step20;
|
|
26763
26796
|
try {
|
|
26764
|
-
for (
|
|
26765
|
-
var partialResult =
|
|
26797
|
+
for (_iterator20.s(); !(_step20 = _iterator20.n()).done; ) {
|
|
26798
|
+
var partialResult = _step20.value;
|
|
26766
26799
|
var frameSpec = frameStack.shift();
|
|
26767
26800
|
if (!partialResult) {
|
|
26768
26801
|
continue;
|
|
@@ -26772,9 +26805,9 @@
|
|
|
26772
26805
|
frameStack.unshift.apply(frameStack, _toConsumableArray(frameSpecs));
|
|
26773
26806
|
}
|
|
26774
26807
|
} catch (err) {
|
|
26775
|
-
|
|
26808
|
+
_iterator20.e(err);
|
|
26776
26809
|
} finally {
|
|
26777
|
-
|
|
26810
|
+
_iterator20.f();
|
|
26778
26811
|
}
|
|
26779
26812
|
}
|
|
26780
26813
|
function getMergedFrameSpecs(_ref146) {
|
|
@@ -27003,6 +27036,10 @@
|
|
|
27003
27036
|
description: 'Ensures every ARIA button, link and menuitem has an accessible name',
|
|
27004
27037
|
help: 'ARIA commands must have an accessible name'
|
|
27005
27038
|
},
|
|
27039
|
+
'aria-deprecated-role': {
|
|
27040
|
+
description: 'Ensures elements do not use deprecated roles',
|
|
27041
|
+
help: 'Deprecated ARIA roles must not be used'
|
|
27042
|
+
},
|
|
27006
27043
|
'aria-dialog-name': {
|
|
27007
27044
|
description: 'Ensures every ARIA dialog and alertdialog node has an accessible name',
|
|
27008
27045
|
help: 'ARIA dialog and alertdialog nodes should have an accessible name'
|
|
@@ -28441,7 +28478,7 @@
|
|
|
28441
28478
|
id: 'area-alt',
|
|
28442
28479
|
selector: 'map area[href]',
|
|
28443
28480
|
excludeHidden: false,
|
|
28444
|
-
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag244', 'wcag412', 'section508', 'section508.22.a', '
|
|
28481
|
+
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag244', 'wcag412', 'section508', 'section508.22.a', 'TTv5', 'TT6.a', 'EN-301-549', 'EN-9.2.4.4', 'EN-9.4.1.2', 'ACT' ],
|
|
28445
28482
|
actIds: [ 'c487ae' ],
|
|
28446
28483
|
all: [],
|
|
28447
28484
|
any: [ {
|
|
@@ -28459,7 +28496,7 @@
|
|
|
28459
28496
|
}, {
|
|
28460
28497
|
id: 'aria-allowed-attr',
|
|
28461
28498
|
matches: 'aria-allowed-attr-matches',
|
|
28462
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag412' ],
|
|
28499
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
28463
28500
|
actIds: [ '5c01ea' ],
|
|
28464
28501
|
all: [ {
|
|
28465
28502
|
options: {
|
|
@@ -28498,7 +28535,7 @@
|
|
|
28498
28535
|
id: 'aria-command-name',
|
|
28499
28536
|
selector: '[role="link"], [role="button"], [role="menuitem"]',
|
|
28500
28537
|
matches: 'no-naming-method-matches',
|
|
28501
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag412', '
|
|
28538
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'TTv5', 'TT6.a', 'EN-301-549', 'EN-9.4.1.2', 'ACT' ],
|
|
28502
28539
|
actIds: [ '97a4e1' ],
|
|
28503
28540
|
all: [],
|
|
28504
28541
|
any: [ 'has-visible-text', 'aria-label', 'aria-labelledby', {
|
|
@@ -28508,6 +28545,16 @@
|
|
|
28508
28545
|
id: 'non-empty-title'
|
|
28509
28546
|
} ],
|
|
28510
28547
|
none: []
|
|
28548
|
+
}, {
|
|
28549
|
+
id: 'aria-deprecated-role',
|
|
28550
|
+
selector: '[role]',
|
|
28551
|
+
matches: 'no-empty-role-matches',
|
|
28552
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
28553
|
+
impact: 'minor',
|
|
28554
|
+
actIds: [ '674b10' ],
|
|
28555
|
+
all: [],
|
|
28556
|
+
any: [],
|
|
28557
|
+
none: [ 'deprecatedrole' ]
|
|
28511
28558
|
}, {
|
|
28512
28559
|
id: 'aria-dialog-name',
|
|
28513
28560
|
selector: '[role="dialog"], [role="alertdialog"]',
|
|
@@ -28526,7 +28573,7 @@
|
|
|
28526
28573
|
selector: 'body',
|
|
28527
28574
|
excludeHidden: false,
|
|
28528
28575
|
matches: 'is-initiator-matches',
|
|
28529
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag412' ],
|
|
28576
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
28530
28577
|
all: [],
|
|
28531
28578
|
any: [ 'aria-hidden-body' ],
|
|
28532
28579
|
none: []
|
|
@@ -28535,7 +28582,7 @@
|
|
|
28535
28582
|
selector: '[aria-hidden="true"]',
|
|
28536
28583
|
matches: 'aria-hidden-focus-matches',
|
|
28537
28584
|
excludeHidden: false,
|
|
28538
|
-
tags: [ 'cat.name-role-value', 'wcag2a', 'wcag412' ],
|
|
28585
|
+
tags: [ 'cat.name-role-value', 'wcag2a', 'wcag412', 'TTv5', 'TT6.a', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
28539
28586
|
actIds: [ '6cfa84' ],
|
|
28540
28587
|
all: [ 'focusable-modal-open', 'focusable-disabled', 'focusable-not-tabbable' ],
|
|
28541
28588
|
any: [],
|
|
@@ -28544,7 +28591,7 @@
|
|
|
28544
28591
|
id: 'aria-input-field-name',
|
|
28545
28592
|
selector: '[role="combobox"], [role="listbox"], [role="searchbox"], [role="slider"], [role="spinbutton"], [role="textbox"]',
|
|
28546
28593
|
matches: 'no-naming-method-matches',
|
|
28547
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag412', '
|
|
28594
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'TTv5', 'TT5.c', 'EN-301-549', 'EN-9.4.1.2', 'ACT' ],
|
|
28548
28595
|
actIds: [ 'e086e5' ],
|
|
28549
28596
|
all: [],
|
|
28550
28597
|
any: [ 'aria-label', 'aria-labelledby', {
|
|
@@ -28558,7 +28605,7 @@
|
|
|
28558
28605
|
id: 'aria-meter-name',
|
|
28559
28606
|
selector: '[role="meter"]',
|
|
28560
28607
|
matches: 'no-naming-method-matches',
|
|
28561
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag111' ],
|
|
28608
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag111', 'EN-301-549', 'EN-9.1.1.1' ],
|
|
28562
28609
|
all: [],
|
|
28563
28610
|
any: [ 'aria-label', 'aria-labelledby', {
|
|
28564
28611
|
options: {
|
|
@@ -28571,7 +28618,7 @@
|
|
|
28571
28618
|
id: 'aria-progressbar-name',
|
|
28572
28619
|
selector: '[role="progressbar"]',
|
|
28573
28620
|
matches: 'no-naming-method-matches',
|
|
28574
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag111' ],
|
|
28621
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag111', 'EN-301-549', 'EN-9.1.1.1' ],
|
|
28575
28622
|
all: [],
|
|
28576
28623
|
any: [ 'aria-label', 'aria-labelledby', {
|
|
28577
28624
|
options: {
|
|
@@ -28583,7 +28630,7 @@
|
|
|
28583
28630
|
}, {
|
|
28584
28631
|
id: 'aria-required-attr',
|
|
28585
28632
|
selector: '[role]',
|
|
28586
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag412' ],
|
|
28633
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
28587
28634
|
actIds: [ '4e8ab6' ],
|
|
28588
28635
|
all: [],
|
|
28589
28636
|
any: [ 'aria-required-attr' ],
|
|
@@ -28592,7 +28639,7 @@
|
|
|
28592
28639
|
id: 'aria-required-children',
|
|
28593
28640
|
selector: '[role]',
|
|
28594
28641
|
matches: 'aria-required-children-matches',
|
|
28595
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag131' ],
|
|
28642
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag131', 'EN-301-549', 'EN-9.1.3.1' ],
|
|
28596
28643
|
actIds: [ 'bc4a75', 'ff89c9' ],
|
|
28597
28644
|
all: [],
|
|
28598
28645
|
any: [ {
|
|
@@ -28606,7 +28653,7 @@
|
|
|
28606
28653
|
id: 'aria-required-parent',
|
|
28607
28654
|
selector: '[role]',
|
|
28608
28655
|
matches: 'aria-required-parent-matches',
|
|
28609
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag131' ],
|
|
28656
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag131', 'EN-301-549', 'EN-9.1.3.1' ],
|
|
28610
28657
|
actIds: [ 'ff89c9' ],
|
|
28611
28658
|
all: [],
|
|
28612
28659
|
any: [ {
|
|
@@ -28619,7 +28666,7 @@
|
|
|
28619
28666
|
}, {
|
|
28620
28667
|
id: 'aria-roledescription',
|
|
28621
28668
|
selector: '[aria-roledescription]',
|
|
28622
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'deprecated' ],
|
|
28669
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'EN-301-549', 'EN-9.4.1.2', 'deprecated' ],
|
|
28623
28670
|
enabled: false,
|
|
28624
28671
|
all: [],
|
|
28625
28672
|
any: [ {
|
|
@@ -28633,11 +28680,11 @@
|
|
|
28633
28680
|
id: 'aria-roles',
|
|
28634
28681
|
selector: '[role]',
|
|
28635
28682
|
matches: 'no-empty-role-matches',
|
|
28636
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag412' ],
|
|
28683
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
28637
28684
|
actIds: [ '674b10' ],
|
|
28638
28685
|
all: [],
|
|
28639
28686
|
any: [],
|
|
28640
|
-
none: [ 'invalidrole', 'abstractrole', 'unsupportedrole'
|
|
28687
|
+
none: [ 'invalidrole', 'abstractrole', 'unsupportedrole' ]
|
|
28641
28688
|
}, {
|
|
28642
28689
|
id: 'aria-text',
|
|
28643
28690
|
selector: '[role=text]',
|
|
@@ -28649,7 +28696,7 @@
|
|
|
28649
28696
|
id: 'aria-toggle-field-name',
|
|
28650
28697
|
selector: '[role="checkbox"], [role="menuitemcheckbox"], [role="menuitemradio"], [role="radio"], [role="switch"], [role="option"]',
|
|
28651
28698
|
matches: 'no-naming-method-matches',
|
|
28652
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag412', '
|
|
28699
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'TTv5', 'TT5.c', 'EN-301-549', 'EN-9.4.1.2', 'ACT' ],
|
|
28653
28700
|
actIds: [ 'e086e5' ],
|
|
28654
28701
|
all: [],
|
|
28655
28702
|
any: [ 'has-visible-text', 'aria-label', 'aria-labelledby', {
|
|
@@ -28663,7 +28710,7 @@
|
|
|
28663
28710
|
id: 'aria-tooltip-name',
|
|
28664
28711
|
selector: '[role="tooltip"]',
|
|
28665
28712
|
matches: 'no-naming-method-matches',
|
|
28666
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag412' ],
|
|
28713
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
28667
28714
|
all: [],
|
|
28668
28715
|
any: [ 'has-visible-text', 'aria-label', 'aria-labelledby', {
|
|
28669
28716
|
options: {
|
|
@@ -28688,7 +28735,7 @@
|
|
|
28688
28735
|
}, {
|
|
28689
28736
|
id: 'aria-valid-attr-value',
|
|
28690
28737
|
matches: 'aria-has-attr-matches',
|
|
28691
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag412' ],
|
|
28738
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
28692
28739
|
actIds: [ '6a7281' ],
|
|
28693
28740
|
all: [ {
|
|
28694
28741
|
options: [],
|
|
@@ -28699,7 +28746,7 @@
|
|
|
28699
28746
|
}, {
|
|
28700
28747
|
id: 'aria-valid-attr',
|
|
28701
28748
|
matches: 'aria-has-attr-matches',
|
|
28702
|
-
tags: [ 'cat.aria', 'wcag2a', 'wcag412' ],
|
|
28749
|
+
tags: [ 'cat.aria', 'wcag2a', 'wcag412', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
28703
28750
|
actIds: [ '5f99a7' ],
|
|
28704
28751
|
all: [],
|
|
28705
28752
|
any: [ {
|
|
@@ -28712,7 +28759,7 @@
|
|
|
28712
28759
|
selector: 'audio',
|
|
28713
28760
|
enabled: false,
|
|
28714
28761
|
excludeHidden: false,
|
|
28715
|
-
tags: [ 'cat.time-and-media', 'wcag2a', 'wcag121', 'section508', 'section508.22.a', 'deprecated' ],
|
|
28762
|
+
tags: [ 'cat.time-and-media', 'wcag2a', 'wcag121', 'EN-301-549', 'EN-9.1.2.1', 'section508', 'section508.22.a', 'deprecated' ],
|
|
28716
28763
|
actIds: [ '2eb176', 'afb423' ],
|
|
28717
28764
|
all: [],
|
|
28718
28765
|
any: [],
|
|
@@ -28720,7 +28767,7 @@
|
|
|
28720
28767
|
}, {
|
|
28721
28768
|
id: 'autocomplete-valid',
|
|
28722
28769
|
matches: 'autocomplete-matches',
|
|
28723
|
-
tags: [ 'cat.forms', 'wcag21aa', 'wcag135', 'ACT' ],
|
|
28770
|
+
tags: [ 'cat.forms', 'wcag21aa', 'wcag135', 'EN-301-549', 'EN-9.1.3.5', 'ACT' ],
|
|
28724
28771
|
actIds: [ '73f2c2' ],
|
|
28725
28772
|
all: [ {
|
|
28726
28773
|
options: {
|
|
@@ -28734,7 +28781,7 @@
|
|
|
28734
28781
|
id: 'avoid-inline-spacing',
|
|
28735
28782
|
selector: '[style]',
|
|
28736
28783
|
matches: 'is-visible-on-screen-matches',
|
|
28737
|
-
tags: [ 'cat.structure', 'wcag21aa', 'wcag1412', 'ACT' ],
|
|
28784
|
+
tags: [ 'cat.structure', 'wcag21aa', 'wcag1412', 'EN-301-549', 'EN-9.1.4.12', 'ACT' ],
|
|
28738
28785
|
actIds: [ '24afc2', '9e45ec', '78fd32' ],
|
|
28739
28786
|
all: [ {
|
|
28740
28787
|
options: {
|
|
@@ -28763,7 +28810,7 @@
|
|
|
28763
28810
|
id: 'blink',
|
|
28764
28811
|
selector: 'blink',
|
|
28765
28812
|
excludeHidden: false,
|
|
28766
|
-
tags: [ 'cat.time-and-media', 'wcag2a', 'wcag222', 'section508', 'section508.22.j', 'TTv5', 'TT2.b' ],
|
|
28813
|
+
tags: [ 'cat.time-and-media', 'wcag2a', 'wcag222', 'section508', 'section508.22.j', 'TTv5', 'TT2.b', 'EN-301-549', 'EN-9.2.2.2' ],
|
|
28767
28814
|
all: [],
|
|
28768
28815
|
any: [],
|
|
28769
28816
|
none: [ 'is-on-screen' ]
|
|
@@ -28771,7 +28818,7 @@
|
|
|
28771
28818
|
id: 'button-name',
|
|
28772
28819
|
selector: 'button',
|
|
28773
28820
|
matches: 'no-explicit-name-required-matches',
|
|
28774
|
-
tags: [ 'cat.name-role-value', 'wcag2a', 'wcag412', 'section508', 'section508.22.a', '
|
|
28821
|
+
tags: [ 'cat.name-role-value', 'wcag2a', 'wcag412', 'section508', 'section508.22.a', 'TTv5', 'TT6.a', 'EN-301-549', 'EN-9.4.1.2', 'ACT' ],
|
|
28775
28822
|
actIds: [ '97a4e1', 'm6b1q3' ],
|
|
28776
28823
|
all: [],
|
|
28777
28824
|
any: [ 'button-has-visible-text', 'aria-label', 'aria-labelledby', {
|
|
@@ -28787,7 +28834,7 @@
|
|
|
28787
28834
|
pageLevel: true,
|
|
28788
28835
|
matches: 'bypass-matches',
|
|
28789
28836
|
reviewOnFail: true,
|
|
28790
|
-
tags: [ 'cat.keyboard', 'wcag2a', 'wcag241', 'section508', 'section508.22.o', 'TTv5', 'TT9.a' ],
|
|
28837
|
+
tags: [ 'cat.keyboard', 'wcag2a', 'wcag241', 'section508', 'section508.22.o', 'TTv5', 'TT9.a', 'EN-301-549', 'EN-9.2.4.1' ],
|
|
28791
28838
|
actIds: [ 'cf77f2', '047fe0', 'b40fd1', '3e12e1', 'ye5d6e' ],
|
|
28792
28839
|
all: [],
|
|
28793
28840
|
any: [ 'internal-link-present', {
|
|
@@ -28839,7 +28886,7 @@
|
|
|
28839
28886
|
id: 'color-contrast',
|
|
28840
28887
|
matches: 'color-contrast-matches',
|
|
28841
28888
|
excludeHidden: false,
|
|
28842
|
-
tags: [ 'cat.color', 'wcag2aa', 'wcag143', '
|
|
28889
|
+
tags: [ 'cat.color', 'wcag2aa', 'wcag143', 'TTv5', 'TT13.c', 'EN-301-549', 'EN-9.1.4.3', 'ACT' ],
|
|
28843
28890
|
actIds: [ 'afw4f7', '09o5cg' ],
|
|
28844
28891
|
all: [],
|
|
28845
28892
|
any: [ {
|
|
@@ -28868,7 +28915,7 @@
|
|
|
28868
28915
|
}, {
|
|
28869
28916
|
id: 'css-orientation-lock',
|
|
28870
28917
|
selector: 'html',
|
|
28871
|
-
tags: [ 'cat.structure', 'wcag134', 'wcag21aa', 'experimental' ],
|
|
28918
|
+
tags: [ 'cat.structure', 'wcag134', 'wcag21aa', 'EN-301-549', 'EN-9.1.3.4', 'experimental' ],
|
|
28872
28919
|
actIds: [ 'b33eff' ],
|
|
28873
28920
|
all: [ {
|
|
28874
28921
|
options: {
|
|
@@ -28883,7 +28930,7 @@
|
|
|
28883
28930
|
id: 'definition-list',
|
|
28884
28931
|
selector: 'dl',
|
|
28885
28932
|
matches: 'no-role-matches',
|
|
28886
|
-
tags: [ 'cat.structure', 'wcag2a', 'wcag131' ],
|
|
28933
|
+
tags: [ 'cat.structure', 'wcag2a', 'wcag131', 'EN-301-549', 'EN-9.1.3.1' ],
|
|
28887
28934
|
all: [],
|
|
28888
28935
|
any: [],
|
|
28889
28936
|
none: [ 'structured-dlitems', {
|
|
@@ -28898,7 +28945,7 @@
|
|
|
28898
28945
|
id: 'dlitem',
|
|
28899
28946
|
selector: 'dd, dt',
|
|
28900
28947
|
matches: 'no-role-matches',
|
|
28901
|
-
tags: [ 'cat.structure', 'wcag2a', 'wcag131' ],
|
|
28948
|
+
tags: [ 'cat.structure', 'wcag2a', 'wcag131', 'EN-301-549', 'EN-9.1.3.1' ],
|
|
28902
28949
|
all: [],
|
|
28903
28950
|
any: [ 'dlitem' ],
|
|
28904
28951
|
none: []
|
|
@@ -28906,7 +28953,7 @@
|
|
|
28906
28953
|
id: 'document-title',
|
|
28907
28954
|
selector: 'html',
|
|
28908
28955
|
matches: 'is-initiator-matches',
|
|
28909
|
-
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag242', '
|
|
28956
|
+
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag242', 'TTv5', 'TT12.a', 'EN-301-549', 'EN-9.2.4.2', 'ACT' ],
|
|
28910
28957
|
actIds: [ '2779a5' ],
|
|
28911
28958
|
all: [],
|
|
28912
28959
|
any: [ 'doc-has-title' ],
|
|
@@ -28916,7 +28963,8 @@
|
|
|
28916
28963
|
selector: '[id]',
|
|
28917
28964
|
matches: 'duplicate-id-active-matches',
|
|
28918
28965
|
excludeHidden: false,
|
|
28919
|
-
tags: [ 'cat.parsing', 'wcag2a', 'wcag411' ],
|
|
28966
|
+
tags: [ 'cat.parsing', 'wcag2a-obsolete', 'wcag411', 'deprecated' ],
|
|
28967
|
+
enabled: false,
|
|
28920
28968
|
actIds: [ '3ea0c8' ],
|
|
28921
28969
|
all: [],
|
|
28922
28970
|
any: [ 'duplicate-id-active' ],
|
|
@@ -28926,7 +28974,8 @@
|
|
|
28926
28974
|
selector: '[id]',
|
|
28927
28975
|
matches: 'duplicate-id-aria-matches',
|
|
28928
28976
|
excludeHidden: false,
|
|
28929
|
-
tags: [ 'cat.parsing', 'wcag2a', '
|
|
28977
|
+
tags: [ 'cat.parsing', 'wcag2a', 'wcag412', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
28978
|
+
reviewOnFail: true,
|
|
28930
28979
|
actIds: [ '3ea0c8' ],
|
|
28931
28980
|
all: [],
|
|
28932
28981
|
any: [ 'duplicate-id-aria' ],
|
|
@@ -28936,7 +28985,8 @@
|
|
|
28936
28985
|
selector: '[id]',
|
|
28937
28986
|
matches: 'duplicate-id-misc-matches',
|
|
28938
28987
|
excludeHidden: false,
|
|
28939
|
-
tags: [ 'cat.parsing', 'wcag2a', 'wcag411' ],
|
|
28988
|
+
tags: [ 'cat.parsing', 'wcag2a-obsolete', 'wcag411', 'deprecated' ],
|
|
28989
|
+
enabled: false,
|
|
28940
28990
|
actIds: [ '3ea0c8' ],
|
|
28941
28991
|
all: [],
|
|
28942
28992
|
any: [ 'duplicate-id' ],
|
|
@@ -28983,7 +29033,7 @@
|
|
|
28983
29033
|
id: 'form-field-multiple-labels',
|
|
28984
29034
|
selector: 'input, select, textarea',
|
|
28985
29035
|
matches: 'label-matches',
|
|
28986
|
-
tags: [ 'cat.forms', 'wcag2a', 'wcag332', 'TTv5', 'TT5.c' ],
|
|
29036
|
+
tags: [ 'cat.forms', 'wcag2a', 'wcag332', 'TTv5', 'TT5.c', 'EN-301-549', 'EN-9.3.3.2' ],
|
|
28987
29037
|
all: [],
|
|
28988
29038
|
any: [],
|
|
28989
29039
|
none: [ 'multiple-label' ]
|
|
@@ -28991,7 +29041,7 @@
|
|
|
28991
29041
|
id: 'frame-focusable-content',
|
|
28992
29042
|
selector: 'html',
|
|
28993
29043
|
matches: 'frame-focusable-content-matches',
|
|
28994
|
-
tags: [ 'cat.keyboard', 'wcag2a', 'wcag211', 'TTv5', 'TT4.a' ],
|
|
29044
|
+
tags: [ 'cat.keyboard', 'wcag2a', 'wcag211', 'TTv5', 'TT4.a', 'EN-301-549', 'EN-9.2.1.1' ],
|
|
28995
29045
|
actIds: [ 'akn7bn' ],
|
|
28996
29046
|
all: [],
|
|
28997
29047
|
any: [ 'frame-focusable-content' ],
|
|
@@ -28999,7 +29049,7 @@
|
|
|
28999
29049
|
}, {
|
|
29000
29050
|
id: 'frame-tested',
|
|
29001
29051
|
selector: 'html, frame, iframe',
|
|
29002
|
-
tags: [ 'cat.structure', '
|
|
29052
|
+
tags: [ 'cat.structure', 'best-practice', 'review-item' ],
|
|
29003
29053
|
all: [ {
|
|
29004
29054
|
options: {
|
|
29005
29055
|
isViolation: false
|
|
@@ -29012,7 +29062,7 @@
|
|
|
29012
29062
|
id: 'frame-title-unique',
|
|
29013
29063
|
selector: 'frame[title], iframe[title]',
|
|
29014
29064
|
matches: 'frame-title-has-text-matches',
|
|
29015
|
-
tags: [ 'cat.text-alternatives', '
|
|
29065
|
+
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag412', 'TTv5', 'TT12.d', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
29016
29066
|
actIds: [ '4b1c6c' ],
|
|
29017
29067
|
all: [],
|
|
29018
29068
|
any: [],
|
|
@@ -29022,7 +29072,7 @@
|
|
|
29022
29072
|
id: 'frame-title',
|
|
29023
29073
|
selector: 'frame, iframe',
|
|
29024
29074
|
matches: 'no-negative-tabindex-matches',
|
|
29025
|
-
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag412', 'section508', 'section508.22.i', 'TTv5', 'TT12.
|
|
29075
|
+
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag412', 'section508', 'section508.22.i', 'TTv5', 'TT12.d', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
29026
29076
|
actIds: [ 'cae760' ],
|
|
29027
29077
|
all: [],
|
|
29028
29078
|
any: [ {
|
|
@@ -29044,7 +29094,7 @@
|
|
|
29044
29094
|
id: 'hidden-content',
|
|
29045
29095
|
selector: '*',
|
|
29046
29096
|
excludeHidden: false,
|
|
29047
|
-
tags: [ 'cat.structure', '
|
|
29097
|
+
tags: [ 'cat.structure', 'best-practice', 'experimental', 'review-item' ],
|
|
29048
29098
|
all: [],
|
|
29049
29099
|
any: [ 'hidden-content' ],
|
|
29050
29100
|
none: []
|
|
@@ -29052,7 +29102,7 @@
|
|
|
29052
29102
|
id: 'html-has-lang',
|
|
29053
29103
|
selector: 'html',
|
|
29054
29104
|
matches: 'is-initiator-matches',
|
|
29055
|
-
tags: [ 'cat.language', 'wcag2a', 'wcag311', '
|
|
29105
|
+
tags: [ 'cat.language', 'wcag2a', 'wcag311', 'TTv5', 'TT11.a', 'EN-301-549', 'EN-9.3.1.1', 'ACT' ],
|
|
29056
29106
|
actIds: [ 'b5c3f8' ],
|
|
29057
29107
|
all: [],
|
|
29058
29108
|
any: [ {
|
|
@@ -29065,7 +29115,7 @@
|
|
|
29065
29115
|
}, {
|
|
29066
29116
|
id: 'html-lang-valid',
|
|
29067
29117
|
selector: 'html[lang]:not([lang=""]), html[xml\\:lang]:not([xml\\:lang=""])',
|
|
29068
|
-
tags: [ 'cat.language', 'wcag2a', 'wcag311', '
|
|
29118
|
+
tags: [ 'cat.language', 'wcag2a', 'wcag311', 'TTv5', 'TT11.a', 'EN-301-549', 'EN-9.3.1.1', 'ACT' ],
|
|
29069
29119
|
actIds: [ 'bf051a' ],
|
|
29070
29120
|
all: [],
|
|
29071
29121
|
any: [],
|
|
@@ -29079,7 +29129,7 @@
|
|
|
29079
29129
|
id: 'html-xml-lang-mismatch',
|
|
29080
29130
|
selector: 'html[lang][xml\\:lang]',
|
|
29081
29131
|
matches: 'xml-lang-mismatch-matches',
|
|
29082
|
-
tags: [ 'cat.language', 'wcag2a', 'wcag311', 'ACT' ],
|
|
29132
|
+
tags: [ 'cat.language', 'wcag2a', 'wcag311', 'EN-301-549', 'EN-9.3.1.1', 'ACT' ],
|
|
29083
29133
|
actIds: [ '5b7ae0' ],
|
|
29084
29134
|
all: [ 'xml-lang-mismatch' ],
|
|
29085
29135
|
any: [],
|
|
@@ -29099,7 +29149,7 @@
|
|
|
29099
29149
|
id: 'image-alt',
|
|
29100
29150
|
selector: 'img',
|
|
29101
29151
|
matches: 'no-explicit-name-required-matches',
|
|
29102
|
-
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag111', 'section508', 'section508.22.a', '
|
|
29152
|
+
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag111', 'section508', 'section508.22.a', 'TTv5', 'TT7.a', 'TT7.b', 'EN-301-549', 'EN-9.1.1.1', 'ACT' ],
|
|
29103
29153
|
actIds: [ '23a2a8' ],
|
|
29104
29154
|
all: [],
|
|
29105
29155
|
any: [ 'has-alt', 'aria-label', 'aria-labelledby', {
|
|
@@ -29125,7 +29175,7 @@
|
|
|
29125
29175
|
id: 'input-button-name',
|
|
29126
29176
|
selector: 'input[type="button"], input[type="submit"], input[type="reset"]',
|
|
29127
29177
|
matches: 'no-explicit-name-required-matches',
|
|
29128
|
-
tags: [ 'cat.name-role-value', 'wcag2a', 'wcag412', 'section508', 'section508.22.a', '
|
|
29178
|
+
tags: [ 'cat.name-role-value', 'wcag2a', 'wcag412', 'section508', 'section508.22.a', 'TTv5', 'TT5.c', 'EN-301-549', 'EN-9.4.1.2', 'ACT' ],
|
|
29129
29179
|
actIds: [ '97a4e1' ],
|
|
29130
29180
|
all: [],
|
|
29131
29181
|
any: [ 'non-empty-if-present', {
|
|
@@ -29144,7 +29194,7 @@
|
|
|
29144
29194
|
id: 'input-image-alt',
|
|
29145
29195
|
selector: 'input[type="image"]',
|
|
29146
29196
|
matches: 'no-explicit-name-required-matches',
|
|
29147
|
-
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag111', 'wcag412', 'section508', 'section508.22.a', '
|
|
29197
|
+
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag111', 'wcag412', 'section508', 'section508.22.a', 'TTv5', 'TT7.a', 'EN-301-549', 'EN-9.1.1.1', 'EN-9.4.1.2', 'ACT' ],
|
|
29148
29198
|
actIds: [ '59796f' ],
|
|
29149
29199
|
all: [],
|
|
29150
29200
|
any: [ {
|
|
@@ -29162,7 +29212,7 @@
|
|
|
29162
29212
|
}, {
|
|
29163
29213
|
id: 'label-content-name-mismatch',
|
|
29164
29214
|
matches: 'label-content-name-mismatch-matches',
|
|
29165
|
-
tags: [ 'cat.semantics', 'wcag21a', 'wcag253', 'experimental' ],
|
|
29215
|
+
tags: [ 'cat.semantics', 'wcag21a', 'wcag253', 'EN-301-549', 'EN-9.2.5.3', 'experimental' ],
|
|
29166
29216
|
actIds: [ '2ee8b8' ],
|
|
29167
29217
|
all: [],
|
|
29168
29218
|
any: [ {
|
|
@@ -29185,7 +29235,7 @@
|
|
|
29185
29235
|
id: 'label',
|
|
29186
29236
|
selector: 'input, textarea',
|
|
29187
29237
|
matches: 'label-matches',
|
|
29188
|
-
tags: [ 'cat.forms', 'wcag2a', 'wcag412', 'section508', 'section508.22.n', '
|
|
29238
|
+
tags: [ 'cat.forms', 'wcag2a', 'wcag412', 'section508', 'section508.22.n', 'TTv5', 'TT5.c', 'EN-301-549', 'EN-9.4.1.2', 'ACT' ],
|
|
29189
29239
|
actIds: [ 'e086e5' ],
|
|
29190
29240
|
all: [],
|
|
29191
29241
|
any: [ 'implicit-label', 'explicit-label', 'aria-label', 'aria-labelledby', {
|
|
@@ -29294,7 +29344,7 @@
|
|
|
29294
29344
|
selector: 'a[href], [role=link]',
|
|
29295
29345
|
matches: 'link-in-text-block-matches',
|
|
29296
29346
|
excludeHidden: false,
|
|
29297
|
-
tags: [ 'cat.color', 'wcag2a', 'wcag141', 'TTv5', 'TT13.a' ],
|
|
29347
|
+
tags: [ 'cat.color', 'wcag2a', 'wcag141', 'TTv5', 'TT13.a', 'EN-301-549', 'EN-9.1.4.1' ],
|
|
29298
29348
|
all: [],
|
|
29299
29349
|
any: [ {
|
|
29300
29350
|
options: {
|
|
@@ -29307,7 +29357,7 @@
|
|
|
29307
29357
|
}, {
|
|
29308
29358
|
id: 'link-name',
|
|
29309
29359
|
selector: 'a[href]',
|
|
29310
|
-
tags: [ 'cat.name-role-value', 'wcag2a', '
|
|
29360
|
+
tags: [ 'cat.name-role-value', 'wcag2a', 'wcag244', 'wcag412', 'section508', 'section508.22.a', 'TTv5', 'TT6.a', 'EN-301-549', 'EN-9.2.4.4', 'EN-9.4.1.2', 'ACT' ],
|
|
29311
29361
|
actIds: [ 'c487ae' ],
|
|
29312
29362
|
all: [],
|
|
29313
29363
|
any: [ 'has-visible-text', 'aria-label', 'aria-labelledby', {
|
|
@@ -29321,7 +29371,7 @@
|
|
|
29321
29371
|
id: 'list',
|
|
29322
29372
|
selector: 'ul, ol',
|
|
29323
29373
|
matches: 'no-role-matches',
|
|
29324
|
-
tags: [ 'cat.structure', 'wcag2a', 'wcag131' ],
|
|
29374
|
+
tags: [ 'cat.structure', 'wcag2a', 'wcag131', 'EN-301-549', 'EN-9.1.3.1' ],
|
|
29325
29375
|
all: [],
|
|
29326
29376
|
any: [],
|
|
29327
29377
|
none: [ {
|
|
@@ -29335,7 +29385,7 @@
|
|
|
29335
29385
|
id: 'listitem',
|
|
29336
29386
|
selector: 'li',
|
|
29337
29387
|
matches: 'no-role-matches',
|
|
29338
|
-
tags: [ 'cat.structure', 'wcag2a', 'wcag131' ],
|
|
29388
|
+
tags: [ 'cat.structure', 'wcag2a', 'wcag131', 'EN-301-549', 'EN-9.1.3.1' ],
|
|
29339
29389
|
all: [],
|
|
29340
29390
|
any: [ 'listitem' ],
|
|
29341
29391
|
none: []
|
|
@@ -29343,7 +29393,7 @@
|
|
|
29343
29393
|
id: 'marquee',
|
|
29344
29394
|
selector: 'marquee',
|
|
29345
29395
|
excludeHidden: false,
|
|
29346
|
-
tags: [ 'cat.parsing', 'wcag2a', 'wcag222', 'TTv5', 'TT2.b' ],
|
|
29396
|
+
tags: [ 'cat.parsing', 'wcag2a', 'wcag222', 'TTv5', 'TT2.b', 'EN-301-549', 'EN-9.2.2.2' ],
|
|
29347
29397
|
all: [],
|
|
29348
29398
|
any: [],
|
|
29349
29399
|
none: [ 'is-on-screen' ]
|
|
@@ -29367,7 +29417,7 @@
|
|
|
29367
29417
|
id: 'meta-refresh',
|
|
29368
29418
|
selector: 'meta[http-equiv="refresh"][content]',
|
|
29369
29419
|
excludeHidden: false,
|
|
29370
|
-
tags: [ 'cat.time-and-media', 'wcag2a', 'wcag221', 'TTv5', '
|
|
29420
|
+
tags: [ 'cat.time-and-media', 'wcag2a', 'wcag221', 'TTv5', 'TT8.a', 'EN-301-549', 'EN-9.2.2.1' ],
|
|
29371
29421
|
actIds: [ 'bc659a', 'bisz58' ],
|
|
29372
29422
|
all: [],
|
|
29373
29423
|
any: [ {
|
|
@@ -29398,7 +29448,7 @@
|
|
|
29398
29448
|
selector: 'meta[name="viewport"]',
|
|
29399
29449
|
matches: 'is-initiator-matches',
|
|
29400
29450
|
excludeHidden: false,
|
|
29401
|
-
tags: [ 'cat.sensory-and-visual-cues', 'wcag2aa', 'wcag144', 'ACT' ],
|
|
29451
|
+
tags: [ 'cat.sensory-and-visual-cues', 'wcag2aa', 'wcag144', 'EN-301-549', 'EN-9.1.4.4', 'ACT' ],
|
|
29402
29452
|
actIds: [ 'b4f0c3' ],
|
|
29403
29453
|
all: [],
|
|
29404
29454
|
any: [ {
|
|
@@ -29411,7 +29461,7 @@
|
|
|
29411
29461
|
}, {
|
|
29412
29462
|
id: 'nested-interactive',
|
|
29413
29463
|
matches: 'nested-interactive-matches',
|
|
29414
|
-
tags: [ 'cat.keyboard', 'wcag2a', 'wcag412', 'TTv5', '
|
|
29464
|
+
tags: [ 'cat.keyboard', 'wcag2a', 'wcag412', 'TTv5', 'TT6.a', 'EN-301-549', 'EN-9.4.1.2' ],
|
|
29415
29465
|
actIds: [ '307n5z' ],
|
|
29416
29466
|
all: [],
|
|
29417
29467
|
any: [ 'no-focusable-content' ],
|
|
@@ -29422,7 +29472,7 @@
|
|
|
29422
29472
|
selector: 'audio[autoplay], video[autoplay]',
|
|
29423
29473
|
matches: 'no-autoplay-audio-matches',
|
|
29424
29474
|
reviewOnFail: true,
|
|
29425
|
-
tags: [ 'cat.time-and-media', 'wcag2a', 'wcag142', '
|
|
29475
|
+
tags: [ 'cat.time-and-media', 'wcag2a', 'wcag142', 'TTv5', 'TT2.a', 'EN-301-549', 'EN-9.1.4.2', 'ACT' ],
|
|
29426
29476
|
actIds: [ '80f0bf' ],
|
|
29427
29477
|
preload: true,
|
|
29428
29478
|
all: [ {
|
|
@@ -29437,7 +29487,7 @@
|
|
|
29437
29487
|
id: 'object-alt',
|
|
29438
29488
|
selector: 'object[data]',
|
|
29439
29489
|
matches: 'object-is-loaded-matches',
|
|
29440
|
-
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag111', 'section508', 'section508.22.a' ],
|
|
29490
|
+
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag111', 'section508', 'section508.22.a', 'EN-301-549', 'EN-9.1.1.1' ],
|
|
29441
29491
|
actIds: [ '8fc3b6' ],
|
|
29442
29492
|
all: [],
|
|
29443
29493
|
any: [ 'aria-label', 'aria-labelledby', {
|
|
@@ -29451,7 +29501,7 @@
|
|
|
29451
29501
|
id: 'p-as-heading',
|
|
29452
29502
|
selector: 'p',
|
|
29453
29503
|
matches: 'p-as-heading-matches',
|
|
29454
|
-
tags: [ 'cat.semantics', 'wcag2a', 'wcag131', 'experimental' ],
|
|
29504
|
+
tags: [ 'cat.semantics', 'wcag2a', 'wcag131', 'EN-301-549', 'EN-9.1.3.1', 'experimental' ],
|
|
29455
29505
|
all: [ {
|
|
29456
29506
|
options: {
|
|
29457
29507
|
margins: [ {
|
|
@@ -29511,7 +29561,7 @@
|
|
|
29511
29561
|
id: 'role-img-alt',
|
|
29512
29562
|
selector: '[role=\'img\']:not(img, area, input, object)',
|
|
29513
29563
|
matches: 'html-namespace-matches',
|
|
29514
|
-
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag111', 'section508', 'section508.22.a', '
|
|
29564
|
+
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag111', 'section508', 'section508.22.a', 'TTv5', 'TT7.a', 'EN-301-549', 'EN-9.1.1.1', 'ACT' ],
|
|
29515
29565
|
actIds: [ '23a2a8' ],
|
|
29516
29566
|
all: [],
|
|
29517
29567
|
any: [ 'aria-label', 'aria-labelledby', {
|
|
@@ -29537,7 +29587,7 @@
|
|
|
29537
29587
|
id: 'scrollable-region-focusable',
|
|
29538
29588
|
selector: '*:not(select,textarea)',
|
|
29539
29589
|
matches: 'scrollable-region-focusable-matches',
|
|
29540
|
-
tags: [ 'cat.keyboard', 'wcag2a', 'wcag211' ],
|
|
29590
|
+
tags: [ 'cat.keyboard', 'wcag2a', 'wcag211', 'TTv5', 'TT4.a', 'EN-301-549', 'EN-9.2.1.1' ],
|
|
29541
29591
|
actIds: [ '0ssw9k' ],
|
|
29542
29592
|
all: [],
|
|
29543
29593
|
any: [ 'focusable-content', 'focusable-element' ],
|
|
@@ -29545,7 +29595,7 @@
|
|
|
29545
29595
|
}, {
|
|
29546
29596
|
id: 'select-name',
|
|
29547
29597
|
selector: 'select',
|
|
29548
|
-
tags: [ 'cat.forms', 'wcag2a', 'wcag412', 'section508', 'section508.22.n', '
|
|
29598
|
+
tags: [ 'cat.forms', 'wcag2a', 'wcag412', 'section508', 'section508.22.n', 'TTv5', 'TT5.c', 'EN-301-549', 'EN-9.4.1.2', 'ACT' ],
|
|
29549
29599
|
actIds: [ 'e086e5' ],
|
|
29550
29600
|
all: [],
|
|
29551
29601
|
any: [ 'implicit-label', 'explicit-label', 'aria-label', 'aria-labelledby', {
|
|
@@ -29558,7 +29608,7 @@
|
|
|
29558
29608
|
}, {
|
|
29559
29609
|
id: 'server-side-image-map',
|
|
29560
29610
|
selector: 'img[ismap]',
|
|
29561
|
-
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag211', 'section508', 'section508.22.f' ],
|
|
29611
|
+
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag211', 'section508', 'section508.22.f', 'TTv5', 'TT4.a', 'EN-301-549', 'EN-9.2.1.1' ],
|
|
29562
29612
|
all: [],
|
|
29563
29613
|
any: [],
|
|
29564
29614
|
none: [ 'exists' ]
|
|
@@ -29574,7 +29624,7 @@
|
|
|
29574
29624
|
id: 'svg-img-alt',
|
|
29575
29625
|
selector: '[role="img"], [role="graphics-symbol"], svg[role="graphics-document"]',
|
|
29576
29626
|
matches: 'svg-namespace-matches',
|
|
29577
|
-
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag111', 'section508', 'section508.22.a', '
|
|
29627
|
+
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag111', 'section508', 'section508.22.a', 'TTv5', 'TT7.a', 'EN-301-549', 'EN-9.1.1.1', 'ACT' ],
|
|
29578
29628
|
actIds: [ '7d6734' ],
|
|
29579
29629
|
all: [],
|
|
29580
29630
|
any: [ 'svg-non-empty-title', 'aria-label', 'aria-labelledby', {
|
|
@@ -29602,7 +29652,7 @@
|
|
|
29602
29652
|
id: 'table-fake-caption',
|
|
29603
29653
|
selector: 'table',
|
|
29604
29654
|
matches: 'data-table-matches',
|
|
29605
|
-
tags: [ 'cat.tables', 'experimental', 'wcag2a', 'wcag131', 'section508', 'section508.22.g' ],
|
|
29655
|
+
tags: [ 'cat.tables', 'experimental', 'wcag2a', 'wcag131', 'section508', 'section508.22.g', 'EN-301-549', 'EN-9.1.3.1' ],
|
|
29606
29656
|
all: [ 'caption-faked' ],
|
|
29607
29657
|
any: [],
|
|
29608
29658
|
none: []
|
|
@@ -29611,7 +29661,7 @@
|
|
|
29611
29661
|
selector: '*',
|
|
29612
29662
|
enabled: false,
|
|
29613
29663
|
matches: 'widget-not-inline-matches',
|
|
29614
|
-
tags: [ '
|
|
29664
|
+
tags: [ 'cat.sensory-and-visual-cues', 'wcag22aa', 'wcag258' ],
|
|
29615
29665
|
all: [],
|
|
29616
29666
|
any: [ {
|
|
29617
29667
|
options: {
|
|
@@ -29629,7 +29679,7 @@
|
|
|
29629
29679
|
id: 'td-has-header',
|
|
29630
29680
|
selector: 'table',
|
|
29631
29681
|
matches: 'data-table-large-matches',
|
|
29632
|
-
tags: [ 'cat.tables', 'experimental', 'wcag2a', 'wcag131', 'section508', 'section508.22.g', 'TTv5', 'TT14.b' ],
|
|
29682
|
+
tags: [ 'cat.tables', 'experimental', 'wcag2a', 'wcag131', 'section508', 'section508.22.g', 'TTv5', 'TT14.b', 'EN-301-549', 'EN-9.1.3.1' ],
|
|
29633
29683
|
all: [ 'td-has-header' ],
|
|
29634
29684
|
any: [],
|
|
29635
29685
|
none: []
|
|
@@ -29637,7 +29687,7 @@
|
|
|
29637
29687
|
id: 'td-headers-attr',
|
|
29638
29688
|
selector: 'table',
|
|
29639
29689
|
matches: 'table-or-grid-role-matches',
|
|
29640
|
-
tags: [ 'cat.tables', 'wcag2a', 'wcag131', 'section508', 'section508.22.g' ],
|
|
29690
|
+
tags: [ 'cat.tables', 'wcag2a', 'wcag131', 'section508', 'section508.22.g', 'TTv5', 'TT14.b', 'EN-301-549', 'EN-9.1.3.1' ],
|
|
29641
29691
|
actIds: [ 'a25f45' ],
|
|
29642
29692
|
all: [ 'td-headers-attr' ],
|
|
29643
29693
|
any: [],
|
|
@@ -29646,7 +29696,7 @@
|
|
|
29646
29696
|
id: 'th-has-data-cells',
|
|
29647
29697
|
selector: 'table',
|
|
29648
29698
|
matches: 'data-table-matches',
|
|
29649
|
-
tags: [ 'cat.tables', 'wcag2a', 'wcag131', 'section508', 'section508.22.g', 'TTv5', '
|
|
29699
|
+
tags: [ 'cat.tables', 'wcag2a', 'wcag131', 'section508', 'section508.22.g', 'TTv5', 'TT14.b', 'EN-301-549', 'EN-9.1.3.1' ],
|
|
29650
29700
|
actIds: [ 'd0f69e' ],
|
|
29651
29701
|
all: [ 'th-has-data-cells' ],
|
|
29652
29702
|
any: [],
|
|
@@ -29654,7 +29704,7 @@
|
|
|
29654
29704
|
}, {
|
|
29655
29705
|
id: 'valid-lang',
|
|
29656
29706
|
selector: '[lang]:not(html), [xml\\:lang]:not(html)',
|
|
29657
|
-
tags: [ 'cat.language', 'wcag2aa', 'wcag312', '
|
|
29707
|
+
tags: [ 'cat.language', 'wcag2aa', 'wcag312', 'TTv5', 'TT11.b', 'EN-301-549', 'EN-9.3.1.2', 'ACT' ],
|
|
29658
29708
|
actIds: [ 'de46e4' ],
|
|
29659
29709
|
all: [],
|
|
29660
29710
|
any: [],
|
|
@@ -29667,7 +29717,7 @@
|
|
|
29667
29717
|
}, {
|
|
29668
29718
|
id: 'video-caption',
|
|
29669
29719
|
selector: 'video',
|
|
29670
|
-
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag122', 'section508', 'section508.22.a', 'TTv5', 'TT17.a' ],
|
|
29720
|
+
tags: [ 'cat.text-alternatives', 'wcag2a', 'wcag122', 'section508', 'section508.22.a', 'TTv5', 'TT17.a', 'EN-301-549', 'EN-9.1.2.2' ],
|
|
29671
29721
|
actIds: [ 'eac66b' ],
|
|
29672
29722
|
all: [],
|
|
29673
29723
|
any: [],
|