ravnur-player-public 3.4.2 → 3.4.4

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 (262) hide show
  1. package/.eslintignore +7 -0
  2. package/.eslintrc.js +206 -0
  3. package/.flowconfig +3 -0
  4. package/.vscode/extensions.json +7 -0
  5. package/.vscode/launch.json +37 -0
  6. package/.vscode/settings.json +4 -0
  7. package/README-Private.md +54 -0
  8. package/babel.config.js +28 -0
  9. package/bitbucket-pipelines.yml +61 -0
  10. package/cert.pem +23 -0
  11. package/demo/BaseM.mp4 +0 -0
  12. package/demo/HD.mp4 +0 -0
  13. package/demo/annotations.json +50 -0
  14. package/demo/annotations_ge.json +50 -0
  15. package/demo/base.mp3 +0 -0
  16. package/demo/cc_2125en.vtt +4958 -0
  17. package/demo/cc_en.vtt +171 -0
  18. package/demo/cc_ge.vtt +178 -0
  19. package/demo/chapters_en.vtt +38 -0
  20. package/demo/chapters_ge.vtt +5 -0
  21. package/demo/chapters_ge1.json +23 -0
  22. package/demo/hls/audio/stereo/en/128kbit.m3u8 +912 -0
  23. package/demo/hls/audio/stereo/none/128kbit.m3u8 +912 -0
  24. package/demo/hls/audio/surround/en/320kbit.m3u8 +912 -0
  25. package/demo/hls/playlist.m3u8 +31 -0
  26. package/demo/hls/video/10000kbit.m3u8 +894 -0
  27. package/demo/hls/video/1100kbit.m3u8 +894 -0
  28. package/demo/hls/video/1500kbit.m3u8 +894 -0
  29. package/demo/hls/video/250kbit.m3u8 +894 -0
  30. package/demo/hls/video/4000kbit.m3u8 +894 -0
  31. package/demo/hls/video/500kbit.m3u8 +894 -0
  32. package/demo/hls/video/6000kbit.m3u8 +894 -0
  33. package/demo/hls/video/800kbit.m3u8 +894 -0
  34. package/demo/hls.js +5 -0
  35. package/demo/hls.js.map +1 -0
  36. package/demo/hls.min.js +2 -0
  37. package/demo/hls.min.js.map +1 -0
  38. package/demo/playlist.m3u8 +31 -0
  39. package/demo/ravnur-flash-audio.swf +0 -0
  40. package/demo/ravnur-flash-video-hls.swf +0 -0
  41. package/demo/ravnur-flash-video.swf +0 -0
  42. package/demo/shaka/shaka-player.foo.debug.d.ts +4532 -0
  43. package/demo/shaka/shaka-player.foo.debug.externs.js +3886 -0
  44. package/demo/shaka/shaka-player.foo.debug.js +1746 -0
  45. package/demo/shaka/shaka-player.foo.debug.map +8 -0
  46. package/demo/shaka/wrapper.js +7 -0
  47. package/demo/test.html +458 -0
  48. package/dist/RavnurMediaPlayer.min.js +1 -1
  49. package/dist/cdn/RavnurMediaPlayer.min.js +1 -1
  50. package/jest.config.js +4 -0
  51. package/key.pem +27 -0
  52. package/lib/es5.js +344 -0
  53. package/lib/images/Spinner-small.gif +0 -0
  54. package/lib/images/close.png +0 -0
  55. package/lib/images/ic_check_box_black_24dp_1x.png +0 -0
  56. package/lib/images/ic_check_box_outline_blank_black_24dp_1x.png +0 -0
  57. package/lib/images/ic_chevron_left_white_24dp_1x.png +0 -0
  58. package/lib/images/ic_chevron_right_white_24dp_1x.png +0 -0
  59. package/lib/images/ic_closed_caption_white_24dp_1x.png +0 -0
  60. package/lib/images/ic_fast_forward_white_24dp_1x.png +0 -0
  61. package/lib/images/ic_fast_rewind_white_24dp_1x.png +0 -0
  62. package/lib/images/ic_fullscreen_exit_white_24dp_1x.png +0 -0
  63. package/lib/images/ic_fullscreen_white_24dp_1x.png +0 -0
  64. package/lib/images/ic_hd_white_24dp_1x.png +0 -0
  65. package/lib/images/ic_keyboard_arrow_left_black_24dp_1x.png +0 -0
  66. package/lib/images/ic_keyboard_arrow_right_black_24dp_1x.png +0 -0
  67. package/lib/images/ic_pause_white_24dp_1x.png +0 -0
  68. package/lib/images/ic_photo_white_24dp_1x.png +0 -0
  69. package/lib/images/ic_play_arrow_white_24dp_1x.png +0 -0
  70. package/lib/images/ic_refresh_white_24dp_1x.png +0 -0
  71. package/lib/images/ic_settings_white_24dp_1x.png +0 -0
  72. package/lib/images/ic_skip_next_white_24dp_1x.png +0 -0
  73. package/lib/images/ic_skip_previous_white_24dp_1x.png +0 -0
  74. package/lib/images/ic_toc_white_24dp_1x.png +0 -0
  75. package/lib/images/ic_volume_off_white_24dp_1x.png +0 -0
  76. package/lib/images/ic_volume_up_white_24dp_1x.png +0 -0
  77. package/lib/player4ie8.css +225 -0
  78. package/package.json +1 -5
  79. package/server.js +29 -0
  80. package/src/config/cc.js +56 -0
  81. package/src/config/i18n.js +101 -0
  82. package/src/config/options.js +123 -0
  83. package/src/config/playlist.js +9 -0
  84. package/src/config/source.js +23 -0
  85. package/src/config/statuses.js +8 -0
  86. package/src/config/styles.js +16 -0
  87. package/src/entity.js +27 -0
  88. package/src/events.js +5 -0
  89. package/src/extensions/annotations.js +142 -0
  90. package/src/extensions/audio-tarcks.js +115 -0
  91. package/src/extensions/backward.js +45 -0
  92. package/src/extensions/base.js +73 -0
  93. package/src/extensions/bottom-next.js +50 -0
  94. package/src/extensions/bottom-prev.js +50 -0
  95. package/src/extensions/buffering.js +78 -0
  96. package/src/extensions/c2pa.js +350 -0
  97. package/src/extensions/caption-search.js +230 -0
  98. package/src/extensions/cc.js +874 -0
  99. package/src/extensions/crawl.js +118 -0
  100. package/src/extensions/download.js +411 -0
  101. package/src/extensions/error.js +47 -0
  102. package/src/extensions/forward.js +44 -0
  103. package/src/extensions/fullscreen.js +84 -0
  104. package/src/extensions/help.js +201 -0
  105. package/src/extensions/helpers/FileSaver.js +157 -0
  106. package/src/extensions/helpers/clickOpener.js +180 -0
  107. package/src/extensions/helpers/opener.js +30 -0
  108. package/src/extensions/helpers/openerHeightChecker.js +13 -0
  109. package/src/extensions/helpers/popover.js +33 -0
  110. package/src/extensions/helpers/popoverPosition.js +30 -0
  111. package/src/extensions/helpers/scrollIntoView.js +9 -0
  112. package/src/extensions/helpers/storage.js +20 -0
  113. package/src/extensions/helpers/textContent.js +6 -0
  114. package/src/extensions/helpers/timeCodeToSeconds.js +44 -0
  115. package/src/extensions/helpers/transport.js +43 -0
  116. package/src/extensions/helpers/vtt-loader.js +42 -0
  117. package/src/extensions/index.js +87 -0
  118. package/src/extensions/live.js +76 -0
  119. package/src/extensions/mux.js +57 -0
  120. package/src/extensions/next-frame.js +44 -0
  121. package/src/extensions/next.js +48 -0
  122. package/src/extensions/placeholder.js +241 -0
  123. package/src/extensions/play.js +102 -0
  124. package/src/extensions/poster.js +47 -0
  125. package/src/extensions/prev-frame.js +44 -0
  126. package/src/extensions/prev.js +48 -0
  127. package/src/extensions/progress.js +465 -0
  128. package/src/extensions/resizer.js +37 -0
  129. package/src/extensions/settings.js +367 -0
  130. package/src/extensions/theater.js +56 -0
  131. package/src/extensions/title.js +38 -0
  132. package/src/extensions/toc.js +334 -0
  133. package/src/extensions/volume.js +196 -0
  134. package/src/flash/FlashPlugin.js +301 -0
  135. package/src/flash/MediaElement.js +361 -0
  136. package/src/flash/plugins.js +32 -0
  137. package/src/flash-detector.js +66 -0
  138. package/src/helpers/$t.js +10 -0
  139. package/src/helpers/binder.js +11 -0
  140. package/src/helpers/isAndroid.js +5 -0
  141. package/src/helpers/isBlackBerry.js +5 -0
  142. package/src/helpers/isCanvasSupported.js +6 -0
  143. package/src/helpers/isIE.js +21 -0
  144. package/src/helpers/isMobile.js +10 -0
  145. package/src/helpers/isWindows.js +5 -0
  146. package/src/helpers/isWindowsPhone.js +5 -0
  147. package/src/helpers/isiOS.js +5 -0
  148. package/src/html5media.js +19 -0
  149. package/src/index.js +2 -0
  150. package/src/logger.js +31 -0
  151. package/src/microevent.js +65 -0
  152. package/src/normalize-options.js +139 -0
  153. package/src/player.js +864 -0
  154. package/src/players/base.js +209 -0
  155. package/src/players/flash.js +172 -0
  156. package/src/players/hls.js +278 -0
  157. package/src/players/html.js +205 -0
  158. package/src/players/index.js +59 -0
  159. package/src/players/shaka.js +219 -0
  160. package/src/playlist.js +362 -0
  161. package/src/screenfull.js +121 -0
  162. package/src/state.js +474 -0
  163. package/src/static/es5.js +344 -0
  164. package/src/static/images/Spinner-small.gif +0 -0
  165. package/src/static/images/close.png +0 -0
  166. package/src/static/images/ic_check_box_black_24dp_1x.png +0 -0
  167. package/src/static/images/ic_check_box_outline_blank_black_24dp_1x.png +0 -0
  168. package/src/static/images/ic_chevron_left_white_24dp_1x.png +0 -0
  169. package/src/static/images/ic_chevron_right_white_24dp_1x.png +0 -0
  170. package/src/static/images/ic_closed_caption_white_24dp_1x.png +0 -0
  171. package/src/static/images/ic_fast_forward_white_24dp_1x.png +0 -0
  172. package/src/static/images/ic_fast_rewind_white_24dp_1x.png +0 -0
  173. package/src/static/images/ic_fullscreen_exit_white_24dp_1x.png +0 -0
  174. package/src/static/images/ic_fullscreen_white_24dp_1x.png +0 -0
  175. package/src/static/images/ic_hd_white_24dp_1x.png +0 -0
  176. package/src/static/images/ic_keyboard_arrow_left_black_24dp_1x.png +0 -0
  177. package/src/static/images/ic_keyboard_arrow_right_black_24dp_1x.png +0 -0
  178. package/src/static/images/ic_pause_white_24dp_1x.png +0 -0
  179. package/src/static/images/ic_play_arrow_white_24dp_1x.png +0 -0
  180. package/src/static/images/ic_refresh_white_24dp_1x.png +0 -0
  181. package/src/static/images/ic_settings_white_24dp_1x.png +0 -0
  182. package/src/static/images/ic_skip_next_white_24dp_1x.png +0 -0
  183. package/src/static/images/ic_skip_previous_white_24dp_1x.png +0 -0
  184. package/src/static/images/ic_toc_white_24dp_1x.png +0 -0
  185. package/src/static/images/ic_volume_off_white_24dp_1x.png +0 -0
  186. package/src/static/images/ic_volume_up_white_24dp_1x.png +0 -0
  187. package/src/static/player4ie8.css +225 -0
  188. package/src/styles/bplaylist.css.js +124 -0
  189. package/src/styles/index.js +1966 -0
  190. package/src/styles/playlist.css.js +84 -0
  191. package/src/styles/rplaylist.css.js +98 -0
  192. package/src/svgs.js +111 -0
  193. package/src/types/Logger.js +10 -0
  194. package/src/types/Options.js +179 -0
  195. package/src/types/Playlist.js +3 -0
  196. package/src/types/Source.js +28 -0
  197. package/src/types/State.js +46 -0
  198. package/src/types/Styles.js +11 -0
  199. package/src/types/TimeData.js +8 -0
  200. package/src/types/Translation.js +69 -0
  201. package/src/utils/absolutizeUrl.js +9 -0
  202. package/src/utils/addClass.js +9 -0
  203. package/src/utils/addEvent.js +31 -0
  204. package/src/utils/addProperty.js +65 -0
  205. package/src/utils/appendChild.js +14 -0
  206. package/src/utils/buff2hex.js +5 -0
  207. package/src/utils/contains.js +33 -0
  208. package/src/utils/createElement.js +24 -0
  209. package/src/utils/each.js +34 -0
  210. package/src/utils/escapeHTML.js +8 -0
  211. package/src/utils/existy.js +4 -0
  212. package/src/utils/extend.js +17 -0
  213. package/src/utils/filter.js +16 -0
  214. package/src/utils/find.js +11 -0
  215. package/src/utils/findIndex.js +20 -0
  216. package/src/utils/first.js +5 -0
  217. package/src/utils/get.js +19 -0
  218. package/src/utils/has.js +5 -0
  219. package/src/utils/hasClass.js +6 -0
  220. package/src/utils/head.js +11 -0
  221. package/src/utils/inRange.js +16 -0
  222. package/src/utils/index.js +73 -0
  223. package/src/utils/isArray.js +4 -0
  224. package/src/utils/isBoolean.js +3 -0
  225. package/src/utils/isElement.js +7 -0
  226. package/src/utils/isEmpty.js +6 -0
  227. package/src/utils/isEqual.js +33 -0
  228. package/src/utils/isEqualBuffer.js +13 -0
  229. package/src/utils/isFunction.js +3 -0
  230. package/src/utils/isNotEmpty.js +5 -0
  231. package/src/utils/isObject.js +5 -0
  232. package/src/utils/isString.js +9 -0
  233. package/src/utils/last.js +4 -0
  234. package/src/utils/map.js +11 -0
  235. package/src/utils/negate.js +8 -0
  236. package/src/utils/noop.js +1 -0
  237. package/src/utils/notExisty.js +5 -0
  238. package/src/utils/reduce.js +8 -0
  239. package/src/utils/remove.js +7 -0
  240. package/src/utils/removeClass.js +8 -0
  241. package/src/utils/removeEvent.js +7 -0
  242. package/src/utils/toArray.js +7 -0
  243. package/src/utils/toggleClass.js +16 -0
  244. package/src/utils/uidGenerator.js +8 -0
  245. package/src/utils/upperFirst.js +4 -0
  246. package/tests/extensions/__snapshots__/download.spec.js.snap +226 -0
  247. package/tests/extensions/__snapshots__/fullscreen.spec.js.snap +30 -0
  248. package/tests/extensions/__snapshots__/title.spec.js.snap +16 -0
  249. package/tests/extensions/download.spec.js +111 -0
  250. package/tests/extensions/fullscreen.spec.js +56 -0
  251. package/tests/extensions/title.spec.js +35 -0
  252. package/tests/mocks/assets/BaseM.mp4 +0 -0
  253. package/tests/mocks/assets/hls.min.js +5 -0
  254. package/tests/mocks/assets/styleMock.js +1 -0
  255. package/tests/mocks/base-player-options.js +47 -0
  256. package/tests/mocks/sources.js +58 -0
  257. package/tests/mocks/timedata/cc_en.vtt +171 -0
  258. package/tests/mocks/timedata/cc_ge.vtt +178 -0
  259. package/tests/utils/wait.js +1 -0
  260. package/webpack.config.js +78 -0
  261. package/dist/.DS_Store +0 -0
  262. package/dist/cdn/.DS_Store +0 -0
