byteoss 1.0.0

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.
Files changed (105) hide show
  1. package/README.md +109 -0
  2. package/index.js +147 -0
  3. package/oss/059e300c-9447-401a-9160-bc09b94a5bd4.css +516 -0
  4. package/oss/0fb02e11-31af-4551-a92e-b4457ad4ab0d.svg +3 -0
  5. package/oss/139daa0c-24fd-4be3-b9c6-8e51f96f6b96.svg +3 -0
  6. package/oss/1600dbb0-15a5-483d-bdbc-84971697ad90.svg +15 -0
  7. package/oss/177f61e2-3422-4c87-8110-ff1615758f91.css +153 -0
  8. package/oss/18cab5b9-4981-4274-8c5f-1978588297b0.png +0 -0
  9. package/oss/1c9abd94-340f-4c18-92a3-d28c61a16bbb.js +936 -0
  10. package/oss/258f066d-7574-491d-ba06-0f2e67db0773.js +1 -0
  11. package/oss/28225623-cdb8-4d7b-afe7-a25b9cdf4c79.svg +4 -0
  12. package/oss/2b103172-c38e-4c9c-b67c-753ede400c6b.js +1 -0
  13. package/oss/2cd0609f-d7a7-4c53-a277-79e8dec5dfc6.svg +4 -0
  14. package/oss/332d0e76-3c05-4285-af16-13e9f9bbcbed.css +431 -0
  15. package/oss/36a32028-256f-465d-be90-a65d1df04a90.js +1 -0
  16. package/oss/370921ea-2b94-4c18-9d1a-785aa58bef86.js +770 -0
  17. package/oss/3e98311d-bbf6-40d6-82b7-52b710aca34a.css +198 -0
  18. package/oss/40117c3a-1925-4250-90bf-f3ef878ee97d.svg +3 -0
  19. package/oss/469b8af5-1826-4f55-826f-56d57a896563.js +1 -0
  20. package/oss/49f08903-6594-475c-aab6-4c15b41ebc3a.svg +28 -0
  21. package/oss/4a5a9153-2bd7-443c-b628-aee3d4d55fd6.js +300 -0
  22. package/oss/4f100f7b-f956-431f-93f9-1e9e3a103574.css +197 -0
  23. package/oss/4f14fb89-2a43-49d4-89fe-c245508b451f.js +1 -0
  24. package/oss/50863606-18e8-4eaa-b738-6e98b7ff791f.css +513 -0
  25. package/oss/54a1eff8-ecd1-4604-956e-91e461d0f704.js +705 -0
  26. package/oss/554a3dbe-14c7-4349-956a-236b08a149f6.css +124 -0
  27. package/oss/5cb13f6f-423d-41e9-a081-ce544bf322f1.css +513 -0
  28. package/oss/5fd8e893-8b05-452f-b914-26965c19fd31.svg +1 -0
  29. package/oss/6016b5f9-4473-44d9-9373-c761278cc244.js +2909 -0
  30. package/oss/630ebd92-9296-4c85-a18c-954545b9716b.mp4 +0 -0
  31. package/oss/66127685-903b-4261-bc3a-887459229b79.js +90 -0
  32. package/oss/6bf3a690-882e-47b2-a3bf-07600e1067d9.svg +1 -0
  33. package/oss/6d15d999-42a6-48f8-85dc-d6dd2547d33c.svg +10 -0
  34. package/oss/72ca2a33-968f-4bc4-ba39-417aca989e2a.svg +40 -0
  35. package/oss/74a7f15c-cf9e-41e5-a649-bc7a9960b89d.js +936 -0
  36. package/oss/754fca20-6995-4b15-bf56-2202c2107f41.svg +1 -0
  37. package/oss/7dbeba7d-92dc-4f24-981f-6ee5988326a3.js +90 -0
  38. package/oss/7ec89667-7160-44da-8c5d-8cb2e5b6ed51.css +144 -0
  39. package/oss/80254c08-1b12-4f32-bec9-b56251fb7b6e.svg +14 -0
  40. package/oss/80c9635a-2d99-483a-b46a-eec29d831dbc.svg +1 -0
  41. package/oss/83982b15-f2af-4c7d-98d1-9885c934adee.css +153 -0
  42. package/oss/842d27d8-4c7d-4655-bd81-d19376b9c779.ttf +0 -0
  43. package/oss/86e16498-0990-4f5f-9c78-919d6e901b3e.png +0 -0
  44. package/oss/871ce06b-adf2-4d23-893e-c929ed0dc660.css +1079 -0
  45. package/oss/875441a7-46aa-4510-b395-59d32129b643.js +84 -0
  46. package/oss/886aaec0-d95a-44c0-a809-b611c3a385bc.svg +1 -0
  47. package/oss/8870cb0a-075f-4296-8855-cf708905377f.js +51 -0
  48. package/oss/88a1fdfb-b313-4021-8c2e-97db3dddd4af.svg +26 -0
  49. package/oss/8bd1a260-f002-42d3-a288-9ec0270490ea.svg +14 -0
  50. package/oss/8d1ac209-5712-43a7-9d86-c4a1b4d6734a.json +1 -0
  51. package/oss/917711d3-9f92-4b63-804c-a17050b72502.svg +1 -0
  52. package/oss/92122f36-32a3-44ad-81f9-96427ad7d999.svg +4 -0
  53. package/oss/945aebff-92e3-4f5a-b3e1-9d891c525d95.js +19 -0
  54. package/oss/945aebff-92e3-4f5a-b3e1-9d891c525d95_bak.js +19 -0
  55. package/oss/94b77c89-093d-48ae-b363-9f6648f91ab6.css +2435 -0
  56. package/oss/9697873a-4c40-401e-addd-3736815acf10.svg +3 -0
  57. package/oss/9bd56993-3d11-4a5c-a682-a95e527da09e.svg +1 -0
  58. package/oss/9fa42c0c-617c-44a2-9bb9-aec8994af673.svg +1 -0
  59. package/oss/a25bc2e8-28e3-4bd2-b0cf-c4f577934119.svg +3 -0
  60. package/oss/a2e59c39-138a-4d1e-84c8-bc058454133f.js +434 -0
  61. package/oss/a5535c26-8363-4625-afa2-8fbbee4dab40.css +124 -0
  62. package/oss/a6a7c636-670b-4f99-aa6b-e5cb6f029327.ico +0 -0
  63. package/oss/a6f63612-b3d1-4aba-bf5f-0cd3055a7251.svg +1 -0
  64. package/oss/a85345e2-b625-4917-8c47-d85503226015.svg +12 -0
  65. package/oss/ab70067a-ed3f-4d8c-8776-cd1a7b67097d.svg +8 -0
  66. package/oss/abe3279f-b713-403f-b0d1-7efa24502c11.css +2251 -0
  67. package/oss/b10e7a02-f948-4c79-98a1-504ef025d37a.ttf +0 -0
  68. package/oss/b43dabdf-cf3d-4e74-aaec-46b451089b4b.svg +4 -0
  69. package/oss/b4e5962d-0b64-4667-89aa-bdbfc967f9d5.svg +12 -0
  70. package/oss/b7633fb4-4845-45b1-b516-b76bc0b31692.svg +10 -0
  71. package/oss/bd64bd8e-ad36-4b30-bc3f-047f0b5472af.eot +0 -0
  72. package/oss/be75e4b2-9d84-41a1-b2ad-941100c6eb9f.svg +1 -0
  73. package/oss/bf600662-21bc-427a-a3ff-c7148bfb7a37.css +516 -0
  74. package/oss/bktjgd.js +0 -0
  75. package/oss/bktjwb.js +0 -0
  76. package/oss/c1c43d05-3fe7-4f66-92c3-a4e673de15d2.css +126 -0
  77. package/oss/c40e78e1-28a9-403f-9bb6-6a61bb759f3c.svg +9 -0
  78. package/oss/c5e67efa-03ef-4285-9eb2-979d24b97b0a.js +505 -0
  79. package/oss/ca88122c-71f0-4bdb-801b-845c3e2416c0.js +57 -0
  80. package/oss/ce7d2a57-04d3-4320-95de-a1acb29c2299.svg +1 -0
  81. package/oss/cf261a0a-f683-4e12-92c1-98c42038da76.js +301 -0
  82. package/oss/d13ba061-af1c-420f-a700-4a8c175a6d90.js +51 -0
  83. package/oss/d820804f-af30-4364-b882-9d7b23e98353.js +1 -0
  84. package/oss/dae77962-f0f3-487f-bfff-1251e44b3d98.js +313 -0
  85. package/oss/db0b6693-9a13-4a89-9c67-82a5c2208ed9.svg +1 -0
  86. package/oss/dd3a7016-cf8c-493c-ba87-c7da470f9307.svg +1 -0
  87. package/oss/dd4c56f1-700e-49b8-a40f-530ed2e06934.svg +1 -0
  88. package/oss/de85749c-9ab2-4798-a080-1dafbd2bb89a.css +393 -0
  89. package/oss/dfd0db36-8259-4d6e-a426-7c1167c7657d.svg +18 -0
  90. package/oss/e082736c-726c-4029-b3ce-6c89d83ad9ce.css +3177 -0
  91. package/oss/e0efdb0b-2cf8-41fe-b862-7560a8d957e3.js +193 -0
  92. package/oss/e1d3a1a8-c200-47de-bba9-b92aa112010b.svg +1 -0
  93. package/oss/e937b5e0-2285-474e-84e7-5c478f305280.js +775 -0
  94. package/oss/ed850ceb-a7a3-47f4-9d2e-d6fd2666a8c9.js +936 -0
  95. package/oss/ee0c80ad-d7cb-464f-aa4a-a7f439d76ae8.js +665 -0
  96. package/oss/ef62fbf5-a876-4112-8062-c97b5341f1b9.css +653 -0
  97. package/oss/f343adb3-110f-445e-80b4-abca81ff558a.js +787 -0
  98. package/oss/f4d90992-79bf-4a51-a2d7-7d556fac63d3.js +1 -0
  99. package/oss/f59f0ec0-974b-496d-a518-dfb79e0ecec0.js +51 -0
  100. package/oss/f68472c9-1d02-451a-be1f-6d5f0fa2c6fd.css +145 -0
  101. package/oss/f7b46b4d-6311-4416-95b0-e18ad577c166.css +1 -0
  102. package/oss/home.css +459 -0
  103. package/oss/mjandjlbgd.js +0 -0
  104. package/oss/mjandjlbwb.js +0 -0
  105. package/package.json +17 -0
