efront 3.24.2 → 3.24.7

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 (113) hide show
  1. package/apps/kugou/main.js +1 -3
  2. package/coms/basic/assert.js +10 -2
  3. package/coms/basic/extends_.js +13 -0
  4. package/coms/basic/loader.js +22 -17
  5. package/coms/basic/mark.js +155 -0
  6. package/coms/basic/queue.js +11 -14
  7. package/coms/basic/rest_.js +27 -0
  8. package/coms/basic/submit_.js +3 -1
  9. package/{apps → coms}/kugou/api.js +2 -0
  10. package/coms/kugou/buildList.js +7 -1
  11. package/coms/kugou/player.js +1 -0
  12. package/coms/kugou/song.html +1 -1
  13. package/coms/kugou/song.js +1 -0
  14. package/coms/kugou/song.less +12 -1
  15. package/coms/zimoli/cloneVisible.js +1 -0
  16. package/coms/zimoli/compile.js +64 -1
  17. package/coms/{compile → zimoli}/compile_test.js +0 -0
  18. package/coms/zimoli/data.js +8 -2
  19. package/coms/zimoli/input.js +6 -4
  20. package/coms/zimoli/render.js +1 -1
  21. package/package.json +1 -1
  22. package/public/efront.js +1 -1
  23. package/readme.md +0 -1
  24. package/apps/zimoli/book/main.js +0 -8
  25. package/apps/zimoli/broadcast/main.js +0 -8
  26. package/apps/zimoli/collection/add.html +0 -13
  27. package/apps/zimoli/collection/add.js +0 -14
  28. package/apps/zimoli/collection/add.less +0 -0
  29. package/apps/zimoli/collection/main.html +0 -0
  30. package/apps/zimoli/collection/main.js +0 -13
  31. package/apps/zimoli/collection/main.less +0 -8
  32. package/apps/zimoli/config.js +0 -14
  33. package/apps/zimoli/extra/pending.html +0 -1
  34. package/apps/zimoli/extra/pending.js +0 -8
  35. package/apps/zimoli/extra/pending.less +0 -15
  36. package/apps/zimoli/files/info.js +0 -7
  37. package/apps/zimoli/files/main.js +0 -108
  38. package/apps/zimoli/files/main.less +0 -26
  39. package/apps/zimoli/images/avatar.png +0 -0
  40. package/apps/zimoli/images/background.jpg +0 -0
  41. package/apps/zimoli/index.html +0 -42
  42. package/apps/zimoli/kugou/font/demo.css +0 -539
  43. package/apps/zimoli/kugou/font/demo_index.html +0 -1159
  44. package/apps/zimoli/kugou/font/iconfont.css +0 -189
  45. package/apps/zimoli/kugou/font/iconfont.eot +0 -0
  46. package/apps/zimoli/kugou/font/iconfont.js +0 -1
  47. package/apps/zimoli/kugou/font/iconfont.svg +0 -155
  48. package/apps/zimoli/kugou/font/iconfont.ttf +0 -0
  49. package/apps/zimoli/kugou/font/iconfont.woff +0 -0
  50. package/apps/zimoli/kugou/font/iconfont.woff2 +0 -0
  51. package/apps/zimoli/kugou/listen.html +0 -15
  52. package/apps/zimoli/kugou/listen.js +0 -37
  53. package/apps/zimoli/kugou/listen.less +0 -114
  54. package/apps/zimoli/kugou/mine.html +0 -53
  55. package/apps/zimoli/kugou/mine.js +0 -21
  56. package/apps/zimoli/kugou/mine.less +0 -106
  57. package/apps/zimoli/kugou/search.js +0 -109
  58. package/apps/zimoli/kugou/search.less +0 -50
  59. package/apps/zimoli/kugou/sing.js +0 -42
  60. package/apps/zimoli/kugou/sing.less +0 -93
  61. package/apps/zimoli/kugou/view.html +0 -39
  62. package/apps/zimoli/kugou/view.js +0 -17
  63. package/apps/zimoli/kugou/view.less +0 -84
  64. package/apps/zimoli/login/qq.js +0 -20
  65. package/apps/zimoli/login/qq_callback.html +0 -15
  66. package/apps/zimoli/main.js +0 -87
  67. package/apps/zimoli/main.less +0 -81
  68. package/apps/zimoli/message/chatList.js +0 -57
  69. package/apps/zimoli/message/chatList.less +0 -52
  70. package/apps/zimoli/message/commentList.js +0 -55
  71. package/apps/zimoli/message/commentList.less +0 -55
  72. package/apps/zimoli/message/informList.js +0 -69
  73. package/apps/zimoli/message/informList.less +0 -51
  74. package/apps/zimoli/message/main.js +0 -59
  75. package/apps/zimoli/message/main.less +0 -51
  76. package/apps/zimoli/message/praiseList.js +0 -3
  77. package/apps/zimoli/message/praiseList.less +0 -7
  78. package/apps/zimoli/nearby/main.js +0 -8
  79. package/apps/zimoli/skin/main.js +0 -47
  80. package/apps/zimoli/skin/main.less +0 -31
  81. package/apps/zimoli/user/getPassword.js +0 -82
  82. package/apps/zimoli/user/getPassword.less +0 -14
  83. package/apps/zimoli/user/login.html +0 -12
  84. package/apps/zimoli/user/login.js +0 -50
  85. package/apps/zimoli/user/login.less +0 -139
  86. package/apps/zimoli/user/profile-bg.jpg +0 -0
  87. package/apps/zimoli/user/profile.html +0 -32
  88. package/apps/zimoli/user/profile.js +0 -63
  89. package/apps/zimoli/user/profile.less +0 -50
  90. package/apps/zimoli/user/register.js +0 -20
  91. package/apps/zimoli/user/register.less +0 -3
  92. package/apps/zimoli/user/setting.js +0 -90
  93. package/apps/zimoli/user/setting.less +0 -11
  94. package/apps/zimoli/user/welcome.js +0 -36
  95. package/apps/zimoli/user/welcome.less +0 -136
  96. package/apps/zimoli/watch/main.html +0 -22
  97. package/apps/zimoli/watch/main.js +0 -76
  98. package/apps/zimoli/watch/main.less +0 -54
  99. package/apps/zimoli/yuanfen/main.js +0 -55
  100. package/apps/zimoli/yuanfen/main.json +0 -0
  101. package/coms/compile/breakcode.js +0 -78
  102. package/coms/compile/common.js +0 -688
  103. package/coms/compile/compile.js +0 -64
  104. package/coms/compile/keywords.js +0 -6
  105. package/coms/compile/namelist.js +0 -142
  106. package/coms/compile/namelist_test.js +0 -7
  107. package/coms/compile/required.js +0 -20
  108. package/coms/compile/scanner.js +0 -653
  109. package/coms/compile/scanner2.js +0 -921
  110. package/coms/compile/scanner2_test.js +0 -85
  111. package/coms/compile/scanner_test.js +0 -10
  112. package/coms/compile/washcode.js +0 -313
  113. package/coms/zimoli/mark.js +0 -70
