efront 4.35.2 → 4.35.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.
- package/#/345/233/275/351/231/205/345/214/226.yml +3 -0
- package/coms/basic/#loader.js +1 -1
- package/coms/basic/Table.js +26 -0
- package/coms/basic/escapeRegExp.js +24 -0
- package/coms/basic/escapeRegExp_test.js +35 -0
- package/coms/basic/math.js +106 -4
- package/coms/basic/math.md +128 -25
- package/coms/basic/spaces.js +1 -1
- package/coms/compile/Program.js +1 -1
- package/coms/compile/common.js +1 -1
- package/coms/compile//347/256/227/345/274/217.js +62 -20
- package/coms/compile//347/256/227/345/274/217_test.js +6 -2
- package/coms/compile//347/264/240/351/246/250.js +5 -4
- package/coms/compile//347/264/240/351/246/250_test.js +21 -1
- package/coms/explorer/main.less +1 -0
- package/coms/reptile/colors.js +2 -1
- package/coms/zimoli/arriswise.js +6 -1
- package/coms/zimoli/color-config.less +1 -1
- package/coms/zimoli/confirm.js +1 -1
- package/coms/zimoli/getGenerator.js +0 -1
- package/coms/zimoli/list.js +609 -576
- package/coms/zimoli/popup.js +1 -1
- package/coms/zimoli/prompt.js +4 -1
- package/coms/zimoli/scrollbar.less +1 -1
- package/coms/zimoli/table.js +1 -1
- package/coms/zimoli/vbox.js +1 -0
- package/coms//350/214/250/350/217/260//344/270/212/350/211/262.xht +5 -1
- package/coms//350/214/250/350/217/260//346/240/207/347/255/276/345/214/226.js +9 -1
- package/coms//350/214/250/350/217/260//346/270/262/346/237/223.js +1 -1
- package/coms//350/214/250/350/217/260//347/274/226/350/276/221/346/241/206.xht +16 -2
- package/coms//350/214/250/350/217/260//350/257/255/350/250/200.js +5 -0
- package/package.json +1 -1
- package/public/efront.js +1 -1
- package/public//346/226/207/344/273/266/347/263/273/347/273/237//344/270/273/351/241/265.jsp +2 -2
- package/debug.log +0 -3
package/coms/zimoli/popup.js
CHANGED
|
@@ -141,7 +141,7 @@ var popup_view = function (element, target, style) {
|
|
|
141
141
|
}
|
|
142
142
|
else if (target instanceof Array) {
|
|
143
143
|
if (isNode(style) && style.$mask) addMask(element, style);
|
|
144
|
-
else if (typeof style === 'boolean') addMask(element);
|
|
144
|
+
else if (typeof style === 'boolean' && style) addMask(element);
|
|
145
145
|
popup_to_point(element, target);
|
|
146
146
|
}
|
|
147
147
|
else if (target === true || target < 0) {
|
package/coms/zimoli/prompt.js
CHANGED
|
@@ -35,6 +35,7 @@ function prompt() {
|
|
|
35
35
|
var submit = null;
|
|
36
36
|
var wrap = false;
|
|
37
37
|
var value = '';
|
|
38
|
+
var mask = false;
|
|
38
39
|
var attrs = {
|
|
39
40
|
type: null,
|
|
40
41
|
max: null,
|
|
@@ -48,6 +49,7 @@ function prompt() {
|
|
|
48
49
|
else if (typeof arg === 'string') msg = arg;
|
|
49
50
|
else if (isArray(arg)) opts = arg;
|
|
50
51
|
else if (isFunction(arg) || arg instanceof RegExp) check = arg;
|
|
52
|
+
else if (typeof arg === 'boolean') mask = arg;
|
|
51
53
|
else if (isObject(arg)) {
|
|
52
54
|
if (isFunction(arg.test)) check = arg;
|
|
53
55
|
if (isFunction(arg.check)) check = arg.check;
|
|
@@ -55,6 +57,7 @@ function prompt() {
|
|
|
55
57
|
if (isString(arg.msg || arg.title)) msg = arg.msg || arg.title;
|
|
56
58
|
if (isHandled(arg.info)) info = arg.info;
|
|
57
59
|
if (isHandled(arg.value)) value = arg.value;
|
|
60
|
+
if (isHandled(arg.mask)) mask = arg.mask;
|
|
58
61
|
for (var k in attrs) {
|
|
59
62
|
if (k in arg) attrs[k] = arg[k];
|
|
60
63
|
}
|
|
@@ -117,7 +120,7 @@ function prompt() {
|
|
|
117
120
|
} else {
|
|
118
121
|
c.errored = true;
|
|
119
122
|
}
|
|
120
|
-
});
|
|
123
|
+
}, { target: mask });
|
|
121
124
|
on('mounted')(ipt, function () {
|
|
122
125
|
if (setDisable) setDisable();
|
|
123
126
|
setTimeout(function () {
|
package/coms/zimoli/table.js
CHANGED
package/coms/zimoli/vbox.js
CHANGED
|
@@ -147,6 +147,7 @@ function ybox(generator) {
|
|
|
147
147
|
} else {
|
|
148
148
|
var wheelTime = 0;
|
|
149
149
|
onmousewheel(_box, function (event) {
|
|
150
|
+
if (event.defaultPrevented) return;
|
|
150
151
|
event.preventDefault();
|
|
151
152
|
var isNew = event.timeStamp - wheelTime > 120;
|
|
152
153
|
wheelTime = event.timeStamp;
|
|
@@ -71,6 +71,7 @@ var codecolor = function (c) {
|
|
|
71
71
|
};
|
|
72
72
|
var setExpress = function (o, label) {
|
|
73
73
|
if (!o.text || o.wraped) return;
|
|
74
|
+
if (o.type !== EXPRESS) return;
|
|
74
75
|
o.wraped = true;
|
|
75
76
|
var keys = o.text.split(".");
|
|
76
77
|
var pdot = !keys[0] && keys.length > 1;
|
|
@@ -124,6 +125,13 @@ var codecolor = function (c) {
|
|
|
124
125
|
switch (o.type) {
|
|
125
126
|
case LABEL:
|
|
126
127
|
o.text = wrap(o.text, 'label');
|
|
128
|
+
var label = o.tack;
|
|
129
|
+
used[o.tack].forEach(o => {
|
|
130
|
+
if (o.text !== label) return;
|
|
131
|
+
var prev = o.prev;
|
|
132
|
+
if (!prev || prev.type !== STRAP || prev.isend || !/^(break|continue)$/.test(prev.text)) return;
|
|
133
|
+
o.text = wrap(o.text, 'label');
|
|
134
|
+
})
|
|
127
135
|
break;
|
|
128
136
|
case QUOTED:
|
|
129
137
|
if (o.length || !o.text) {
|
|
@@ -157,7 +165,7 @@ var codecolor = function (c) {
|
|
|
157
165
|
if (o.tag_leave) o.tag_leave = wrapcode(o.tag_leave, 'stamp');
|
|
158
166
|
if (o.entry) o.entry = wrapcode(o.entry, 'stamp');
|
|
159
167
|
if (o.leave) o.leave = wrapcode(o.leave, 'stamp');
|
|
160
|
-
o.tag = wrapcode(o.tag, '
|
|
168
|
+
o.tag = wrapcode(o.tag, 'tag');
|
|
161
169
|
o.forEach(setcolor);
|
|
162
170
|
break;
|
|
163
171
|
case SCOPED:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<style>
|
|
2
2
|
& {
|
|
3
|
-
overflow:
|
|
3
|
+
overflow: hidden;
|
|
4
4
|
border-top: 0;
|
|
5
5
|
border-bottom: 0;
|
|
6
6
|
display: block;
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
margin-left:-@{w}em;
|
|
44
44
|
border-left: @{w}em solid transparent;
|
|
45
45
|
width: 100%;
|
|
46
|
-
overflow-x:
|
|
46
|
+
overflow-x: hidden;
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
>[nlist] {
|
|
@@ -107,6 +107,13 @@
|
|
|
107
107
|
height: 1.36em;
|
|
108
108
|
}
|
|
109
109
|
}
|
|
110
|
+
|
|
111
|
+
>scrollbar {
|
|
112
|
+
right: 0;
|
|
113
|
+
left: auto !important;
|
|
114
|
+
position: fixed;
|
|
115
|
+
z-index: 1;
|
|
116
|
+
}
|
|
110
117
|
</style>
|
|
111
118
|
<编辑框 spellcheck=false e-class="上色.className" e-style="{whiteSpace:'pre'}" ntype:="codeSpan">
|
|
112
119
|
<list contenteditable="false" nlist# :src="(r,i) in coderows" -style="{height:codeHeight}">
|
|
@@ -115,9 +122,16 @@
|
|
|
115
122
|
<list clist# body contenteditable:="contenteditable" :src="(r,i) in coderows" -style="{height:codeHeight}">
|
|
116
123
|
<d -html="r"></d>
|
|
117
124
|
</list>
|
|
125
|
+
<scrollbar x></scrollbar>
|
|
126
|
+
<scrollbar y :target="this.parentNode"></scrollbar>
|
|
118
127
|
</编辑框>
|
|
119
128
|
<script>
|
|
120
129
|
var coder = this;
|
|
130
|
+
onmousewheel(this, function (event) {
|
|
131
|
+
if (!event.shiftKey) return;
|
|
132
|
+
event.preventDefault();
|
|
133
|
+
clist.scrollLeft += event.deltaY;
|
|
134
|
+
});
|
|
121
135
|
vbox(this);
|
|
122
136
|
var contenteditable = !this.readonly;
|
|
123
137
|
watch(coder, {
|
|
@@ -40,6 +40,7 @@ gl.straps = gl.straps.concat(
|
|
|
40
40
|
"step", "smoothstep",
|
|
41
41
|
"mix", "clamp"
|
|
42
42
|
);
|
|
43
|
+
const ms = new compile$算式.MathScript;
|
|
43
44
|
var rust = new compile$Javascript;
|
|
44
45
|
rust.powermap = Object.assign({}, rust.powermap);
|
|
45
46
|
rust.powermap["->"] = 0;
|
|
@@ -137,6 +138,9 @@ var 语言 = {
|
|
|
137
138
|
json(a) {
|
|
138
139
|
return 扫描(a, json);
|
|
139
140
|
},
|
|
141
|
+
mathscript(a) {
|
|
142
|
+
return 扫描(a, ms);
|
|
143
|
+
},
|
|
140
144
|
less(a) {
|
|
141
145
|
var c = 扫描(a, 素心);
|
|
142
146
|
setless(c);
|
|
@@ -187,4 +191,5 @@ var 语言 = {
|
|
|
187
191
|
语言.tsx = 语言.ts = 语言.typescript;
|
|
188
192
|
语言.xht = 语言.jsp = 语言.asp = 语言.php = 语言.xml = 语言.html;
|
|
189
193
|
语言.vue = 语言.xht;
|
|
194
|
+
语言.ms = 语言.mathscript;
|
|
190
195
|
return 语言;
|