@@ -0,0 +1,2909 @@
1
+ ! function(e, t) {
2
+ "object" == typeof exports && "object" == typeof module ? module.exports = t() : "function" == typeof define && define
3
+ .amd ? define("yzmplayer", [], t) : "object" == typeof exports ? exports.yzmplayer = t() : e.yzmplayer = t()
4
+ }("undefined" != typeof self ? self : this, function() {
5
+ return function(e) {
6
+ function t(i) {
7
+ if (n[i]) return n[i].exports;
8
+ var a = n[i] = {
9
+ i: i,
10
+ l: !1,
11
+ exports: {}
12
+ };
13
+ return e[i].call(a.exports, a, a.exports, t), a.l = !0, a.exports
14
+ }
15
+ var n = {};
16
+ return t.m = e, t.c = n, t.d = function(e, n, i) {
17
+ t.o(e, n) || Object.defineProperty(e, n, {
18
+ configurable: !1,
19
+ enumerable: !0,
20
+ get: i
21
+ })
22
+ }, t.n = function(e) {
23
+ var n = e && e.__esModule ? function() {
24
+ return e.default
25
+ } : function() {
26
+ return e
27
+ };
28
+ return t.d(n, "a", n), n
29
+ }, t.o = function(e, t) {
30
+ return Object.prototype.hasOwnProperty.call(e, t)
31
+ }, t.p = "/", t(t.s = 5)
32
+ }([
33
+ function(e, t, n) {
34
+ "use strict";
35
+ Object.defineProperty(t, "__esModule", {
36
+ value: !0
37
+ });
38
+ var i = /mobile/i.test(window.navigator.userAgent),
39
+ a = {
40
+ secondToTime: function(e) {
41
+ var t = function(e) {
42
+ return e < 10 ? "0" + e : "" + e
43
+ },
44
+ n = Math.floor(e / 3600),
45
+ i = Math.floor((e - 3600 * n) / 60),
46
+ a = Math.floor(e - 3600 * n - 60 * i);
47
+ return (n > 0 ? [n, i, a] : [i, a]).map(t).join(":")
48
+ },
49
+ getElementViewLeft: function(e) {
50
+ var t = e.offsetLeft,
51
+ n = e.offsetParent,
52
+ i = document.body.scrollLeft + document.documentElement.scrollLeft;
53
+ if (document.fullscreenElement || document.mozFullScreenElement || document.webkitFullscreenElement)
54
+ for (; null !== n && n !== e;) t += n.offsetLeft, n = n.offsetParent;
55
+ else
56
+ for (; null !== n;) t += n.offsetLeft, n = n.offsetParent;
57
+ return t - i
58
+ },
59
+ getScrollPosition: function() {
60
+ return {
61
+ left: window.pageXOffset || document.documentElement.scrollLeft || document.body.scrollLeft || 0,
62
+ top: window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop || 0
63
+ }
64
+ },
65
+ setScrollPosition: function(e) {
66
+ var t = e.left,
67
+ n = void 0 === t ? 0 : t,
68
+ i = e.top,
69
+ a = void 0 === i ? 0 : i;
70
+ this.isFirefox ? (document.documentElement.scrollLeft = n, document.documentElement.scrollTop = a) : window.scrollTo(
71
+ n, a)
72
+ },
73
+ isMobile: i,
74
+ isFirefox: /firefox/i.test(window.navigator.userAgent),
75
+ isChrome: /chrome/i.test(window.navigator.userAgent),
76
+ storage: {
77
+ set: function(e, t) {
78
+ localStorage.setItem(e, t)
79
+ },
80
+ get: function(e) {
81
+ return localStorage.getItem(e)
82
+ }
83
+ },
84
+ cumulativeOffset: function(e) {
85
+ var t = 0,
86
+ n = 0;
87
+ do {
88
+ t += e.offsetTop || 0, n += e.offsetLeft || 0, e = e.offsetParent
89
+ } while (e);
90
+ return {
91
+ top: t,
92
+ left: n
93
+ }
94
+ },
95
+ nameMap: {
96
+ dragStart: i ? "touchstart" : "mousedown",
97
+ dragMove: i ? "touchmove" : "mousemove",
98
+ dragEnd: i ? "touchend" : "mouseup"
99
+ }
100
+ };
101
+ t.default = a
102
+ },
103
+ function(e, t, n) {
104
+ "use strict";
105
+ var i, a = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
106
+ return typeof e
107
+ } : function(e) {
108
+ return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" :
109
+ typeof e
110
+ };
111
+ i = function() {
112
+ return this
113
+ }();
114
+ try {
115
+ i = i || Function("return this")() || (0, eval)("this")
116
+ } catch (e) {
117
+ "object" === ("undefined" == typeof window ? "undefined" : a(window)) && (i = window)
118
+ }
119
+ e.exports = i
120
+ },
121
+ function(e, t, n) {
122
+ "use strict";
123
+
124
+ function i(e) {
125
+ return e && e.__esModule ? e : {
126
+ default: e
127
+ }
128
+ }
129
+ Object.defineProperty(t, "__esModule", {
130
+ value: !0
131
+ });
132
+ var a = n(16),
133
+ o = i(a),
134
+ s = n(17),
135
+ r = i(s),
136
+ l = n(18),
137
+ c = i(l),
138
+ u = n(19),
139
+ d = i(u),
140
+ p = n(20),
141
+ h = i(p),
142
+ y = n(21),
143
+ m = i(y),
144
+ f = n(22),
145
+ v = i(f),
146
+ g = n(23),
147
+ b = i(g),
148
+ k = n(24),
149
+ w = i(k),
150
+ x = n(25),
151
+ S = i(x),
152
+ T = n(26),
153
+ L = i(T),
154
+ M = n(27),
155
+ _ = i(M),
156
+ q = n(28),
157
+ E = i(q),
158
+ B = n(29),
159
+ P = i(B),
160
+ C = n(30),
161
+ O = i(C),
162
+ z = n(31),
163
+ F = i(z),
164
+ I = {
165
+ play: o.default,
166
+ pause: r.default,
167
+ volumeUp: c.default,
168
+ volumeDown: d.default,
169
+ volumeOff: h.default,
170
+ full: m.default,
171
+ fullWeb: v.default,
172
+ setting: b.default,
173
+ right: w.default,
174
+ comment: S.default,
175
+ commentOff: L.default,
176
+ send: _.default,
177
+ pallette: E.default,
178
+ camera: P.default,
179
+ subtitle: O.default,
180
+ loading: F.default
181
+ };
182
+ t.default = I
183
+ },
184
+ function(e, t, n) {
185
+ "use strict";
186
+ e.exports = n(33)
187
+ },
188
+ function(e, t, n) {
189
+ var i = n(3);
190
+ e.exports = function(e) {
191
+ "use strict";
192
+ e = e || {};
193
+ var t = "",
194
+ n = e.enableSubtitle,
195
+ a = e.subtitle,
196
+ o = e.current,
197
+ s = e.pic,
198
+ r = i.$escape,
199
+ l = e.screenshot,
200
+ c = e.preload,
201
+ u = e.url,
202
+ n = a && "webvtt" === a.type;
203
+ return t += '\n<video\n class="yzmplayer-video ', o && (t += "yzmplayer-video-current"), t +=
204
+ '"\n webkit-playsinline\n playsinline\n ', s && (t += 'poster="', t += r(s), t += '"'), t += "\n ",
205
+ (l || n) && (t += 'crossorigin="anonymous"'), t += "\n ", c && (t += 'preload="', t += r(c), t += '"'), t +=
206
+ "\n ", u && (t += 'src="', t += r(u), t += '"'), t += "\n >\n ", n && (t +=
207
+ '\n <track kind="metadata" default src="', t += r(a.url), t += '"></track>\n '), t += "\n</video>"
208
+ }
209
+ },
210
+ function(e, t, n) {
211
+ "use strict";
212
+ Object.defineProperty(t, "__esModule", {
213
+ value: !0
214
+ }), n(6);
215
+ var i = n(7),
216
+ a = function(e) {
217
+ return e && e.__esModule ? e : {
218
+ default: e
219
+ }
220
+ }(i);
221
+
222
+ console.log('%c页面加载完毕消耗了' + Math.round(performance.now() * 100) / 100 + 'ms',
223
+ 'background:#fff;color:#333;text-shadow:0 0 2px #eee,0 0 3px #eee,0 0 3px #eee,0 0 2px #eee,0 0 3px #eee;');
224
+ t.default = a.default
225
+ },
226
+ function(e, t) {},
227
+ function(e, t, n) {
228
+ "use strict";
229
+
230
+ function i(e) {
231
+ return e && e.__esModule ? e : {
232
+ default: e
233
+ }
234
+ }
235
+
236
+ function a(e, t) {
237
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
238
+ }
239
+ Object.defineProperty(t, "__esModule", {
240
+ value: !0
241
+ });
242
+ var o = function() {
243
+ function e(e, t) {
244
+ for (var n = 0; n < t.length; n++) {
245
+ var i = t[n];
246
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
247
+ e, i.key, i)
248
+ }
249
+ }
250
+ return function(t, n, i) {
251
+ return n && e(t.prototype, n), i && e(t, i), t
252
+ }
253
+ }(),
254
+ s = n(8),
255
+ r = i(s),
256
+ l = n(0),
257
+ c = i(l),
258
+ u = n(12),
259
+ d = i(u),
260
+ p = n(14),
261
+ h = i(p),
262
+ y = n(15),
263
+ m = i(y),
264
+ f = n(2),
265
+ v = i(f),
266
+ g = n(35),
267
+ b = i(g),
268
+ k = n(36),
269
+ w = i(k),
270
+ x = n(37),
271
+ S = i(x),
272
+ T = n(38),
273
+ L = i(T),
274
+ M = n(39),
275
+ _ = i(M),
276
+ q = n(40),
277
+ E = i(q),
278
+ B = n(41),
279
+ P = i(B),
280
+ C = n(42),
281
+ O = i(C),
282
+ z = n(43),
283
+ F = i(z),
284
+ I = n(45),
285
+ j = i(I),
286
+ D = n(46),
287
+ W = i(D),
288
+ H = n(47),
289
+ A = i(H),
290
+ V = n(48),
291
+ R = i(V),
292
+ X = n(49),
293
+ N = i(X),
294
+ U = n(4),
295
+ $ = i(U),
296
+ Q = 0,
297
+ J = [],
298
+ Y = function() {
299
+ function e(t) {
300
+ var n = this;
301
+ a(this, e), this.options = (0, d.default)(t), this.options.video.quality && (this.qualityIndex = this.options.video
302
+ .defaultQuality, this.quality = this.options.video.quality[this.options.video.defaultQuality]), this.tran =
303
+ new h.default(this.options.lang).tran, this.events = new w.default, this.user = new L.default(this), this.container =
304
+ this.options.container, this.container.classList.add("yzmplayer"), this.options.danmaku || this.container.classList
305
+ .add("yzmplayer-no-danmaku"), this.options.live && this.container.classList.add("yzmplayer-live"), c.default.isMobile &&
306
+ this.container.classList.add("yzmplayer-mobile"), this.arrow = this.container.offsetWidth <= 500, this.arrow &&
307
+ this.container.classList.add("yzmplayer-arrow"), this.template = new m.default({
308
+ container: this.container,
309
+ options: this.options,
310
+ index: Q,
311
+ tran: this.tran
312
+ }), this.video = this.template.video, this.bar = new E.default(this.template), this.bezel = new O.default(
313
+ this.template.bezel), this.fullScreen = new S.default(this), this.controller = new F.default(this), this.options
314
+ .danmaku && (this.danmaku = new b.default({
315
+ container: this.template.danmaku,
316
+ opacity: this.user.get("opacity"),
317
+ callback: function() {
318
+ setTimeout(function() {
319
+ n.template.danmakuLoading.style.display = "none", setTimeout(function() {
320
+ document.getElementById('link2-success').style.display = "block"
321
+ }, 1 * 1500), n.options.autoplay && n.play()
322
+ }, 0)
323
+ },
324
+ error: function(e) {
325
+ document.getElementById('link2-success').remove(), setTimeout(function() {
326
+ document.getElementById('link2-error').style.display = "block"
327
+ }, 1 * 1000), n.notice(e)
328
+ },
329
+ apiBackend: this.options.apiBackend,
330
+ borderColor: this.options.theme,
331
+ height: this.arrow ? 24 : 30,
332
+ time: function() {
333
+ return n.video.currentTime
334
+ },
335
+ unlimited: this.user.get("unlimited"),
336
+ api: {
337
+ id: this.options.danmaku.id,
338
+ address: this.options.danmaku.api,
339
+ token: this.options.danmaku.token,
340
+ maximum: this.options.danmaku.maximum,
341
+ addition: this.options.danmaku.addition,
342
+ user: this.options.danmaku.user
343
+ },
344
+ events: this.events
345
+ }), this.comment = new W.default(this)), this.setting = new j.default(this), document.addEventListener(
346
+ "click",
347
+ function() {
348
+ n.focus = !1
349
+ }, !0), this.container.addEventListener("click", function() {
350
+ n.focus = !0
351
+ }, !0), this.paused = !0, this.time = new P.default(this), this.hotkey = new A.default(this), this.contextmenu =
352
+ new R.default(this), this.initVideo(this.video, this.quality && this.quality.type || this.options.video.type),
353
+ this.infoPanel = new N.default(this), !this.danmaku && this.options.autoplay && this.play(), Q++, J.push(this)
354
+ }
355
+ return o(e, [{
356
+ key: "seek",
357
+ value: function(e) {
358
+ e = Math.max(e, 0), this.video.duration && (e = Math.min(e, this.video.duration)), this.video.currentTime <
359
+ e ? this.notice(this.tran("FF") + " " + (e - this.video.currentTime).toFixed(0) + " " + this.tran("s")) :
360
+ this.video.currentTime > e && this.notice(this.tran("REW") + " " + (this.video.currentTime - e).toFixed(
361
+ 0) + " " + this.tran("s")), this.video.currentTime = e, this.danmaku && this.danmaku.seek(), this.bar.set(
362
+ "played", e / this.video.duration, "width")
363
+ }
364
+ }, {
365
+ key: "play",
366
+ value: function() {
367
+ var e = this;
368
+ if (this.paused = !1, this.video.paused && this.bezel.switch(v.default.play), this.template.playButton.innerHTML =
369
+ v.default.pause, r.default.resolve(this.video.play()).catch(function() {
370
+ e.pause()
371
+ }).then(function() {}), this.time.enable("loading"), this.time.enable("progress"), this.container.classList
372
+ .remove("yzmplayer-paused"), this.container.classList.add("yzmplayer-playing"), this.danmaku && this.danmaku
373
+ .play(), this.options.mutex)
374
+ for (var t = 0; t < J.length; t++) this !== J[t] && J[t].pause()
375
+ }
376
+ }, {
377
+ key: "pause",
378
+ value: function() {
379
+ this.paused = !0, this.container.classList.remove("yzmplayer-loading"), this.video.paused || this.bezel.switch(
380
+ v.default.pause), this.ended = !1, this.template.playButton.innerHTML = v.default.play, this.video.pause(),
381
+ this.time.disable("loading"), this.time.disable("progress"), this.container.classList.remove(
382
+ "yzmplayer-playing"), this.container.classList.add("yzmplayer-paused"), this.danmaku && this.danmaku.pause()
383
+ }
384
+ }, {
385
+ key: "switchVolumeIcon",
386
+ value: function() {
387
+ this.volume() >= .95 ? this.template.volumeIcon.innerHTML = v.default.volumeUp : this.volume() > 0 ? this
388
+ .template.volumeIcon.innerHTML = v.default.volumeDown : this.template.volumeIcon.innerHTML = v.default.volumeOff
389
+ }
390
+ }, {
391
+ key: "volume",
392
+ value: function(e, t, n) {
393
+ if (e = parseFloat(e), !isNaN(e)) {
394
+ e = Math.max(e, 0), e = Math.min(e, 1), this.bar.set("volume", e, "width");
395
+ var i = (100 * e).toFixed(0) + "%";
396
+ this.template.volumeBarWrapWrap.dataset.balloon = i, t || this.user.set("volume", e), n || this.notice(
397
+ this.tran("Volume") + " " + (100 * e).toFixed(0) + "%"), this.video.volume = e, this.video.muted && (
398
+ this.video.muted = !1), this.switchVolumeIcon()
399
+ }
400
+ return this.video.volume
401
+ }
402
+ }, {
403
+ key: "toggle",
404
+ value: function() {
405
+ this.video.paused ? this.play() : this.pause()
406
+ }
407
+ }, {
408
+ key: "on",
409
+ value: function(e, t) {
410
+ this.events.on(e, t)
411
+ }
412
+ }, {
413
+ key: "switchVideo",
414
+ value: function(e, t) {
415
+ this.pause(), this.video.poster = e.pic ? e.pic : "", this.video.src = e.url, this.initMSE(this.video, e.type ||
416
+ "auto"), t && (this.template.danmakuLoading.style.display = "block", this.bar.set("played", 0, "width"),
417
+ this.bar.set("loaded", 0, "width"), this.template.ptime.innerHTML = "00:00", this.template.danmaku.innerHTML =
418
+ "", this.danmaku && this.danmaku.reload({
419
+ id: t.id,
420
+ address: t.api,
421
+ token: t.token,
422
+ maximum: t.maximum,
423
+ addition: t.addition,
424
+ user: t.user
425
+ }))
426
+ }
427
+ }, {
428
+ key: "initMSE",
429
+ value: function(e, t) {
430
+ var n = this;
431
+ if (this.type = t, this.options.video.customType && this.options.video.customType[t]) "[object Function]" ===
432
+ Object.prototype.toString.call(this.options.video.customType[t]) ? this.options.video.customType[t](this
433
+ .video, this) : console.error("Illegal customType: " + t);
434
+ else switch ("auto" === this.type && (/m3u8(#|\?|$)/i.exec(e.src) ? this.type = "hls" : /.flv(#|\?|$)/i.exec(
435
+ e.src) ? this.type = "flv" : /.mpd(#|\?|$)/i.exec(e.src) ? this.type = "dash" : this.type = "normal"),
436
+ this.type) {
437
+ case "hls":
438
+ if (Hls)
439
+ if (Hls.isSupported()) {
440
+ var i = new Hls;
441
+ i.loadSource(e.src), i.attachMedia(e)
442
+ } else this.notice("");
443
+ else this.notice("");
444
+ break;
445
+ case "flv":
446
+ if (flvjs && flvjs.isSupported())
447
+ if (flvjs.isSupported()) {
448
+ var a = flvjs.createPlayer({
449
+ type: "flv",
450
+ url: e.src
451
+ });
452
+ a.attachMediaElement(e), a.load()
453
+ } else this.notice("Error: flvjs is not supported.");
454
+ else this.notice("Error: Can't find flvjs.");
455
+ break;
456
+ case "dash":
457
+ dashjs ? dashjs.MediaPlayer().create().initialize(e, e.src, !1) : this.notice(
458
+ "Error: Can't find dashjs.");
459
+ break;
460
+ case "webtorrent":
461
+ if (WebTorrent)
462
+ if (WebTorrent.WEBRTC_SUPPORT) {
463
+ this.container.classList.add("yzmplayer-loading");
464
+ var o = new WebTorrent,
465
+ s = e.src;
466
+ o.add(s, function(e) {
467
+ e.files.find(function(e) {
468
+ return e.name.endsWith(".mp4")
469
+ }).renderTo(n.video, {
470
+ autoplay: n.options.autoplay
471
+ }, function() {
472
+ n.container.classList.remove("yzmplayer-loading")
473
+ })
474
+ })
475
+ } else this.notice("Error: Webtorrent is not supported.");
476
+ else this.notice("Error: Can't find Webtorrent.")
477
+ }
478
+ }
479
+ }, {
480
+ key: "initVideo",
481
+ value: function(e, t) {
482
+ var n = this;
483
+ this.initMSE(e, t), this.on("durationchange", function() {
484
+ 1 !== e.duration && (n.template.dtime.innerHTML = c.default.secondToTime(e.duration))
485
+ }), this.on("progress", function() {
486
+ var t = e.buffered.length ? e.buffered.end(e.buffered.length - 1) / e.duration : 0;
487
+ n.bar.set("loaded", t, "width")
488
+ }), this.on("error", function() {
489
+ setTimeout(function() {
490
+ document.getElementById('link3-error').style.display = "block"
491
+ }, 5 * 1000), n.tran && n.notice && (n.type, n.notice(n.tran("This video fails to load"), -1))
492
+ }), this.ended = !1, this.on("ended", function() {
493
+ n.bar.set("played", 1, "width"), n.setting.loop ? (n.seek(0), e.play()) : (n.ended = !0, n.pause()), n
494
+ .danmaku && (n.danmaku.danIndex = 0)
495
+ }), this.on("play", function() {
496
+ n.paused && n.play()
497
+ }), this.on("pause", function() {
498
+ n.paused || n.pause()
499
+ });
500
+ for (var i = 0; i < this.events.videoEvents.length; i++) ! function(t) {
501
+ e.addEventListener(n.events.videoEvents[t], function() {
502
+ n.events.trigger(n.events.videoEvents[t])
503
+ })
504
+ }(i);
505
+ this.volume(this.user.get("volume"), !0, !0), this.options.subtitle && (this.subtitle = new _.default(
506
+ this.template.subtitle, this.video, this.options.subtitle, this.events), this.user.get("subtitle") ||
507
+ this.subtitle.hide())
508
+ }
509
+ }, {
510
+ key: "switchQuality",
511
+ value: function(e) {
512
+ var t = this;
513
+ if (this.qualityIndex !== e && !this.switchingQuality) {
514
+ this.qualityIndex = e, this.switchingQuality = !0, this.quality = this.options.video.quality[e], this.template
515
+ .qualityButton.innerHTML = this.quality.name;
516
+ var n = this.video.paused;
517
+ this.video.pause();
518
+ var i = (0, $.default)({
519
+ current: !1,
520
+ pic: null,
521
+ screenshot: this.options.screenshot,
522
+ preload: "auto",
523
+ url: this.quality.url,
524
+ subtitle: this.options.subtitle
525
+ }),
526
+ a = (new DOMParser).parseFromString(i, "text/html").body.firstChild;
527
+ this.template.videoWrap.insertBefore(a, this.template.videoWrap.getElementsByTagName("div")[0]), this.prevVideo =
528
+ this.video, this.video = a, this.initVideo(this.video, this.quality.type || this.options.video.type),
529
+ this.seek(this.prevVideo.currentTime), this.notice(this.tran("Switching to") + " " + this.quality.name +
530
+ " " + this.tran("quality"), -1), this.events.trigger("quality_start", this.quality), this.on("canplay",
531
+ function() {
532
+ if (t.prevVideo) {
533
+ if (t.video.currentTime !== t.prevVideo.currentTime) return void t.seek(t.prevVideo.currentTime);
534
+ t.template.videoWrap.removeChild(t.prevVideo), t.video.classList.add("yzmplayer-video-current"), n ||
535
+ t.video.play(), t.prevVideo = null, t.notice(t.tran("Switched to") + " " + t.quality.name + " " + t
536
+ .tran("quality")), t.switchingQuality = !1, t.events.trigger("quality_end")
537
+ }
538
+ })
539
+ }
540
+ }
541
+ }, {
542
+ key: "notice",
543
+ value: function(e) {
544
+ var t = this,
545
+ n = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : 2e3,
546
+ i = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : .8;
547
+ this.template.notice.innerHTML = e, this.template.notice.style.opacity = i, this.noticeTime &&
548
+ clearTimeout(this.noticeTime), this.events.trigger("notice_show", e), this.noticeTime = setTimeout(
549
+ function() {
550
+ t.template.notice.style.opacity = 0, t.events.trigger("notice_hide")
551
+ }, n)
552
+ }
553
+ }, {
554
+ key: "resize",
555
+ value: function() {
556
+ this.danmaku && this.danmaku.resize(), this.events.trigger("resize")
557
+ }
558
+ }, {
559
+ key: "speed",
560
+ value: function(e) {
561
+ this.video.playbackRate = e
562
+ }
563
+ }, {
564
+ key: "destroy",
565
+ value: function() {
566
+ J.splice(J.indexOf(this), 1), this.pause(), this.controller.destroy(), this.time.destroy(), this.video.src =
567
+ "", this.container.innerHTML = "", this.events.trigger("destroy");
568
+ for (var e in this) this.hasOwnProperty(e) && "paused" !== e && delete this[e]
569
+ }
570
+ }]), e
571
+ }();
572
+ t.default = Y
573
+ },
574
+ function(e, t, n) {
575
+ "use strict";
576
+ (function(t) {
577
+ function n() {}
578
+
579
+ function i(e, t) {
580
+ return function() {
581
+ e.apply(t, arguments)
582
+ }
583
+ }
584
+
585
+ function a(e) {
586
+ if (!(this instanceof a)) throw new TypeError("Promises must be constructed via new");
587
+ if ("function" != typeof e) throw new TypeError("not a function");
588
+ this._state = 0, this._handled = !1, this._value = void 0, this._deferreds = [], u(e, this)
589
+ }
590
+
591
+ function o(e, t) {
592
+ for (; 3 === e._state;) e = e._value;
593
+ if (0 === e._state) return void e._deferreds.push(t);
594
+ e._handled = !0, a._immediateFn(function() {
595
+ var n = 1 === e._state ? t.onFulfilled : t.onRejected;
596
+ if (null === n) return void(1 === e._state ? s : r)(t.promise, e._value);
597
+ var i;
598
+ try {
599
+ i = n(e._value)
600
+ } catch (e) {
601
+ return void r(t.promise, e)
602
+ }
603
+ s(t.promise, i)
604
+ })
605
+ }
606
+
607
+ function s(e, t) {
608
+ try {
609
+ if (t === e) throw new TypeError("A promise cannot be resolved with itself.");
610
+ if (t && ("object" === (void 0 === t ? "undefined" : d(t)) || "function" == typeof t)) {
611
+ var n = t.then;
612
+ if (t instanceof a) return e._state = 3, e._value = t, void l(e);
613
+ if ("function" == typeof n) return void u(i(n, t), e)
614
+ }
615
+ e._state = 1, e._value = t, l(e)
616
+ } catch (t) {
617
+ r(e, t)
618
+ }
619
+ }
620
+
621
+ function r(e, t) {
622
+ e._state = 2, e._value = t, l(e)
623
+ }
624
+
625
+ function l(e) {
626
+ 2 === e._state && 0 === e._deferreds.length && a._immediateFn(function() {
627
+ e._handled || a._unhandledRejectionFn(e._value)
628
+ });
629
+ for (var t = 0, n = e._deferreds.length; t < n; t++) o(e, e._deferreds[t]);
630
+ e._deferreds = null
631
+ }
632
+
633
+ function c(e, t, n) {
634
+ this.onFulfilled = "function" == typeof e ? e : null, this.onRejected = "function" == typeof t ? t : null,
635
+ this.promise = n
636
+ }
637
+
638
+ function u(e, t) {
639
+ var n = !1;
640
+ try {
641
+ e(function(e) {
642
+ n || (n = !0, s(t, e))
643
+ }, function(e) {
644
+ n || (n = !0, r(t, e))
645
+ })
646
+ } catch (e) {
647
+ if (n) return;
648
+ n = !0, r(t, e)
649
+ }
650
+ }
651
+ var d = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
652
+ return typeof e
653
+ } : function(e) {
654
+ return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" :
655
+ typeof e
656
+ },
657
+ p = setTimeout;
658
+ a.prototype.catch = function(e) {
659
+ return this.then(null, e)
660
+ }, a.prototype.then = function(e, t) {
661
+ var i = new this.constructor(n);
662
+ return o(this, new c(e, t, i)), i
663
+ }, a.all = function(e) {
664
+ return new a(function(t, n) {
665
+ function i(e, s) {
666
+ try {
667
+ if (s && ("object" === (void 0 === s ? "undefined" : d(s)) || "function" == typeof s)) {
668
+ var r = s.then;
669
+ if ("function" == typeof r) return void r.call(s, function(t) {
670
+ i(e, t)
671
+ }, n)
672
+ }
673
+ a[e] = s, 0 == --o && t(a)
674
+ } catch (e) {
675
+ n(e)
676
+ }
677
+ }
678
+ if (!e || void 0 === e.length) throw new TypeError("Promise.all accepts an array");
679
+ var a = Array.prototype.slice.call(e);
680
+ if (0 === a.length) return t([]);
681
+ for (var o = a.length, s = 0; s < a.length; s++) i(s, a[s])
682
+ })
683
+ }, a.resolve = function(e) {
684
+ return e && "object" === (void 0 === e ? "undefined" : d(e)) && e.constructor === a ? e : new a(function(t) {
685
+ t(e)
686
+ })
687
+ }, a.reject = function(e) {
688
+ return new a(function(t, n) {
689
+ n(e)
690
+ })
691
+ }, a.race = function(e) {
692
+ return new a(function(t, n) {
693
+ for (var i = 0, a = e.length; i < a; i++) e[i].then(t, n)
694
+ })
695
+ }, a._immediateFn = "function" == typeof t && function(e) {
696
+ t(e)
697
+ } || function(e) {
698
+ p(e, 0)
699
+ }, a._unhandledRejectionFn = function(e) {
700
+ "undefined" != typeof console && console && console.warn("Possible Unhandled Promise Rejection:", e)
701
+ }, e.exports = a
702
+ }).call(t, n(9).setImmediate)
703
+ },
704
+ function(e, t, n) {
705
+ "use strict";
706
+
707
+ function i(e, t) {
708
+ this._id = e, this._clearFn = t
709
+ }
710
+ var a = Function.prototype.apply;
711
+ t.setTimeout = function() {
712
+ return new i(a.call(setTimeout, window, arguments), clearTimeout)
713
+ }, t.setInterval = function() {
714
+ return new i(a.call(setInterval, window, arguments), clearInterval)
715
+ }, t.clearTimeout = t.clearInterval = function(e) {
716
+ e && e.close()
717
+ }, i.prototype.unref = i.prototype.ref = function() {}, i.prototype.close = function() {
718
+ this._clearFn.call(window, this._id)
719
+ }, t.enroll = function(e, t) {
720
+ clearTimeout(e._idleTimeoutId), e._idleTimeout = t
721
+ }, t.unenroll = function(e) {
722
+ clearTimeout(e._idleTimeoutId), e._idleTimeout = -1
723
+ }, t._unrefActive = t.active = function(e) {
724
+ clearTimeout(e._idleTimeoutId);
725
+ var t = e._idleTimeout;
726
+ t >= 0 && (e._idleTimeoutId = setTimeout(function() {
727
+ e._onTimeout && e._onTimeout()
728
+ }, t))
729
+ }, n(10), t.setImmediate = setImmediate, t.clearImmediate = clearImmediate
730
+ },
731
+ function(e, t, n) {
732
+ "use strict";
733
+ (function(e, t) {
734
+ ! function(e, n) {
735
+ function i(e) {
736
+ "function" != typeof e && (e = new Function("" + e));
737
+ for (var t = new Array(arguments.length - 1), n = 0; n < t.length; n++) t[n] = arguments[n + 1];
738
+ var i = {
739
+ callback: e,
740
+ args: t
741
+ };
742
+ return c[l] = i, r(l), l++
743
+ }
744
+
745
+ function a(e) {
746
+ delete c[e]
747
+ }
748
+
749
+ function o(e) {
750
+ var t = e.callback,
751
+ i = e.args;
752
+ switch (i.length) {
753
+ case 0:
754
+ t();
755
+ break;
756
+ case 1:
757
+ t(i[0]);
758
+ break;
759
+ case 2:
760
+ t(i[0], i[1]);
761
+ break;
762
+ case 3:
763
+ t(i[0], i[1], i[2]);
764
+ break;
765
+ default:
766
+ t.apply(n, i)
767
+ }
768
+ }
769
+
770
+ function s(e) {
771
+ if (u) setTimeout(s, 0, e);
772
+ else {
773
+ var t = c[e];
774
+ if (t) {
775
+ u = !0;
776
+ try {
777
+ o(t)
778
+ } finally {
779
+ a(e), u = !1
780
+ }
781
+ }
782
+ }
783
+ }
784
+ if (!e.setImmediate) {
785
+ var r, l = 1,
786
+ c = {},
787
+ u = !1,
788
+ d = e.document,
789
+ p = Object.getPrototypeOf && Object.getPrototypeOf(e);
790
+ p = p && p.setTimeout ? p : e, "[object process]" === {}.toString.call(e.process) ? function() {
791
+ r = function(e) {
792
+ t.nextTick(function() {
793
+ s(e)
794
+ })
795
+ }
796
+ }() : function() {
797
+ if (e.postMessage && !e.importScripts) {
798
+ var t = !0,
799
+ n = e.onmessage;
800
+ return e.onmessage = function() {
801
+ t = !1
802
+ }, e.postMessage("", "*"), e.onmessage = n, t
803
+ }
804
+ }() ? function() {
805
+ var t = "setImmediate$" + Math.random() + "$",
806
+ n = function(n) {
807
+ n.source === e && "string" == typeof n.data && 0 === n.data.indexOf(t) && s(+n.data.slice(t.length))
808
+ };
809
+ e.addEventListener ? e.addEventListener("message", n, !1) : e.attachEvent("onmessage", n), r = function(n) {
810
+ e.postMessage(t + n, "*")
811
+ }
812
+ }() : e.MessageChannel ? function() {
813
+ var e = new MessageChannel;
814
+ e.port1.onmessage = function(e) {
815
+ s(e.data)
816
+ }, r = function(t) {
817
+ e.port2.postMessage(t)
818
+ }
819
+ }() : d && "onreadystatechange" in d.createElement("script") ? function() {
820
+ var e = d.documentElement;
821
+ r = function(t) {
822
+ var n = d.createElement("script");
823
+ n.onreadystatechange = function() {
824
+ s(t), n.onreadystatechange = null, e.removeChild(n), n = null
825
+ }, e.appendChild(n)
826
+ }
827
+ }() : function() {
828
+ r = function(e) {
829
+ setTimeout(s, 0, e)
830
+ }
831
+ }(), p.setImmediate = i, p.clearImmediate = a
832
+ }
833
+ }("undefined" == typeof self ? void 0 === e ? void 0 : e : self)
834
+ }).call(t, n(1), n(11))
835
+ },
836
+ function(e, t, n) {
837
+ "use strict";
838
+
839
+ function i() {
840
+ throw new Error("setTimeout has not been defined")
841
+ }
842
+
843
+ function a() {
844
+ throw new Error("clearTimeout has not been defined")
845
+ }
846
+
847
+ function o(e) {
848
+ if (d === setTimeout) return setTimeout(e, 0);
849
+ if ((d === i || !d) && setTimeout) return d = setTimeout, setTimeout(e, 0);
850
+ try {
851
+ return d(e, 0)
852
+ } catch (t) {
853
+ try {
854
+ return d.call(null, e, 0)
855
+ } catch (t) {
856
+ return d.call(this, e, 0)
857
+ }
858
+ }
859
+ }
860
+
861
+ function s(e) {
862
+ if (p === clearTimeout) return clearTimeout(e);
863
+ if ((p === a || !p) && clearTimeout) return p = clearTimeout, clearTimeout(e);
864
+ try {
865
+ return p(e)
866
+ } catch (t) {
867
+ try {
868
+ return p.call(null, e)
869
+ } catch (t) {
870
+ return p.call(this, e)
871
+ }
872
+ }
873
+ }
874
+
875
+ function r() {
876
+ f && y && (f = !1, y.length ? m = y.concat(m) : v = -1, m.length && l())
877
+ }
878
+
879
+ function l() {
880
+ if (!f) {
881
+ var e = o(r);
882
+ f = !0;
883
+ for (var t = m.length; t;) {
884
+ for (y = m, m = []; ++v < t;) y && y[v].run();
885
+ v = -1, t = m.length
886
+ }
887
+ y = null, f = !1, s(e)
888
+ }
889
+ }
890
+
891
+ function c(e, t) {
892
+ this.fun = e, this.array = t
893
+ }
894
+
895
+ function u() {}
896
+ var d, p, h = e.exports = {};
897
+ ! function() {
898
+ try {
899
+ d = "function" == typeof setTimeout ? setTimeout : i
900
+ } catch (e) {
901
+ d = i
902
+ }
903
+ try {
904
+ p = "function" == typeof clearTimeout ? clearTimeout : a
905
+ } catch (e) {
906
+ p = a
907
+ }
908
+ }();
909
+ var y, m = [],
910
+ f = !1,
911
+ v = -1;
912
+ h.nextTick = function(e) {
913
+ var t = new Array(arguments.length - 1);
914
+ if (arguments.length > 1)
915
+ for (var n = 1; n < arguments.length; n++) t[n - 1] = arguments[n];
916
+ m.push(new c(e, t)), 1 !== m.length || f || o(l)
917
+ }, c.prototype.run = function() {
918
+ this.fun.apply(null, this.array)
919
+ }, h.title = "browser", h.browser = !0, h.env = {}, h.argv = [], h.version = "", h.versions = {}, h.on = u, h.addListener =
920
+ u, h.once = u, h.off = u, h.removeListener = u, h.removeAllListeners = u, h.emit = u, h.prependListener = u, h.prependOnceListener =
921
+ u, h.listeners = function(e) {
922
+ return []
923
+ }, h.binding = function(e) {
924
+ throw new Error("process.binding is not supported")
925
+ }, h.cwd = function() {
926
+ return "/"
927
+ }, h.chdir = function(e) {
928
+ throw new Error("process.chdir is not supported")
929
+ }, h.umask = function() {
930
+ return 0
931
+ }
932
+ },
933
+ function(e, t, n) {
934
+ "use strict";
935
+ Object.defineProperty(t, "__esModule", {
936
+ value: !0
937
+ });
938
+ var i = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
939
+ return typeof e
940
+ } : function(e) {
941
+ return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" :
942
+ typeof e
943
+ },
944
+ a = n(13),
945
+ o = function(e) {
946
+ return e && e.__esModule ? e : {
947
+ default: e
948
+ }
949
+ }(a);
950
+ t.default = function(e) {
951
+ var t = {
952
+ container: e.element || document.getElementsByClassName("yzmplayer")[0],
953
+ live: !1,
954
+ autoplay: !1,
955
+ theme: "#b7daff",
956
+ loop: !1,
957
+ lang: (navigator.language || navigator.browserLanguage).toLowerCase(),
958
+ screenshot: !1,
959
+ hotkey: !0,
960
+ preload: "auto",
961
+ volume: .7,
962
+ apiBackend: o.default,
963
+ video: {},
964
+ contextmenu: [],
965
+ mutex: !0
966
+ };
967
+ for (var n in t) t.hasOwnProperty(n) && !e.hasOwnProperty(n) && (e[n] = t[n]);
968
+ return e.video && !e.video.type && (e.video.type = "auto"), "object" === i(e.danmaku) && e.danmaku && !e.danmaku
969
+ .user && (e.danmaku.user = "DIYgod"), e.subtitle && (!e.subtitle.type && (e.subtitle.type = "webvtt"), !e.subtitle
970
+ .fontSize && (e.subtitle.fontSize = "20px"), !e.subtitle.bottom && (e.subtitle.bottom = "40px"), !e.subtitle.color &&
971
+ (e.subtitle.color = "#fff")), e.video.quality && (e.video.url = [e.video.quality[e.video.defaultQuality].url]),
972
+ e.lang && (e.lang = e.lang.toLowerCase()), e.contextmenu = e.contextmenu.concat(), e
973
+ }
974
+ },
975
+ function(e, t, n) {
976
+ "use strict";
977
+ Object.defineProperty(t, "__esModule", {
978
+ value: !0
979
+ });
980
+ var i = function(e, t, n, i, a) {
981
+ var o = new XMLHttpRequest;
982
+ o.onreadystatechange = function() {
983
+ if (4 === o.readyState) {
984
+ if (o.status >= 200 && o.status < 300 || 304 === o.status) {
985
+ var e = JSON.parse(o.responseText);
986
+ return 23 !== e.code ? i(o, e) : n(o, e)
987
+ }
988
+ a(o)
989
+ }
990
+ }, o.open(null !== t ? "POST" : "GET", e, !0), o.send(null !== t ? JSON.stringify(t) : null)
991
+ };
992
+ t.default = {
993
+ send: function(e, t, n) {
994
+ i(e, t, function(e, t) {
995
+ console.log("发送弹幕成功"), n && n()
996
+ }, function(e, t) {
997
+ alert(t.msg)
998
+ }, function(e) {
999
+ console.log("Request was unsuccessful: " + e.status)
1000
+ })
1001
+ },
1002
+ read: function(e, t) {
1003
+ i(e, null, function(e, n) {
1004
+ t(null, n.danmuku)
1005
+ }, function(e, n) {
1006
+ t({
1007
+ status: e.status,
1008
+ response: n
1009
+ })
1010
+ }, function(e) {
1011
+ t({
1012
+ status: e.status,
1013
+ response: null
1014
+ })
1015
+ })
1016
+ }
1017
+ }
1018
+ },
1019
+ function(e, t, n) {
1020
+ "use strict";
1021
+
1022
+ function i(e) {
1023
+ var t = this;
1024
+ this.lang = e, this.tran = function(e) {
1025
+ return a[t.lang] && a[t.lang][e] ? a[t.lang][e] : e
1026
+ }
1027
+ }
1028
+ Object.defineProperty(t, "__esModule", {
1029
+ value: !0
1030
+ });
1031
+ var a = {
1032
+ "zh-cn": {
1033
+ "Danmaku is loading": "弹幕加载中",
1034
+ Top: "顶部",
1035
+ Bottom: "底部",
1036
+ Rolling: "滚动",
1037
+ "Input danmaku, hit Enter": "发个弹幕见证当下",
1038
+ "About author": "关于作者",
1039
+ "yzmplayer feedback": "播放器意见反馈",
1040
+ "About yzmplayer": "关于 yzmplayer 播放器",
1041
+ Loop: "洗脑循环",
1042
+ Speed: "速度",
1043
+ "Opacity for danmaku": "弹幕透明度",
1044
+ Normal: "正常",
1045
+ "Please input danmaku content!": "要输入弹幕内容啊喂!",
1046
+ "Set danmaku color": "弹幕颜色",
1047
+ "Set danmaku type": "弹幕模式",
1048
+ "Show danmaku": "显示弹幕",
1049
+ "This video fails to load": "视频加载失败",
1050
+ "Switching to": "正在切换至",
1051
+ "Switched to": "已经切换至",
1052
+ quality: "画质",
1053
+ FF: "快进",
1054
+ REW: "快退",
1055
+ "Unlimited danmaku": "海量弹幕",
1056
+ "Send danmaku": "发送弹幕",
1057
+ Setting: "设置",
1058
+ "Full screen": "全屏",
1059
+ "Web full screen": "页面全屏",
1060
+ Send: "发送",
1061
+ Screenshot: "截图",
1062
+ s: "秒",
1063
+ "Show subtitle": "显示字幕",
1064
+ "Hide subtitle": "隐藏字幕",
1065
+ Volume: "音量",
1066
+ Live: "直播",
1067
+ "Video info": "视频统计信息"
1068
+ },
1069
+ "zh-tw": {
1070
+ "Danmaku is loading": "彈幕加載中",
1071
+ Top: "頂部",
1072
+ Bottom: "底部",
1073
+ Rolling: "滾動",
1074
+ "Input danmaku, hit Enter": "輸入彈幕,Enter 發送",
1075
+ "About author": "關於作者",
1076
+ "yzmplayer feedback": "播放器意見反饋",
1077
+ "About yzmplayer": "關於 yzmplayer 播放器",
1078
+ Loop: "循環播放",
1079
+ Speed: "速度",
1080
+ "Opacity for danmaku": "彈幕透明度",
1081
+ Normal: "正常",
1082
+ "Please input danmaku content!": "請輸入彈幕内容啊!",
1083
+ "Set danmaku color": "設置彈幕顏色",
1084
+ "Set danmaku type": "設置彈幕類型",
1085
+ "Show danmaku": "顯示彈幕",
1086
+ "This video fails to load": "視頻加載失敗",
1087
+ "Switching to": "正在切換至",
1088
+ "Switched to": "已經切換至",
1089
+ quality: "畫質",
1090
+ FF: "快進",
1091
+ REW: "快退",
1092
+ "Unlimited danmaku": "海量彈幕",
1093
+ "Send danmaku": "發送彈幕",
1094
+ Setting: "設置",
1095
+ "Full screen": "全屏",
1096
+ "Web full screen": "頁面全屏",
1097
+ Send: "發送",
1098
+ Screenshot: "截圖",
1099
+ s: "秒",
1100
+ "Show subtitle": "顯示字幕",
1101
+ "Hide subtitle": "隱藏字幕",
1102
+ Volume: "音量",
1103
+ Live: "直播",
1104
+ "Video info": "視頻統計信息"
1105
+ }
1106
+ };
1107
+ t.default = i
1108
+ },
1109
+ function(e, t, n) {
1110
+ "use strict";
1111
+
1112
+ function i(e) {
1113
+ return e && e.__esModule ? e : {
1114
+ default: e
1115
+ }
1116
+ }
1117
+
1118
+ function a(e, t) {
1119
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
1120
+ }
1121
+ Object.defineProperty(t, "__esModule", {
1122
+ value: !0
1123
+ });
1124
+ var o = function() {
1125
+ function e(e, t) {
1126
+ for (var n = 0; n < t.length; n++) {
1127
+ var i = t[n];
1128
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
1129
+ e, i.key, i)
1130
+ }
1131
+ }
1132
+ return function(t, n, i) {
1133
+ return n && e(t.prototype, n), i && e(t, i), t
1134
+ }
1135
+ }(),
1136
+ s = n(2),
1137
+ r = i(s),
1138
+ l = n(32),
1139
+ c = i(l),
1140
+ u = function() {
1141
+ function e(t) {
1142
+ a(this, e), this.container = t.container, this.options = t.options, this.index = t.index, this.tran = t.tran,
1143
+ this.init()
1144
+ }
1145
+ return o(e, [{
1146
+ key: "init",
1147
+ value: function() {
1148
+ this.container.innerHTML = (0, c.default)({
1149
+ options: this.options,
1150
+ index: this.index,
1151
+ tran: this.tran,
1152
+ icons: r.default,
1153
+ video: {
1154
+ current: !0,
1155
+ pic: this.options.video.pic,
1156
+ screenshot: this.options.screenshot,
1157
+ preload: this.options.preload,
1158
+ url: this.options.video.url,
1159
+ subtitle: this.options.subtitle
1160
+ }
1161
+ }), this.volumeBar = this.container.querySelector(".yzmplayer-volume-bar-inner"), this.volumeBarWrap =
1162
+ this.container.querySelector(".yzmplayer-volume-bar"), this.volumeBarWrapWrap = this.container.querySelector(
1163
+ ".yzmplayer-volume-bar-wrap"), this.volumeButton = this.container.querySelector(".yzmplayer-volume"),
1164
+ this.volumeIcon = this.container.querySelector(".yzmplayer-volume-icon .yzmplayer-icon-content"), this.playedBar =
1165
+ this.container.querySelector(".yzmplayer-played"), this.loadedBar = this.container.querySelector(
1166
+ ".yzmplayer-loaded"), this.playedBarWrap = this.container.querySelector(".yzmplayer-bar-wrap"), this.playedBarTime =
1167
+ this.container.querySelector(".yzmplayer-bar-time"), this.danmaku = this.container.querySelector(
1168
+ ".yzmplayer-danmaku"), this.danmakuLoading = this.container.querySelector(".yzmplayer-danloading"),
1169
+ this.video = this.container.querySelector(".yzmplayer-video-current"), this.bezel = this.container.querySelector(
1170
+ ".yzmplayer-bezel-icon"), this.playButton = this.container.querySelector(".yzmplayer-play-icon"), this.videoWrap =
1171
+ this.container.querySelector(".yzmplayer-video-wrap"), this.controllerMask = this.container.querySelector(
1172
+ ".yzmplayer-controller-mask"), this.ptime = this.container.querySelector(".yzmplayer-ptime"), this.settingButton =
1173
+ this.container.querySelector(".yzmplayer-setting-icon"), this.settingBox = this.container.querySelector(
1174
+ ".yzmplayer-setting-box"), this.mask = this.container.querySelector(".yzmplayer-mask"), this.loop =
1175
+ this.container.querySelector(".yzmplayer-setting-loop"), this.loopToggle = this.container.querySelector(
1176
+ ".yzmplayer-setting-loop .yzmplayer-toggle-setting-input"), this.showDanmaku = this.container.querySelector(
1177
+ ".yzmplayer-setting-showdan"), this.showDanmakuToggle = this.container.querySelector(
1178
+ ".yzmplayer-showdan-setting-input"), this.unlimitDanmaku = this.container.querySelector(
1179
+ ".yzmplayer-setting-danunlimit"), this.unlimitDanmakuToggle = this.container.querySelector(
1180
+ ".yzmplayer-danunlimit-setting-input"), this.speed = this.container.querySelector(
1181
+ ".yzmplayer-setting-speed"), this.speedItem = this.container.querySelectorAll(
1182
+ ".yzmplayer-setting-speed-item"), this.danmakuOpacityBar = this.container.querySelector(
1183
+ ".yzmplayer-danmaku-bar-inner"), this.danmakuOpacityBarWrap = this.container.querySelector(
1184
+ ".yzmplayer-danmaku-bar"), this.danmakuOpacityBarWrapWrap = this.container.querySelector(
1185
+ ".yzmplayer-danmaku-bar-wrap"), this.danmakuOpacityBox = this.container.querySelector(
1186
+ ".yzmplayer-setting-danmaku"), this.dtime = this.container.querySelector(".yzmplayer-dtime"), this.controller =
1187
+ this.container.querySelector(".yzmplayer-controller"), this.commentInput = this.container.querySelector(
1188
+ ".yzmplayer-comment-input"), this.commentButton = this.container.querySelector(
1189
+ ".yzmplayer-comment-icon"), this.yzmcomment = this.container.querySelector(
1190
+ ".yzm-yzmplayer-comment-input"), this.commentSettingBox = this.container.querySelector(
1191
+ ".yzmplayer-comment-setting-box"), this.commentSettingButton = this.container.querySelector(
1192
+ ".yzmplayer-comment-setting-icon"), this.commentSettingFill = this.container.querySelector(
1193
+ ".yzmplayer-comment-setting-icon path"), this.commentSendButton = this.container.querySelector(
1194
+ ".yzmplayer-send-icon"), this.commentSendFill = this.container.querySelector(
1195
+ ".yzmplayer-send-icon path"), this.commentColorSettingBox = this.container.querySelector(
1196
+ ".yzmplayer-comment-setting-color"), this.browserFullButton = this.container.querySelector(
1197
+ ".yzmplayer-full-icon"), this.webFullButton = this.container.querySelector(".yzmplayer-full-in-icon"),
1198
+ this.menu = this.container.querySelector(".yzmplayer-menu"), this.menuItem = this.container.querySelectorAll(
1199
+ ".yzmplayer-menu-item"), this.qualityList = this.container.querySelector(".yzmplayer-quality-list"),
1200
+ this.camareButton = this.container.querySelector(".yzmplayer-camera-icon"), this.subtitleButton = this.container
1201
+ .querySelector(".yzmplayer-subtitle-icon"), this.subtitleButtonInner = this.container.querySelector(
1202
+ ".yzmplayer-subtitle-icon .yzmplayer-icon-content"), this.subtitle = this.container.querySelector(
1203
+ ".yzmplayer-subtitle"), this.qualityButton = this.container.querySelector(".yzmplayer-quality-icon"),
1204
+ this.barPreview = this.container.querySelector(".yzmplayer-bar-preview"), this.barWrap = this.container.querySelector(
1205
+ ".yzmplayer-bar-wrap"), this.notice = this.container.querySelector(".yzmplayer-notice"), this.infoPanel =
1206
+ this.container.querySelector(".yzmplayer-info-panel"), this.infoPanelClose = this.container.querySelector(
1207
+ ".yzmplayer-info-panel-close"), this.infoVersion = this.container.querySelector(
1208
+ ".yzmplayer-info-panel-item-version .yzmplayer-info-panel-item-data"), this.infoFPS = this.container.querySelector(
1209
+ ".yzmplayer-info-panel-item-fps .yzmplayer-info-panel-item-data"), this.infoType = this.container.querySelector(
1210
+ ".yzmplayer-info-panel-item-type .yzmplayer-info-panel-item-data"), this.infoUrl = this.container.querySelector(
1211
+ ".yzmplayer-info-panel-item-url .yzmplayer-info-panel-item-data"), this.infoResolution = this.container
1212
+ .querySelector(".yzmplayer-info-panel-item-resolution .yzmplayer-info-panel-item-data"), this.infoDuration =
1213
+ this.container.querySelector(".yzmplayer-info-panel-item-duration .yzmplayer-info-panel-item-data"),
1214
+ this.infoDanmakuId = this.container.querySelector(
1215
+ ".yzmplayer-info-panel-item-danmaku-id .yzmplayer-info-panel-item-data"), this.infoDanmakuApi = this.container
1216
+ .querySelector(".yzmplayer-info-panel-item-danmaku-api .yzmplayer-info-panel-item-data"), this.infoDanmakuAmount =
1217
+ this.container.querySelector(".yzmplayer-info-panel-item-danmaku-amount .yzmplayer-info-panel-item-data")
1218
+ }
1219
+ }]), e
1220
+ }();
1221
+ t.default = u
1222
+ },
1223
+ function(e, t) {
1224
+ e.exports =
1225
+ '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"><path d="M17.982 9.275L8.06 3.27A2.013 2.013 0 005 4.994v12.011a2.017 2.017 0 003.06 1.725l9.922-6.005a2.017 2.017 0 000-3.45z"></path></svg>'
1226
+ },
1227
+ function(e, t) {
1228
+ e.exports =
1229
+ '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"><path d="M7 3a2 2 0 00-2 2v12a2 2 0 104 0V5a2 2 0 00-2-2zM15 3a2 2 0 00-2 2v12a2 2 0 104 0V5a2 2 0 00-2-2z"></path></svg>'
1230
+ },
1231
+ function(e, t) {
1232
+ e.exports =
1233
+ '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"><path d="M10.188 4.65L6 8H5a2 2 0 00-2 2v2a2 2 0 002 2h1l4.188 3.35a.5.5 0 00.812-.39V5.04a.498.498 0 00-.812-.39zM14.446 3.778a1 1 0 00-.862 1.804 6.002 6.002 0 01-.007 10.838 1 1 0 00.86 1.806A8.001 8.001 0 0019 11a8.001 8.001 0 00-4.554-7.222z"></path><path d="M15 11a3.998 3.998 0 00-2-3.465v6.93A3.998 3.998 0 0015 11z"></path></svg>'
1234
+ },
1235
+ function(e, t) {
1236
+ e.exports =
1237
+ '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"><path d="M10.188 4.65L6 8H5a2 2 0 00-2 2v2a2 2 0 002 2h1l4.188 3.35a.5.5 0 00.812-.39V5.04a.498.498 0 00-.812-.39zM14.446 3.778a1 1 0 00-.862 1.804 6.002 6.002 0 01-.007 10.838 1 1 0 00.86 1.806A8.001 8.001 0 0019 11a8.001 8.001 0 00-4.554-7.222z"></path><path d="M15 11a3.998 3.998 0 00-2-3.465v6.93A3.998 3.998 0 0015 11z"></path></svg>'
1238
+ },
1239
+ function(e, t) {
1240
+ e.exports =
1241
+ '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"><path d="M15 11a3.998 3.998 0 00-2-3.465v2.636l1.865 1.865A4.02 4.02 0 0015 11z"></path><path d="M13.583 5.583A5.998 5.998 0 0117 11a6 6 0 01-.585 2.587l1.477 1.477a8.001 8.001 0 00-3.446-11.286 1 1 0 00-.863 1.805zM18.778 18.778l-2.121-2.121-1.414-1.414-1.415-1.415L13 13l-2-2-3.889-3.889-3.889-3.889a.999.999 0 10-1.414 1.414L5.172 8H5a2 2 0 00-2 2v2a2 2 0 002 2h1l4.188 3.35a.5.5 0 00.812-.39v-3.131l2.587 2.587-.01.005a1 1 0 00.86 1.806c.215-.102.424-.214.627-.333l2.3 2.3a1.001 1.001 0 001.414-1.416zM11 5.04a.5.5 0 00-.813-.39L8.682 5.854 11 8.172V5.04z"></path></svg>'
1242
+ },
1243
+ function(e, t) {
1244
+ e.exports =
1245
+ '<svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%" version="1.1" viewBox="0 0 1024 1024"><path class="yzmplayer-fill" style="fill:#ffffff" d="M172.76790012 458.3867064c-16.56714924 0-30.76756226-13.41150166-30.76756226-30.76756226V276.93697895C142.00033786 205.93491169 182.23484286 163.33367119 249.29235047 163.33367119h148.31542969c16.56714924 0 30.76756226 13.41150166 30.76756298 30.76756226s-13.41150166 30.76756226-30.76756298 30.76756228H250.08126254c-28.40082677 0-46.54579943 8.67803065-46.54580015 52.8570953v150.68216519c0 15.77823717-14.20041374 29.97865091-30.76756227 29.97865018z m597.99518975 441.79064149H622.44766018c-16.56714924 0-29.97865091-13.41150166-29.97865019-29.97865019s13.41150166-29.97865091 29.97865019-29.9786509h148.31542969c28.40082677 0 46.54579943-8.67803065 46.54580016-52.85709459V635.89187494c0-16.56714924 13.41150166-29.97865091 29.97865019-29.97865019s29.97865091 13.41150166 29.97865092 29.97865019v150.68216518c0.78891208 71.00206727-39.44559292 113.60330777-106.50310127 113.60330777z" id="yzmplayer-full"></path></svg>'
1246
+ },
1247
+ function(e, t) {
1248
+ e.exports =
1249
+ '<svg id="yemian"xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"><path d="M18 4H4a2 2 0 00-2 2v10a2 2 0 002 2h14a2 2 0 002-2V6a2 2 0 00-2-2zM8 15.5a.5.5 0 01-.5.5h-3a.5.5 0 01-.5-.5v-3a.5.5 0 01.5-.5h1a.5.5 0 01.5.5V14h1.5a.5.5 0 01.5.5v1zm0-8a.5.5 0 01-.5.5H6v1.5a.5.5 0 01-.5.5h-1a.5.5 0 01-.5-.5v-3a.5.5 0 01.5-.5h3a.5.5 0 01.5.5v1zm10 8a.5.5 0 01-.5.5h-3a.5.5 0 01-.5-.5v-1a.5.5 0 01.5-.5H16v-1.5a.5.5 0 01.5-.5h1a.5.5 0 01.5.5v3zm0-6a.5.5 0 01-.5.5h-1a.5.5 0 01-.5-.5V8h-1.5a.5.5 0 01-.5-.5v-1a.5.5 0 01.5-.5h3a.5.5 0 01.5.5v3z"></path></svg><svg id="tuichuuyemian" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"><path d="M18 4H4a2 2 0 00-2 2v10a2 2 0 002 2h14a2 2 0 002-2V6a2 2 0 00-2-2zM8 15.5a.5.5 0 01-.5.5h-1a.5.5 0 01-.5-.5V14H4.5a.5.5 0 01-.5-.5v-1a.5.5 0 01.5-.5h3a.5.5 0 01.5.5v3zm0-6a.5.5 0 01-.5.5h-3a.5.5 0 01-.5-.5v-1a.5.5 0 01.5-.5H6V6.5a.5.5 0 01.5-.5h1a.5.5 0 01.5.5v3zm10 4a.5.5 0 01-.5.5H16v1.5a.5.5 0 01-.5.5h-1a.5.5 0 01-.5-.5v-3a.5.5 0 01.5-.5h3a.5.5 0 01.5.5v1zm0-4a.5.5 0 01-.5.5h-3a.5.5 0 01-.5-.5v-3a.5.5 0 01.5-.5h1a.5.5 0 01.5.5V8h1.5a.5.5 0 01.5.5v1z"></path></svg>'
1250
+ },
1251
+ function(e, t) {
1252
+ e.exports =
1253
+ '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"><circle cx="11" cy="11" r="2"></circle><path d="M19.164 8.861L17.6 8.6a6.978 6.978 0 00-1.186-2.099l.574-1.533a1 1 0 00-.436-1.217l-1.997-1.153a1.001 1.001 0 00-1.272.23l-1.008 1.225a7.04 7.04 0 00-2.55.001L8.716 2.829a1 1 0 00-1.272-.23L5.447 3.751a1 1 0 00-.436 1.217l.574 1.533A6.997 6.997 0 004.4 8.6l-1.564.261A.999.999 0 002 9.847v2.306c0 .489.353.906.836.986l1.613.269a7 7 0 001.228 2.075l-.558 1.487a1 1 0 00.436 1.217l1.997 1.153c.423.244.961.147 1.272-.23l1.04-1.263a7.089 7.089 0 002.272 0l1.04 1.263a1 1 0 001.272.23l1.997-1.153a1 1 0 00.436-1.217l-.557-1.487c.521-.61.94-1.31 1.228-2.075l1.613-.269a.999.999 0 00.835-.986V9.847a.999.999 0 00-.836-.986zM11 15a4 4 0 110-8 4 4 0 010 8z"></path></svg>'
1254
+ },
1255
+ function(e, t) {
1256
+ e.exports =
1257
+ '<svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 32 32"><path d="M22 16l-10.105-10.6-1.895 1.987 8.211 8.613-8.211 8.612 1.895 1.988 8.211-8.613z"></path></svg>'
1258
+ },
1259
+ function(e, t) {
1260
+ e.exports =
1261
+ '<svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%" version="1.1" viewBox="0 0 1024 1024"><path class="yzmplayer-fill" style="fill:#ffffff" d="M634.307692 358.53846172H341.23076914c-24.23076943 0-45-19.61538487-45-45S315.84615401 269.69230742 341.23076914 269.69230742h293.07692285c24.23076943 0 43.84615342 19.61538487 43.84615429 45s-19.61538487 43.84615342-43.84615429 43.8461543z m-74.99999971 159.23076943c0-24.23076943-19.61538487-45-45-45H328.53846113c-24.23076943 0-45 19.61538487-45 45s19.61538487 45 45 45h186.92307773c24.23076943-1.15384658 43.84615342-20.76923057 43.84615343-45zM520.07692344 835.07692344c0-23.07692285-18.46153828-42.69230771-42.69230772-42.69230771H252.38461573c-54.23076914 0-96.92307685-47.30769229-96.92307686-106.15384688v-426.92307627c0-58.84615371 43.84615342-106.15384599 96.92307685-106.153846h630c54.23076914 0 96.92307685 47.30769229 96.92307686 106.153846v94.61538456c0 23.07692285 18.46153828 42.69230771 42.69230771 42.69230773s42.69230771-18.46153828 42.69230772-42.69230773v-94.61538456C1064.69230801 154.30769229 982.76923057 68.92307685 882.38461573 68.92307685H252.38461573C153.15384658 68.92307685 71.23076914 154.30769229 71.23076914 259.30769258v428.07692285c0 105.00000029 81.92307656 190.38461573 181.15384658 190.38461572H477.38461573c24.23076943 0 42.69230771-19.61538487 42.69230771-42.69230771z m323.07692255-521.53846172c0-27.69230742-23.07692285-50.76923115-50.76923026-50.76923115s-50.76923115 23.07692285-50.76923116 50.76923115 23.07692285 50.76923115 50.76923116 50.76923028c28.84615401 0 50.76923115-23.07692285 50.76923026-50.76923028m255.00000059 377.3076917c0-148.84615372-121.15384629-270-268.84615429-270S559.30769229 541.99999971 559.30769229 690.84615342s121.15384629 268.84615342 270 268.84615429 268.84615342-119.99999971 268.84615429-268.84615429z m-87.69230772 0c0 99.23076914-80.76923086 181.15384658-181.15384657 181.15384658s-181.15384658-80.76923086-181.15384571-181.15384658 80.76923086-180 181.15384571-180 181.15384658 80.76923086 181.15384657 180z m-167.30769287 114.23076944l170.76923086-184.61538458c15.00000029-16.15384599 13.84615371-41.53846114-2.30769228-56.53846143-16.15384599-15.00000029-41.53846114-13.84615371-56.53846142 2.30769229L807.38461513 724.307692 731.23076885 672.38461513c-18.46153828-12.69230801-42.69230771-8.07692344-55.38461484 10.38461573-12.69230801 18.46153828-8.07692344 42.69230771 10.38461484 55.38461572l106.15384687 72.69230743c6.92307685 4.61538457 15.00000029 6.92307685 23.07692285 6.92307685 9.23076914 0 19.61538487-4.61538457 27.69230742-12.69230801z" id="yzmplayer-comment"></path></svg>'
1262
+ },
1263
+ function(e, t) {
1264
+ e.exports =
1265
+ '<svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 32 32"><path d="M27.090 0.131h-22.731c-2.354 0-4.262 1.839-4.262 4.109v16.401c0 2.269 1.908 4.109 4.262 4.109h4.262v-2.706h8.469l-8.853 8.135 1.579 1.451 7.487-6.88h9.787c2.353 0 4.262-1.84 4.262-4.109v-16.401c0-2.27-1.909-4.109-4.262-4.109v0zM28.511 19.304c0 1.512-1.272 2.738-2.841 2.738h-8.425l-0.076-0.070-0.076 0.070h-11.311c-1.569 0-2.841-1.226-2.841-2.738v-13.696c0-1.513 1.272-2.739 2.841-2.739h19.889c1.569 0 2.841-0.142 2.841 1.37v15.064z"></path></svg>'
1266
+ },
1267
+ function(e, t) {
1268
+ e.exports =
1269
+ '<svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 1048 1024"><path d="M675.48206831 405.43059956c-21.34102395 0-38.61709113-17.27606717-38.61709114-38.61709114 0-21.34102395 17.27606717-38.61709113 38.61709113-38.6170903s38.61709113 17.27606717 38.6170903 38.6170903c0 21.34102395-17.27606717 38.61709113-38.6170903 38.61709114M825.88547437 93.44515543c-1.0162392 0-3.04871759 1.0162392-4.06495679 1.0162392L171.42740857 347.50496286c-32.51965512 9.14615277-57.92563586 35.56837271-67.07178864 68.08802865-9.14615277 34.55213351 0 69.10426785 25.40598074 94.5102486 5.08119598 5.08119598 11.17863116 8.12991357 18.29230555 10.1623928L284.22996353 557.86648401l104.67264139 30.48717673c48.77948309-45.7307655 144.30597089-134.14357891 159.54955883-148.37092768 15.24358878-15.24358878 39.63333032-15.24358878 54.87691911 0 15.24358878 15.24358878 15.24358878 39.63333032 0 54.87691911-18.29230637 18.29230637-132.11110052 123.98118613-157.51708127 147.35468847L498.65644147 883.06303852c2.03247839 7.11367438 5.08119598 14.22734958 10.16239279 19.30854556 18.29230637 18.29230637 42.68204792 28.45469834 69.10426703 28.45469833 8.12991357 0 17.27606717-1.0162392 25.40598157-3.04871759 33.53589431-9.14615277 58.94187506-33.53589431 68.08802783-66.05555026L943.76922531 218.44258075c1.0162392-2.03247839 1.0162392-3.04871759 2.0324784-5.08119598 9.14615277-34.55213351 0-69.10426785-25.40598074-94.5102486C894.98974222 94.46139462 860.43760788 84.29900183 825.88547437 93.44515543z"></path></svg>'
1270
+ },
1271
+ function(e, t) {
1272
+ e.exports =
1273
+ '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"><path d="M16.5 8c1.289 0 2.49.375 3.5 1.022V6a2 2 0 00-2-2H4a2 2 0 00-2 2v10a2 2 0 002 2h7.022A6.5 6.5 0 0116.5 8zM7 13H5a1 1 0 010-2h2a1 1 0 010 2zm2-4H5a1 1 0 010-2h4a1 1 0 010 2z"></path><path d="M20.587 13.696l-.787-.131a3.503 3.503 0 00-.593-1.051l.301-.804a.46.46 0 00-.21-.56l-1.005-.581a.52.52 0 00-.656.113l-.499.607a3.53 3.53 0 00-1.276 0l-.499-.607a.52.52 0 00-.656-.113l-1.005.581a.46.46 0 00-.21.56l.301.804c-.254.31-.456.665-.593 1.051l-.787.131a.48.48 0 00-.413.465v1.209a.48.48 0 00.413.465l.811.135c.144.382.353.733.614 1.038l-.292.78a.46.46 0 00.21.56l1.005.581a.52.52 0 00.656-.113l.515-.626a3.549 3.549 0 001.136 0l.515.626a.52.52 0 00.656.113l1.005-.581a.46.46 0 00.21-.56l-.292-.78c.261-.305.47-.656.614-1.038l.811-.135A.48.48 0 0021 15.37v-1.209a.48.48 0 00-.413-.465zM16.5 16.057a1.29 1.29 0 11.002-2.582 1.29 1.29 0 01-.002 2.582z"></path></svg>'
1274
+ },
1275
+ function(e, t) {
1276
+ e.exports =
1277
+ '<svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 32 32"><path d="M16 23c-3.309 0-6-2.691-6-6s2.691-6 6-6 6 2.691 6 6-2.691 6-6 6zM16 13c-2.206 0-4 1.794-4 4s1.794 4 4 4c2.206 0 4-1.794 4-4s-1.794-4-4-4zM27 28h-22c-1.654 0-3-1.346-3-3v-16c0-1.654 1.346-3 3-3h3c0.552 0 1 0.448 1 1s-0.448 1-1 1h-3c-0.551 0-1 0.449-1 1v16c0 0.552 0.449 1 1 1h22c0.552 0 1-0.448 1-1v-16c0-0.551-0.448-1-1-1h-11c-0.552 0-1-0.448-1-1s0.448-1 1-1h11c1.654 0 3 1.346 3 3v16c0 1.654-1.346 3-3 3zM24 10.5c0 0.828 0.672 1.5 1.5 1.5s1.5-0.672 1.5-1.5c0-0.828-0.672-1.5-1.5-1.5s-1.5 0.672-1.5 1.5zM15 4c0 0.552-0.448 1-1 1h-4c-0.552 0-1-0.448-1-1v0c0-0.552 0.448-1 1-1h4c0.552 0 1 0.448 1 1v0z"></path></svg>'
1278
+ },
1279
+ function(e, t) {
1280
+ e.exports =
1281
+ '<svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 32 32"><path d="M26.667 5.333h-21.333c-0 0-0.001 0-0.001 0-1.472 0-2.666 1.194-2.666 2.666 0 0 0 0.001 0 0.001v-0 16c0 0 0 0.001 0 0.001 0 1.472 1.194 2.666 2.666 2.666 0 0 0.001 0 0.001 0h21.333c0 0 0.001 0 0.001 0 1.472 0 2.666-1.194 2.666-2.666 0-0 0-0.001 0-0.001v0-16c0-0 0-0.001 0-0.001 0-1.472-1.194-2.666-2.666-2.666-0 0-0.001 0-0.001 0h0zM5.333 16h5.333v2.667h-5.333v-2.667zM18.667 24h-13.333v-2.667h13.333v2.667zM26.667 24h-5.333v-2.667h5.333v2.667zM26.667 18.667h-13.333v-2.667h13.333v2.667z"></path></svg>'
1282
+ },
1283
+ function(e, t) {
1284
+ e.exports =
1285
+ '<svg version="1.1" viewBox="0 0 22 22"><svg x="7" y="1"><circle class="diplayer-loading-dot diplayer-loading-dot-0" cx="4" cy="4" r="2"></circle></svg><svg x="11" y="3"><circle class="diplayer-loading-dot diplayer-loading-dot-1" cx="4" cy="4" r="2"></circle></svg><svg x="13" y="7"><circle class="diplayer-loading-dot diplayer-loading-dot-2" cx="4" cy="4" r="2"></circle></svg><svg x="11" y="11"><circle class="diplayer-loading-dot diplayer-loading-dot-3" cx="4" cy="4" r="2"></circle></svg><svg x="7" y="13"><circle class="diplayer-loading-dot diplayer-loading-dot-4" cx="4" cy="4" r="2"></circle></svg><svg x="3" y="11"><circle class="diplayer-loading-dot diplayer-loading-dot-5" cx="4" cy="4" r="2"></circle></svg><svg x="1" y="7"><circle class="diplayer-loading-dot diplayer-loading-dot-6" cx="4" cy="4" r="2"></circle></svg><svg x="3" y="3"><circle class="diplayer-loading-dot diplayer-loading-dot-7" cx="4" cy="4" r="2"></circle></svg></svg>'
1286
+ },
1287
+ function(e, t, n) {
1288
+ var i = n(3);
1289
+ e.exports = function(e) {
1290
+ "use strict";
1291
+ e = e || {};
1292
+ var t = "",
1293
+ a = (arguments[1], e.video),
1294
+ o = e.options,
1295
+ s = i.$escape,
1296
+ r = e.tran,
1297
+ l = e.icons,
1298
+ c = e.index,
1299
+ u = i.$each;
1300
+ e.$value, e.$index;
1301
+ return t +=
1302
+ '<div id="loading-box"><div class="loading"><p class="pic"></p><div class="tips"></div></div><div type="button" id="close" ><div class="playlink"><span id="link1">播放器连接...</span><span id="link1-success">【完成】</span></div><div class="dmlink"><span id="link2">弹幕连接中...</span><span id="link2-success">【完成】</span><span id="link2-error">【失败】</span></div><span class="palycon" id="link3"><e id="link3_tip">等待视频连接中</e><e id="link3-error">【失败】</e><!--d class="wait"><e id="span">3</e>s</d--></span></div></div><div class="yzmplayer-mask"></div>\n<div class="yzmplayer-cplayer"><div class="yzmplayer-showing"><svg aria-hidden="true"><use xlink:href="#icon-play"></use></svg></div><div class="vod-title"><div id="landing-title" class="video-info"><ul class="u-title"><a id="vodlink" href="" target="_blank" ><span class="iconfont icon-back"></span></a><a id="vodtitle"><span></span></a></ul></div></div></div><div class="yzmplayer-video-wrap">\n ',
1303
+ function(e) {
1304
+ t += e
1305
+ }(n(4)(a)), t += "\n ", o.logo && (t += '\n <div class="yzmplayer-logo">\n <img src="', t += s(o.logo),
1306
+ t += '">\n </div>\n '), t += '\n <div class="yzmplayer-danmaku"', o.danmaku && o.danmaku.bottm && (t +=
1307
+ ' style="margin-bottom:', t += s(o.danmaku.bottm), t += '"'), t +=
1308
+ '>\n <div class="yzmplayer-danmaku-item yzmplayer-danmaku-item--demo"></div>\n </div>\n <div class="yzmplayer-subtitle"></div>\n <div class="yzmplayer-bezel">\n <span class="yzmplayer-bezel-icon"></span>\n ',
1309
+ o.danmaku && (t += '\n <span class="yzmplayer-danloading">', t += s(r("Danmaku is loading")), t +=
1310
+ "</span>\n "), t += '\n <span class="diplayer-loading-icon">', t += l.loading, t +=
1311
+ '</span>\n </div>\n</div>\n<div class="yzmplayer-controller-mask"></div>\n<div class="yzmplayer-controller">\n <div class="controller-box">\n <div class="yzmplayer-icons yzmplayer-icons-left">\n <button class="yzmplayer-icon yzmplayer-play-icon">\n <span class="yzmplayer-icon-content">',
1312
+ t += l.play, t +=
1313
+ '</span>\n </button>\n <button onclick="YZM.video.next();" class="yzmplayer-icon icon-xj" data-balloon="下一集" data-balloon-pos="up">\n<span class="yzmplayer-icon-content"><svg aria-hidden="true" fill="#fff"><use xlink:href="#icon-play-xj"></use></svg></span></button>\n <div class="yzmplayer-volume">\n <button class="yzmplayer-icon yzmplayer-volume-icon">\n <span class="yzmplayer-icon-content">',
1314
+ t += l.volumeDown, t +=
1315
+ '</span>\n </button>\n <div class="yzmplayer-volume-bar-wrap" data-balloon-pos="up">\n <div class="yzmplayer-volume-bar">\n <div class="yzmplayer-volume-bar-inner" style="background: ',
1316
+ t += s(o.theme), t += ';">\n <span class="yzmplayer-thumb" style="background: ', t += s(
1317
+ o.theme), t +=
1318
+ '"></span>\n </div>\n </div>\n </div>\n </div>\n <span class="yzmplayer-time">\n <span class="yzmplayer-ptime">0:00</span> /\n <span class="yzmplayer-dtime">0:00</span>\n </span>\n ',
1319
+ o.live && (t +=
1320
+ '\n <span class="yzmplayer-live-badge"><span class="yzmplayer-live-dot" style="background: ', t += s(o
1321
+ .theme), t += ';"></span>', t += s(r("Live")), t += "</span>\n "), t +=
1322
+ '\n </div>\n <div class="yzmplayer-icons yzmplayer-icons-right">\n ', o.video.quality && (t +=
1323
+ '\n <div class="yzmplayer-quality">\n <button class="yzmplayer-icon yzmplayer-quality-icon">',
1324
+ t += s(o.video.quality[o.video.defaultQuality].name), t +=
1325
+ '</button>\n <div class="yzmplayer-quality-mask">\n <div class="yzmplayer-quality-list"></div>\n ',
1326
+ u(o.video.quality, function(e, n) {
1327
+ t += '\n <div class="yzmplayer-quality-item" data-index="', t += s(n), t += '">', t += s(
1328
+ e.name), t += "</div>\n "
1329
+ }), t += "\n </div>\n </div>\n </div>\n "), t += "\n ", o.screenshot &&
1330
+ (t += '\n <a href="#" class="yzmplayer-icon yzmplayer-camera-icon" data-balloon="', t += s(r(
1331
+ "Screenshot")), t += '" data-balloon-pos="up">\n <span class="yzmplayer-icon-content">', t += l.camera,
1332
+ t += "</span>\n </a>\n "), t +=
1333
+ '\n <div class="yzmplayer-comment">\n <button class="yzmplayer-icon yzmplayer-comment-icon" data-balloon="',
1334
+ t += s(r("Send danmaku")), t +=
1335
+ '" data-balloon-pos="up">\n <span class="yzmplayer-icon-content">', t += l.comment, t +=
1336
+ "</span>\n </button>\n </div>\n ", o.subtitle && (t +=
1337
+ '\n <div class="yzmplayer-subtitle-btn">\n <button class="yzmplayer-icon yzmplayer-subtitle-icon" data-balloon="',
1338
+ t += s(r("Hide subtitle")), t +=
1339
+ '" data-balloon-pos="up">\n <span class="yzmplayer-icon-content">', t += l.subtitle, t +=
1340
+ "</span>\n </button>\n </div>\n "), t +=
1341
+ '\n <div class="yzmplayer-setting"><button class="yzmplayer-icon yzmplayer-setting-speeds "data-balloon="速度"data-balloon-pos="up"><span class="yzmplayer-label title">倍速</span><div class="yzmplayer-setting-speed-panel speed-stting"><div class="yzmplayer-setting-speed-item"data-speed="0.5"><span class="yzmplayer-label">0.5x</span></div><div class="yzmplayer-setting-speed-item"data-speed="0.75"><span class="yzmplayer-label">0.75x</span></div><div class="yzmplayer-setting-speed-item"data-speed="1"><span class="yzmplayer-label">正常</span></div><div class="yzmplayer-setting-speed-item"data-speed="1.25"><span class="yzmplayer-label">1.25x</span></div><div class="yzmplayer-setting-speed-item"data-speed="1.5"><span class="yzmplayer-label">1.5x</span></div><div class="yzmplayer-setting-speed-item"data-speed="2"><span class="yzmplayer-label">2.0x</span></div></div></button><button class="yzmplayer-icon yzmplayer-list-icon" data-balloon="弹幕列表" data-balloon-pos="up"><span class="yzmplayer-icon-content"><svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%" version="1.1" viewBox="0 0 32 32"><path class="yzmplayer-fill" style="fill:#ffffff" d="M26.667 5.333h-21.333c-0 0-0.001 0-0.001 0-1.472 0-2.666 1.194-2.666 2.666 0 0 0 0.001 0 0.001v-0 16c0 0 0 0.001 0 0.001 0 1.472 1.194 2.666 2.666 2.666 0 0 0.001 0 0.001 0h21.333c0 0 0.001 0 0.001 0 1.472 0 2.666-1.194 2.666-2.666 0-0 0-0.001 0-0.001v0-16c0-0 0-0.001 0-0.001 0-1.472-1.194-2.666-2.666-2.666-0 0-0.001 0-0.001 0h0zM5.333 16h5.333v2.667h-5.333v-2.667zM18.667 24h-13.333v-2.667h13.333v2.667zM26.667 24h-5.333v-2.667h5.333v2.667zM26.667 18.667h-13.333v-2.667h13.333v2.667z" id="yzmplayer-full-in"></path></svg></span></button>\n <button class="yzmplayer-icon yzmplayer-setting-icon" data-balloon="',
1342
+ t += s(r("Setting")), t += '" data-balloon-pos="up">\n <span class="yzmplayer-icon-content">',
1343
+ t += l.setting, t +=
1344
+ '</span>\n </button>\n <div class="yzmplayer-setting-box">\n <div class="yzmplayer-setting-origin-panel">\n <div class="yzmplayer-setting-item yzmplayer-setting-speed">\n <span class="yzmplayer-label">',
1345
+ t += s(r("Speed")), t += '</span>\n <div class="yzmplayer-toggle">', t += l.right, t +=
1346
+ '</div>\n </div>\n <div class="yzmplayer-setting-item yzmplayer-setting-loop">\n <span class="yzmplayer-label">',
1347
+ t += s(r("Loop")), t +=
1348
+ '</span>\n <div class="yzmplayer-toggle">\n <input class="yzmplayer-toggle-setting-input" type="checkbox" name="yzmplayer-toggle">\n <label for="yzmplayer-toggle"></label>\n </div>\n </div><div class="yzmplayer-setting-item yzmplayer-setting-jlast"><span class="yzmplayer-label">跳过片尾 <input id="jumptime" placeholder="单位/秒"></span><div class="yzmplayer-toggle"><input class="yzmplayer-toggle-setting-input" type="checkbox" name="yzmplayer-toggle"><label for="yzmplayer-toggle"></label></div></div><div class="yzmplayer-setting-item yzmplayer-setting-jfrist"><span class="yzmplayer-label">跳过片头 <input id="fristtime" placeholder="单位/秒"></span><div class="yzmplayer-toggle"><input class="yzmplayer-toggle-setting-input" type="checkbox" name="yzmplayer-toggle"><label for="yzmplayer-toggle"></label></div></div>\n </div>\n <div class="yzmplayer-setting-speed-panel">\n <div class="yzmplayer-setting-speed-item" data-speed="0.5">\n <span class="yzmplayer-label">0.5</span>\n </div>\n <div class="yzmplayer-setting-speed-item" data-speed="0.75">\n <span class="yzmplayer-label">0.75</span>\n </div>\n <div class="yzmplayer-setting-speed-item" data-speed="1">\n <span class="yzmplayer-label">',
1349
+ t += s(r("Normal")), t +=
1350
+ '</span>\n </div>\n <div class="yzmplayer-setting-speed-item" data-speed="1.25">\n <span class="yzmplayer-label">1.25</span>\n </div>\n <div class="yzmplayer-setting-speed-item" data-speed="1.5">\n <span class="yzmplayer-label">1.5</span>\n </div>\n <div class="yzmplayer-setting-speed-item" data-speed="2">\n <span class="yzmplayer-label">2</span>\n </div>\n </div>\n </div>\n </div>\n <div class="yzmplayer-full">\n <button class="yzmplayer-icon yzmplayer-full-in-icon" data-balloon="',
1351
+ t += s(r("Web full screen")), t +=
1352
+ '" data-balloon-pos="up">\n <span class="yzmplayer-icon-content">', t += l.fullWeb, t +=
1353
+ '</span>\n </button>\n <button class="yzmplayer-icon yzmplayer-full-icon" data-balloon="',
1354
+ t += s(r("Full screen")), t +=
1355
+ '" data-balloon-pos="up">\n <span class="yzmplayer-icon-content">', t += l.full, t +=
1356
+ '</span>\n </button><button class="yzmplayer-icon yzmplayer-fulloff-icon" data-balloon="退出全屏" data-balloon-pos="up"><span class="yzmplayer-icon-content"><svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%" version="1.1" viewBox="0 0 1024 1024"><path class="yzmplayer-fill" style="fill:#ffffff" d="M308.3555518 432.05693128H150.1524268c-17.67162586 0-32.81873308-14.30560177-32.81873308-32.81873308s14.30560177-32.81873308 32.81873308-32.81873309h158.203125c30.29421522 0 49.64885273-9.25656603 49.6488535-56.38090166V150.1524268c0-17.67162586 14.30560177-32.81873308 32.81873308-32.81873308s32.81873308 14.30560177 32.81873309 32.81873308v160.72764287c-0.84150622 75.73553842-43.75831155 121.17686162-115.28631967 121.17686161z m321.45528573 471.24335092c-17.67162586 0-31.97722764-14.30560177-31.97722687-31.97722687V709.75390625c0-75.73553842 42.91680533-121.17686162 114.44481346-121.17686162h158.203125c17.67162586 0 31.97722764 14.30560177 31.97722763 31.97722764s-14.30560177 31.97722764-31.97722763 31.97722687H712.27842412c-30.29421522 0-49.64885273 9.25656603-49.64885273 56.38090089v160.72764287c-0.84150622 18.51313131-15.14710799 33.6602393-32.81873386 33.6602393z" id="yzmplayer-fulloff"></path></svg></span></button>\n </div>\n </div>\n <div class="yzmplayer-bar-wrap">\n <div class="yzmplayer-bar-time hidden">00:00</div>\n <div class="yzmplayer-bar-preview"></div>\n <div class="yzmplayer-bar">\n <div class="yzmplayer-loaded" style="width: 0;"></div>\n <div class="yzmplayer-played" style="width: 0; background: ',
1357
+ t += s(o.theme), t += '">\n <span class="yzmplayer-thumb" style="background: ', t += s(o.theme),
1358
+ t +=
1359
+ '"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 18 18" width="18" height="18" preserveAspectRatio="xMidYMid meet" style="width: 100%; height: 100%; transform: translate3d(0px, 0px, 0px);"><defs><clipPath id="__lottie_element_25"><rect width="18" height="18" x="0" y="0"></rect></clipPath></defs><g clip-path="url(#__lottie_element_25)"><g transform="matrix(1,0,0,1,8.937000274658203,8.25)" opacity="0.14" style="display: block;"><g opacity="1" transform="matrix(1,0,0,1,0.07500000298023224,1.2130000591278076)"><path fill="rgb(251,114,153)" fill-opacity="1" d=" M9,-3.5 C9,-3.5 9,3.5 9,3.5 C9,5.707600116729736 7.207600116729736,7.5 5,7.5 C5,7.5 -5,7.5 -5,7.5 C-7.207600116729736,7.5 -9,5.707600116729736 -9,3.5 C-9,3.5 -9,-3.5 -9,-3.5 C-9,-5.707600116729736 -7.207600116729736,-7.5 -5,-7.5 C-5,-7.5 5,-7.5 5,-7.5 C7.207600116729736,-7.5 9,-5.707600116729736 9,-3.5z"></path></g></g><g transform="matrix(1,0,0,1,9.140999794006348,8.67199993133545)" opacity="0.28" style="display: block;"><g opacity="1" transform="matrix(1,0,0,1,-0.1509999930858612,0.7990000247955322)"><path fill="rgb(251,114,153)" fill-opacity="1" d=" M8,-3 C8,-3 8,3 8,3 C8,4.931650161743164 6.431650161743164,6.5 4.5,6.5 C4.5,6.5 -4.5,6.5 -4.5,6.5 C-6.431650161743164,6.5 -8,4.931650161743164 -8,3 C-8,3 -8,-3 -8,-3 C-8,-4.931650161743164 -6.431650161743164,-6.5 -4.5,-6.5 C-4.5,-6.5 4.5,-6.5 4.5,-6.5 C6.431650161743164,-6.5 8,-4.931650161743164 8,-3z"></path></g></g><g transform="matrix(0.9883429408073425,-0.7275781631469727,0.6775955557823181,0.920446515083313,7.3224687576293945,-0.7606706619262695)" opacity="1" style="display: block;"><g opacity="1" transform="matrix(0.9937776327133179,-0.11138220876455307,0.11138220876455307,0.9937776327133179,-2.5239999294281006,1.3849999904632568)"><path fill="rgb(0,0,0)" fill-opacity="1" d=" M0.75,-1.25 C0.75,-1.25 0.75,1.25 0.75,1.25 C0.75,1.663925051689148 0.4139249920845032,2 0,2 C0,2 0,2 0,2 C-0.4139249920845032,2 -0.75,1.663925051689148 -0.75,1.25 C-0.75,1.25 -0.75,-1.25 -0.75,-1.25 C-0.75,-1.663925051689148 -0.4139249920845032,-2 0,-2 C0,-2 0,-2 0,-2 C0.4139249920845032,-2 0.75,-1.663925051689148 0.75,-1.25z" style="fill: #000;"></path></g></g><g transform="matrix(1.1436611413955688,0.7535901665687561,-0.6317168474197388,0.9587040543556213,16.0070743560791,2.902894973754883)" opacity="1" style="display: block;"><g opacity="1" transform="matrix(0.992861807346344,0.1192704513669014,-0.1192704513669014,0.992861807346344,-2.5239999294281006,1.3849999904632568)"><path fill="rgb(0,0,0)" fill-opacity="1" d=" M0.75,-1.25 C0.75,-1.25 0.75,1.25 0.75,1.25 C0.75,1.663925051689148 0.4139249920845032,2 0,2 C0,2 0,2 0,2 C-0.4139249920845032,2 -0.75,1.663925051689148 -0.75,1.25 C-0.75,1.25 -0.75,-1.25 -0.75,-1.25 C-0.75,-1.663925051689148 -0.4139249920845032,-2 0,-2 C0,-2 0,-2 0,-2 C0.4139249920845032,-2 0.75,-1.663925051689148 0.75,-1.25z" style="fill: #000;"></path></g></g><g transform="matrix(1,0,0,1,8.890999794006348,8.406000137329102)" opacity="1" style="display: block;"><g opacity="1" transform="matrix(1,0,0,1,0.09099999815225601,1.1009999513626099)"><path fill="rgb(255,255,255)" fill-opacity="1" d=" M7,-3 C7,-3 7,3 7,3 C7,4.379749774932861 5.879749774932861,5.5 4.5,5.5 C4.5,5.5 -4.5,5.5 -4.5,5.5 C-5.879749774932861,5.5 -7,4.379749774932861 -7,3 C-7,3 -7,-3 -7,-3 C-7,-4.379749774932861 -5.879749774932861,-5.5 -4.5,-5.5 C-4.5,-5.5 4.5,-5.5 4.5,-5.5 C5.879749774932861,-5.5 7,-4.379749774932861 7,-3z"></path><path stroke-linecap="butt" stroke-linejoin="miter" fill-opacity="0" stroke-miterlimit="4" stroke="rgb(0,0,0)" stroke-opacity="1" stroke-width="1.5" d=" M7,-3 C7,-3 7,3 7,3 C7,4.379749774932861 5.879749774932861,5.5 4.5,5.5 C4.5,5.5 -4.5,5.5 -4.5,5.5 C-5.879749774932861,5.5 -7,4.379749774932861 -7,3 C-7,3 -7,-3 -7,-3 C-7,-4.379749774932861 -5.879749774932861,-5.5 -4.5,-5.5 C-4.5,-5.5 4.5,-5.5 4.5,-5.5 C5.879749774932861,-5.5 7,-4.379749774932861 7,-3z"></path></g></g><g transform="matrix(1,0,0,1,8.89900016784668,8.083999633789062)" opacity="1" style="display: block;"><g opacity="1" transform="matrix(1,0,0,1,-2.5239999294281006,1.3849999904632568)"><path fill="rgb(0,0,0)" fill-opacity="1" d=" M0.875,-1.125 C0.875,-1.125 0.875,1.125 0.875,1.125 C0.875,1.607912540435791 0.48291251063346863,2 0,2 C0,2 0,2 0,2 C-0.48291251063346863,2 -0.875,1.607912540435791 -0.875,1.125 C-0.875,1.125 -0.875,-1.125 -0.875,-1.125 C-0.875,-1.607912540435791 -0.48291251063346863,-2 0,-2 C0,-2 0,-2 0,-2 C0.48291251063346863,-2 0.875,-1.607912540435791 0.875,-1.125z" style="fill: #000;"></path></g></g><g transform="matrix(1,0,0,1,14.008999824523926,8.083999633789062)" opacity="1" style="display: block;"><g opacity="1" transform="matrix(1,0,0,1,-2.5239999294281006,1.3849999904632568)"><path fill="rgb(0,0,0)" fill-opacity="1" d=" M0.8999999761581421,-1.100000023841858 C0.8999999761581421,-1.100000023841858 0.8999999761581421,1.100000023841858 0.8999999761581421,1.100000023841858 C0.8999999761581421,1.596709966659546 0.4967099726200104,2 0,2 C0,2 0,2 0,2 C-0.4967099726200104,2 -0.8999999761581421,1.596709966659546 -0.8999999761581421,1.100000023841858 C-0.8999999761581421,1.100000023841858 -0.8999999761581421,-1.100000023841858 -0.8999999761581421,-1.100000023841858 C-0.8999999761581421,-1.596709966659546 -0.4967099726200104,-2 0,-2 C0,-2 0,-2 0,-2 C0.4967099726200104,-2 0.8999999761581421,-1.596709966659546 0.8999999761581421,-1.100000023841858z" style="fill: #000;"></path></g></g></g></svg></span>\n </div>\n </div>\n </div>\n </div>\n <div class="yzmplayer-icons yzmplayer-comment-box"><div class="yzmplayer-setting-item yzmplayer-setting-showdan showdan-setting"> <span class="yzmplayer-label"></span>\n<div class="yzmplayer-toggle"><input class="yzmplayer-showdan-setting-input"type="checkbox"name="yzmplayer-toggle-dan"><label for="yzmplayer-toggle-dan"></label></div></div>\n <button class="yzmplayer-icon yzmplayer-comment-setting-icon" data-balloon="',
1360
+ t += s(r("Setting")), t += '" data-balloon-pos="up">\n <span class="yzmplayer-icon-content">', t +=
1361
+ l.pallette, t +=
1362
+ '</span>\n </button>\n <div class="yzmplayer-comment-setting-box">\n <div class="yzmplayer-setting-item yzmplayer-setting-danunlimit">\n <span class="yzmplayer-label">',
1363
+ t += s(r("Unlimited danmaku")), t +=
1364
+ '</span>\n <div class="yzmplayer-toggle">\n <input class="yzmplayer-danunlimit-setting-input" type="checkbox" name="yzmplayer-toggle-danunlimit">\n <label for="yzmplayer-toggle-danunlimit"></label>\n </div>\n </div>\n <div class="yzmplayer-setting-item yzmplayer-setting-danmaku">\n <span class="yzmplayer-label">',
1365
+ t += s(r("Opacity for danmaku")), t +=
1366
+ '</span>\n <div class="yzmplayer-danmaku-bar-wrap">\n <div class="yzmplayer-danmaku-bar">\n <div class="yzmplayer-danmaku-bar-inner">\n <span class="yzmplayer-thumb"></span>\n </div>\n </div>\n </div>\n </div>\n <div class="yzmplayer-comment-setting-type">\n <div class="yzmplayer-comment-setting-title">',
1367
+ t += s(r("Set danmaku type")), t +=
1368
+ '</div>\n <label>\n <input type="radio" name="yzmplayer-danmaku-type-', t +=
1369
+ s(c), t += '" value="top">\n <span>', t += s(r("Top")), t +=
1370
+ '</span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-type-',
1371
+ t += s(c), t += '" value="right" checked>\n <span>', t += s(r("Rolling")), t +=
1372
+ '</span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-type-',
1373
+ t += s(c), t += '" value="bottom">\n <span>', t += s(r("Bottom")), t +=
1374
+ '</span>\n </label>\n </div>\n <div class="yzmplayer-comment-setting-font"><div class="yzmplayer-comment-setting-title">弹幕大小</div><label><input type="radio"name="yzmplayer-danmaku-font-0"value="50px"><span>超大</span></label><label><input type="radio"name="yzmplayer-danmaku-font-0"value="35px"><span>较大</span></label><label><input type="radio"name="yzmplayer-danmaku-font-0"value="27.5px"checked=""><span>标准</span></label><label><input type="radio"name="yzmplayer-danmaku-font-0"value="18px"><span>较小</span></label></div> <div class="yzmplayer-comment-setting-color">\n <div class="yzmplayer-comment-setting-title">',
1375
+ t += s(r("Set danmaku color")), t +=
1376
+ '</div>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-', t +=
1377
+ s(c), t +=
1378
+ '" value="#FE0302">\n <span style="background:#FE0302;"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1379
+ t += s(c), t +=
1380
+ '" value="#FF7204">\n <span style="background: #FF7204"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1381
+ t += s(c), t +=
1382
+ '" value="#FFAA02">\n <span style="background: #FFAA02"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1383
+ t += s(c), t +=
1384
+ '" value="#FFD302">\n <span style="background: #FFD302"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1385
+ t += s(c), t +=
1386
+ '" value="#FFFF00">\n <span style="background: #FFFF00"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1387
+ t += s(c), t +=
1388
+ '" value="#A0EE00">\n <span style="background: #A0EE00"></span>\n </label>\n<label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1389
+ t += s(c), t +=
1390
+ '" value="#00CD00">\n <span style="background: #00CD00;"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1391
+ t += s(c), t +=
1392
+ '" value="#019899">\n <span style="background: #019899"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1393
+ t += s(c), t +=
1394
+ '" value="#4266BE">\n <span style="background: #4266BE"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1395
+ t += s(c), t +=
1396
+ '" value="#89D5FF">\n <span style="background: #89D5FF"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1397
+ t += s(c), t +=
1398
+ '" value="#CC0273">\n <span style="background: #CC0273"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1399
+ t += s(c), t +=
1400
+ '" value="#222222">\n <span style="background: #222222"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1401
+ t += s(c), t +=
1402
+ '" value="#9B9B9B">\n <span style="background: #9B9B9B"></span>\n </label>\n <label>\n <input type="radio" name="yzmplayer-danmaku-color-',
1403
+ t += s(c), t +=
1404
+ '" value="#FFFFFF" checked>\n <span style="background: #FFFFFF"></span>\n </label>\n</div>\n </div>\n <input class="yzmplayer-comment-input" type="text" placeholder="',
1405
+ t += s(r("Input danmaku, hit Enter")), t +=
1406
+ '" maxlength="30">\n <button class="yzmplayer-icon yzmplayer-send-icon" data-balloon="', t += s(r(
1407
+ "Send")), t += '" data-balloon-pos="up">\n <span class="yzmplayer-icon-content">', t += l.send, t +=
1408
+ '</span>\n </button>\n<input id="dmtext" dmtype="right" size="27.5px" class="yzm-yzmplayer-comment-input" type="text" placeholder="',
1409
+ t += s(r("Input danmaku, hit Enter")), t +=
1410
+ '" maxlength="30" >\n <button class="yzmplayer-icon yzm-yzmplayer-send-icon" data-balloon="', t += s(r(
1411
+ "Send")), t +=
1412
+ '" data-balloon-pos="up">发送 </button>\n </div>\n </div>\n<div class="yzmplayer-info-panel yzmplayer-info-panel-hide">\n <div class="yzmplayer-info-panel-close">关闭</div>\n <div class="yzmplayer-info-panel-item yzmplayer-info-panel-item-version">\n <span class="yzmplayer-info-panel-item-title">播放器版本</span>\n <span class="yzmplayer-info-panel-item-data"></span>\n </div>\n <div class="yzmplayer-info-panel-item yzmplayer-info-panel-item-fps">\n <span class="yzmplayer-info-panel-item-title">播放器帧率</span>\n <span class="yzmplayer-info-panel-item-data"></span>\n </div>\n <div class="yzmplayer-info-panel-item yzmplayer-info-panel-item-type">\n <span class="yzmplayer-info-panel-item-title">视频类型</span>\n <span class="yzmplayer-info-panel-item-data"></span>\n </div>\n <div class="yzmplayer-info-panel-item yzmplayer-info-panel-item-url">\n <span class="yzmplayer-info-panel-item-title">视频地址</span>\n <span class="yzmplayer-info-panel-item-data"></span>\n </div>\n <div class="yzmplayer-info-panel-item yzmplayer-info-panel-item-resolution">\n <span class="yzmplayer-info-panel-item-title">视频分辨率</span>\n <span class="yzmplayer-info-panel-item-data"></span>\n </div>\n <div class="yzmplayer-info-panel-item yzmplayer-info-panel-item-duration">\n <span class="yzmplayer-info-panel-item-title">视频时长</span>\n <span class="yzmplayer-info-panel-item-data"></span>\n </div>\n ',
1413
+ o.danmaku && (t +=
1414
+ '\n <div class="yzmplayer-info-panel-item yzmplayer-info-panel-item-danmaku-id">\n <span class="yzmplayer-info-panel-item-title">弹幕 ID</span>\n <span class="yzmplayer-info-panel-item-data"></span>\n </div>\n <div class="yzmplayer-info-panel-item yzmplayer-info-panel-item-danmaku-api">\n <span class="yzmplayer-info-panel-item-title">弹幕API</span>\n <span class="yzmplayer-info-panel-item-data"></span>\n </div>\n <div class="yzmplayer-info-panel-item yzmplayer-info-panel-item-danmaku-amount">\n <span class="yzmplayer-info-panel-item-title">弹幕数量</span>\n <span class="yzmplayer-info-panel-item-data"></span>\n </div>\n<div class="yzmplayer-info-panel-item yzmplayer-info-panel-item-title-amount"><span class="yzmplayer-info-panel-item-title">视频标题</span><span class="yzmplayer-info-panel-item-data" id="vod-title"></span></div>\n '
1415
+ ), t += '\n</div>\n<div class="yzmplayer-menu">\n ', u(o.contextmenu, function(e, n) {
1416
+ t += '\n <div class="yzmplayer-menu-item">\n <a target="_blank" href="', t += s(e.link ||
1417
+ "javascript:void(0);"), t += '">', t += s(r(e.text)), t += "</a>\n </div>\n "
1418
+ }), t +=
1419
+ '\n</div>\n<div class="yzmplayer-notice"></div><div class="yzmplayer-danmu"><div class="yzmplayer-watching"><span class="yzmplayer-watching-number" title="播放器在线人数">1</span>人正在观看,<span class="danmuku-num">100</span>条弹幕</div><ul class="yzmplayer-list"><li>时间</li><li>弹幕内容</li><li>发送时间</li></ul><ul class="list-show"></ul></div><div class="svg-icon"><svg aria-hidden="true"><symbol id="icon-play" width="64" height="64" viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><defs><filter x="-11.2%" y="-10.8%" width="122.4%" height="125.5%" filterUnits="objectBoundingBox" id="pid-1-svgo-a"><feOffset dy="1" in="SourceAlpha" result="shadowOffsetOuter1"></feOffset><feGaussianBlur stdDeviation="2" in="shadowOffsetOuter1" result="shadowBlurOuter1"></feGaussianBlur><feComposite in="shadowBlurOuter1" in2="SourceAlpha" operator="out" result="shadowBlurOuter1"></feComposite><feColorMatrix values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.3 0" in="shadowBlurOuter1"></feColorMatrix></filter><path d="M52.352 13.5c4.837 0 8.707 4.32 8.647 9.72v21.06C61 49.62 57.128 54 52.29 54h-2.479c0 1.681-1.452 3-3.206 3S43.4 55.62 43.4 54H20.841c0 1.681-1.452 3-3.204 3-1.756 0-3.206-1.38-3.206-3h-2.722C6.87 54 3 49.68 3 44.28V23.22c0-5.4 3.87-9.72 8.709-9.72h11.25l-4.78-4.44c-.725-.661-.725-1.8 0-2.52.424-.36.908-.54 1.391-.54.546 0 1.029.18 1.392.54l7.5 6.96h7.318l7.5-6.96c.422-.36.907-.54 1.39-.54.544 0 1.029.18 1.392.54.725.659.725 1.8 0 2.52l-4.78 4.44h11.07zM26.527 45.54l17.418-10.08c1.45-.901 1.45-2.221 0-3.122L26.527 22.2c-1.452-.84-2.662-.12-2.662 1.56v20.22c0 1.74 1.21 2.4 2.662 1.561z" id="pid-1-svgo-b"></path></defs><g fill="none" fill-rule="evenodd"><use fill="#000" filter="url(#pid-1-svgo-a)" xlink:href="#pid-1-svgo-b"></use><use fill-opacity=".7" fill="#FFF" xlink:href="#pid-1-svgo-b"></use><path d="M26.527 45.541c-1.452.84-2.662.18-2.662-1.56V23.76c0-1.68 1.21-2.4 2.662-1.56L43.945 32.34c1.45.9 1.45 2.22 0 3.121L26.527 45.541z" fill="#000" opacity=".06"></path></g></symbol><symbol id="icon-play-xj" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"><path d="M16 5a1 1 0 00-1 1v4.615a1.431 1.431 0 00-.615-.829L7.21 5.23A1.439 1.439 0 005 6.445v9.11a1.44 1.44 0 002.21 1.215l7.175-4.555a1.436 1.436 0 00.616-.828V16a1 1 0 002 0V6C17 5.448 16.552 5 16 5z"></path></symbol></svg></div>'
1420
+ }
1421
+ },
1422
+ function(e, t, n) {
1423
+ "use strict";
1424
+ (function(t) {
1425
+ function i(e) {
1426
+ return "string" != typeof e && (e = void 0 === e || null === e ? "" : "function" == typeof e ? i(e.call(e)) :
1427
+ JSON.stringify(e)), e
1428
+ }
1429
+
1430
+ function a(e) {
1431
+ var t = "" + e,
1432
+ n = r.exec(t);
1433
+ if (!n) return e;
1434
+ var i = "",
1435
+ a = void 0,
1436
+ o = void 0,
1437
+ s = void 0;
1438
+ for (a = n.index, o = 0; a < t.length; a++) {
1439
+ switch (t.charCodeAt(a)) {
1440
+ case 34:
1441
+ s = "&#34;";
1442
+ break;
1443
+ case 38:
1444
+ s = "&#38;";
1445
+ break;
1446
+ case 39:
1447
+ s = "&#39;";
1448
+ break;
1449
+ case 60:
1450
+ s = "&#60;";
1451
+ break;
1452
+ case 62:
1453
+ s = "&#62;";
1454
+ break;
1455
+ default:
1456
+ continue
1457
+ }
1458
+ o !== a && (i += t.substring(o, a)), o = a + 1, i += s
1459
+ }
1460
+ return o !== a ? i + t.substring(o, a) : i
1461
+ }
1462
+ var o = n(34),
1463
+ s = Object.create(o ? t : window),
1464
+ r = /["&'<>]/;
1465
+ s.$escape = function(e) {
1466
+ return a(i(e))
1467
+ }, s.$each = function(e, t) {
1468
+ if (Array.isArray(e))
1469
+ for (var n = 0, i = e.length; n < i; n++) t(e[n], n);
1470
+ else
1471
+ for (var a in e) t(e[a], a)
1472
+ }, e.exports = s
1473
+ }).call(t, n(1))
1474
+ },
1475
+ function(e, t, n) {
1476
+ "use strict";
1477
+ (function(t) {
1478
+ e.exports = !1;
1479
+ try {
1480
+ e.exports = "[object process]" === Object.prototype.toString.call(t.process)
1481
+ } catch (e) {}
1482
+ }).call(t, n(1))
1483
+ },
1484
+ function(e, t, n) {
1485
+ "use strict";
1486
+
1487
+ function i(e, t) {
1488
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
1489
+ }
1490
+ Object.defineProperty(t, "__esModule", {
1491
+ value: !0
1492
+ });
1493
+ var a = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
1494
+ return typeof e
1495
+ } : function(e) {
1496
+ return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" :
1497
+ typeof e
1498
+ },
1499
+ o = function() {
1500
+ function e(e, t) {
1501
+ for (var n = 0; n < t.length; n++) {
1502
+ var i = t[n];
1503
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
1504
+ e, i.key, i)
1505
+ }
1506
+ }
1507
+ return function(t, n, i) {
1508
+ return n && e(t.prototype, n), i && e(t, i), t
1509
+ }
1510
+ }(),
1511
+ s = function() {
1512
+ function e(t) {
1513
+ i(this, e), this.options = t, this.container = this.options.container, this.danTunnel = {
1514
+ right: {},
1515
+ top: {},
1516
+ bottom: {}
1517
+ }, this.danIndex = 0, this.dan = [], this.showing = !0, this._opacity = this.options.opacity, this.events =
1518
+ this.options.events, this.unlimited = this.options.unlimited, this._measure(""), this.load()
1519
+ }
1520
+ return o(e, [{
1521
+ key: "load",
1522
+ value: function() {
1523
+ var e = this,
1524
+ t = void 0;
1525
+ t = this.options.api.maximum ? this.options.api.address + "&id=" + this.options.api.id + "&max=" + this.options
1526
+ .api.maximum : this.options.api.address + "&id=" + this.options.api.id;
1527
+ var n = (this.options.api.addition || []).slice(0);
1528
+ n.push(t), this.events && this.events.trigger("danmaku_load_start", n), this._readAllEndpoints(n,
1529
+ function(t) {
1530
+ e.dan = [].concat.apply([], t).sort(function(e, t) {
1531
+ return e.time - t.time
1532
+ }), window.requestAnimationFrame(function() {
1533
+ e.frame()
1534
+ }), e.options.callback(), e.events && e.events.trigger("danmaku_load_end")
1535
+ })
1536
+ }
1537
+ }, {
1538
+ key: "reload",
1539
+ value: function(e) {
1540
+ this.options.api = e, this.dan = [], this.clear(), this.load()
1541
+ }
1542
+ }, {
1543
+ key: "_readAllEndpoints",
1544
+ value: function(e, t) {
1545
+ for (var n = this, i = [], a = 0, o = 0; o < e.length; ++o) this.options.apiBackend.read(e[o], function(o) {
1546
+ return function(s, r) {
1547
+ if (++a, s) s.response ? n.options.error(s.response.msg) : n.options.error("弹幕加载失败:" + s.status), i[
1548
+ o] = [];
1549
+ else {
1550
+ var l = ["right", "top", "bottom"];
1551
+ i[o] = r ? r.map(function(e) {
1552
+ return {
1553
+ time: e[0],
1554
+ type: e[1],
1555
+ color: e[2],
1556
+ author: e[3],
1557
+ text: e[4],
1558
+ size: e[7]
1559
+ }
1560
+ }) : []
1561
+ }
1562
+ if (a === e.length) return t(i)
1563
+ }
1564
+ }(o))
1565
+ }
1566
+ }, {
1567
+ key: "send",
1568
+ value: function(e, t) {
1569
+ var n = {
1570
+ token: this.options.api.token,
1571
+ player: this.options.api.id,
1572
+ author: this.options.api.user,
1573
+ time: this.options.time(),
1574
+ text: e.text,
1575
+ color: e.color,
1576
+ type: e.type,
1577
+ size: e.size
1578
+ };
1579
+ this.options.apiBackend.send(this.options.api.address, n, t), this.dan.splice(this.danIndex, 0, n), this.danIndex++;
1580
+ var i = {
1581
+ text: this.htmlEncode(n.text),
1582
+ color: n.color,
1583
+ type: n.type,
1584
+ size: n.size,
1585
+ border: "2px solid " + this.options.borderColor
1586
+ };
1587
+ this.draw(i), this.events && this.events.trigger("danmaku_send", n)
1588
+ }
1589
+ }, {
1590
+ key: "frame",
1591
+ value: function() {
1592
+ var e = this;
1593
+ if (this.dan.length && !this.paused && this.showing) {
1594
+ for (var t = this.dan[this.danIndex], n = []; t && this.options.time() > parseFloat(t.time);) n.push(t),
1595
+ t = this.dan[++this.danIndex];
1596
+ this.draw(n)
1597
+ }
1598
+ window.requestAnimationFrame(function() {
1599
+ e.frame()
1600
+ })
1601
+ }
1602
+ }, {
1603
+ key: "opacity",
1604
+ value: function(e) {
1605
+ if (void 0 !== e) {
1606
+ for (var t = this.container.getElementsByClassName("yzmplayer-danmaku-item"), n = 0; n < t.length; n++) t[
1607
+ n].style.opacity = e;
1608
+ this._opacity = e, this.events && this.events.trigger("danmaku_opacity", this._opacity)
1609
+ }
1610
+ return this._opacity
1611
+ }
1612
+ }, {
1613
+ key: "draw",
1614
+ value: function(e) {
1615
+ var t = this;
1616
+ if (this.showing) {
1617
+ var n = this.options.height,
1618
+ i = this.container.offsetWidth,
1619
+ o = this.container.offsetHeight,
1620
+ s = parseInt(o / n),
1621
+ r = function(e) {
1622
+ var n = e.offsetWidth || parseInt(e.style.width),
1623
+ i = e.getBoundingClientRect().right || t.container.getBoundingClientRect().right + n;
1624
+ return t.container.getBoundingClientRect().right - i
1625
+ },
1626
+ l = function(e) {
1627
+ return (i + e) / 5
1628
+ },
1629
+ c = function(e, n, o) {
1630
+ for (var c = i / l(o), u = 0; t.unlimited || u < s; u++) {
1631
+ var d = function(a) {
1632
+ var o = t.danTunnel[n][a + ""];
1633
+ if (!o || !o.length) return t.danTunnel[n][a + ""] = [e], e.addEventListener("animationend",
1634
+ function() {
1635
+ t.danTunnel[n][a + ""].splice(0, 1)
1636
+ }), {
1637
+ v: a % s
1638
+ };
1639
+ if ("right" !== n) return "continue";
1640
+ for (var u = 0; u < o.length; u++) {
1641
+ var d = r(o[u]) - 10;
1642
+ if (d <= i - c * l(parseInt(o[u].style.width)) || d <= 0) break;
1643
+ if (u === o.length - 1) return t.danTunnel[n][a + ""].push(e), e.addEventListener("animationend",
1644
+ function() {
1645
+ t.danTunnel[n][a + ""].splice(0, 1)
1646
+ }), {
1647
+ v: a % s
1648
+ }
1649
+ }
1650
+ }(u);
1651
+ switch (d) {
1652
+ case "continue":
1653
+ continue;
1654
+ default:
1655
+ if ("object" === (void 0 === d ? "undefined" : a(d))) return d.v
1656
+ }
1657
+ }
1658
+ return -1
1659
+ };
1660
+ "[object Array]" !== Object.prototype.toString.call(e) && (e = [e]);
1661
+ for (var u = document.createDocumentFragment(), d = 0; d < e.length; d++) ! function(a) {
1662
+ e[a].type || (e[a].type = "right"), e[a].color || (e[a].color = "#fff");
1663
+ e[a].size || (e[a].fontSize = "27.5px");
1664
+ var o = document.createElement("div");
1665
+ o.classList.add("yzmplayer-danmaku-item"), o.classList.add("yzmplayer-danmaku-" + e[a].type), e[a].border ?
1666
+ o.innerHTML = '<span style="border-bottom:' + e[a].border + '">' + e[a].text + "</span>" : o.innerHTML =
1667
+ e[a].text, o.style.opacity = t._opacity, o.style.color = e[a].color, o.style.fontSize = e[a].size, o.addEventListener(
1668
+ "animationend",
1669
+ function() {
1670
+ t.container.removeChild(o)
1671
+ });
1672
+ var s = t._measure(e[a].text),
1673
+ r = void 0;
1674
+ switch (e[a].type) {
1675
+ case "right":
1676
+ r = c(o, e[a].type, s), r >= 0 && (o.style.width = s + 1 + "px", o.style.top = n * r + "px", o.style
1677
+ .transform = "translateX(-" + i + "px)");
1678
+ break;
1679
+ case "top":
1680
+ r = c(o, e[a].type), r >= 0 && (o.style.top = n * r + "px");
1681
+ break;
1682
+ case "bottom":
1683
+ r = c(o, e[a].type), r >= 0 && (o.style.bottom = n * r + "px");
1684
+ break;
1685
+ default:
1686
+ console.error("Can't handled danmaku type: " + e[a].type)
1687
+ }
1688
+ r >= 0 && (o.classList.add("yzmplayer-danmaku-move"), u.appendChild(o))
1689
+ }(d);
1690
+ return this.container.appendChild(u), u
1691
+ }
1692
+ }
1693
+ }, {
1694
+ key: "play",
1695
+ value: function() {
1696
+ this.paused = !1
1697
+ }
1698
+ }, {
1699
+ key: "pause",
1700
+ value: function() {
1701
+ this.paused = !0
1702
+ }
1703
+ }, {
1704
+ key: "_measure",
1705
+ value: function(e) {
1706
+ if (!this.context) {
1707
+ var t = getComputedStyle(this.container.getElementsByClassName("yzmplayer-danmaku-item")[0], null);
1708
+ this.context = document.createElement("canvas").getContext("2d"), this.context.font = t.getPropertyValue(
1709
+ "font")
1710
+ }
1711
+ return this.context.measureText(e).width
1712
+ }
1713
+ }, {
1714
+ key: "seek",
1715
+ value: function() {
1716
+ this.clear();
1717
+ for (var e = 0; e < this.dan.length; e++) {
1718
+ if (this.dan[e].time >= this.options.time()) {
1719
+ this.danIndex = e;
1720
+ break
1721
+ }
1722
+ this.danIndex = this.dan.length
1723
+ }
1724
+ }
1725
+ }, {
1726
+ key: "clear",
1727
+ value: function() {
1728
+ this.danTunnel = {
1729
+ right: {},
1730
+ top: {},
1731
+ bottom: {}
1732
+ }, this.danIndex = 0, this.options.container.innerHTML = "", this.events && this.events.trigger(
1733
+ "danmaku_clear")
1734
+ }
1735
+ }, {
1736
+ key: "htmlEncode",
1737
+ value: function(e) {
1738
+ return e.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(
1739
+ /'/g, "&#x27;").replace(/\//g, "&#x2f;")
1740
+ }
1741
+ }, {
1742
+ key: "resize",
1743
+ value: function() {
1744
+ for (var e = this.container.offsetWidth, t = this.container.getElementsByClassName(
1745
+ "yzmplayer-danmaku-item"), n = 0; n < t.length; n++) t[n].style.transform = "translateX(-" + e + "px)"
1746
+ }
1747
+ }, {
1748
+ key: "hide",
1749
+ value: function() {
1750
+ this.showing = !1, this.pause(), this.clear(), this.events && this.events.trigger("danmaku_hide")
1751
+ }
1752
+ }, {
1753
+ key: "show",
1754
+ value: function() {
1755
+ this.seek(), this.showing = !0, this.play(), this.events && this.events.trigger("danmaku_show")
1756
+ }
1757
+ }, {
1758
+ key: "unlimit",
1759
+ value: function(e) {
1760
+ this.unlimited = e
1761
+ }
1762
+ }]), e
1763
+ }();
1764
+ t.default = s
1765
+ },
1766
+ function(e, t, n) {
1767
+ "use strict";
1768
+
1769
+ function i(e, t) {
1770
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
1771
+ }
1772
+ Object.defineProperty(t, "__esModule", {
1773
+ value: !0
1774
+ });
1775
+ var a = function() {
1776
+ function e(e, t) {
1777
+ for (var n = 0; n < t.length; n++) {
1778
+ var i = t[n];
1779
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
1780
+ e, i.key, i)
1781
+ }
1782
+ }
1783
+ return function(t, n, i) {
1784
+ return n && e(t.prototype, n), i && e(t, i), t
1785
+ }
1786
+ }(),
1787
+ o = function() {
1788
+ function e() {
1789
+ i(this, e), this.events = {}, this.videoEvents = ["abort", "canplay", "canplaythrough", "durationchange",
1790
+ "emptied", "ended", "error", "loadeddata", "loadedmetadata", "loadstart", "mozaudioavailable", "pause",
1791
+ "play", "playing", "progress", "ratechange", "seeked", "seeking", "stalled", "suspend", "timeupdate",
1792
+ "volumechange", "waiting"
1793
+ ], this.playerEvents = ["screenshot", "thumbnails_show", "thumbnails_hide", "danmaku_show", "danmaku_hide",
1794
+ "danmaku_clear", "danmaku_loaded", "danmaku_send", "danmaku_opacity", "contextmenu_show", "contextmenu_hide",
1795
+ "notice_show", "notice_hide", "quality_start", "quality_end", "destroy", "resize", "fullscreen",
1796
+ "fullscreen_cancel", "webfullscreen", "webfullscreen_cancel", "subtitle_show", "subtitle_hide",
1797
+ "subtitle_change"
1798
+ ]
1799
+ }
1800
+ return a(e, [{
1801
+ key: "on",
1802
+ value: function(e, t) {
1803
+ this.type(e) && "function" == typeof t && (this.events[e] || (this.events[e] = []), this.events[e].push(t))
1804
+ }
1805
+ }, {
1806
+ key: "trigger",
1807
+ value: function(e, t) {
1808
+ if (this.events[e] && this.events[e].length)
1809
+ for (var n = 0; n < this.events[e].length; n++) this.events[e][n](t)
1810
+ }
1811
+ }, {
1812
+ key: "type",
1813
+ value: function(e) {
1814
+ return -1 !== this.playerEvents.indexOf(e) ? "player" : -1 !== this.videoEvents.indexOf(e) ? "video" : (
1815
+ console.error("Unknown event name: " + e), null)
1816
+ }
1817
+ }]), e
1818
+ }();
1819
+ t.default = o
1820
+ },
1821
+ function(e, t, n) {
1822
+ "use strict";
1823
+
1824
+ function i(e, t) {
1825
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
1826
+ }
1827
+ Object.defineProperty(t, "__esModule", {
1828
+ value: !0
1829
+ });
1830
+ var a = function() {
1831
+ function e(e, t) {
1832
+ for (var n = 0; n < t.length; n++) {
1833
+ var i = t[n];
1834
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
1835
+ e, i.key, i)
1836
+ }
1837
+ }
1838
+ return function(t, n, i) {
1839
+ return n && e(t.prototype, n), i && e(t, i), t
1840
+ }
1841
+ }(),
1842
+ o = n(0),
1843
+ s = function(e) {
1844
+ return e && e.__esModule ? e : {
1845
+ default: e
1846
+ }
1847
+ }(o),
1848
+ r = function() {
1849
+ function e(t) {
1850
+ var n = this;
1851
+ i(this, e), this.player = t, this.player.events.on("webfullscreen", function() {
1852
+ n.player.resize()
1853
+ }), this.player.events.on("webfullscreen_cancel", function() {
1854
+ n.player.resize(), s.default.setScrollPosition(n.lastScrollPosition)
1855
+ });
1856
+ var a = function() {
1857
+ n.player.resize(), n.isFullScreen("browser") ? n.player.events.trigger("fullscreen") : (s.default.setScrollPosition(
1858
+ n.lastScrollPosition), n.player.events.trigger("fullscreen_cancel"))
1859
+ };
1860
+ this.player.container.addEventListener("fullscreenchange", a), this.player.container.addEventListener(
1861
+ "mozfullscreenchange", a), this.player.container.addEventListener("webkitfullscreenchange", a)
1862
+ }
1863
+ return a(e, [{
1864
+ key: "isFullScreen",
1865
+ value: function() {
1866
+ switch (arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "browser") {
1867
+ case "browser":
1868
+ return document.fullscreenElement || document.mozFullScreenElement || document.webkitFullscreenElement;
1869
+ case "web":
1870
+ return this.player.container.classList.contains("yzmplayer-fulled")
1871
+ }
1872
+ }
1873
+ }, {
1874
+ key: "request",
1875
+ value: function() {
1876
+ var e = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "browser",
1877
+ t = "browser" === e ? "web" : "browser",
1878
+ n = this.isFullScreen(t);
1879
+ switch (n || (this.lastScrollPosition = s.default.getScrollPosition()), e) {
1880
+ case "browser":
1881
+ this.player.container.requestFullscreen ? this.player.container.requestFullscreen() : this.player.container
1882
+ .mozRequestFullScreen ? this.player.container.mozRequestFullScreen() : this.player.container.webkitRequestFullscreen ?
1883
+ this.player.container.webkitRequestFullscreen() : this.player.video.webkitEnterFullscreen && this.player
1884
+ .video.webkitEnterFullscreen();
1885
+ break;
1886
+ case "web":
1887
+ this.player.container.classList.add("yzmplayer-fulled"), document.body.classList.add(
1888
+ "yzmplayer-web-fullscreen-fix"), this.player.events.trigger("webfullscreen")
1889
+ }
1890
+ n && this.cancel(t)
1891
+ }
1892
+ }, {
1893
+ key: "cancel",
1894
+ value: function() {
1895
+ switch (arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "browser") {
1896
+ case "browser":
1897
+ document.cancelFullScreen ? document.cancelFullScreen() : document.mozCancelFullScreen ? document.mozCancelFullScreen() :
1898
+ document.webkitCancelFullScreen && document.webkitCancelFullScreen();
1899
+ break;
1900
+ case "web":
1901
+ this.player.container.classList.remove("yzmplayer-fulled"), document.body.classList.remove(
1902
+ "yzmplayer-web-fullscreen-fix"), this.player.events.trigger("webfullscreen_cancel")
1903
+ }
1904
+ }
1905
+ }, {
1906
+ key: "toggle",
1907
+ value: function() {
1908
+ var e = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "browser";
1909
+ this.isFullScreen(e) ? this.cancel(e) : this.request(e)
1910
+ }
1911
+ }]), e
1912
+ }();
1913
+ t.default = r
1914
+ },
1915
+ function(e, t, n) {
1916
+ "use strict";
1917
+
1918
+ function i(e, t) {
1919
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
1920
+ }
1921
+ Object.defineProperty(t, "__esModule", {
1922
+ value: !0
1923
+ });
1924
+ var a = function() {
1925
+ function e(e, t) {
1926
+ for (var n = 0; n < t.length; n++) {
1927
+ var i = t[n];
1928
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
1929
+ e, i.key, i)
1930
+ }
1931
+ }
1932
+ return function(t, n, i) {
1933
+ return n && e(t.prototype, n), i && e(t, i), t
1934
+ }
1935
+ }(),
1936
+ o = n(0),
1937
+ s = function(e) {
1938
+ return e && e.__esModule ? e : {
1939
+ default: e
1940
+ }
1941
+ }(o),
1942
+ r = function() {
1943
+ function e(t) {
1944
+ i(this, e), this.storageName = {
1945
+ opacity: "yzmplayer-danmaku-opacity",
1946
+ volume: "yzmplayer-volume",
1947
+ unlimited: "yzmplayer-danmaku-unlimited",
1948
+ danmaku: "yzmplayer-danmaku-show",
1949
+ subtitle: "yzmplayer-subtitle-show"
1950
+ }, this.default = {
1951
+ opacity: .7,
1952
+ volume: t.options.volume || .7,
1953
+ unlimited: (t.options.danmaku && t.options.danmaku.unlimited ? 1 : 0) || 0,
1954
+ danmaku: 1,
1955
+ subtitle: 1
1956
+ }, this.data = {}, this.init()
1957
+ }
1958
+ return a(e, [{
1959
+ key: "init",
1960
+ value: function() {
1961
+ for (var e in this.storageName) {
1962
+ var t = this.storageName[e];
1963
+ this.data[e] = parseFloat(s.default.storage.get(t) || this.default[e])
1964
+ }
1965
+ }
1966
+ }, {
1967
+ key: "get",
1968
+ value: function(e) {
1969
+ return this.data[e]
1970
+ }
1971
+ }, {
1972
+ key: "set",
1973
+ value: function(e, t) {
1974
+ this.data[e] = t, s.default.storage.set(this.storageName[e], t)
1975
+ }
1976
+ }]), e
1977
+ }();
1978
+ t.default = r
1979
+ },
1980
+ function(e, t, n) {
1981
+ "use strict";
1982
+
1983
+ function i(e, t) {
1984
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
1985
+ }
1986
+ Object.defineProperty(t, "__esModule", {
1987
+ value: !0
1988
+ });
1989
+ var a = function() {
1990
+ function e(e, t) {
1991
+ for (var n = 0; n < t.length; n++) {
1992
+ var i = t[n];
1993
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
1994
+ e, i.key, i)
1995
+ }
1996
+ }
1997
+ return function(t, n, i) {
1998
+ return n && e(t.prototype, n), i && e(t, i), t
1999
+ }
2000
+ }(),
2001
+ o = function() {
2002
+ function e(t, n, a, o) {
2003
+ i(this, e), this.container = t, this.video = n, this.options = a, this.events = o, this.init()
2004
+ }
2005
+ return a(e, [{
2006
+ key: "init",
2007
+ value: function() {
2008
+ var e = this;
2009
+ if (this.container.style.fontSize = this.options.fontSize, this.container.style.bottom = this.options.bottom,
2010
+ this.container.style.color = this.options.color, this.video.textTracks && this.video.textTracks[0]) {
2011
+ var t = this.video.textTracks[0];
2012
+ t.oncuechange = function() {
2013
+ var n = t.activeCues[0];
2014
+ if (n) {
2015
+ e.container.innerHTML = "";
2016
+ var i = document.createElement("p");
2017
+ i.appendChild(n.getCueAsHTML()), e.container.appendChild(i)
2018
+ } else e.container.innerHTML = "";
2019
+ e.events.trigger("subtitle_change")
2020
+ }
2021
+ }
2022
+ }
2023
+ }, {
2024
+ key: "show",
2025
+ value: function() {
2026
+ this.container.classList.remove("yzmplayer-subtitle-hide"), this.events.trigger("subtitle_show")
2027
+ }
2028
+ }, {
2029
+ key: "hide",
2030
+ value: function() {
2031
+ this.container.classList.add("yzmplayer-subtitle-hide"), this.events.trigger("subtitle_hide")
2032
+ }
2033
+ }, {
2034
+ key: "toggle",
2035
+ value: function() {
2036
+ this.container.classList.contains("yzmplayer-subtitle-hide") ? this.show() : this.hide()
2037
+ }
2038
+ }]), e
2039
+ }();
2040
+ t.default = o
2041
+ },
2042
+ function(e, t, n) {
2043
+ "use strict";
2044
+
2045
+ function i(e, t) {
2046
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
2047
+ }
2048
+ Object.defineProperty(t, "__esModule", {
2049
+ value: !0
2050
+ });
2051
+ var a = function() {
2052
+ function e(e, t) {
2053
+ for (var n = 0; n < t.length; n++) {
2054
+ var i = t[n];
2055
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
2056
+ e, i.key, i)
2057
+ }
2058
+ }
2059
+ return function(t, n, i) {
2060
+ return n && e(t.prototype, n), i && e(t, i), t
2061
+ }
2062
+ }(),
2063
+ o = function() {
2064
+ function e(t) {
2065
+ i(this, e), this.elements = {}, this.elements.volume = t.volumeBar, this.elements.played = t.playedBar, this.elements
2066
+ .loaded = t.loadedBar, this.elements.danmaku = t.danmakuOpacityBar
2067
+ }
2068
+ return a(e, [{
2069
+ key: "set",
2070
+ value: function(e, t, n) {
2071
+ t = Math.max(t, 0), t = Math.min(t, 1), this.elements[e].style[n] = 100 * t + "%"
2072
+ }
2073
+ }, {
2074
+ key: "get",
2075
+ value: function(e) {
2076
+ return parseFloat(this.elements[e].style.width) / 100
2077
+ }
2078
+ }]), e
2079
+ }();
2080
+ t.default = o
2081
+ },
2082
+ function(e, t, n) {
2083
+ "use strict";
2084
+
2085
+ function i(e, t) {
2086
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
2087
+ }
2088
+ Object.defineProperty(t, "__esModule", {
2089
+ value: !0
2090
+ });
2091
+ var a = function() {
2092
+ function e(e, t) {
2093
+ for (var n = 0; n < t.length; n++) {
2094
+ var i = t[n];
2095
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
2096
+ e, i.key, i)
2097
+ }
2098
+ }
2099
+ return function(t, n, i) {
2100
+ return n && e(t.prototype, n), i && e(t, i), t
2101
+ }
2102
+ }(),
2103
+ o = n(0),
2104
+ s = function(e) {
2105
+ return e && e.__esModule ? e : {
2106
+ default: e
2107
+ }
2108
+ }(o),
2109
+ r = function() {
2110
+ function e(t) {
2111
+ i(this, e), this.player = t, window.requestAnimationFrame = function() {
2112
+ return window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame ||
2113
+ window.oRequestAnimationFrame || window.msRequestAnimationFrame || function(e) {
2114
+ window.setTimeout(e, 1e3 / 60)
2115
+ }
2116
+ }(), this.types = ["loading", "progress", "info", "fps"], this.init()
2117
+ }
2118
+ return a(e, [{
2119
+ key: "init",
2120
+ value: function() {
2121
+ for (var e = 0; e < this.types.length; e++) {
2122
+ var t = this.types[e];
2123
+ "fps" !== t && this["init" + t + "Checker"]()
2124
+ }
2125
+ }
2126
+ }, {
2127
+ key: "initloadingChecker",
2128
+ value: function() {
2129
+ var e = this,
2130
+ t = 0,
2131
+ n = 0,
2132
+ i = !1;
2133
+ this.loadingChecker = setInterval(function() {
2134
+ e.enableloadingChecker && (n = e.player.video.currentTime, i || n !== t || e.player.video.paused || (e
2135
+ .player.container.classList.add("yzmplayer-loading"), i = !0), i && n > t && !e.player.video.paused &&
2136
+ (e.player.container.classList.remove("yzmplayer-loading"), i = !1), t = n)
2137
+ }, 100)
2138
+ }
2139
+ }, {
2140
+ key: "initprogressChecker",
2141
+ value: function() {
2142
+ var e = this;
2143
+ this.progressChecker = setInterval(function() {
2144
+ if (e.enableprogressChecker) {
2145
+ e.player.bar.set("played", e.player.video.currentTime / e.player.video.duration, "width");
2146
+ var t = s.default.secondToTime(e.player.video.currentTime);
2147
+ e.player.template.ptime.innerHTML !== t && (e.player.template.ptime.innerHTML = s.default.secondToTime(
2148
+ e.player.video.currentTime))
2149
+ }
2150
+ }, 100)
2151
+ }
2152
+ }, {
2153
+ key: "initfpsChecker",
2154
+ value: function() {
2155
+ var e = this;
2156
+ window.requestAnimationFrame(function() {
2157
+ if (e.enablefpsChecker)
2158
+ if (e.initfpsChecker(), e.fpsStart) {
2159
+ e.fpsIndex++;
2160
+ var t = new Date;
2161
+ t - e.fpsStart > 1e3 && (e.player.infoPanel.fps(e.fpsIndex / (t - e.fpsStart) * 1e3), e.fpsStart =
2162
+ new Date, e.fpsIndex = 0)
2163
+ } else e.fpsStart = new Date, e.fpsIndex = 0;
2164
+ else e.fpsStart = 0, e.fpsIndex = 0
2165
+ })
2166
+ }
2167
+ }, {
2168
+ key: "initinfoChecker",
2169
+ value: function() {
2170
+ var e = this;
2171
+ this.infoChecker = setInterval(function() {
2172
+ e.enableinfoChecker && e.player.infoPanel.update()
2173
+ }, 1e3)
2174
+ }
2175
+ }, {
2176
+ key: "enable",
2177
+ value: function(e) {
2178
+ this["enable" + e + "Checker"] = !0, "fps" === e && this.initfpsChecker()
2179
+ }
2180
+ }, {
2181
+ key: "disable",
2182
+ value: function(e) {
2183
+ this["enable" + e + "Checker"] = !1
2184
+ }
2185
+ }, {
2186
+ key: "destroy",
2187
+ value: function(e) {
2188
+ this[e + "Checker"] && clearInterval(this[e + "Checker"])
2189
+ }
2190
+ }]), e
2191
+ }();
2192
+ t.default = r
2193
+ },
2194
+ function(e, t, n) {
2195
+ "use strict";
2196
+
2197
+ function i(e, t) {
2198
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
2199
+ }
2200
+ Object.defineProperty(t, "__esModule", {
2201
+ value: !0
2202
+ });
2203
+ var a = function() {
2204
+ function e(e, t) {
2205
+ for (var n = 0; n < t.length; n++) {
2206
+ var i = t[n];
2207
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
2208
+ e, i.key, i)
2209
+ }
2210
+ }
2211
+ return function(t, n, i) {
2212
+ return n && e(t.prototype, n), i && e(t, i), t
2213
+ }
2214
+ }(),
2215
+ o = function() {
2216
+ function e(t) {
2217
+ var n = this;
2218
+ i(this, e), this.container = t, this.container.addEventListener("animationend", function() {
2219
+ n.container.classList.remove("yzmplayer-bezel-transition")
2220
+ })
2221
+ }
2222
+ return a(e, [{
2223
+ key: "switch",
2224
+ value: function(e) {
2225
+ this.container.innerHTML = e, this.container.classList.add("yzmplayer-bezel-transition")
2226
+ }
2227
+ }]), e
2228
+ }();
2229
+ t.default = o
2230
+ },
2231
+ function(e, t, n) {
2232
+ "use strict";
2233
+
2234
+ function i(e) {
2235
+ return e && e.__esModule ? e : {
2236
+ default: e
2237
+ }
2238
+ }
2239
+
2240
+ function a(e, t) {
2241
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
2242
+ }
2243
+ Object.defineProperty(t, "__esModule", {
2244
+ value: !0
2245
+ });
2246
+ var o = function() {
2247
+ function e(e, t) {
2248
+ for (var n = 0; n < t.length; n++) {
2249
+ var i = t[n];
2250
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
2251
+ e, i.key, i)
2252
+ }
2253
+ }
2254
+ return function(t, n, i) {
2255
+ return n && e(t.prototype, n), i && e(t, i), t
2256
+ }
2257
+ }(),
2258
+ s = n(0),
2259
+ r = i(s),
2260
+ l = n(44),
2261
+ c = i(l),
2262
+ u = n(2),
2263
+ d = i(u),
2264
+ p = function() {
2265
+ function e(t) {
2266
+ var n = this;
2267
+ a(this, e), this.player = t, this.autoHideTimer = 0, r.default.isMobile || (this.player.container.addEventListener(
2268
+ "mousemove",
2269
+ function() {
2270
+ n.setAutoHide()
2271
+ }), this.player.container.addEventListener("click", function() {
2272
+ n.setAutoHide()
2273
+ }), this.player.on("play", function() {
2274
+ n.setAutoHide()
2275
+ }), this.player.on("pause", function() {
2276
+ n.setAutoHide()
2277
+ })), this.initPlayButton(), this.initThumbnails(), this.initPlayedBar(), this.initFullButton(), this.initQualityButton(),
2278
+ this.initScreenshotButton(), this.initSubtitleButton(), r.default.isMobile || this.initVolumeButton()
2279
+ }
2280
+ return o(e, [{
2281
+ key: "initPlayButton",
2282
+ value: function() {
2283
+ var e = this;
2284
+ this.player.template.playButton.addEventListener("click", function() {
2285
+ e.player.toggle()
2286
+ }), r.default.isMobile ? (this.player.template.videoWrap.addEventListener("click", function() {
2287
+ e.toggle()
2288
+ }), this.player.template.controllerMask.addEventListener("click", function() {
2289
+ e.toggle()
2290
+ })) : (this.player.template.videoWrap.addEventListener("click", function() {
2291
+ e.player.toggle()
2292
+ }), this.player.template.controllerMask.addEventListener("click", function() {
2293
+ e.player.toggle()
2294
+ }))
2295
+ }
2296
+ }, {
2297
+ key: "initThumbnails",
2298
+ value: function() {
2299
+ var e = this;
2300
+ this.player.options.video.thumbnails && (this.thumbnails = new c.default({
2301
+ container: this.player.template.barPreview,
2302
+ barWidth: this.player.template.barWrap.offsetWidth,
2303
+ url: this.player.options.video.thumbnails,
2304
+ events: this.player.events
2305
+ }), this.player.on("loadedmetadata", function() {
2306
+ e.thumbnails.resize(160, e.player.video.videoHeight / e.player.video.videoWidth * 160)
2307
+ }))
2308
+ }
2309
+ }, {
2310
+ key: "initPlayedBar",
2311
+ value: function() {
2312
+ var e = this,
2313
+ t = function(t) {
2314
+ var n = ((t.clientX || t.changedTouches[0].clientX) - r.default.getElementViewLeft(e.player.template.playedBarWrap)) /
2315
+ e.player.template.playedBarWrap.clientWidth;
2316
+ n = Math.max(n, 0), n = Math.min(n, 1), e.player.bar.set("played", n, "width"), e.player.template.ptime
2317
+ .innerHTML = r.default.secondToTime(n * e.player.video.duration)
2318
+ },
2319
+ n = function n(i) {
2320
+ document.removeEventListener(r.default.nameMap.dragEnd, n), document.removeEventListener(r.default.nameMap
2321
+ .dragMove, t);
2322
+ var a = ((i.clientX || i.changedTouches[0].clientX) - r.default.getElementViewLeft(e.player.template.playedBarWrap)) /
2323
+ e.player.template.playedBarWrap.clientWidth;
2324
+ a = Math.max(a, 0), a = Math.min(a, 1), e.player.bar.set("played", a, "width"), e.player.seek(e.player.bar
2325
+ .get("played") * e.player.video.duration), e.player.time.enable("progress")
2326
+ };
2327
+ this.player.template.playedBarWrap.addEventListener(r.default.nameMap.dragStart, function() {
2328
+ e.player.time.disable("progress"), document.addEventListener(r.default.nameMap.dragMove, t), document.addEventListener(
2329
+ r.default.nameMap.dragEnd, n)
2330
+ }), this.player.template.playedBarWrap.addEventListener(r.default.nameMap.dragMove, function(t) {
2331
+ if (e.player.video.duration) {
2332
+ var n = r.default.cumulativeOffset(e.player.template.playedBarWrap).left,
2333
+ i = (t.clientX || t.changedTouches[0].clientX) - n;
2334
+ if (i < 0 || i > e.player.template.playedBarWrap.offsetWidth) return;
2335
+ var a = e.player.video.duration * (i / e.player.template.playedBarWrap.offsetWidth);
2336
+ r.default.isMobile && e.thumbnails && e.thumbnails.show(), e.thumbnails && e.thumbnails.move(i), e.player
2337
+ .template.playedBarTime.style.left = i - 20 + "px", e.player.template.playedBarTime.innerText = r.default
2338
+ .secondToTime(a), e.player.template.playedBarTime.classList.remove("hidden")
2339
+ }
2340
+ }), this.player.template.playedBarWrap.addEventListener(r.default.nameMap.dragEnd, function() {
2341
+ r.default.isMobile && e.thumbnails && e.thumbnails.hide()
2342
+ }), r.default.isMobile || (this.player.template.playedBarWrap.addEventListener("mouseenter", function() {
2343
+ e.player.video.duration && (e.thumbnails && e.thumbnails.show(), e.player.template.playedBarTime.classList
2344
+ .remove("hidden"))
2345
+ }), this.player.template.playedBarWrap.addEventListener("mouseleave", function() {
2346
+ e.player.video.duration && (e.thumbnails && e.thumbnails.hide(), e.player.template.playedBarTime.classList
2347
+ .add("hidden"))
2348
+ }))
2349
+ }
2350
+ }, {
2351
+ key: "initFullButton",
2352
+ value: function() {
2353
+ var e = this;
2354
+ this.player.template.browserFullButton.addEventListener("click", function() {
2355
+ e.player.fullScreen.toggle("browser")
2356
+ }), this.player.template.webFullButton.addEventListener("click", function() {
2357
+ e.player.fullScreen.toggle("web")
2358
+ })
2359
+ }
2360
+ }, {
2361
+ key: "initVolumeButton",
2362
+ value: function() {
2363
+ var e = this,
2364
+ t = function(t) {
2365
+ var n = t || window.event,
2366
+ i = ((n.clientX || n.changedTouches[0].clientX) - r.default.getElementViewLeft(e.player.template.volumeBarWrap) -
2367
+ 5.5) / 35;
2368
+ e.player.volume(i)
2369
+ },
2370
+ n = function n() {
2371
+ document.removeEventListener(r.default.nameMap.dragEnd, n), document.removeEventListener(r.default.nameMap
2372
+ .dragMove, t), e.player.template.volumeButton.classList.remove("yzmplayer-volume-active")
2373
+ };
2374
+ this.player.template.volumeBarWrapWrap.addEventListener("click", function(t) {
2375
+ var n = t || window.event,
2376
+ i = ((n.clientX || n.changedTouches[0].clientX) - r.default.getElementViewLeft(e.player.template.volumeBarWrap) -
2377
+ 5.5) / 35;
2378
+ e.player.volume(i)
2379
+ }), this.player.template.volumeBarWrapWrap.addEventListener(r.default.nameMap.dragStart, function() {
2380
+ document.addEventListener(r.default.nameMap.dragMove, t), document.addEventListener(r.default.nameMap.dragEnd,
2381
+ n), e.player.template.volumeButton.classList.add("yzmplayer-volume-active")
2382
+ }), this.player.template.volumeIcon.addEventListener("click", function() {
2383
+ e.player.video.muted ? (e.player.video.muted = !1, e.player.switchVolumeIcon(), e.player.bar.set(
2384
+ "volume", e.player.volume(), "width")) : (e.player.video.muted = !0, e.player.template.volumeIcon.innerHTML =
2385
+ d.default.volumeOff, e.player.bar.set("volume", 0, "width"))
2386
+ })
2387
+ }
2388
+ }, {
2389
+ key: "initQualityButton",
2390
+ value: function() {
2391
+ var e = this;
2392
+ this.player.options.video.quality && this.player.template.qualityList.addEventListener("click", function(
2393
+ t) {
2394
+ t.target.classList.contains("yzmplayer-quality-item") && e.player.switchQuality(t.target.dataset.index)
2395
+ })
2396
+ }
2397
+ }, {
2398
+ key: "initScreenshotButton",
2399
+ value: function() {
2400
+ var e = this;
2401
+ this.player.options.screenshot && this.player.template.camareButton.addEventListener("click", function() {
2402
+ var t = document.createElement("canvas");
2403
+ t.width = e.player.video.videoWidth, t.height = e.player.video.videoHeight, t.getContext("2d").drawImage(
2404
+ e.player.video, 0, 0, t.width, t.height);
2405
+ var n = t.toDataURL();
2406
+ e.player.template.camareButton.href = n, e.player.template.camareButton.download = "yzmplayer.png", e.player
2407
+ .events.trigger("screenshot", n)
2408
+ })
2409
+ }
2410
+ }, {
2411
+ key: "initSubtitleButton",
2412
+ value: function() {
2413
+ var e = this;
2414
+ this.player.options.subtitle && (this.player.events.on("subtitle_show", function() {
2415
+ e.player.template.subtitleButton.dataset.balloon = e.player.tran("Hide subtitle"), e.player.template.subtitleButtonInner
2416
+ .style.opacity = "", e.player.user.set("subtitle", 1)
2417
+ }), this.player.events.on("subtitle_hide", function() {
2418
+ e.player.template.subtitleButton.dataset.balloon = e.player.tran("Show subtitle"), e.player.template.subtitleButtonInner
2419
+ .style.opacity = "0.4", e.player.user.set("subtitle", 0)
2420
+ }), this.player.template.subtitleButton.addEventListener("click", function() {
2421
+ e.player.subtitle.toggle()
2422
+ }))
2423
+ }
2424
+ }, {
2425
+ key: "setAutoHide",
2426
+ value: function() {
2427
+ var e = this;
2428
+ this.show(), clearTimeout(this.autoHideTimer), this.autoHideTimer = setTimeout(function() {
2429
+ !e.player.video.played.length || e.player.paused || e.disableAutoHide || e.hide()
2430
+ }, 3e3)
2431
+ }
2432
+ }, {
2433
+ key: "show",
2434
+ value: function() {
2435
+ this.player.container.classList.remove("yzmplayer-hide-controller")
2436
+ }
2437
+ }, {
2438
+ key: "hide",
2439
+ value: function() {
2440
+ this.player.container.classList.add("yzmplayer-hide-controller"), this.player.setting.hide(), this.player
2441
+ .comment && this.player.comment.hide()
2442
+ }
2443
+ }, {
2444
+ key: "isShow",
2445
+ value: function() {
2446
+ return !this.player.container.classList.contains("yzmplayer-hide-controller")
2447
+ }
2448
+ }, {
2449
+ key: "toggle",
2450
+ value: function() {
2451
+ this.isShow() ? this.hide() : this.show()
2452
+ }
2453
+ }, {
2454
+ key: "destroy",
2455
+ value: function() {
2456
+ clearTimeout(this.autoHideTimer)
2457
+ }
2458
+ }]), e
2459
+ }();
2460
+ t.default = p
2461
+ },
2462
+ function(e, t, n) {
2463
+ "use strict";
2464
+
2465
+ function i(e, t) {
2466
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
2467
+ }
2468
+ Object.defineProperty(t, "__esModule", {
2469
+ value: !0
2470
+ });
2471
+ var a = function() {
2472
+ function e(e, t) {
2473
+ for (var n = 0; n < t.length; n++) {
2474
+ var i = t[n];
2475
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
2476
+ e, i.key, i)
2477
+ }
2478
+ }
2479
+ return function(t, n, i) {
2480
+ return n && e(t.prototype, n), i && e(t, i), t
2481
+ }
2482
+ }(),
2483
+ o = function() {
2484
+ function e(t) {
2485
+ i(this, e), this.container = t.container, this.barWidth = t.barWidth, this.container.style.backgroundImage =
2486
+ "url('" + t.url + "')", this.events = t.events
2487
+ }
2488
+ return a(e, [{
2489
+ key: "resize",
2490
+ value: function(e, t) {
2491
+ this.container.style.width = e + "px", this.container.style.height = t + "px", this.container.style.top =
2492
+ 2 - t + "px"
2493
+ }
2494
+ }, {
2495
+ key: "show",
2496
+ value: function() {
2497
+ this.container.style.display = "block", this.events && this.events.trigger("thumbnails_show")
2498
+ }
2499
+ }, {
2500
+ key: "move",
2501
+ value: function(e) {
2502
+ this.container.style.backgroundPosition = "-" + 160 * (Math.ceil(e / this.barWidth * 100) - 1) + "px 0",
2503
+ this.container.style.left = e - this.container.offsetWidth / 2 + "px"
2504
+ }
2505
+ }, {
2506
+ key: "hide",
2507
+ value: function() {
2508
+ this.container.style.display = "none", this.events && this.events.trigger("thumbnails_hide")
2509
+ }
2510
+ }]), e
2511
+ }();
2512
+ t.default = o
2513
+ },
2514
+ function(e, t, n) {
2515
+ "use strict";
2516
+
2517
+ function i(e, t) {
2518
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
2519
+ }
2520
+ Object.defineProperty(t, "__esModule", {
2521
+ value: !0
2522
+ });
2523
+ var a = function() {
2524
+ function e(e, t) {
2525
+ for (var n = 0; n < t.length; n++) {
2526
+ var i = t[n];
2527
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
2528
+ e, i.key, i)
2529
+ }
2530
+ }
2531
+ return function(t, n, i) {
2532
+ return n && e(t.prototype, n), i && e(t, i), t
2533
+ }
2534
+ }(),
2535
+ o = n(0),
2536
+ s = function(e) {
2537
+ return e && e.__esModule ? e : {
2538
+ default: e
2539
+ }
2540
+ }(o),
2541
+ r = function() {
2542
+ function e(t) {
2543
+ var n = this;
2544
+ i(this, e), this.player = t, this.player.template.mask.addEventListener("click", function() {
2545
+ n.hide()
2546
+ }), this.player.template.settingButton.addEventListener("click", function() {
2547
+ n.show()
2548
+ }), this.loop = this.player.options.loop, this.player.template.loopToggle.checked = this.loop, this.player.template
2549
+ .loop.addEventListener("click", function() {
2550
+ n.player.template.loopToggle.checked = !n.player.template.loopToggle.checked, n.player.template.loopToggle.checked ?
2551
+ n.loop = !0 : n.loop = !1, n.hide()
2552
+ }), this.showDanmaku = this.player.user.get("danmaku"), this.showDanmaku || this.player.danmaku && this.player
2553
+ .danmaku.hide(), this.player.template.showDanmakuToggle.checked = this.showDanmaku, this.player.template.showDanmaku
2554
+ .addEventListener("click", function() {
2555
+ n.player.template.showDanmakuToggle.checked = !n.player.template.showDanmakuToggle.checked, n.player.template
2556
+ .showDanmakuToggle.checked ? (n.showDanmaku = !0, n.player.danmaku.show()) : (n.showDanmaku = !1, n.player
2557
+ .danmaku.hide()), n.player.user.set("danmaku", n.showDanmaku ? 1 : 0), n.hide()
2558
+ }), this.unlimitDanmaku = this.player.user.get("unlimited"), this.player.template.unlimitDanmakuToggle.checked =
2559
+ this.unlimitDanmaku, this.player.template.unlimitDanmaku.addEventListener("click", function() {
2560
+ n.player.template.unlimitDanmakuToggle.checked = !n.player.template.unlimitDanmakuToggle.checked, n.player.template
2561
+ .unlimitDanmakuToggle.checked ? (n.unlimitDanmaku = !0, n.player.danmaku.unlimit(!0)) : (n.unlimitDanmaku = !
2562
+ 1, n.player.danmaku.unlimit(!1)), n.player.user.set("unlimited", n.unlimitDanmaku ? 1 : 0), n.hide()
2563
+ }), this.player.template.speed.addEventListener("click", function() {
2564
+ n.player.template.settingBox.classList.add("yzmplayer-setting-box-narrow"), n.player.template.settingBox.classList
2565
+ .add("yzmplayer-setting-box-speed")
2566
+ });
2567
+ for (var a = 0; a < this.player.template.speedItem.length; a++) ! function(e) {
2568
+ n.player.template.speedItem[e].addEventListener("click", function() {
2569
+ n.player.speed(n.player.template.speedItem[e].dataset.speed), n.hide()
2570
+ })
2571
+ }(a);
2572
+ if (this.player.danmaku) {
2573
+ this.player.on("danmaku_opacity", function(e) {
2574
+ n.player.bar.set("danmaku", e, "width"), n.player.user.set("opacity", e)
2575
+ }), this.player.danmaku.opacity(this.player.user.get("opacity"));
2576
+ var o = function(e) {
2577
+ var t = e || window.event,
2578
+ i = ((t.clientX || t.changedTouches[0].clientX) - s.default.getElementViewLeft(n.player.template.danmakuOpacityBarWrap)) /
2579
+ 130;
2580
+ i = Math.max(i, 0), i = Math.min(i, 1), n.player.danmaku.opacity(i)
2581
+ },
2582
+ r = function e() {
2583
+ document.removeEventListener(s.default.nameMap.dragEnd, e), document.removeEventListener(s.default.nameMap.dragMove,
2584
+ o), n.player.template.danmakuOpacityBox.classList.remove("yzmplayer-setting-danmaku-active")
2585
+ };
2586
+ this.player.template.danmakuOpacityBarWrapWrap.addEventListener("click", function(e) {
2587
+ var t = e || window.event,
2588
+ i = ((t.clientX || t.changedTouches[0].clientX) - s.default.getElementViewLeft(n.player.template.danmakuOpacityBarWrap)) /
2589
+ 130;
2590
+ i = Math.max(i, 0), i = Math.min(i, 1), n.player.danmaku.opacity(i)
2591
+ }), this.player.template.danmakuOpacityBarWrapWrap.addEventListener(s.default.nameMap.dragStart, function() {
2592
+ document.addEventListener(s.default.nameMap.dragMove, o), document.addEventListener(s.default.nameMap.dragEnd,
2593
+ r), n.player.template.danmakuOpacityBox.classList.add("yzmplayer-setting-danmaku-active")
2594
+ })
2595
+ }
2596
+ }
2597
+ return a(e, [{
2598
+ key: "hide",
2599
+ value: function() {
2600
+ var e = this;
2601
+ this.player.template.settingBox.classList.remove("yzmplayer-setting-box-open"), this.player.template.mask
2602
+ .classList.remove("yzmplayer-mask-show"), setTimeout(function() {
2603
+ e.player.template.settingBox.classList.remove("yzmplayer-setting-box-narrow"), e.player.template.settingBox
2604
+ .classList.remove("yzmplayer-setting-box-speed")
2605
+ }, 300), this.player.controller.disableAutoHide = !1
2606
+ }
2607
+ }, {
2608
+ key: "show",
2609
+ value: function() {
2610
+ this.player.template.settingBox.classList.add("yzmplayer-setting-box-open"), this.player.template.mask.classList
2611
+ .add("yzmplayer-mask-show"), this.player.controller.disableAutoHide = !0
2612
+ }
2613
+ }]), e
2614
+ }();
2615
+ t.default = r
2616
+ },
2617
+ function(e, t, n) {
2618
+ "use strict";
2619
+
2620
+ function i(e, t) {
2621
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
2622
+ }
2623
+ Object.defineProperty(t, "__esModule", {
2624
+ value: !0
2625
+ });
2626
+ var a = function() {
2627
+ function e(e, t) {
2628
+ for (var n = 0; n < t.length; n++) {
2629
+ var i = t[n];
2630
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
2631
+ e, i.key, i)
2632
+ }
2633
+ }
2634
+ return function(t, n, i) {
2635
+ return n && e(t.prototype, n), i && e(t, i), t
2636
+ }
2637
+ }(),
2638
+ o = function() {
2639
+ function e(t) {
2640
+ var n = this;
2641
+ i(this, e), this.player = t, this.player.template.mask.addEventListener("click", function() {
2642
+ n.hide()
2643
+ }), this.player.template.commentButton.addEventListener("click", function() {
2644
+ n.show()
2645
+ }), this.player.template.yzmcomment.addEventListener("click", function() {
2646
+ n.show()
2647
+ }), this.player.template.commentSettingButton.addEventListener("click", function() {
2648
+ n.toggleSetting()
2649
+ }), this.player.template.commentColorSettingBox.addEventListener("click", function() {
2650
+ if (n.player.template.commentColorSettingBox.querySelector("input:checked+span")) {
2651
+ var e = n.player.template.commentColorSettingBox.querySelector("input:checked").value;
2652
+ n.player.template.commentSettingFill.style.fill = e, n.player.template.commentInput.style.color = e, n.player
2653
+ .template.commentSendFill.style.fill = e
2654
+ }
2655
+ }), this.player.template.commentInput.addEventListener("click", function() {
2656
+ n.hideSetting()
2657
+ }), this.player.template.commentInput.addEventListener("keydown", function(e) {
2658
+ 13 === (e || window.event).keyCode && n.send()
2659
+ }), this.player.template.commentSendButton.addEventListener("click", function() {
2660
+ n.send()
2661
+ })
2662
+ }
2663
+ return a(e, [{
2664
+ key: "show",
2665
+ value: function() {
2666
+ this.player.controller.disableAutoHide = !0, this.player.template.controller.classList.add(
2667
+ "yzmplayer-controller-comment"), this.player.template.mask.classList.add("yzmplayer-mask-show"), this.player
2668
+ .container.classList.add("yzmplayer-show-controller"), this.player.template.commentInput.focus()
2669
+ }
2670
+ }, {
2671
+ key: "hide",
2672
+ value: function() {
2673
+ this.player.template.controller.classList.remove("yzmplayer-controller-comment"), this.player.template.mask
2674
+ .classList.remove("yzmplayer-mask-show"), this.player.container.classList.remove(
2675
+ "yzmplayer-show-controller"), this.player.controller.disableAutoHide = !1, this.hideSetting()
2676
+ }
2677
+ }, {
2678
+ key: "showSetting",
2679
+ value: function() {
2680
+ this.player.template.commentSettingBox.classList.add("yzmplayer-comment-setting-open")
2681
+ }
2682
+ }, {
2683
+ key: "hideSetting",
2684
+ value: function() {
2685
+ this.player.template.commentSettingBox.classList.remove("yzmplayer-comment-setting-open")
2686
+ }
2687
+ }, {
2688
+ key: "toggleSetting",
2689
+ value: function() {
2690
+ this.player.template.commentSettingBox.classList.contains("yzmplayer-comment-setting-open") ? this.hideSetting() :
2691
+ this.showSetting()
2692
+ }
2693
+ }, {
2694
+ key: "send",
2695
+ value: function() {
2696
+ var e = this;
2697
+ if (this.player.template.commentInput.blur(), !this.player.template.commentInput.value.replace(
2698
+ /^\s+|\s+$/g, "")) return void this.player.notice(this.player.tran("Please input danmaku content!"));
2699
+ this.player.danmaku.send({
2700
+ text: this.player.template.commentInput.value,
2701
+ color: this.player.container.querySelector(".yzmplayer-comment-setting-color input:checked").value,
2702
+ type: this.player.container.querySelector(".yzmplayer-comment-setting-type input:checked").value,
2703
+ size: this.player.container.querySelector(".yzmplayer-comment-setting-font input:checked").value
2704
+ }, function() {
2705
+ e.player.template.commentInput.value = "", e.hide()
2706
+ })
2707
+ }
2708
+ }]), e
2709
+ }();
2710
+ t.default = o
2711
+ },
2712
+ function(e, t, n) {
2713
+ "use strict";
2714
+
2715
+ function i(e, t) {
2716
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
2717
+ }
2718
+ Object.defineProperty(t, "__esModule", {
2719
+ value: !0
2720
+ });
2721
+ var a = function e(t) {
2722
+ i(this, e), t.options.hotkey && document.addEventListener("keydown", function(e) {
2723
+ if (t.focus) {
2724
+ var n = document.activeElement.tagName.toUpperCase(),
2725
+ i = document.activeElement.getAttribute("contenteditable");
2726
+ if ("INPUT" !== n && "TEXTAREA" !== n && "" !== i && "true" !== i) {
2727
+ var a = e || window.event,
2728
+ o = void 0;
2729
+ switch (a.keyCode) {
2730
+ case 32:
2731
+ a.preventDefault(), t.toggle();
2732
+ break;
2733
+ case 37:
2734
+ a.preventDefault(), t.seek(t.video.currentTime - 5), t.controller.setAutoHide();
2735
+ break;
2736
+ case 39:
2737
+ a.preventDefault(), t.seek(t.video.currentTime + 5), t.controller.setAutoHide();
2738
+ break;
2739
+ case 38:
2740
+ a.preventDefault(), o = t.volume() + .1, t.volume(o);
2741
+ break;
2742
+ case 40:
2743
+ a.preventDefault(), o = t.volume() - .1, t.volume(o)
2744
+ }
2745
+ }
2746
+ }
2747
+ }), document.addEventListener("keydown", function(e) {
2748
+ switch ((e || window.event).keyCode) {
2749
+ case 27:
2750
+ t.fullScreen.isFullScreen("web") && t.fullScreen.cancel("web")
2751
+ }
2752
+ })
2753
+ };
2754
+ t.default = a
2755
+ },
2756
+ function(e, t, n) {
2757
+ "use strict";
2758
+
2759
+ function i(e) {
2760
+ if (Array.isArray(e)) {
2761
+ for (var t = 0, n = Array(e.length); t < e.length; t++) n[t] = e[t];
2762
+ return n
2763
+ }
2764
+ return Array.from(e)
2765
+ }
2766
+
2767
+ function a(e, t) {
2768
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
2769
+ }
2770
+ Object.defineProperty(t, "__esModule", {
2771
+ value: !0
2772
+ });
2773
+ var o = function() {
2774
+ function e(e, t) {
2775
+ for (var n = 0; n < t.length; n++) {
2776
+ var i = t[n];
2777
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
2778
+ e, i.key, i)
2779
+ }
2780
+ }
2781
+ return function(t, n, i) {
2782
+ return n && e(t.prototype, n), i && e(t, i), t
2783
+ }
2784
+ }(),
2785
+ s = function() {
2786
+ function e(t) {
2787
+ var n = this;
2788
+ a(this, e), this.player = t, [].concat(i(this.player.template.menuItem)).map(function(e, t) {
2789
+ return n.player.options.contextmenu[t].click && e.addEventListener("click", function() {
2790
+ n.player.options.contextmenu[t].click(n.player), n.hide()
2791
+ }), e
2792
+ }), this.player.container.addEventListener("contextmenu", function(e) {
2793
+ var t = e || window.event;
2794
+ t.preventDefault();
2795
+ var i = n.player.container.getBoundingClientRect();
2796
+ n.show(t.clientX - i.left, t.clientY - i.top), n.player.template.mask.addEventListener("click", function() {
2797
+ n.hide()
2798
+ })
2799
+ })
2800
+ }
2801
+ return o(e, [{
2802
+ key: "show",
2803
+ value: function(e, t) {
2804
+ this.player.template.menu.classList.add("yzmplayer-menu-show");
2805
+ var n = this.player.container.getBoundingClientRect();
2806
+ e + this.player.template.menu.offsetWidth >= n.width ? (this.player.template.menu.style.right = n.width -
2807
+ e + "px", this.player.template.menu.style.left = "initial") : (this.player.template.menu.style.left = e +
2808
+ "px", this.player.template.menu.style.right = "initial"), t + this.player.template.menu.offsetHeight >=
2809
+ n.height ? (this.player.template.menu.style.bottom = n.height - t + "px", this.player.template.menu.style
2810
+ .top = "initial") : (this.player.template.menu.style.top = t + "px", this.player.template.menu.style.bottom =
2811
+ "initial"), this.player.template.mask.classList.add("yzmplayer-mask-show"), this.player.events.trigger(
2812
+ "contextmenu_show")
2813
+ }
2814
+ }, {
2815
+ key: "hide",
2816
+ value: function() {
2817
+ this.player.template.mask.classList.remove("yzmplayer-mask-show"), this.player.template.menu.classList.remove(
2818
+ "yzmplayer-menu-show"), this.player.events.trigger("contextmenu_hide")
2819
+ }
2820
+ }]), e
2821
+ }();
2822
+ t.default = s
2823
+ },
2824
+ function(e, t, n) {
2825
+ "use strict";
2826
+
2827
+ function i(e, t) {
2828
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
2829
+ }
2830
+ Object.defineProperty(t, "__esModule", {
2831
+ value: !0
2832
+ });
2833
+ var a = function() {
2834
+ function e(e, t) {
2835
+ for (var n = 0; n < t.length; n++) {
2836
+ var i = t[n];
2837
+ i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(
2838
+ e, i.key, i)
2839
+ }
2840
+ }
2841
+ return function(t, n, i) {
2842
+ return n && e(t.prototype, n), i && e(t, i), t
2843
+ }
2844
+ }(),
2845
+ o = function() {
2846
+ function e(t) {
2847
+
2848
+ var n = this;
2849
+ i(this, e), this.container = t.template.infoPanel, this.template = t.template, this.video = t.video, this.player =
2850
+ t, this.template.infoPanelClose.addEventListener("click", function() {
2851
+ n.hide()
2852
+ })
2853
+ }
2854
+ return a(e, [{
2855
+ key: "show",
2856
+ value: function() {
2857
+ this.beginTime = Date.now(), this.update(), this.player.time.enable("info"), this.player.time.enable(
2858
+ "fps"), this.container.classList.remove("yzmplayer-info-panel-hide")
2859
+ }
2860
+ }, {
2861
+ key: "hide",
2862
+ value: function() {
2863
+ this.player.time.disable("info"), this.player.time.disable("fps"), this.container.classList.add(
2864
+ "yzmplayer-info-panel-hide")
2865
+ }
2866
+ }, {
2867
+ key: "triggle",
2868
+ value: function() {
2869
+ this.container.classList.contains("yzmplayer-info-panel-hide") ? this.show() : this.hide()
2870
+ }
2871
+ }, {
2872
+ key: "update",
2873
+ value: function() {
2874
+ function formatTime(a) {
2875
+ return [parseInt(a / 60 / 60), parseInt(a / 60 % 60), parseInt(a % 60)].join(":").replace(/\b(\d)\b/g,
2876
+ "0$1")
2877
+ }
2878
+ this.template.infoVersion.innerHTML = "1.2.1", this.template.infoType.innerHTML = this.player.type, this.template
2879
+ .infoUrl.innerHTML = this.player.options.video.url, this.template.infoResolution.innerHTML = this.player
2880
+ .video.videoWidth + " x " + this.player.video.videoHeight, this.template.infoDuration.innerHTML =
2881
+ formatTime(this.player.video.duration), this.player.options.danmaku && (this.template.infoDanmakuId.innerHTML =
2882
+ this.player.options.danmaku.id, this.template.infoDanmakuApi.innerHTML = this.player.options.danmaku.api,
2883
+ this.template.infoDanmakuAmount.innerHTML = this.player.danmaku.dan.length - 2)
2884
+ }
2885
+ }, {
2886
+ key: "fps",
2887
+ value: function(e) {
2888
+ this.template.infoFPS.innerHTML = "" + e.toFixed(1)
2889
+ }
2890
+ }]), e
2891
+ }();
2892
+ t.default = o
2893
+ }
2894
+ ]).default
2895
+ });
2896
+ var yzmck = {
2897
+ set: function(a, b) {
2898
+ window.sessionStorage.setItem(a, b)
2899
+ },
2900
+ get: function(a) {
2901
+ return window.sessionStorage.getItem(a)
2902
+ },
2903
+ del: function(a) {
2904
+ window.sessionStorage.removeItem(a)
2905
+ },
2906
+ clear: function(a) {
2907
+ window.sessionStorage.clear()
2908
+ }
2909
+ };