-
Notifications
You must be signed in to change notification settings - Fork 4
/
cs.js
79 lines (70 loc) · 3.27 KB
/
cs.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
/**
* App namespace.
* @type {object}
*/
var YouTubeOnRepeatApp = {};
// Some Constants
youtubeOnRepeatApp.URL_BASE = 'http://youtubeonrepeat.com/watch?v=';
YouTubeOnRepeatApp.ICON_DATA_URL =
'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAFwklE' +
'QVRoge2aXYhVVRTHt/kBmqUVZkFBQRgxUNjVhtGZOWstP++9e20Q9VmQeurjpUCIHswgKAghKM' +
'kgIdJM6E3LEp2XGJWGNPGqeOeevXahMPbpDIozOnN6OPfeOXPvuV9Hx5nAA4s5zAzrnN/+r//a' +
'6+4ZJQa/sgYPi8ETjumiM3RJDA0I07CY6RQ44jT+LYYGHGNeDP0ijEeVMxQ4xsAZqgqJ+d5Uhh' +
'iM3Idf1VS/1O3GPYCpjnsANYNxLNocpHyPpZ+NTWsAMRhYgyOOaacwfuwY91vGk2JoOASiQPTt' +
'g0ymAoFjutbb0TFXKTUj19Y2J59uf7B/bfeTvoZXhVFChTCQ24CYRACKAsRevqHNVsNFxzgmhg' +
'KnoWWQKQVQSqnC6tQCq2G7Y7guhgLHrUFMogcocJqu9aVSs+sBlC6bwXYxNDCtFLCGhq2BLTaD' +
'7efWdT3ex6l5ddVgb7kw/ekMhgafFAANY46Lq8wYtscYE4bGjM4uMGgNHnZZ7/V8umtRLQjhrh' +
'ct07/jOe4EQKRviwlbpGg84jRsEoP/1Bz6oqvI5b1gVBgHrIEttZXAjdHBrXWAyOoVu8NNx/SX' +
'1XTSZmHb+VUvPVKuXcYvWiutIhRj4Bv8q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hxeRN4JykABsJ4s8Deu3UgVA/ArNy6jof99fisrz22Bo7VzWuo5rh85wAm+I' +
'ECMfBmo1O30uUM7WpqUr0bANG6lCwcjNvkKi/L+NlkvHxiBULZsXj6BoNWwy4LsLCmAtMOIAJS' +
'NrfBwDLulyytyKe7Fv269vn7+1Kp2duVum/6KVAFAuXDquLpxCVhPGoZ9wrjp9bQmVrz/PQAiC' +
'oyfj/+ZyXGZPPSXQeYgrgHMNXx/wcoz9bhXxUDZ0pT4sR/rphOUWoOYihQjmGP1XjIMh4XxvPO' +
'4G9iaEA0XRODI1P/bzaRYLoaTqzYbxlPi6Fj/wFSuttApJJnVAAAAABJRU5ErkJggg==';
/**
* Extracts parameters from the url string.
* @param {string} param
* @param {string} string
* @return {string} param value.
*/
youtubeOnRepeatApp.urlParamExtract = function (param, string) {
var results = new RegExp('[\\?&]' + param + '=([^&#$]*)').exec(string);
return results[1] || 0;
};
/**
* Creates a repeat button.
* @param {string} repeatUrl
* @return {string} html element as string.
*/
youtubeOnRepeatApp.createRepeatButton = function () {
return '<img src="' + this.ICON_DATA_URL + '">';
};
/**
* Gets user info container.
* @return {object} element
*/
youtubeOnRepeatApp.getUserInfoContainer = function () {
};
/**
* Adds repeat button to page.
* @param {object} button
*/
youtubeOnRepeatApp.addRepeatButton = function (button) {
}
YouTubeOnRepeatApp.init = function () {
console.log('I am Loaded');
};
YouTubeOnRepeatApp.init();