package/readme.md CHANGED
@@ -1,6 +1,5 @@
1
1
 
2
2
  # efront 思想
3
- 上次参加一个github的面试,一帮中国人组成的团队跟我说不能用中文。他妈的,老子就要用中文,你们狗逼管的着吗?
4
3
  1. 每个文件只导出一份数据,这一份数据可以是 boolean,number,string,function,object,bigint,null,undefined 中的任意一种
5
4
  2. 文件名即变量名,在其他文件中引用当前文件导出的变量,只要使用当前文件的文件名(不含后缀)即可
6
5
  3. 无环形引用(相互调用:a引用b,b引用a;首尾引用:a引用b,b引用...c,c引用a)
@@ -1,8 +0,0 @@
1
- // 中文编码 utf-8
2
- var tbar = titlebar("预订", null, false);
3
- var page = createElement(div, tbar);
4
- css(page, "font-size:40px;color:#fff;");
5
-
6
- function main() {
7
- return vbox(page);
8
- }
@@ -1,8 +0,0 @@
1
- // 中文编码 utf-8
2
- var tbar = titlebar("大厅", null, false);
3
- var page = createElement(div, tbar);
4
- css(page, "font-size:40px;color:#fff;");
5
-
6
- function main() {
7
- return page;
8
- }
@@ -1,13 +0,0 @@
1
- <form>
2
- <field title="名称"><input /></field>
3
- <field title="类型">
4
- <select ng-model="type">
5
- <option value="1" selected>歌曲</option>
6
- <option value="2">歌单</option>
7
- </select>
8
- </field>
9
- <field title="文件链接">
10
- <option value=""></option>
11
- </field>
12
- <btn>确定</btn>
13
- </form>
@@ -1,14 +0,0 @@
1
- titlebar("添加到我的收藏");
2
- var page = div();
3
- console.log(page);
4
- page.innerHTML = add;
5
- render(page, {
6
- type: "1",
7
- titlebar,
8
- field,
9
- btn: button,
10
- select
11
- });
12
- function main() {
13
- return page;
14
- }
File without changes
File without changes
@@ -1,13 +0,0 @@
1
- titlebar("我的收藏", {
2
- 添加() {
3
- go("add", "添加到我的收藏");
4
- }
5
- });
6
- var page = div();
7
- page.innerHTML = main;
8
- page.initialStyle = "margin-left:100%;z-index:1";
9
- login();
10
-
11
- var main = function () {
12
- return page;
13
- };
@@ -1,8 +0,0 @@
1
- & {
2
- position: absolute;
3
- top: 0;
4
- bottom: 0;
5
- left: 0;
6
- right: 0;
7
- background: #fff;
8
- }
@@ -1,14 +0,0 @@
1
- new Promise(function (ok) {
2
- var config = {
3
- target: 'fc',
4
- api_domain: "efront.cc:5989",
5
- api_base: "http://efront.cc:5989/",
6
- };
7
- if (!/(localhost|127\.0\.0\.1)/i.test(location.hostname)) return ok(config);
8
- var testconfig = {
9
- target: 'fc',
10
- api_domain: "localhost:5984",
11
- api_base: "http://localhost:5984/",
12
- };
13
- cross("get", testconfig.api_base).done(e => ok(testconfig)).error(e => ok(config));
14
- })
@@ -1 +0,0 @@
1
- <div>您访问的功能区正在开发中..</div>
@@ -1,8 +0,0 @@
1
- var tbar = titlebar("建设中");
2
- var page = div();
3
- page.innerHTML = pending;
4
- page.initialStyle = "transform:perspective 800px rotate3d(0,0,1,180deg);background:#000;z-index:2;margin-left:100%;";
5
- function main(title) {
6
- tbar.querySelector("label").innerHTML = title;
7
- return page;
8
- }
@@ -1,15 +0,0 @@
1
- & {
2
- position: absolute;
3
- left: 0;
4
- top: 0;
5
- bottom: 0;
6
- right: 0;
7
- padding-top: 50px;
8
- font-size: 16px;
9
- color: #666;
10
- background: #fff;
11
- perspective: 800px;
12
- text-align: center;
13
- line-height: 200px;
14
- transform: rotate3d(0, 1, 0, 0deg);
15
- }
@@ -1,7 +0,0 @@
1
- titlebar();
2
- var page = div();
3
- page.initialStyle = "margin-left:100%;z-index:2";
4
- console.log(page);
5
- function main() {
6
- return page;
7
- }
@@ -1,108 +0,0 @@
1
- var tbar = titlebar(i18n("文件管理器", "File Manager"), {
2
- [i18n("管理", "Table View")]() {
3
- go("/files/info");
4
- }
5
- });
6
- var page = createVboxWithState(state);
7
- page.innerHTML = `
8
- <list></list>
9
- `;
10
-
11
- var roots = [];
12
- var currentFolder = [];
13
- var request = function (value, folder) {
14
- if (!request.rest) request.rest = [];
15
- var { rest, loading } = request;
16
- if (folder && folder !== request.folder) {
17
- if (isNumber(loading)) {
18
- clearTimeout(loading);
19
- } else if (loading) {
20
- loading.cancel();
21
- loading = false;
22
- }
23
- rest.splice(0, rest.length);
24
- };
25
- if (value) {
26
- rest.push(value);
27
- request.folder = folder;
28
- }
29
- if (loading) return;
30
- request.loading = setTimeout(function () {
31
- var files = request.rest.splice(0, rest.length);
32
- if (!files.length) return rest.loading = false;
33
- request.loading = api("/file/info", {
34
- files: files.map(function (file) {
35
- return file.name;
36
- }),
37
- folder: request.folder
38
- }).success(function (result) {
39
- result.result.map(function (file, cx) {
40
- extend(files[cx], file);
41
- });
42
- _list.refresh();
43
- request.loading = false;
44
- if (request.rest.length) request();
45
- }).error(function () {
46
- request.loading = false;
47
- if (request.rest.length) request();
48
- });
49
- }, 200);
50
- }
51
- var _list = tree(function (data) {
52
- var { value } = data;
53
- var { isFolder } = value;
54
- if (isFolder) {
55
- return role$folder(value);
56
- }
57
- if (!value.isFile) {
58
- request(value, value.folder);
59
- }
60
- return role$file(value);
61
- });
62
- onactive(_list, function (event) {
63
- var { value, item } = event;
64
- if (value.isFolder && !item.length) {
65
- _list.addData(value.children.map(function (name) {
66
- return {
67
- tab: data.tab + 1,
68
- name,
69
- folder: value.pathname,
70
- pathname: (value.pathname + "/" + name).replace(/\\/g, "/")
71
- };
72
- }), item);
73
- item.closed = true;
74
- } else if (value.isFile) {
75
- if (view$image.support(item.value)) {
76
- var viewer = view$image(item);
77
- } else if (view$video.support(item.value)) {
78
- var viewer = view$video(item);
79
- }
80
- if (viewer) {
81
- confirm(viewer, item.name, ["关闭"]);
82
- }
83
- }
84
- })
85
- render(page, {
86
- go,
87
- List(a) {
88
- return _list;
89
- },
90
- btn(a) {
91
- return button(a);
92
- }
93
- })
94
- page.initialStyle = "margin-left:100%;z-index:2;";
95
- onback(function () {
96
- });
97
- api = api.newBaseUrl("/api");
98
- api("/file/info").success(function (response) {
99
- roots = currentFolder = response.result;
100
- roots.map(function (a) {
101
- a.tab = 0;
102
- })
103
- _list.setData(roots);
104
- _list.go(0);
105
- });
106
- function main() {
107
- return page;
108
- }
@@ -1,26 +0,0 @@
1
- & {
2
- padding-top: 50px;
3
- width: 100%;
4
- height: 100%;
5
- position: absolute;
6
- left: 0;
7
- right: 0;
8
- top: 0;
9
- bottom: 0;
10
- background-color: #f2f4f9;
11
- }
12
- .button{
13
- text-align: left;
14
- white-space: normal;
15
- vertical-align: middle;
16
- }
17
- .tree{
18
- text-align: left;
19
- display: block;
20
- height: auto;
21
- max-height: 100%;
22
- position: relative;
23
- >.button{
24
- background-color: transparent;
25
- }
26
- }
Binary file
Binary file
@@ -1,42 +0,0 @@
1
- <!DOCTYPE html>
2
- <!--
3
- http://efront.cc
4
- -->
5
- <html lang="zh-CN">
6
-
7
- <head>
8
- <meta http-equiv="X-UA-Compatible" content="IE=Edge" />
9
- <meta charset="utf-8" />
10
- <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
11
- <link rel="Shortcut Icon" href="/favicon.ico" type="image/x-icon" />
12
- <meta name="viewport" content="initial-scale=1,maximum-scale=1,width=device-width" />
13
- <title>紫茉莉 项目</title>
14
- <script deleteoncompile efrontloader>
15
- // 若要在开发环境使用内置组件,请保留此script标签中的代码,在编译发布时,这里的代码会自动删除
16
- </script>
17
- <style>
18
- html {
19
- height: 100%;
20
- font-family: "SF Pro SC", "SF Pro Text", "SF Pro Icons", "PingFang SC", "Helvetica Neue", "Helvetica", "Arial", sans-serif;
21
- }
22
-
23
- *,
24
- ::before,
25
- ::after {
26
- box-sizing: border-box;
27
- }
28
-
29
- body {
30
- border: none;
31
- margin: 0;
32
- padding: 0;
33
- height: 100%;
34
- overflow: hidden;
35
- }
36
- </style>
37
- <script>window.e=0</script>
38
- </head>
39
-
40
- <body scroll=no max-render=1440></body>
41
-
42
- </html>