@shadowtube/tizentube-noanimations 1.15.7 → 1.15.9
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.
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
!function(){"use strict";if(!window.__ttArrowSeekInstalled){window.__ttArrowSeekInstalled=!0;var e={},t=10;document.addEventListener("keydown",n,!0),document.addEventListener("keyup",n,!0)}function r(e){for(;e&&e!==document;){var t=window.getComputedStyle(e);if("true"===e.getAttribute("aria-hidden")||e.classList&&e.classList.contains("zylon-hidden")||"none"===t.display||"hidden"===t.visibility)return!0;e=e.parentNode}return!1}function n(n){if(function(e){return"ArrowLeft"===e.key||"ArrowRight"===e.key||37===e.keyCode||39===e.keyCode}(n)){var i=n.keyCode||n.which,o=39===i?1:-1;if("keyup"===n.type){if(!e[i])return;return n.preventDefault(),n.stopImmediatePropagation(),void delete e[i]}if(!(n.altKey||n.ctrlKey||n.metaKey||n.shiftKey||(a=n.target)&&(a.isContentEditable||/^(INPUT|TEXTAREA|SELECT)$/.test(a.tagName||"")))){var a,d=document.querySelector("video");if(d&&!d.paused&&!d.ended){if(!e[i]){if(function(e){if(!e||!e.closest)return!1;var t=e.closest("ytlr-tile-renderer");return!(!t||r(t))}(n.target))return;if(function(){var e,t,n,i=["ytlr-player-page","ytlr-player-actions-container","ytlr-progress-bar"];for(e=0;e<i.length;e++)if((t=document.querySelector(i[e]))&&!r(t)&&"hidden"!==(n=window.getComputedStyle(t)).visibility&&parseFloat(n.opacity)>0&&t.getClientRects().length>0)return!0;return!1}())return;e[i]=!0}n.preventDefault(),n.stopImmediatePropagation(),function(e,r){var n=e.currentTime+r*t,i=e.duration;n<0&&(n=0),isFinite(i)&&n>i&&(n=i),e.currentTime=n}(d,o)}}}}}();[/-]
|
|
2
|
+
[+]!(function () {[/+][-] ```[/-]
|
|
3
|
+
[+]'use strict';[/+]
|
|
4
|
+
[+]if (!window.__ttArrowSeekInstalled) {[/+]
|
|
5
|
+
[+]window.__ttArrowSeekInstalled = !0;[/+]
|
|
6
|
+
[+]var e = {},[/+]
|
|
7
|
+
[+]t = 10;[/+]
|
|
8
|
+
[+](document.addEventListener('keydown', n, !0),[/+]
|
|
9
|
+
[+]document.addEventListener('keyup', n, !0));[/+]
|
|
10
|
+
[+]}[/+]
|
|
11
|
+
[+]function r(e) {[/+]
|
|
12
|
+
[+]for (; e && e !== document; ) {[/+]
|
|
13
|
+
[+]var t = window.getComputedStyle(e);[/+]
|
|
14
|
+
[+]if ([/+]
|
|
15
|
+
[+]'true' === e.getAttribute('aria-hidden') ||[/+]
|
|
16
|
+
[+](e.classList && e.classList.contains('zylon-hidden')) ||[/+]
|
|
17
|
+
[+]'none' === t.display ||[/+]
|
|
18
|
+
[+]'hidden' === t.visibility[/+]
|
|
19
|
+
[+])[/+]
|
|
20
|
+
[+]return !0;[/+]
|
|
21
|
+
[+]e = e.parentNode;[/+]
|
|
22
|
+
[+]}[/+]
|
|
23
|
+
[+]return !1;[/+]
|
|
24
|
+
[+]}[/+]
|
|
25
|
+
[+]function n(n) {[/+]
|
|
26
|
+
[+]if ([/+]
|
|
27
|
+
[+](function (e) {[/+]
|
|
28
|
+
[+]return ([/+]
|
|
29
|
+
[+]'ArrowLeft' === e.key ||[/+]
|
|
30
|
+
[+]'ArrowRight' === e.key ||[/+]
|
|
31
|
+
[+]37 === e.keyCode ||[/+]
|
|
32
|
+
[+]39 === e.keyCode[/+]
|
|
33
|
+
[+]);[/+]
|
|
34
|
+
[+]})(n)[/+]
|
|
35
|
+
[+]) {[/+]
|
|
36
|
+
[+]var i = n.keyCode || n.which,[/+]
|
|
37
|
+
[+]o = 39 === i ? 1 : -1;[/+]
|
|
38
|
+
[+]if ('keyup' === n.type) {[/+]
|
|
39
|
+
[+]if (!e[i]) return;[/+]
|
|
40
|
+
[+]return ([/+]
|
|
41
|
+
[+]n.preventDefault(),[/+]
|
|
42
|
+
[+]n.stopImmediatePropagation(),[/+]
|
|
43
|
+
[+]void delete e[i][/+]
|
|
44
|
+
[+]);[/+]
|
|
45
|
+
[+]}[/+]
|
|
46
|
+
[+]if ([/+]
|
|
47
|
+
[+]!([/+]
|
|
48
|
+
[+]n.altKey ||[/+]
|
|
49
|
+
[+]n.ctrlKey ||[/+]
|
|
50
|
+
[+]n.metaKey ||[/+]
|
|
51
|
+
[+]n.shiftKey ||[/+]
|
|
52
|
+
[+]((a = n.target) &&[/+]
|
|
53
|
+
[+](a.isContentEditable ||[/+]
|
|
54
|
+
[+]/^(INPUT|TEXTAREA|SELECT)$/.test(a.tagName || '')))[/+]
|
|
55
|
+
[+])[/+]
|
|
56
|
+
[+]) {[/+]
|
|
57
|
+
[+]var a,[/+]
|
|
58
|
+
[+]d = document.querySelector('video');[/+]
|
|
59
|
+
[+]if (d && !d.paused && !d.ended) {[/+]
|
|
60
|
+
[+]if (!e[i]) {[/+]
|
|
61
|
+
[+]if ([/+]
|
|
62
|
+
[+](function (e) {[/+]
|
|
63
|
+
[+]if (!e || !e.closest) return !1;[/+]
|
|
64
|
+
[+]var t = e.closest('ytlr-tile-renderer');[/+]
|
|
65
|
+
[+]return !(!t || r(t));[/+]
|
|
66
|
+
[+]})(n.target)[/+]
|
|
67
|
+
[+])[/+]
|
|
68
|
+
[+]return;[/+]
|
|
69
|
+
[+]if ([/+]
|
|
70
|
+
[+](function () {[/+]
|
|
71
|
+
[+]var e,[/+]
|
|
72
|
+
[+]t,[/+]
|
|
73
|
+
[+]n,[/+]
|
|
74
|
+
[+]i = [[/+]
|
|
75
|
+
[+]'ytlr-player-page',[/+]
|
|
76
|
+
[+]'ytlr-player-actions-container',[/+]
|
|
77
|
+
[+]'ytlr-progress-bar',[/+]
|
|
78
|
+
[+]];[/+]
|
|
79
|
+
[+]for (e = 0; e < i.length; e++)[/+]
|
|
80
|
+
[+]if ([/+]
|
|
81
|
+
[+](t = document.querySelector(i[e])) &&[/+]
|
|
82
|
+
[+]!r(t) &&[/+]
|
|
83
|
+
[+]'hidden' !== (n = window.getComputedStyle(t)).visibility &&[/+]
|
|
84
|
+
[+]parseFloat(n.opacity) > 0 &&[/+]
|
|
85
|
+
[+]t.getClientRects().length > 0[/+]
|
|
86
|
+
[+])[/+]
|
|
87
|
+
[+]return !0;[/+]
|
|
88
|
+
[+]return !1;[/+]
|
|
89
|
+
[+]})()[/+]
|
|
90
|
+
[+])[/+]
|
|
91
|
+
[+]return;[/+]
|
|
92
|
+
[+]e[i] = !0;[/+]
|
|
93
|
+
[+]}[/+]
|
|
94
|
+
[+](n.preventDefault(),[/+]
|
|
95
|
+
[+]n.stopImmediatePropagation(),[/+]
|
|
96
|
+
[+](function (e, r) {[/+]
|
|
97
|
+
[+]var n = e.currentTime + r * t,[/+]
|
|
98
|
+
[+]i = e.duration;[/+]
|
|
99
|
+
[+](n < 0 && (n = 0),[/+]
|
|
100
|
+
[+]isFinite(i) && n > i && (n = i),[/+]
|
|
101
|
+
[+](e.currentTime = n));[/+]
|
|
102
|
+
[+]})(d, o));[/+]
|
|
103
|
+
[+]}[/+]
|
|
104
|
+
[+]}[/+]
|
|
105
|
+
[+]}[/+]
|
|
106
|
+
[+]}[/+]
|
|
107
|
+
[+]})();
|