@@ -0,0 +1,344 @@
1
+ //----------------------------------------------------------------------
2
+ //
3
+ // ECMAScript 5 Polyfills
4
+ //
5
+ //----------------------------------------------------------------------
6
+
7
+ //----------------------------------------------------------------------
8
+ // ES5 15.2 Object Objects
9
+ //----------------------------------------------------------------------
10
+
11
+ //
12
+ // ES5 15.2.3 Properties of the Object Constructor
13
+ //
14
+
15
+ // ES5 15.2.3.2 Object.getPrototypeOf ( O )
16
+ // From http://ejohn.org/blog/objectgetprototypeof/
17
+ // NOTE: won't work for typical function T() {}; T.prototype = {}; new T; case
18
+ // since the constructor property is destroyed.
19
+ if (!Object.getPrototypeOf) {
20
+ Object.getPrototypeOf = function (o) {
21
+ if (o !== Object(o)) { throw TypeError("Object.getPrototypeOf called on non-object"); }
22
+ return o.__proto__ || o.constructor.prototype || Object.prototype;
23
+ };
24
+ }
25
+
26
+ // ES5 15.2.3.3 Object.getOwnPropertyDescriptor ( O, P )
27
+ Object._origin_getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
28
+ Object.getOwnPropertyDescriptor = function (o, name) {
29
+ try {
30
+ return Object._origin_getOwnPropertyDescriptor(o, name);
31
+ } catch(e) {
32
+ if (o !== Object(o)) { throw TypeError(); }
33
+ if (Object.prototype.hasOwnProperty.call(o, name)) {
34
+ return {
35
+ value: o[name],
36
+ enumerable: true,
37
+ writable: true,
38
+ configurable: true
39
+ };
40
+ }
41
+ }
42
+ };
43
+
44
+ // ES5 15.2.3.4 Object.getOwnPropertyNames ( O )
45
+ if (typeof Object.getOwnPropertyNames !== "function") {
46
+ Object.getOwnPropertyNames = function (o) {
47
+ if (o !== Object(o)) { throw TypeError("Object.getOwnPropertyNames called on non-object"); }
48
+ var props = [], p;
49
+ for (p in o) {
50
+ if (Object.prototype.hasOwnProperty.call(o, p)) {
51
+ props.push(p);
52
+ }
53
+ }
54
+ return props;
55
+ };
56
+ }
57
+
58
+ // ES5 15.2.3.5 Object.create ( O [, Properties] )
59
+ if (typeof Object.create !== "function") {
60
+ Object.create = function (prototype, properties) {
61
+ if (typeof prototype !== "object") { throw TypeError(); }
62
+ function Ctor() {}
63
+ Ctor.prototype = prototype;
64
+ var o = new Ctor();
65
+ if (prototype) { o.constructor = Ctor; }
66
+ if (properties !== undefined) {
67
+ if (properties !== Object(properties)) { throw TypeError(); }
68
+ Object.defineProperties(o, properties);
69
+ }
70
+ return o;
71
+ };
72
+ }
73
+
74
+ // ES 15.2.3.6 Object.defineProperty ( O, P, Attributes )
75
+ // Partial support for most common case - getters, setters, and values
76
+ (function() {
77
+ if (!Object.defineProperty ||
78
+ !(function () { try { Object.defineProperty({}, 'x', {}); return true; } catch (e) { return false; } } ())) {
79
+ var orig = Object.defineProperty;
80
+ Object.defineProperty = function (o, prop, desc) {
81
+ // In IE8 try built-in implementation for defining properties on DOM prototypes.
82
+ if (orig) { try { return orig(o, prop, desc); } catch (e) {} }
83
+
84
+ if (o !== Object(o)) { throw TypeError("Object.defineProperty called on non-object"); }
85
+ if (Object.prototype.__defineGetter__ && ('get' in desc)) {
86
+ Object.prototype.__defineGetter__.call(o, prop, desc.get);
87
+ }
88
+ if (Object.prototype.__defineSetter__ && ('set' in desc)) {
89
+ Object.prototype.__defineSetter__.call(o, prop, desc.set);
90
+ }
91
+ if ('value' in desc) {
92
+ o[prop] = desc.value;
93
+ }
94
+ return o;
95
+ };
96
+ }
97
+ }());
98
+
99
+ // ES 15.2.3.7 Object.defineProperties ( O, Properties )
100
+ if (typeof Object.defineProperties !== "function") {
101
+ Object.defineProperties = function (o, properties) {
102
+ if (o !== Object(o)) { throw TypeError("Object.defineProperties called on non-object"); }
103
+ var name;
104
+ for (name in properties) {
105
+ if (Object.prototype.hasOwnProperty.call(properties, name)) {
106
+ Object.defineProperty(o, name, properties[name]);
107
+ }
108
+ }
109
+ return o;
110
+ };
111
+ }
112
+
113
+
114
+ // ES5 15.2.3.14 Object.keys ( O )
115
+ // https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/keys
116
+ if (!Object.keys) {
117
+ Object.keys = function (o) {
118
+ if (o !== Object(o)) { throw TypeError('Object.keys called on non-object'); }
119
+ var ret = [], p;
120
+ for (p in o) {
121
+ if (Object.prototype.hasOwnProperty.call(o, p)) {
122
+ ret.push(p);
123
+ }
124
+ }
125
+ return ret;
126
+ };
127
+ }
128
+
129
+ //----------------------------------------------------------------------
130
+ // ES5 15.3 Function Objects
131
+ //----------------------------------------------------------------------
132
+
133
+ //
134
+ // ES5 15.3.4 Properties of the Function Prototype Object
135
+ //
136
+
137
+ // ES5 15.3.4.5 Function.prototype.bind ( thisArg [, arg1 [, arg2, ... ]] )
138
+ // https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Function/bind
139
+ if (!Function.prototype.bind) {
140
+ Function.prototype.bind = function (o) {
141
+ if (typeof this !== 'function') { throw TypeError("Bind must be called on a function"); }
142
+
143
+ var args = Array.prototype.slice.call(arguments, 1),
144
+ self = this,
145
+ nop = function() {},
146
+ bound = function () {
147
+ return self.apply(this instanceof nop ? this : o,
148
+ args.concat(Array.prototype.slice.call(arguments)));
149
+ };
150
+
151
+ if (this.prototype)
152
+ nop.prototype = this.prototype;
153
+ bound.prototype = new nop();
154
+ return bound;
155
+ };
156
+ }
157
+
158
+
159
+ //----------------------------------------------------------------------
160
+ // ES5 15.4 Array Objects
161
+ //----------------------------------------------------------------------
162
+
163
+ //
164
+ // ES5 15.4.3 Properties of the Array Constructor
165
+ //
166
+
167
+
168
+ // ES5 15.4.3.2 Array.isArray ( arg )
169
+ // https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/isArray
170
+ Array.isArray = Array.isArray || function (o) { return Boolean(o && Object.prototype.toString.call(Object(o)) === '[object Array]'); };
171
+
172
+
173
+ //
174
+ // ES5 15.4.4 Properties of the Array Prototype Object
175
+ //
176
+
177
+ // ES5 15.4.4.14 Array.prototype.indexOf ( searchElement [ , fromIndex ] )
178
+ // From https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/indexOf
179
+ if (!Array.prototype.indexOf) {
180
+ Array.prototype.indexOf = function (searchElement /*, fromIndex */) {
181
+ if (this === void 0 || this === null) { throw TypeError(); }
182
+
183
+ var t = Object(this);
184
+ var len = t.length >>> 0;
185
+ if (len === 0) { return -1; }
186
+
187
+ var n = 0;
188
+ if (arguments.length > 0) {
189
+ n = Number(arguments[1]);
190
+ if (isNaN(n)) {
191
+ n = 0;
192
+ } else if (n !== 0 && n !== (1 / 0) && n !== -(1 / 0)) {
193
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
194
+ }
195
+ }
196
+
197
+ if (n >= len) { return -1; }
198
+
199
+ var k = n >= 0 ? n : Math.max(len - Math.abs(n), 0);
200
+
201
+ for (; k < len; k++) {
202
+ if (k in t && t[k] === searchElement) {
203
+ return k;
204
+ }
205
+ }
206
+ return -1;
207
+ };
208
+ }
209
+
210
+ // ES5 15.4.4.15 Array.prototype.lastIndexOf ( searchElement [ , fromIndex ] )
211
+ // From https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/lastIndexOf
212
+ if (!Array.prototype.lastIndexOf) {
213
+ Array.prototype.lastIndexOf = function (searchElement /*, fromIndex*/) {
214
+ if (this === void 0 || this === null) { throw TypeError(); }
215
+
216
+ var t = Object(this);
217
+ var len = t.length >>> 0;
218
+ if (len === 0) { return -1; }
219
+
220
+ var n = len;
221
+ if (arguments.length > 1) {
222
+ n = Number(arguments[1]);
223
+ if (n !== n) {
224
+ n = 0;
225
+ } else if (n !== 0 && n !== (1 / 0) && n !== -(1 / 0)) {
226
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
227
+ }
228
+ }
229
+
230
+ var k = n >= 0 ? Math.min(n, len - 1) : len - Math.abs(n);
231
+
232
+ for (; k >= 0; k--) {
233
+ if (k in t && t[k] === searchElement) {
234
+ return k;
235
+ }
236
+ }
237
+ return -1;
238
+ };
239
+ }
240
+
241
+ // ES5 15.4.4.17 Array.prototype.some ( callbackfn [ , thisArg ] )
242
+ // From https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/some
243
+ if (!Array.prototype.some) {
244
+ Array.prototype.some = function (fun /*, thisp */) {
245
+ if (this === void 0 || this === null) { throw TypeError(); }
246
+
247
+ var t = Object(this);
248
+ var len = t.length >>> 0;
249
+ if (typeof fun !== "function") { throw TypeError(); }
250
+
251
+ var thisp = arguments[1], i;
252
+ for (i = 0; i < len; i++) {
253
+ if (i in t && fun.call(thisp, t[i], i, t)) {
254
+ return true;
255
+ }
256
+ }
257
+
258
+ return false;
259
+ };
260
+ }
261
+
262
+ // ES5 15.4.4.18 Array.prototype.forEach ( callbackfn [ , thisArg ] )
263
+ // From https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/forEach
264
+ if (!Array.prototype.forEach) {
265
+ Array.prototype.forEach = function (fun /*, thisp */) {
266
+ if (this === void 0 || this === null) { throw TypeError(); }
267
+
268
+ var t = Object(this);
269
+ var len = t.length >>> 0;
270
+ if (typeof fun !== "function") { throw TypeError(); }
271
+
272
+ var thisp = arguments[1], i;
273
+ for (i = 0; i < len; i++) {
274
+ if (i in t) {
275
+ fun.call(thisp, t[i], i, t);
276
+ }
277
+ }
278
+ };
279
+ }
280
+
281
+
282
+ // ES5 15.4.4.20 Array.prototype.filter ( callbackfn [ , thisArg ] )
283
+ // From https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/Filter
284
+ if (!Array.prototype.filter) {
285
+ Array.prototype.filter = function (fun /*, thisp */) {
286
+ if (this === void 0 || this === null) { throw TypeError(); }
287
+
288
+ var t = Object(this);
289
+ var len = t.length >>> 0;
290
+ if (typeof fun !== "function") { throw TypeError(); }
291
+
292
+ var res = [];
293
+ var thisp = arguments[1], i;
294
+ for (i = 0; i < len; i++) {
295
+ if (i in t) {
296
+ var val = t[i]; // in case fun mutates this
297
+ if (fun.call(thisp, val, i, t)) {
298
+ res.push(val);
299
+ }
300
+ }
301
+ }
302
+
303
+ return res;
304
+ };
305
+ }
306
+
307
+
308
+ // ES5 15.5.4.20 String.prototype.trim()
309
+ if (!String.prototype.trim) {
310
+ String.prototype.trim = function () {
311
+ return String(this).replace(/^\s+/, '').replace(/\s+$/, '');
312
+ };
313
+ }
314
+
315
+ if (Object.defineProperty
316
+ && Object.getOwnPropertyDescriptor
317
+ && Object.getOwnPropertyDescriptor(Element.prototype, "textContent")
318
+ && !Object.getOwnPropertyDescriptor(Element.prototype, "textContent").get) {
319
+ (function() {
320
+ var innerText = Object.getOwnPropertyDescriptor(Element.prototype, "innerText");
321
+ Object.defineProperty(Element.prototype, "textContent",
322
+ {
323
+ get: function() {
324
+ return innerText.get.call(this);
325
+ },
326
+ set: function(s) {
327
+ s = s || '';
328
+ return innerText.set.call(this, s.trim());
329
+ }
330
+ }
331
+ );
332
+ })();
333
+ }
334
+
335
+ if (!Event.prototype.preventDefault) {
336
+ Event.prototype.preventDefault=function() {
337
+ this.returnValue=false;
338
+ };
339
+ }
340
+ if (!Event.prototype.stopPropagation) {
341
+ Event.prototype.stopPropagation=function() {
342
+ this.cancelBubble=true;
343
+ };
344
+ }
Binary file
@@ -0,0 +1,225 @@
1
+
2
+ .rmp-extensions--hidden {
3
+ /*visibility: hidden;*/
4
+ display: none;
5
+ }
6
+
7
+ .rmp-ext-placeholder {
8
+ -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=1)";
9
+ }
10
+
11
+ .rplayer__inner--light .rmp-ext-placeholder {
12
+ -ms-filter: inherit;
13
+ }
14
+
15
+ .rmp-ext-c2pa__item--thumbnail {
16
+ background: url(images/ic_photo_white_24dp_1x.png) no-repeat center center #bababa;
17
+ }
18
+
19
+ .rplayer__inner--light .rmp-ext-placeholder__play-btn {
20
+ background: url(images/ic_play_arrow_white_24dp_1x.png) no-repeat center center #717171;
21
+ }
22
+
23
+ .rmp-ext-backward {
24
+ background: url(images/ic_fast_rewind_white_24dp_1x.png) no-repeat center center transparent;
25
+ }
26
+
27
+ .rmp-ext-play--paused {
28
+ background: url(images/ic_play_arrow_white_24dp_1x.png) no-repeat center center transparent;
29
+ }
30
+
31
+ .rmp-ext-play--playing {
32
+ background: url(images/ic_pause_white_24dp_1x.png) no-repeat center center transparent;
33
+ }
34
+
35
+ .rmp-ext-play--ended {
36
+ background: url(images/ic_refresh_white_24dp_1x.png) no-repeat center center transparent;
37
+ }
38
+
39
+ .rmp-ext-forward {
40
+ background: url(images/ic_fast_forward_white_24dp_1x.png) no-repeat center center transparent;
41
+ }
42
+
43
+ .rmp-ext-volume__btn {
44
+ background: url(images/ic_volume_up_white_24dp_1x.png) no-repeat center center transparent;
45
+ }
46
+
47
+ .rmp-ext-volume__btn--muted {
48
+ background: url(images/ic_volume_off_white_24dp_1x.png) no-repeat center center transparent;
49
+ }
50
+
51
+ .rmp-ext-settings__button {
52
+ background: url(images/ic_settings_white_24dp_1x.png) no-repeat center center transparent;
53
+ }
54
+
55
+ .rmp-ext-toc__button {
56
+ background: url(images/ic_toc_white_24dp_1x.png) no-repeat center center transparent;
57
+ }
58
+
59
+ .rmp-ext-cc__button {
60
+ background: url(images/ic_closed_caption_white_24dp_1x.png) no-repeat center center transparent;
61
+ }
62
+
63
+ .rmp-ext-fullscreen {
64
+ background: url(images/ic_fullscreen_white_24dp_1x.png) no-repeat center center transparent;
65
+ }
66
+
67
+ .rmp-ext-fullscreen--exit {
68
+ background: url(images/ic_fullscreen_exit_white_24dp_1x.png) no-repeat center center transparent;
69
+ }
70
+
71
+ .rmp-annotation__button {
72
+ background: url(images/close.png) no-repeat center center transparent;
73
+ }
74
+
75
+ .rmp-ext-settings__annotations--on .rmp-ext-settings__toggler {
76
+ background: url(images/ic_check_box_black_24dp_1x.png) no-repeat center center transparent;
77
+ border: 0;
78
+ }
79
+
80
+ .rmp-ext-settings__annotations--off .rmp-ext-settings__toggler {
81
+ background: url(images/ic_check_box_outline_blank_black_24dp_1x.png) no-repeat center center transparent;
82
+ border: 0;
83
+ }
84
+
85
+ .rmp-ext-next__button {
86
+ width: 32px;
87
+ background: url(images/ic_skip_next_white_24dp_1x.png) no-repeat center center transparent;
88
+ }
89
+
90
+ .rmp-ext-prev__button {
91
+ width: 32px;
92
+ background: url(images/ic_skip_previous_white_24dp_1x.png) no-repeat center center transparent;
93
+ }
94
+
95
+ .rmp-ext-next-frame {
96
+ width: 32px;
97
+ background: url(images/ic_skip_next_white_24dp_1x.png) no-repeat center center transparent;
98
+ }
99
+
100
+ .rmp-ext-prev-frame {
101
+ width: 32px;
102
+ background: url(images/ic_skip_previous_white_24dp_1x.png) no-repeat center center transparent;
103
+ }
104
+
105
+ .rmp-ext-settings__more .arrow, .rmp-ext-cc__more .arrow {
106
+ background: url(images/ic_keyboard_arrow_right_black_24dp_1x.png) no-repeat center center transparent;
107
+ }
108
+
109
+ .rmp-ext-settings__back .arrow, .rmp-ext-cc__back .arrow {
110
+ background: url(images/ic_keyboard_arrow_left_black_24dp_1x.png) no-repeat center center transparent;
111
+ display: block;
112
+ width: 32px;
113
+ height: 32px;
114
+ float: left;
115
+ }
116
+
117
+ .rplayer__playlist-right-btn {
118
+ background: url(images/ic_keyboard_arrow_right_black_24dp_1x.png) no-repeat center center #EEE;
119
+ width: 24px;
120
+ }
121
+
122
+ .rplayer__playlist-left-btn {
123
+ background: url(images/ic_keyboard_arrow_left_black_24dp_1x.png) no-repeat center center #EEE;
124
+ width: 24px;
125
+ }
126
+
127
+ .rmp-ext-toc__selector a {
128
+ position: relative;
129
+ display: block;
130
+ }
131
+
132
+ .rmp-ext-cc__item--checked, .rmp-ext-settings__item--checked {
133
+ padding-left: 18px !important;
134
+ }
135
+
136
+ .rmp-ext-cc__item--checked:before, .rmp-ext-settings__item--checked:before {
137
+ left: 0;
138
+ float: left;
139
+ margin: 0 !important;
140
+ width: 12px !important;
141
+ padding: 0 0 0 6px !important;
142
+ }
143
+
144
+ .rmp-ext-settings__selector--additional .rmp-ext-settings__main-step,
145
+ .rplayer__inner--playing .rmp-ext-help, .rplayer__inner--playing .rmp-ext-title,
146
+ .rplayer__inner--playing .rmp-ext-prev, .rplayer__inner--playing .rmp-ext-next {
147
+ display: none !important
148
+ }
149
+
150
+ .rmp-ext-title {
151
+ padding-top: 10px;
152
+ }
153
+
154
+ .rplayer--fullscreen , .rplayer--fullscreen .rplayer__inner {
155
+ width: 100% !important;
156
+ top: 0 !important;
157
+ right: 0 !important;
158
+ left: 0 !important;
159
+ bottom: 0 !important;
160
+ margin: 0 !important;
161
+ position: fixed
162
+ }
163
+
164
+ .rmp-ext-cc__item--checked::before, .rmp-ext-settings__item--checked::before {
165
+ position: relative !important;
166
+ margin-left: 0;
167
+ margin-top: 0;
168
+ }
169
+
170
+ .rplayer__playlist-item-inner span {
171
+ background-color: #717171;
172
+ }
173
+
174
+ .rplayer__playlist-item--current b {
175
+ display: block;
176
+ position: absolute;
177
+ top: 0;
178
+ bottom: 0;
179
+ left: 0;
180
+ right: 0;
181
+ font-size: 28px;
182
+ text-align: center;
183
+ z-index: 9;
184
+ line-height: 70px;
185
+ width: 112px;
186
+ }
187
+
188
+ .rplayer__playlist-item--current b:before {
189
+ display: block;
190
+ content: '►';
191
+ position: absolute;
192
+ top: 0;
193
+ bottom: 0;
194
+ left: 0;
195
+ font-size: 28px;
196
+ text-align: center;
197
+ z-index: 9;
198
+ line-height: 70px;
199
+ width: 112px;
200
+ }
201
+
202
+ .rplayer--bottom-playlist .rplayer__playlist-item--current b:before,
203
+ .rplayer--bottom-playlist .rplayer__playlist-item--current b {
204
+ line-height: 90px;
205
+ width: 160px;
206
+ }
207
+
208
+ .rplayer__inner--light .rmp-extensions, .rplayer__inner--light .rmp-ext-help {
209
+ display: none;
210
+ }
211
+
212
+ .rplayer__inner--light:hover .rmp-extensions, .rplayer__inner--light:hover .rmp-ext-help {
213
+ display: block;
214
+ }
215
+
216
+ .rplayer--right-playlist .rplayer__playlist-wrapper .rplayer__playlist-item-title {
217
+ display: block !important;
218
+ }
219
+
220
+ .rplayer--right-playlist .rplayer__playlist-wrapper .rplayer__playlist-header {
221
+ height: 56px;
222
+ }
223
+
224
+
225
+