efront 3.34.0 → 3.34.2

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.
Binary file
Binary file
@@ -20,6 +20,7 @@
20
20
  <script deleteoncompile>
21
21
  cross_host = '';
22
22
  </script>
23
+ <script type="deleteoncompile" src="crypto/*"></script>
23
24
  <style>
24
25
  *,
25
26
  ::before,
@@ -40,12 +40,12 @@ function main(params, from) {
40
40
  if (!resultMap[id]) resultMap[id] = Object.assign([], { singer: singerName, song: songName });
41
41
  resultMap[id].push(info);
42
42
  },
43
- async requestSearch(type, id, params, mp, timeout) {
44
- var res = await data.from(id, params, timeout);
43
+ async requestSearch(type, id, params, mp, timeout, parse) {
44
+ var res = await data.lazyInstance(id, params, timeout, parse);
45
45
  if (mp !== this.resultMap) return;
46
46
  res.forEach(a => a.type = type);
47
47
  res.forEach(this.addResult, this);
48
- this.result = Object.keys(this.resultMap).map(k => this.resultMap[k]);
48
+ this.result = Object.keys(this.resultMap).map(k => this.resultMap[k]).sort((a, b) => b.length - a.length);
49
49
  for (var r of this.result) r.sort((a, b) => a.priced - b.priced);
50
50
  return res;
51
51
  },
@@ -56,15 +56,33 @@ function main(params, from) {
56
56
  this.searched = keyword;
57
57
  this.resultMap = Object.create(null);
58
58
  this.result = [];
59
- var s1 = this.requestSearch("kugo", 'search', { keyword }, this.resultMap, timeout);
60
- var s2 = this.requestSearch("kuwo", "search-kuwo", { key: keyword }, this.resultMap, timeout);
61
- state({ keyword });
62
- s1.then(function (s1) {
59
+ if (!keyword) return;
60
+ var s1 = this.requestSearch("kugo", 'search', { keyword }, this.resultMap, timeout, function (s1) {
63
61
  s1.forEach(a => {
64
62
  a.priced = a.privilege === 10 && (a.price_sq > 0);
65
63
  });
66
- })
67
- await Promise.all([s1, s2]);
64
+ return s1;
65
+ });
66
+ var s2 = this.requestSearch("kuwo", "search-kuwo", { key: keyword }, this.resultMap, timeout);
67
+ var s3 = this.requestSearch("yyyy", "search-yyyy", yyyc.encode({ hlposttag: "</span>", hlposttag: `<span class="s-fc7">`, limit: 30, offset: 0, s: keyword, total: true, type: 1 }), this.resultMap, timeout, function (s3) {
68
+ s3.forEach(a => {
69
+ a.priced = a.fee === 1;
70
+ a.singername = a.ar.map(a => {
71
+ if (a.name === "." || isEmpty(a.name)) return a.alia.join("、");
72
+ return a.name;
73
+ }).join("、");
74
+ });
75
+ return s3;
76
+ });
77
+ var p4 = {
78
+ word: keyword,
79
+ type: 1,
80
+ // pageSize: 20,
81
+ };
82
+ qqjc(p4);
83
+ var s4 = this.requestSearch("qqjt", "search-qqjt", p4, this.resultMap, timeout);
84
+ state({ keyword });
85
+ await Promise.all([s1, s2, s3, s4]);
68
86
 
69
87
  },
70
88
  confirm() {
@@ -17,8 +17,8 @@
17
17
  // │ href │
18
18
  // └────────────────────────────────────────────────────────────────────────────────────────────────┘
19
19
 
20
- // -------/// ---------------1---------------------------------///////////////////2-----3--------//////// ------4----2/////5---------------------------------------------------6-----------------------------------------------------------------------------------//////////////-7--5///8-------9----------//10--11---10/8/--12----////
21
- var reg = /^([^\:\/\\\?#\[]+\:(?![^\:\/\\\?\#]*@|[\/\\][^\/\\]))?(?:\/\/|\\\\)?(?:(([^\:\/\\\?#]+)?(?:\:([^\/\\\?#]+))?)@)?(([^\/\\@\?\#\.]*?[^\/\\@\:\?\#\.\d][^\/\\@\:\?\#\.]*?|[^\/\\@\:\?\#\.]+(?:\:[\@\/\\\?#\.]*[^\d\@\:\/\\\?#\.]+|(?:\.[^\/\\@\:\?\#\.]+)+))?(?:(?:\:|^)(\d+))?)(((?:\/|\\|^)[^\?#]*)?(\?([^#]*))?)(#[\s\S]*)?$/;
20
+ // -------/// ---------------1---------------------------------///////////////////2-----3--------//////// ------4----2/////5---------------------------------------------------6------------------------------------------------------------------------------------//////////////-7--5///8-------9----------//10--11---10/8/--12----////
21
+ var reg = /^([^\:\/\\\?#\[]+\:(?![^\:\/\\\?\#]*@|[\/\\][^\/\\]))?(?:\/\/|\\\\)?(?:(([^\:\/\\\?#]+)?(?:\:([^\/\\\?#]+))?)@)?(([^\/\\@\?\#\.]*?[^\/\\@\:\?\#\.\d][^\/\\@\:\?\#\.]*?|[^\/\\@\:\?\#\.]+(?:\:[^\@\/\\\?#\.]*[^\d\@\:\/\\\?#\.]+|(?:\.[^\/\\@\:\?\#\.]+)+))?(?:(?:\:|^)(\d+))?)(((?:\/|\\|^)[^\?#]*)?(\?([^#]*))?)(#[\s\S]*)?$/;
22
22
  var hrefDescriptor = {
23
23
  get() {
24
24
  var href = '';
@@ -50,6 +50,7 @@ test("./cluster-opt.html", "pathname", "./cluster-opt.html")
50
50
  test(":cluster-opt.html", "pathname", ":cluster-opt.html")
51
51
  test("d:/cluster-opt.html", "pathname", "d:/cluster-opt.html")
52
52
  test("d:\\cluster-opt.html", "pathname", "d:\\cluster-opt.html")
53
+ test("d:\\work\\cluster-opt.html", "pathname", "d:\\work\\cluster-opt.html")
53
54
  test("ftp:\\\\cluster-opt.html", "host", "cluster-opt.html")
54
55
  test("\\\\cluster-opt.html", "host", "cluster-opt.html")
55
56
  test("https://a:b@測試?abc#foo", "host", "測試")
@@ -1,3 +1,8 @@
1
+ class join {
2
+ constructor(t) {
3
+ this.text = t;
4
+ }
5
+ }
1
6
  var seek = function (object, seeker) {
2
7
  if (seeker === null || seeker === undefined || isEmpty(object)) return;
3
8
  if (seeker instanceof Function) {
@@ -6,15 +11,48 @@ var seek = function (object, seeker) {
6
11
  if (typeof seeker === "string") {
7
12
  if (/^(['"`])[\s\S]*$/i.test(seeker)) return seeker.replace(/^(['"`])([\s\S*])\1?$/, "$2");
8
13
  if (seeker === '' || seeker === ".") return object;
9
- seeker = seeker.split(".");
14
+ var s = [];
15
+ s.unshift(seeker.replace(/[\.]([^\.\[]*)|\[([^\]]*)\]|\<([^\>]*)\>/g, (a, b, c, d) => {
16
+ if (b) s.push(b);
17
+ else if (d) {
18
+ s.push(new join(c));
19
+ }
20
+ else if (c) {
21
+ s.push(c || '0');
22
+ }
23
+ return '';
24
+ }));
25
+ seeker = s;
10
26
  }
11
27
  if (seeker instanceof Array) {
12
28
  if (!seeker.length) return;
13
- for (var cx = 0, dx = seeker.length; cx < dx; cx++) {
29
+ loop: for (var cx = 0, dx = seeker.length; cx < dx; cx++) {
14
30
  var key = seeker[cx];
15
31
  if (typeof key === "string") {
16
- object = object[key];
17
- } else {
32
+ if (/[\^]/.test(key)) {
33
+ key = key.split(/[\^]/);
34
+ for (var k of key) {
35
+ if (k in object) {
36
+ object = object[k];
37
+ continue loop;
38
+ }
39
+ }
40
+ object = undefined;
41
+ } else {
42
+ object = object[key];
43
+ }
44
+ }
45
+ else if (key instanceof join) {
46
+ if (object instanceof Array) {
47
+ var restk = seeker.slice(cx + 1, dx);
48
+ object = object.map(a => seek(a, restk)).join(key.text);
49
+ }
50
+ else {
51
+ object = '';
52
+ }
53
+ break;
54
+ }
55
+ else {
18
56
  object = seek(object, key);
19
57
  }
20
58
  if (object === undefined || object === null) return;
package/coms/kugou/api.js CHANGED
@@ -32,7 +32,21 @@
32
32
  "play-url;mid=rid": "get:data music/playUrl?type=music",
33
33
  },
34
34
 
35
- "http://newlyric.kuwo.cn/": {
36
- "kuwo-lrc;rid": "get:data newlyric.lrc",
35
+ "http://m.kuwo.cn/newh5/": {
36
+ "kuwo-lrc;musicId=rid": "get:data.lrclist singles/songinfoandlrc",
37
+ },
38
+ "https://music.163.com/weapi/": {
39
+ "search-yyyy": "form:result.songs cloudsearch/get/web#songname=name&avatar=al.picUrl",
40
+ "yyyy-url": "form:data[0] song/enhance/player/url/v1#encode=type",
41
+ "yyyy-lrc": "form:lrc.lyric song/lyric",
42
+ "yyyy-info": "form:lrc.lyric v3/song/detail",
43
+ },
44
+ "http://lyrics.kugou.com/": {
45
+ "search-krc;keyword=songName&duration=time&hash": "get:candidates[0] search?ver=1&man=yes&client=pc",
46
+ "download-krc;accesskey&id": "get:content download?ver=1&client=pc&fmt=krc&charset=utf8"
47
+ },
48
+ "https://music.91q.com/": {// 千千静听/百度音乐
49
+ "search-qqjt;word": "get:data.typeTrack v1/search#songname=title&singername=artist<、>.name&avatar=pic&priced=isVip",
50
+ "qqjt-url?TSID": "get:data v1/song/tracklink#url=path"
37
51
  }
38
- })
52
+ })
package/coms/kugou/krc.js CHANGED
@@ -2,34 +2,87 @@ var secret = [64, 71, 97, 119, 94, 50, 116, 71, 81, 54, 49, 45, 206, 210, 110, 1
2
2
  var isTrident = /Trident/i.test(navigator.userAgent);
3
3
  function krc(list = div()) {
4
4
  care(list, function (info) {
5
- console.log(info)
6
5
  if (info.type !== "kugo") {
7
6
  remove(list.children);
8
- return;
9
- }
10
- cross("get", `http://lyrics.kugou.com/search?ver=1&man=yes&client=pc&keyword=${info.songName}&duration=${info.time}&hash=${info.hash}`).done(function (response) {
11
- if (!response.response) return;
12
- var liric = JSON.parse(response.response);
13
- var info = liric.candidates[0];
14
- if (!info) return;
15
- var url = `http://lyrics.kugou.com/download?ver=1&client=pc&id=${info.id}&accesskey=${info.accesskey}&fmt=krc&charset=utf8`;
16
- info && cross("get", url).done(function (response) {
17
- if (!response.response) return;
18
- var krc = JSON.parse(response.responseText || response.response);
19
- var content = fromBase64(krc.content);
20
- content = content.slice(4).map((a, i) => a ^ secret[i % 16]);
21
- var bufff = thirdParty$inflate(content.slice(2));
22
- var krc = decodeUTF8(bufff);
23
- remove(list.children);
24
- var children = createKRC(krc);
7
+ if (info.lrc) {
8
+ var children = createLRC(info.lrc);
25
9
  appendChild(list, children);
26
10
  list.process = children.process;
27
- });
28
- });
29
-
11
+ }
12
+ return;
13
+ }
14
+ var content = info.krc.slice(4).map((a, i) => a ^ secret[i % 16]);
15
+ var bufff = thirdParty$inflate(content.slice(2));
16
+ var krc = decodeUTF8(bufff);
17
+ remove(list.children);
18
+ var children = createKRC(krc);
19
+ appendChild(list, children);
20
+ list.process = children.process;
30
21
  })
31
22
  return list;
32
23
  }
24
+ function createLRC(lrc) {
25
+ var saved_rows = [];
26
+ for (var row of lrc.split(/[\r\n]+/)) {
27
+ var data = /^\s*\[(.*?)\](.*?)$/.exec(row);
28
+ if (!data) {
29
+ if (!isProduction) console.info("%c未解析%c", "color:#c28", "color:#333", row, data);
30
+ continue;
31
+ }
32
+ var [, time, words] = data;
33
+ var startTime = 0;
34
+ var times = time.split(":");
35
+ while (times.length) {
36
+ startTime = startTime * 60 + +times.shift();
37
+ }
38
+ saveToOrderedArray(saved_rows, {
39
+ value: startTime,
40
+ startTime,
41
+ text: words
42
+ });
43
+ }
44
+ var krcList = saved_rows.map(a => {
45
+ var r = document.createElement('div');
46
+ text(r, a.text);
47
+ return r;
48
+ });
49
+ var savedIndex = 0;
50
+ krcList.process = function (offset, length) {
51
+ var index = getIndexFromOrderedArray(saved_rows, offset);
52
+ var current_row = saved_rows[index];
53
+ if (current_row) {
54
+ var ele = krcList[index];
55
+ var firstChild = krcList[0];
56
+ if (index > 0) {
57
+ if (index !== savedIndex) {
58
+ savedIndex = index;
59
+ setClass(krcList, index);
60
+ }
61
+ }
62
+ if (ele && firstChild && firstChild.isMounted) {
63
+ var marginTop = (firstChild.parentNode.offsetHeight - ele.offsetHeight >> 1) - ele.offsetTop + firstChild.offsetTop;
64
+ css(firstChild, `margin-top:${marginTop | 0}px;`);
65
+ }
66
+ }
67
+ };
68
+ return krcList;
69
+ }
70
+
71
+ function setClass(krcList, index) {
72
+ var ele = krcList[index];
73
+ krcList.slice(0, index).map(function (a, cx, arr) {
74
+ removeClass(a, "active after after-active before-active");
75
+ addClass(a, "before");
76
+ });
77
+ removeClass(ele, "after before after-active before-active");
78
+ addClass(krcList[index - 1], 'before-active');
79
+ addClass(ele, "active");
80
+ krcList.slice(index + 1).map(function (a) {
81
+ removeClass(a, "before active after-active before-active");
82
+ addClass(a, "after");
83
+ });
84
+ if (index + 2 < krcList.length) addClass(krcList[index + 1], 'after-active');
85
+ }
33
86
  function createKRC(krc) {
34
87
  var saved_rows = [];
35
88
  krc.split(/[\r\n]+/).map(function (row) {
@@ -77,18 +130,7 @@ function createKRC(krc) {
77
130
  var marginTop = (firstChild.parentNode.offsetHeight - ele.offsetHeight >> 1) - ele.offsetTop + firstChild.offsetTop;
78
131
  if (index > 0) {
79
132
  if (markerLabel.parentNode !== ele) {
80
- krcList.slice(0, index).map(function (a, cx, arr) {
81
- removeClass(a, "active after after-active before-active");
82
- addClass(a, "before");
83
- });
84
- removeClass(ele, "after before after-active before-active");
85
- addClass(krcList[index - 1], 'before-active');
86
- addClass(ele, "active");
87
- krcList.slice(index + 1).map(function (a) {
88
- removeClass(a, "before active after-active before-active");
89
- addClass(a, "after");
90
- });
91
- if (index + 2 < krcList.length) addClass(krcList[index + 1], 'after-active');
133
+ setClass(krcList, index);
92
134
  ele.insertBefore(markerLabel, ele.firstChild);
93
135
  }
94
136
  var word_ele = ele.children[current_row_index + 1];
@@ -5,7 +5,7 @@ musicList.forEach(function (music) {
5
5
  });
6
6
 
7
7
  var isSameSong = function (m1, m2) {
8
- return m1 === m2 || m1.mid && m1.mid === m2.mid || m1.hash && m1.hash === m2.hash;
8
+ return m1 === m2 || m1.mid && m1.mid === m2.mid || m1.hash && m1.hash === m2.hash || m1.id && m1.id === m2.id;
9
9
  };
10
10
 
11
11
  function addMethod(name, func) {
@@ -11,9 +11,9 @@
11
11
  <span ng-bind="totalTime"></span>
12
12
  </div>
13
13
  <div class="song">
14
- <span class="name" ng-bind=info.songName></span>
15
- <span class="spliter" ng-if="info.songName&&info.singerName">&nbsp;-&nbsp;</span>
16
- <span class="singer" ng-bind=info.singerName></span>
14
+ <span class="name" ng-bind=songName></span>
15
+ <span class="spliter" ng-if="songName&&singerName">&nbsp;-&nbsp;</span>
16
+ <span class="singer" ng-bind=singerName></span>
17
17
  </div>
18
18
  </div>
19
19
  <btn class="prev" ng-click=play(index-1)></btn>
@@ -4,10 +4,35 @@ var playModes = kugou$playModes;
4
4
  var playModeData = data.getInstance("play-mode");
5
5
  var playList = kugou$playList();
6
6
  var patchMusicInfo = async function (info) {
7
- var res = null;
7
+ var res = null, krc;
8
8
  switch (info.type) {
9
+ case "qqjt":
10
+ info.lrc = (await cross("get", info.lyric)).response;
11
+ console.log(info)
12
+ res = await data.from("qqjt-url", qqjc({
13
+ TSID: info.id
14
+ }))
15
+ break;
16
+ case "yyyy":
17
+ res = await data.from("yyyy-url", yyyc.encode({
18
+ ids: JSON.stringify([info.id]),
19
+ csrf_token: '',
20
+ level: "standard",
21
+ encodeType: "aac"
22
+ }));
23
+ info.lrc = await data.from('yyyy-lrc', yyyc.encode({
24
+ id: info.id,
25
+ lv: 0,
26
+ // tv: 0,
27
+ }));
28
+ info.singerName = info.singername;
29
+ info.songName = info.songname;
30
+ break;
9
31
  case "kuwo":
10
32
  res = await data.from("play-url", info);
33
+ info.lrc = await data.from("kuwo-lrc", info, function (lrc) {
34
+ return lrc.map(l => `[${l.time}]${l.lineLyric}`).join('\r\n');
35
+ });
11
36
  info.avatar = info.pic;
12
37
  info.singerName = info.singername;
13
38
  info.songName = info.songname;
@@ -15,6 +40,9 @@ var patchMusicInfo = async function (info) {
15
40
  case "kugo":
16
41
  default:
17
42
  res = await data.from("song-info", info);
43
+ krc = await data.from("search-krc", res);
44
+ krc = await data.from("download-krc", krc);
45
+ info.krc = fromBase64(krc);
18
46
  if (res.fail_process === 12) res.priced = true;
19
47
  if (res.imgUrl) {
20
48
  res.avatar = res.imgUrl.replace(/\{size\}/ig, 200);
@@ -109,6 +137,12 @@ var $scope = {
109
137
  canvas: kugou$dance,
110
138
  activeList: playList,
111
139
  index: 0,
140
+ get songName() {
141
+ return this.info.singername || this.info.singerName;
142
+ },
143
+ get singerName() {
144
+ return this.info.songname || this.info.songName;
145
+ },
112
146
  update() {
113
147
  if (touching) return;
114
148
  let _audio = $scope.audio;
@@ -0,0 +1,172 @@
1
+ var md5 = function () {
2
+ var ERROR = "input is invalid type"
3
+ var HEX_CHARS = "0123456789abcdef".split("");
4
+ var EXTRA = [128, 32768, 8388608, -2147483648],
5
+ SHIFT = [0, 8, 16, 24],
6
+ OUTPUT_TYPES = ["hex", "array", "digest", "buffer", "arrayBuffer", "base64"],
7
+ BASE64_ENCODE_CHAR = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""),
8
+ blocks = [], buffer8;
9
+ var createOutputMethod = function (e) {
10
+ return function (t) {
11
+ return new Md5(!0).update(t)[e]()
12
+ }
13
+ }
14
+ function Md5(e) {
15
+ if (e)
16
+ blocks[0] = blocks[16] = blocks[1] = blocks[2] = blocks[3] = blocks[4] = blocks[5] = blocks[6] = blocks[7] = blocks[8] = blocks[9] = blocks[10] = blocks[11] = blocks[12] = blocks[13] = blocks[14] = blocks[15] = 0,
17
+ this.blocks = blocks,
18
+ this.buffer8 = buffer8;
19
+ else
20
+ this.blocks = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
21
+ this.h0 = this.h1 = this.h2 = this.h3 = this.start = this.bytes = this.hBytes = 0,
22
+ this.finalized = this.hashed = !1,
23
+ this.first = !0
24
+ }
25
+ Md5.prototype.update = function (e) {
26
+ if (!this.finalized) {
27
+ var t, n = typeof e;
28
+ if ("string" != n) {
29
+ if ("object" != n)
30
+ throw ERROR;
31
+ if (null === e)
32
+ throw ERROR;
33
+ else if (!Array.isArray(e))
34
+ throw ERROR;
35
+ t = !0
36
+ }
37
+ for (var r, i, s = 0, o = e.length, a = this.blocks, l = this.buffer8; s < o;) {
38
+ if (this.hashed && (this.hashed = !1,
39
+ a[0] = a[16],
40
+ a[16] = a[1] = a[2] = a[3] = a[4] = a[5] = a[6] = a[7] = a[8] = a[9] = a[10] = a[11] = a[12] = a[13] = a[14] = a[15] = 0),
41
+ t)
42
+ for (i = this.start; s < o && i < 64; ++s)
43
+ a[i >> 2] |= e[s] << SHIFT[3 & i++];
44
+ else
45
+ for (i = this.start; s < o && i < 64; ++s)
46
+ (r = e.charCodeAt(s)) < 128 ? a[i >> 2] |= r << SHIFT[3 & i++] : (r < 2048 ? a[i >> 2] |= (192 | r >> 6) << SHIFT[3 & i++] : (r < 55296 || 57344 <= r ? a[i >> 2] |= (224 | r >> 12) << SHIFT[3 & i++] : (r = 65536 + ((1023 & r) << 10 | 1023 & e.charCodeAt(++s)),
47
+ a[i >> 2] |= (240 | r >> 18) << SHIFT[3 & i++],
48
+ a[i >> 2] |= (128 | r >> 12 & 63) << SHIFT[3 & i++]),
49
+ a[i >> 2] |= (128 | r >> 6 & 63) << SHIFT[3 & i++]),
50
+ a[i >> 2] |= (128 | 63 & r) << SHIFT[3 & i++]);
51
+ this.lastByteIndex = i,
52
+ this.bytes += i - this.start,
53
+ 64 <= i ? (this.start = i - 64,
54
+ this.hash(),
55
+ this.hashed = !0) : this.start = i
56
+ }
57
+ return 4294967295 < this.bytes && (this.hBytes += this.bytes / 4294967296 << 0,
58
+ this.bytes = this.bytes % 4294967296),
59
+ this
60
+ }
61
+ }
62
+
63
+ Md5.prototype.finalize = function () {
64
+ if (!this.finalized) {
65
+ this.finalized = !0;
66
+ var e = this.blocks
67
+ , t = this.lastByteIndex;
68
+ e[t >> 2] |= EXTRA[3 & t],
69
+ 56 <= t && (this.hashed || this.hash(),
70
+ e[0] = e[16],
71
+ e[16] = e[1] = e[2] = e[3] = e[4] = e[5] = e[6] = e[7] = e[8] = e[9] = e[10] = e[11] = e[12] = e[13] = e[14] = e[15] = 0),
72
+ e[14] = this.bytes << 3,
73
+ e[15] = this.hBytes << 3 | this.bytes >>> 29,
74
+ this.hash()
75
+ }
76
+ }
77
+
78
+ Md5.prototype.hash = function () {
79
+ var e, t, n, r, i, s, o = this.blocks;
80
+ t = this.first ? ((t = ((e = ((e = o[0] - 680876937) << 7 | e >>> 25) - 271733879 << 0) ^ (n = ((n = (-271733879 ^ (r = ((r = (-1732584194 ^ 2004318071 & e) + o[1] - 117830708) << 12 | r >>> 20) + e << 0) & (-271733879 ^ e)) + o[2] - 1126478375) << 17 | n >>> 15) + r << 0) & (r ^ e)) + o[3] - 1316259209) << 22 | t >>> 10) + n << 0 : (e = this.h0,
81
+ t = this.h1,
82
+ n = this.h2,
83
+ ((t += ((e = ((e += ((r = this.h3) ^ t & (n ^ r)) + o[0] - 680876936) << 7 | e >>> 25) + t << 0) ^ (n = ((n += (t ^ (r = ((r += (n ^ e & (t ^ n)) + o[1] - 389564586) << 12 | r >>> 20) + e << 0) & (e ^ t)) + o[2] + 606105819) << 17 | n >>> 15) + r << 0) & (r ^ e)) + o[3] - 1044525330) << 22 | t >>> 10) + n << 0),
84
+ t = ((t += ((e = ((e += (r ^ t & (n ^ r)) + o[4] - 176418897) << 7 | e >>> 25) + t << 0) ^ (n = ((n += (t ^ (r = ((r += (n ^ e & (t ^ n)) + o[5] + 1200080426) << 12 | r >>> 20) + e << 0) & (e ^ t)) + o[6] - 1473231341) << 17 | n >>> 15) + r << 0) & (r ^ e)) + o[7] - 45705983) << 22 | t >>> 10) + n << 0,
85
+ t = ((t += ((e = ((e += (r ^ t & (n ^ r)) + o[8] + 1770035416) << 7 | e >>> 25) + t << 0) ^ (n = ((n += (t ^ (r = ((r += (n ^ e & (t ^ n)) + o[9] - 1958414417) << 12 | r >>> 20) + e << 0) & (e ^ t)) + o[10] - 42063) << 17 | n >>> 15) + r << 0) & (r ^ e)) + o[11] - 1990404162) << 22 | t >>> 10) + n << 0,
86
+ t = ((t += ((e = ((e += (r ^ t & (n ^ r)) + o[12] + 1804603682) << 7 | e >>> 25) + t << 0) ^ (n = ((n += (t ^ (r = ((r += (n ^ e & (t ^ n)) + o[13] - 40341101) << 12 | r >>> 20) + e << 0) & (e ^ t)) + o[14] - 1502002290) << 17 | n >>> 15) + r << 0) & (r ^ e)) + o[15] + 1236535329) << 22 | t >>> 10) + n << 0,
87
+ t = ((t += ((r = ((r += (t ^ n & ((e = ((e += (n ^ r & (t ^ n)) + o[1] - 165796510) << 5 | e >>> 27) + t << 0) ^ t)) + o[6] - 1069501632) << 9 | r >>> 23) + e << 0) ^ e & ((n = ((n += (e ^ t & (r ^ e)) + o[11] + 643717713) << 14 | n >>> 18) + r << 0) ^ r)) + o[0] - 373897302) << 20 | t >>> 12) + n << 0,
88
+ t = ((t += ((r = ((r += (t ^ n & ((e = ((e += (n ^ r & (t ^ n)) + o[5] - 701558691) << 5 | e >>> 27) + t << 0) ^ t)) + o[10] + 38016083) << 9 | r >>> 23) + e << 0) ^ e & ((n = ((n += (e ^ t & (r ^ e)) + o[15] - 660478335) << 14 | n >>> 18) + r << 0) ^ r)) + o[4] - 405537848) << 20 | t >>> 12) + n << 0,
89
+ t = ((t += ((r = ((r += (t ^ n & ((e = ((e += (n ^ r & (t ^ n)) + o[9] + 568446438) << 5 | e >>> 27) + t << 0) ^ t)) + o[14] - 1019803690) << 9 | r >>> 23) + e << 0) ^ e & ((n = ((n += (e ^ t & (r ^ e)) + o[3] - 187363961) << 14 | n >>> 18) + r << 0) ^ r)) + o[8] + 1163531501) << 20 | t >>> 12) + n << 0,
90
+ t = ((t += ((r = ((r += (t ^ n & ((e = ((e += (n ^ r & (t ^ n)) + o[13] - 1444681467) << 5 | e >>> 27) + t << 0) ^ t)) + o[2] - 51403784) << 9 | r >>> 23) + e << 0) ^ e & ((n = ((n += (e ^ t & (r ^ e)) + o[7] + 1735328473) << 14 | n >>> 18) + r << 0) ^ r)) + o[12] - 1926607734) << 20 | t >>> 12) + n << 0,
91
+ t = ((t += ((s = (r = ((r += ((i = t ^ n) ^ (e = ((e += (i ^ r) + o[5] - 378558) << 4 | e >>> 28) + t << 0)) + o[8] - 2022574463) << 11 | r >>> 21) + e << 0) ^ e) ^ (n = ((n += (s ^ t) + o[11] + 1839030562) << 16 | n >>> 16) + r << 0)) + o[14] - 35309556) << 23 | t >>> 9) + n << 0,
92
+ t = ((t += ((s = (r = ((r += ((i = t ^ n) ^ (e = ((e += (i ^ r) + o[1] - 1530992060) << 4 | e >>> 28) + t << 0)) + o[4] + 1272893353) << 11 | r >>> 21) + e << 0) ^ e) ^ (n = ((n += (s ^ t) + o[7] - 155497632) << 16 | n >>> 16) + r << 0)) + o[10] - 1094730640) << 23 | t >>> 9) + n << 0,
93
+ t = ((t += ((s = (r = ((r += ((i = t ^ n) ^ (e = ((e += (i ^ r) + o[13] + 681279174) << 4 | e >>> 28) + t << 0)) + o[0] - 358537222) << 11 | r >>> 21) + e << 0) ^ e) ^ (n = ((n += (s ^ t) + o[3] - 722521979) << 16 | n >>> 16) + r << 0)) + o[6] + 76029189) << 23 | t >>> 9) + n << 0,
94
+ t = ((t += ((s = (r = ((r += ((i = t ^ n) ^ (e = ((e += (i ^ r) + o[9] - 640364487) << 4 | e >>> 28) + t << 0)) + o[12] - 421815835) << 11 | r >>> 21) + e << 0) ^ e) ^ (n = ((n += (s ^ t) + o[15] + 530742520) << 16 | n >>> 16) + r << 0)) + o[2] - 995338651) << 23 | t >>> 9) + n << 0,
95
+ t = ((t += ((r = ((r += (t ^ ((e = ((e += (n ^ (t | ~r)) + o[0] - 198630844) << 6 | e >>> 26) + t << 0) | ~n)) + o[7] + 1126891415) << 10 | r >>> 22) + e << 0) ^ ((n = ((n += (e ^ (r | ~t)) + o[14] - 1416354905) << 15 | n >>> 17) + r << 0) | ~e)) + o[5] - 57434055) << 21 | t >>> 11) + n << 0,
96
+ t = ((t += ((r = ((r += (t ^ ((e = ((e += (n ^ (t | ~r)) + o[12] + 1700485571) << 6 | e >>> 26) + t << 0) | ~n)) + o[3] - 1894986606) << 10 | r >>> 22) + e << 0) ^ ((n = ((n += (e ^ (r | ~t)) + o[10] - 1051523) << 15 | n >>> 17) + r << 0) | ~e)) + o[1] - 2054922799) << 21 | t >>> 11) + n << 0,
97
+ t = ((t += ((r = ((r += (t ^ ((e = ((e += (n ^ (t | ~r)) + o[8] + 1873313359) << 6 | e >>> 26) + t << 0) | ~n)) + o[15] - 30611744) << 10 | r >>> 22) + e << 0) ^ ((n = ((n += (e ^ (r | ~t)) + o[6] - 1560198380) << 15 | n >>> 17) + r << 0) | ~e)) + o[13] + 1309151649) << 21 | t >>> 11) + n << 0,
98
+ t = ((t += ((r = ((r += (t ^ ((e = ((e += (n ^ (t | ~r)) + o[4] - 145523070) << 6 | e >>> 26) + t << 0) | ~n)) + o[11] - 1120210379) << 10 | r >>> 22) + e << 0) ^ ((n = ((n += (e ^ (r | ~t)) + o[2] + 718787259) << 15 | n >>> 17) + r << 0) | ~e)) + o[9] - 343485551) << 21 | t >>> 11) + n << 0,
99
+ this.first ? (this.h0 = e + 1732584193 << 0,
100
+ this.h1 = t - 271733879 << 0,
101
+ this.h2 = n - 1732584194 << 0,
102
+ this.h3 = r + 271733878 << 0,
103
+ this.first = !1) : (this.h0 = this.h0 + e << 0,
104
+ this.h1 = this.h1 + t << 0,
105
+ this.h2 = this.h2 + n << 0,
106
+ this.h3 = this.h3 + r << 0)
107
+ }
108
+
109
+ Md5.prototype.hex = function () {
110
+ this.finalize();
111
+ var e = this.h0
112
+ , t = this.h1
113
+ , n = this.h2
114
+ , r = this.h3;
115
+ return HEX_CHARS[e >> 4 & 15] + HEX_CHARS[15 & e] + HEX_CHARS[e >> 12 & 15] + HEX_CHARS[e >> 8 & 15] + HEX_CHARS[e >> 20 & 15] + HEX_CHARS[e >> 16 & 15] + HEX_CHARS[e >> 28 & 15] + HEX_CHARS[e >> 24 & 15] + HEX_CHARS[t >> 4 & 15] + HEX_CHARS[15 & t] + HEX_CHARS[t >> 12 & 15] + HEX_CHARS[t >> 8 & 15] + HEX_CHARS[t >> 20 & 15] + HEX_CHARS[t >> 16 & 15] + HEX_CHARS[t >> 28 & 15] + HEX_CHARS[t >> 24 & 15] + HEX_CHARS[n >> 4 & 15] + HEX_CHARS[15 & n] + HEX_CHARS[n >> 12 & 15] + HEX_CHARS[n >> 8 & 15] + HEX_CHARS[n >> 20 & 15] + HEX_CHARS[n >> 16 & 15] + HEX_CHARS[n >> 28 & 15] + HEX_CHARS[n >> 24 & 15] + HEX_CHARS[r >> 4 & 15] + HEX_CHARS[15 & r] + HEX_CHARS[r >> 12 & 15] + HEX_CHARS[r >> 8 & 15] + HEX_CHARS[r >> 20 & 15] + HEX_CHARS[r >> 16 & 15] + HEX_CHARS[r >> 28 & 15] + HEX_CHARS[r >> 24 & 15]
116
+ }
117
+
118
+ Md5.prototype.toString = Md5.prototype.hex,
119
+ Md5.prototype.digest = function () {
120
+ this.finalize();
121
+ var e = this.h0
122
+ , t = this.h1
123
+ , n = this.h2
124
+ , r = this.h3;
125
+ return [255 & e, e >> 8 & 255, e >> 16 & 255, e >> 24 & 255, 255 & t, t >> 8 & 255, t >> 16 & 255, t >> 24 & 255, 255 & n, n >> 8 & 255, n >> 16 & 255, n >> 24 & 255, 255 & r, r >> 8 & 255, r >> 16 & 255, r >> 24 & 255]
126
+ }
127
+
128
+ Md5.prototype.array = Md5.prototype.digest
129
+ Md5.prototype.arrayBuffer = function () {
130
+ this.finalize();
131
+ var e = new ArrayBuffer(16)
132
+ , t = new Uint32Array(e);
133
+ return t[0] = this.h0,
134
+ t[1] = this.h1,
135
+ t[2] = this.h2,
136
+ t[3] = this.h3,
137
+ e
138
+ }
139
+
140
+ Md5.prototype.buffer = Md5.prototype.arrayBuffer
141
+ Md5.prototype.base64 = function () {
142
+ for (var e, t, n, r = "", i = this.array(), s = 0; s < 15;)
143
+ e = i[s++],
144
+ t = i[s++],
145
+ n = i[s++],
146
+ r += BASE64_ENCODE_CHAR[e >>> 2] + BASE64_ENCODE_CHAR[63 & (e << 4 | t >>> 4)] + BASE64_ENCODE_CHAR[63 & (t << 2 | n >>> 6)] + BASE64_ENCODE_CHAR[63 & n];
147
+ return e = i[s],
148
+ r + (BASE64_ENCODE_CHAR[e >>> 2] + BASE64_ENCODE_CHAR[e << 4 & 63] + "==")
149
+ };
150
+ return createOutputMethod("hex");
151
+ }();
152
+ var secret = "0b50b02fd0d73a9c4c8c3a781c30845f";
153
+ function createSign(e) {
154
+ if ("[object Object]" !== Object.prototype.toString.call(e))
155
+ throw new Error("The parameter of query must be a Object.");
156
+ var t = Math.floor(Date.now() / 1e3);
157
+ extend(e, {
158
+ timestamp: t,
159
+ appid: 16073360
160
+ });
161
+ var n = Object.keys(e);
162
+ n.sort();
163
+ for (var r = "", i = 0; i < n.length; i++) {
164
+ var s = n[i];
165
+ r += (0 == i ? "" : "&") + s + "=" + e[s]
166
+ }
167
+ return extend(e, {
168
+ sign: md5(r += secret),
169
+ timestamp: t,
170
+ })
171
+ }
172
+ return createSign;
@@ -34,14 +34,13 @@ function main(elem) {
34
34
  songName = songName.replace(/^[\s\S]*?\s*\-\s*/, '');
35
35
  }
36
36
  }
37
- $scope.song = {
38
- hash: item.hash || item.hashid,
39
- imgurl: item.imgurl,
37
+ $scope.song = extendIfNeeded(Object.create(item), {
38
+ imgurl: item.imgurl || item.avatar,
40
39
  singer: singerName,
41
40
  items: item instanceof Array ? item : null,
42
41
  songMarked: mark(songName, elem.mark),
43
42
  singerMarked: mark(singerName, elem.mark)
44
- };
43
+ });
45
44
  if ($scope.song.items) {
46
45
  attr(elem, 'group', true);
47
46
  }
@@ -96,6 +96,12 @@
96
96
  [type=kuwo] {
97
97
  background-image: url("icons/kuwo.png");
98
98
  }
99
+ [type=yyyy] {
100
+ background-image: url("icons/yyyy.ico");
101
+ }
102
+ [type=qqjt] {
103
+ background-image: url("icons/qqjt.ico");
104
+ }
99
105
  }
100
106
 
101
107
  &[group]>.song {