efront 3.25.1 → 3.25.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.
@@ -1 +1 @@
1
- buildScroll("rank-info");
1
+ buildScroll("rank-info", undefined, 'rank-title');
package/coms/kugou/api.js CHANGED
@@ -7,6 +7,7 @@
7
7
  "song-mix;": "mget:script:nth-last-child(2) mixsong/:hashid.html",
8
8
  "rank-list": "get:[].panel-img-list%20li rank/list#href=a!href&=a!href\\rank-info&imgurl=img!_src&name=p|innerText",
9
9
  "rank-info": "get:[].panel-songslist%20li rank/info/:id#src=!id&name=.panel-songs-item-name|innerText&data=.panel-songs-item-download/innerText",
10
+ "rank-title": "get:.page-title rank/info/:id#title=!innerText",
10
11
  "plist-index": "get:[].panel-img-list%20li plist/index#href=a!href&=a!href\\plist-info&imgurl=img!_src&name=.panel-img-content-first|innerText&count=.panel-img-content-sub|innerText",
11
12
  "plist-info": "mget:[].panel-songslist%20li plist/list/:id/#name=.panel-songs-item-name|innerText&data=.panel-songs-item-download/innerText",
12
13
  "search-hot": "get api/v3/search/hot?format=json&plat=0&count=30",
@@ -1,4 +1,4 @@
1
- <list ng-src="s in datas" min-width:=datas[0]?.name?480:120>
1
+ <list ng-src="s in datas" min-width:=datas[0]?.name?320:120>
2
2
  <padding>
3
3
  <song ng-click="run(s)" ng-class="{activate:s.hash===musicList.active_hash,imgonly:!datas[0]?.name}" ng-src="s"></song>
4
4
  </padding>
@@ -20,4 +20,7 @@
20
20
  >div+div {
21
21
  border-top: 1px solid #ccc;
22
22
  }
23
+ }
24
+ .padding{
25
+ max-width: 100%;
23
26
  }
@@ -1,4 +1,4 @@
1
- function Main(dataid, datapath) {
1
+ function Main(dataid, datapath, titleid) {
2
2
  var _titlebar = titlebar(" ");
3
3
  var page = createVboxWithState(state);
4
4
  page.initialStyle = 'margin-left:100%';
@@ -24,7 +24,7 @@ function Main(dataid, datapath) {
24
24
  bindScroll(_titlebar, page);
25
25
  var loadedId;
26
26
  function main(params) {
27
- var { _text, title, name = _text || title, id } = params;
27
+ var { _text, title = "", name = _text || title, id } = params;
28
28
  if (loadedId !== id) {
29
29
  loadedId = id;
30
30
  var ranklist = data.from(dataid, {
@@ -32,6 +32,15 @@ function Main(dataid, datapath) {
32
32
  }, parseSongsList);
33
33
  page.$scope.config = params;
34
34
  page.$scope.datas = ranklist;
35
+ if (titleid) {
36
+ data.from(titleid, {
37
+ id
38
+ }).then(function ({ title }) {
39
+ console.log(arguments)
40
+ _titlebar.setTitle(title);
41
+ document.title = title;
42
+ })
43
+ }
35
44
  }
36
45
  _titlebar.setTitle(name);
37
46
  document.title = name;
@@ -1,13 +1,14 @@
1
1
  var complete_class = "complete";
2
2
  var inadequate_class = "lack";
3
- function lattice(element, minWidth, maxWidth = minWidth << 1, layers) {
4
- var boxCount;
3
+ function lattice(element, minWidth, _maxWidth, layers) {
4
+ var boxCount, maxWidth = _maxWidth || minWidth << 1;
5
5
  var resize = function () {
6
6
  var _layers = layers || _box.src || [];
7
7
  if (!_layers.length) return;
8
8
  var _minWidth = +(element.getAttribute("min-width") || element.getAttribute("item-width"));
9
9
  if (_minWidth) {
10
10
  minWidth = _minWidth;
11
+ maxWidth = _maxWidth || minWidth << 1;
11
12
  }
12
13
  var clientWidth = parseFloat(freePixel(_box.clientWidth));
13
14
  if (!clientWidth) return;
@@ -719,6 +719,7 @@ function renderElement(element, scope = element.$scope, parentScopes = element.$
719
719
  var renders = element.renders;
720
720
  element.renders = [];
721
721
  for (var k in binds) {
722
+ if (k === 'src') continue;
722
723
  if (directives.hasOwnProperty(k)) {
723
724
  directives[k].call(element, [withContext, binds[k]])
724
725
  }
@@ -734,6 +735,7 @@ function renderElement(element, scope = element.$scope, parentScopes = element.$
734
735
  if (element[k] !== props[k]) element[k] = props[k];
735
736
  } catch (e) { }
736
737
  }
738
+ if (binds.src) directives.src.call(element, [withContext, binds.src]);
737
739
  ons.forEach(([on, key, value]) => on.call(element, key, [withContext, value]));
738
740
  if (renders.length) element.renders.push.apply(element.renders, renders);
739
741
  if (element.renders.length) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "efront",
3
- "version": "3.25.1",
3
+ "version": "3.25.2",
4
4
  "description": "一个开发工具,开放源代码,自带组件库和编译环境,可以用来开发web组件,web应用或nodejs模块,或做为已有代码的加密工具,也可以做为静态页面服务器或跨域中转服务器使用",
5
5
  "main": "public/efront.js",
6
6
  "directories": {