cnhis-design-vue 3.1.14-beta.13 → 3.1.14-beta.16
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/es/node_modules/@formily/path/esm/contexts.js +22 -0
- package/es/node_modules/@formily/path/esm/destructor.js +124 -0
- package/es/node_modules/@formily/path/esm/index.js +579 -0
- package/es/node_modules/@formily/path/esm/matcher.js +199 -0
- package/es/node_modules/@formily/path/esm/parser.js +402 -0
- package/es/node_modules/@formily/path/esm/shared.js +73 -0
- package/es/node_modules/@formily/path/esm/tokenizer.js +287 -0
- package/es/node_modules/@formily/path/esm/tokens.js +240 -0
- package/es/node_modules/@formily/path/esm/types.js +17 -0
- package/es/packages/big-table/src/BigTable.vue.d.ts +13 -6
- package/es/packages/big-table/src/BigTable.vue_vue_type_script_setup_true_lang.js +4 -4
- package/es/packages/big-table/src/utils.js +1 -0
- package/es/packages/big-table/style/index.css +133 -0
- package/es/packages/fabric-chart/src/FabricChart.js +0 -1
- package/es/packages/fabric-chart/src/hooks/useLeft.js +15 -4
- package/es/packages/form-render/src/components/renderer/combination.d.ts +6 -0
- package/es/packages/form-render/src/components/renderer/combination.js +53 -16
- package/es/packages/form-render/src/components/renderer/select.js +2 -4
- package/es/packages/form-render/src/components/renderer/simpleComponent.d.ts +1 -0
- package/es/packages/form-render/src/components/renderer/simpleComponent.js +4 -3
- package/es/packages/form-render/src/hooks/useFieldListAdaptor.js +1 -0
- package/es/packages/form-render/src/types/fieldItem.d.ts +1 -0
- package/es/packages/index.css +133 -0
- package/es/packages/shortcut-provider/src/types/index.d.ts +11 -9
- package/es/packages/shortcut-provider/src/utils/index.js +5 -5
- package/es/packages/shortcut-setter/index.d.ts +3248 -1486
- package/es/packages/shortcut-setter/src/ShortcutSetter.js +9 -5
- package/es/packages/shortcut-setter/src/ShortcutSetter.vue.d.ts +3248 -1486
- package/es/packages/shortcut-setter/src/ShortcutSetterItem.js +24 -11
- package/es/packages/shortcut-setter/src/ShortcutSetterItem.vue.d.ts +1700 -1661
- package/package.json +1 -1
|
@@ -0,0 +1,287 @@
|
|
|
1
|
+
import { eofTok, nameTok, ignoreTok, bracketDRTok, braceLTok, braceRTok, dbStarTok, starTok, bangTok, dotTok, bracketDLTok, bracketLTok, expandTok, bracketRTok, parenLTok, parenRTok, commaTok, colonTok } from './tokens.js';
|
|
2
|
+
import { bracketDContext } from './contexts.js';
|
|
3
|
+
|
|
4
|
+
var nonASCIIwhitespace = /[\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff]/;
|
|
5
|
+
var fullCharCodeAtPos = function (input, pos) {
|
|
6
|
+
if (String.fromCharCode)
|
|
7
|
+
return input.codePointAt(pos);
|
|
8
|
+
var code = input.charCodeAt(pos);
|
|
9
|
+
if (code <= 0xd7ff || code >= 0xe000)
|
|
10
|
+
return code;
|
|
11
|
+
var next = input.charCodeAt(pos + 1);
|
|
12
|
+
return (code << 10) + next - 0x35fdc00;
|
|
13
|
+
};
|
|
14
|
+
var isRewordCode = function (code) {
|
|
15
|
+
return code === 42 ||
|
|
16
|
+
code === 46 ||
|
|
17
|
+
code === 33 ||
|
|
18
|
+
code === 91 ||
|
|
19
|
+
code === 93 ||
|
|
20
|
+
code === 40 ||
|
|
21
|
+
code === 41 ||
|
|
22
|
+
code === 44 ||
|
|
23
|
+
code === 58 ||
|
|
24
|
+
code === 126 ||
|
|
25
|
+
code === 123 ||
|
|
26
|
+
code === 125;
|
|
27
|
+
};
|
|
28
|
+
var getError = function (message, props) {
|
|
29
|
+
var err = new Error(message);
|
|
30
|
+
Object.assign(err, props);
|
|
31
|
+
return err;
|
|
32
|
+
};
|
|
33
|
+
var slice = function (string, start, end) {
|
|
34
|
+
var str = '';
|
|
35
|
+
for (var i = start; i < end; i++) {
|
|
36
|
+
var ch = string.charAt(i);
|
|
37
|
+
if (ch !== '\\') {
|
|
38
|
+
str += ch;
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
return str;
|
|
42
|
+
};
|
|
43
|
+
var Tokenizer = /** @class */ (function () {
|
|
44
|
+
function Tokenizer(input) {
|
|
45
|
+
this.input = input;
|
|
46
|
+
this.state = {
|
|
47
|
+
context: [],
|
|
48
|
+
type: null,
|
|
49
|
+
pos: 0,
|
|
50
|
+
};
|
|
51
|
+
this.type_ = null;
|
|
52
|
+
}
|
|
53
|
+
Tokenizer.prototype.curContext = function () {
|
|
54
|
+
return this.state.context[this.state.context.length - 1];
|
|
55
|
+
};
|
|
56
|
+
Tokenizer.prototype.includesContext = function (context) {
|
|
57
|
+
for (var len = this.state.context.length - 1; len >= 0; len--) {
|
|
58
|
+
if (this.state.context[len] === context) {
|
|
59
|
+
return true;
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
return false;
|
|
63
|
+
};
|
|
64
|
+
Tokenizer.prototype.unexpect = function (type) {
|
|
65
|
+
type = type || this.state.type;
|
|
66
|
+
return getError("Unexpect token \"".concat(type.flag, "\" in ").concat(this.state.pos, " char."), {
|
|
67
|
+
pos: this.state.pos,
|
|
68
|
+
});
|
|
69
|
+
};
|
|
70
|
+
Tokenizer.prototype.expectNext = function (type, next) {
|
|
71
|
+
if (type && type.expectNext) {
|
|
72
|
+
if (next && !type.expectNext.call(this, next)) {
|
|
73
|
+
throw getError("Unexpect token \"".concat(next.flag, "\" token should not be behind \"").concat(type.flag, "\" token.(").concat(this.state.pos, "th char)"), {
|
|
74
|
+
pos: this.state.pos,
|
|
75
|
+
});
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
};
|
|
79
|
+
Tokenizer.prototype.expectPrev = function (type, prev) {
|
|
80
|
+
if (type && type.expectPrev) {
|
|
81
|
+
if (prev && !type.expectPrev.call(this, prev)) {
|
|
82
|
+
throw getError("Unexpect token \"".concat(type.flag, "\" should not be behind \"").concat(prev.flag, "\"(").concat(this.state.pos, "th char)."), {
|
|
83
|
+
pos: this.state.pos,
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
};
|
|
88
|
+
Tokenizer.prototype.match = function (type) {
|
|
89
|
+
return this.state.type === type;
|
|
90
|
+
};
|
|
91
|
+
Tokenizer.prototype.skipSpace = function () {
|
|
92
|
+
if (this.curContext() === bracketDContext)
|
|
93
|
+
return;
|
|
94
|
+
loop: while (this.state.pos < this.input.length) {
|
|
95
|
+
var ch = this.input.charCodeAt(this.state.pos);
|
|
96
|
+
switch (ch) {
|
|
97
|
+
case 32:
|
|
98
|
+
case 160:
|
|
99
|
+
++this.state.pos;
|
|
100
|
+
break;
|
|
101
|
+
case 13:
|
|
102
|
+
if (this.input.charCodeAt(this.state.pos + 1) === 10) {
|
|
103
|
+
++this.state.pos;
|
|
104
|
+
}
|
|
105
|
+
case 10:
|
|
106
|
+
case 8232:
|
|
107
|
+
case 8233:
|
|
108
|
+
++this.state.pos;
|
|
109
|
+
break;
|
|
110
|
+
default:
|
|
111
|
+
if ((ch > 8 && ch < 14) ||
|
|
112
|
+
(ch >= 5760 && nonASCIIwhitespace.test(String.fromCharCode(ch)))) {
|
|
113
|
+
++this.state.pos;
|
|
114
|
+
}
|
|
115
|
+
else {
|
|
116
|
+
break loop;
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
};
|
|
121
|
+
Tokenizer.prototype.next = function () {
|
|
122
|
+
this.type_ = this.state.type;
|
|
123
|
+
if (this.input.length <= this.state.pos) {
|
|
124
|
+
return this.finishToken(eofTok);
|
|
125
|
+
}
|
|
126
|
+
this.skipSpace();
|
|
127
|
+
this.readToken(this.getCode(), this.state.pos > 0 ? this.getCode(this.state.pos - 1) : -Infinity);
|
|
128
|
+
};
|
|
129
|
+
Tokenizer.prototype.getCode = function (pos) {
|
|
130
|
+
if (pos === void 0) { pos = this.state.pos; }
|
|
131
|
+
return fullCharCodeAtPos(this.input, pos);
|
|
132
|
+
};
|
|
133
|
+
Tokenizer.prototype.eat = function (type) {
|
|
134
|
+
if (this.match(type)) {
|
|
135
|
+
this.next();
|
|
136
|
+
return true;
|
|
137
|
+
}
|
|
138
|
+
else {
|
|
139
|
+
return false;
|
|
140
|
+
}
|
|
141
|
+
};
|
|
142
|
+
Tokenizer.prototype.readKeyWord = function () {
|
|
143
|
+
var startPos = this.state.pos, string = '';
|
|
144
|
+
while (true) {
|
|
145
|
+
var code = this.getCode();
|
|
146
|
+
var prevCode = this.getCode(this.state.pos - 1);
|
|
147
|
+
if (this.input.length === this.state.pos) {
|
|
148
|
+
string = slice(this.input, startPos, this.state.pos + 1);
|
|
149
|
+
break;
|
|
150
|
+
}
|
|
151
|
+
if (!isRewordCode(code) || prevCode === 92) {
|
|
152
|
+
if (code === 32 ||
|
|
153
|
+
code === 160 ||
|
|
154
|
+
code === 10 ||
|
|
155
|
+
code === 8232 ||
|
|
156
|
+
code === 8233) {
|
|
157
|
+
string = slice(this.input, startPos, this.state.pos);
|
|
158
|
+
break;
|
|
159
|
+
}
|
|
160
|
+
if (code === 13 && this.input.charCodeAt(this.state.pos + 1) === 10) {
|
|
161
|
+
string = slice(this.input, startPos, this.state.pos);
|
|
162
|
+
break;
|
|
163
|
+
}
|
|
164
|
+
if ((code > 8 && code < 14) ||
|
|
165
|
+
(code >= 5760 && nonASCIIwhitespace.test(String.fromCharCode(code)))) {
|
|
166
|
+
string = slice(this.input, startPos, this.state.pos);
|
|
167
|
+
break;
|
|
168
|
+
}
|
|
169
|
+
this.state.pos++;
|
|
170
|
+
}
|
|
171
|
+
else {
|
|
172
|
+
string = slice(this.input, startPos, this.state.pos);
|
|
173
|
+
break;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
this.finishToken(nameTok, string);
|
|
177
|
+
};
|
|
178
|
+
Tokenizer.prototype.readIngoreString = function () {
|
|
179
|
+
var startPos = this.state.pos, prevCode, string = '';
|
|
180
|
+
while (true) {
|
|
181
|
+
var code = this.getCode();
|
|
182
|
+
if (this.state.pos >= this.input.length)
|
|
183
|
+
break;
|
|
184
|
+
if ((code === 91 || code === 93) && prevCode === 92) {
|
|
185
|
+
this.state.pos++;
|
|
186
|
+
prevCode = '';
|
|
187
|
+
}
|
|
188
|
+
else if (code == 93 && prevCode === 93) {
|
|
189
|
+
string = this.input
|
|
190
|
+
.slice(startPos, this.state.pos - 1)
|
|
191
|
+
.replace(/\\([\[\]])/g, '$1');
|
|
192
|
+
this.state.pos++;
|
|
193
|
+
break;
|
|
194
|
+
}
|
|
195
|
+
else {
|
|
196
|
+
this.state.pos++;
|
|
197
|
+
prevCode = code;
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
this.finishToken(ignoreTok, string);
|
|
201
|
+
this.finishToken(bracketDRTok);
|
|
202
|
+
};
|
|
203
|
+
Tokenizer.prototype.finishToken = function (type, value) {
|
|
204
|
+
var preType = this.state.type;
|
|
205
|
+
this.state.type = type;
|
|
206
|
+
if (value !== undefined)
|
|
207
|
+
this.state.value = value;
|
|
208
|
+
this.expectNext(preType, type);
|
|
209
|
+
this.expectPrev(type, preType);
|
|
210
|
+
if (type.updateContext) {
|
|
211
|
+
type.updateContext.call(this, preType);
|
|
212
|
+
}
|
|
213
|
+
};
|
|
214
|
+
Tokenizer.prototype.readToken = function (code, prevCode) {
|
|
215
|
+
if (prevCode === 92) {
|
|
216
|
+
return this.readKeyWord();
|
|
217
|
+
}
|
|
218
|
+
if (this.input.length <= this.state.pos) {
|
|
219
|
+
this.finishToken(eofTok);
|
|
220
|
+
}
|
|
221
|
+
else if (this.curContext() === bracketDContext) {
|
|
222
|
+
this.readIngoreString();
|
|
223
|
+
}
|
|
224
|
+
else if (code === 123) {
|
|
225
|
+
this.state.pos++;
|
|
226
|
+
this.finishToken(braceLTok);
|
|
227
|
+
}
|
|
228
|
+
else if (code === 125) {
|
|
229
|
+
this.state.pos++;
|
|
230
|
+
this.finishToken(braceRTok);
|
|
231
|
+
}
|
|
232
|
+
else if (code === 42) {
|
|
233
|
+
this.state.pos++;
|
|
234
|
+
if (this.getCode() === 42) {
|
|
235
|
+
this.state.pos++;
|
|
236
|
+
return this.finishToken(dbStarTok);
|
|
237
|
+
}
|
|
238
|
+
this.finishToken(starTok);
|
|
239
|
+
}
|
|
240
|
+
else if (code === 33) {
|
|
241
|
+
this.state.pos++;
|
|
242
|
+
this.finishToken(bangTok);
|
|
243
|
+
}
|
|
244
|
+
else if (code === 46) {
|
|
245
|
+
this.state.pos++;
|
|
246
|
+
this.finishToken(dotTok);
|
|
247
|
+
}
|
|
248
|
+
else if (code === 91) {
|
|
249
|
+
this.state.pos++;
|
|
250
|
+
if (this.getCode() === 91) {
|
|
251
|
+
this.state.pos++;
|
|
252
|
+
return this.finishToken(bracketDLTok);
|
|
253
|
+
}
|
|
254
|
+
this.finishToken(bracketLTok);
|
|
255
|
+
}
|
|
256
|
+
else if (code === 126) {
|
|
257
|
+
this.state.pos++;
|
|
258
|
+
this.finishToken(expandTok);
|
|
259
|
+
}
|
|
260
|
+
else if (code === 93) {
|
|
261
|
+
this.state.pos++;
|
|
262
|
+
this.finishToken(bracketRTok);
|
|
263
|
+
}
|
|
264
|
+
else if (code === 40) {
|
|
265
|
+
this.state.pos++;
|
|
266
|
+
this.finishToken(parenLTok);
|
|
267
|
+
}
|
|
268
|
+
else if (code === 41) {
|
|
269
|
+
this.state.pos++;
|
|
270
|
+
this.finishToken(parenRTok);
|
|
271
|
+
}
|
|
272
|
+
else if (code === 44) {
|
|
273
|
+
this.state.pos++;
|
|
274
|
+
this.finishToken(commaTok);
|
|
275
|
+
}
|
|
276
|
+
else if (code === 58) {
|
|
277
|
+
this.state.pos++;
|
|
278
|
+
this.finishToken(colonTok);
|
|
279
|
+
}
|
|
280
|
+
else {
|
|
281
|
+
this.readKeyWord();
|
|
282
|
+
}
|
|
283
|
+
};
|
|
284
|
+
return Tokenizer;
|
|
285
|
+
}());
|
|
286
|
+
|
|
287
|
+
export { Tokenizer };
|
|
@@ -0,0 +1,240 @@
|
|
|
1
|
+
import { destructorContext, braceContext, bracketContext, bracketArrayContext, bracketDContext, parenContext } from './contexts.js';
|
|
2
|
+
|
|
3
|
+
var __assign = (undefined && undefined.__assign) || function () {
|
|
4
|
+
__assign = Object.assign || function(t) {
|
|
5
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
6
|
+
s = arguments[i];
|
|
7
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
8
|
+
t[p] = s[p];
|
|
9
|
+
}
|
|
10
|
+
return t;
|
|
11
|
+
};
|
|
12
|
+
return __assign.apply(this, arguments);
|
|
13
|
+
};
|
|
14
|
+
var TokenType = function (flag, props) {
|
|
15
|
+
return __assign({ flag: flag }, props);
|
|
16
|
+
};
|
|
17
|
+
var nameTok = TokenType('name', {
|
|
18
|
+
expectNext: function (next) {
|
|
19
|
+
if (this.includesContext(destructorContext)) {
|
|
20
|
+
return (next === nameTok ||
|
|
21
|
+
next === commaTok ||
|
|
22
|
+
next === bracketRTok ||
|
|
23
|
+
next === braceRTok ||
|
|
24
|
+
next === colonTok);
|
|
25
|
+
}
|
|
26
|
+
return (next === dotTok ||
|
|
27
|
+
next === commaTok ||
|
|
28
|
+
next === eofTok ||
|
|
29
|
+
next === bracketRTok ||
|
|
30
|
+
next === parenRTok ||
|
|
31
|
+
next === colonTok ||
|
|
32
|
+
next === expandTok ||
|
|
33
|
+
next === bracketLTok);
|
|
34
|
+
},
|
|
35
|
+
});
|
|
36
|
+
var starTok = TokenType('*', {
|
|
37
|
+
expectNext: function (next) {
|
|
38
|
+
return (next === dotTok ||
|
|
39
|
+
next === parenLTok ||
|
|
40
|
+
next === bracketLTok ||
|
|
41
|
+
next === eofTok ||
|
|
42
|
+
next === commaTok ||
|
|
43
|
+
next === parenRTok);
|
|
44
|
+
},
|
|
45
|
+
});
|
|
46
|
+
var dbStarTok = TokenType('**', {
|
|
47
|
+
expectNext: function (next) {
|
|
48
|
+
return (next === dotTok ||
|
|
49
|
+
next === parenLTok ||
|
|
50
|
+
next === bracketLTok ||
|
|
51
|
+
next === eofTok ||
|
|
52
|
+
next === commaTok ||
|
|
53
|
+
next === parenRTok);
|
|
54
|
+
},
|
|
55
|
+
});
|
|
56
|
+
var dotTok = TokenType('.', {
|
|
57
|
+
expectNext: function (next) {
|
|
58
|
+
return (next === dotTok ||
|
|
59
|
+
next === nameTok ||
|
|
60
|
+
next === bracketDLTok ||
|
|
61
|
+
next === starTok ||
|
|
62
|
+
next === dbStarTok ||
|
|
63
|
+
next === bracketLTok ||
|
|
64
|
+
next === braceLTok ||
|
|
65
|
+
next === eofTok);
|
|
66
|
+
},
|
|
67
|
+
expectPrev: function (prev) {
|
|
68
|
+
return (prev === dotTok ||
|
|
69
|
+
prev === nameTok ||
|
|
70
|
+
prev === bracketDRTok ||
|
|
71
|
+
prev === starTok ||
|
|
72
|
+
prev === parenRTok ||
|
|
73
|
+
prev === bracketRTok ||
|
|
74
|
+
prev === expandTok ||
|
|
75
|
+
prev === braceRTok);
|
|
76
|
+
},
|
|
77
|
+
});
|
|
78
|
+
var bangTok = TokenType('!', {
|
|
79
|
+
expectNext: function (next) {
|
|
80
|
+
return next === nameTok || next === bracketDLTok;
|
|
81
|
+
},
|
|
82
|
+
});
|
|
83
|
+
var colonTok = TokenType(':', {
|
|
84
|
+
expectNext: function (next) {
|
|
85
|
+
if (this.includesContext(destructorContext)) {
|
|
86
|
+
return next === nameTok || next === braceLTok || next === bracketLTok;
|
|
87
|
+
}
|
|
88
|
+
return next === nameTok || next === bracketDLTok || next === bracketRTok;
|
|
89
|
+
},
|
|
90
|
+
});
|
|
91
|
+
var braceLTok = TokenType('{', {
|
|
92
|
+
expectNext: function (next) {
|
|
93
|
+
return next === nameTok;
|
|
94
|
+
},
|
|
95
|
+
expectPrev: function (prev) {
|
|
96
|
+
if (this.includesContext(destructorContext)) {
|
|
97
|
+
return prev === colonTok || prev === commaTok || prev === bracketLTok;
|
|
98
|
+
}
|
|
99
|
+
return prev === dotTok || prev === colonTok || prev === parenLTok;
|
|
100
|
+
},
|
|
101
|
+
updateContext: function () {
|
|
102
|
+
this.state.context.push(braceContext);
|
|
103
|
+
},
|
|
104
|
+
});
|
|
105
|
+
var braceRTok = TokenType('}', {
|
|
106
|
+
expectNext: function (next) {
|
|
107
|
+
if (this.includesContext(destructorContext)) {
|
|
108
|
+
return (next === commaTok ||
|
|
109
|
+
next === braceRTok ||
|
|
110
|
+
next === eofTok ||
|
|
111
|
+
next === bracketRTok);
|
|
112
|
+
}
|
|
113
|
+
return next === dotTok || next === eofTok || next === commaTok;
|
|
114
|
+
},
|
|
115
|
+
expectPrev: function (prev) {
|
|
116
|
+
return prev === nameTok || prev === braceRTok || prev === bracketRTok;
|
|
117
|
+
},
|
|
118
|
+
updateContext: function () {
|
|
119
|
+
this.state.context.pop(braceContext);
|
|
120
|
+
},
|
|
121
|
+
});
|
|
122
|
+
var bracketLTok = TokenType('[', {
|
|
123
|
+
expectNext: function (next) {
|
|
124
|
+
if (this.includesContext(destructorContext)) {
|
|
125
|
+
return (next === nameTok ||
|
|
126
|
+
next === bracketLTok ||
|
|
127
|
+
next === braceLTok ||
|
|
128
|
+
next === bracketRTok);
|
|
129
|
+
}
|
|
130
|
+
return (next === nameTok ||
|
|
131
|
+
next === bracketDLTok ||
|
|
132
|
+
next === colonTok ||
|
|
133
|
+
next === bracketLTok ||
|
|
134
|
+
next === ignoreTok ||
|
|
135
|
+
next === bracketRTok);
|
|
136
|
+
},
|
|
137
|
+
expectPrev: function (prev) {
|
|
138
|
+
if (this.includesContext(destructorContext)) {
|
|
139
|
+
return prev === colonTok || prev === commaTok || prev === bracketLTok;
|
|
140
|
+
}
|
|
141
|
+
return (prev === starTok ||
|
|
142
|
+
prev === bracketLTok ||
|
|
143
|
+
prev === dotTok ||
|
|
144
|
+
prev === nameTok ||
|
|
145
|
+
prev === parenLTok ||
|
|
146
|
+
prev == commaTok);
|
|
147
|
+
},
|
|
148
|
+
updateContext: function () {
|
|
149
|
+
this.state.context.push(bracketContext);
|
|
150
|
+
},
|
|
151
|
+
});
|
|
152
|
+
var bracketRTok = TokenType(']', {
|
|
153
|
+
expectNext: function (next) {
|
|
154
|
+
if (this.includesContext(destructorContext)) {
|
|
155
|
+
return (next === commaTok ||
|
|
156
|
+
next === braceRTok ||
|
|
157
|
+
next === bracketRTok ||
|
|
158
|
+
next === eofTok);
|
|
159
|
+
}
|
|
160
|
+
return (next === dotTok ||
|
|
161
|
+
next === eofTok ||
|
|
162
|
+
next === commaTok ||
|
|
163
|
+
next === parenRTok ||
|
|
164
|
+
next === bracketRTok);
|
|
165
|
+
},
|
|
166
|
+
updateContext: function () {
|
|
167
|
+
if (this.includesContext(bracketArrayContext))
|
|
168
|
+
return;
|
|
169
|
+
if (!this.includesContext(bracketContext))
|
|
170
|
+
throw this.unexpect();
|
|
171
|
+
this.state.context.pop();
|
|
172
|
+
},
|
|
173
|
+
});
|
|
174
|
+
var bracketDLTok = TokenType('[[', {
|
|
175
|
+
updateContext: function () {
|
|
176
|
+
this.state.context.push(bracketDContext);
|
|
177
|
+
},
|
|
178
|
+
});
|
|
179
|
+
var bracketDRTok = TokenType(']]', {
|
|
180
|
+
updateContext: function () {
|
|
181
|
+
if (this.curContext() !== bracketDContext)
|
|
182
|
+
throw this.unexpect();
|
|
183
|
+
this.state.context.pop();
|
|
184
|
+
},
|
|
185
|
+
});
|
|
186
|
+
var parenLTok = TokenType('(', {
|
|
187
|
+
expectNext: function (next) {
|
|
188
|
+
return (next === nameTok ||
|
|
189
|
+
next === bracketDLTok ||
|
|
190
|
+
next === braceLTok ||
|
|
191
|
+
next === bangTok ||
|
|
192
|
+
next === bracketLTok);
|
|
193
|
+
},
|
|
194
|
+
expectPrev: function (prev) {
|
|
195
|
+
return prev === starTok;
|
|
196
|
+
},
|
|
197
|
+
updateContext: function () {
|
|
198
|
+
this.state.context.push(parenContext);
|
|
199
|
+
},
|
|
200
|
+
});
|
|
201
|
+
var parenRTok = TokenType(')', {
|
|
202
|
+
expectNext: function (next) {
|
|
203
|
+
return (next === dotTok ||
|
|
204
|
+
next === eofTok ||
|
|
205
|
+
next === commaTok ||
|
|
206
|
+
next === parenRTok);
|
|
207
|
+
},
|
|
208
|
+
updateContext: function () {
|
|
209
|
+
if (this.curContext() !== parenContext)
|
|
210
|
+
throw this.unexpect();
|
|
211
|
+
this.state.context.pop();
|
|
212
|
+
},
|
|
213
|
+
});
|
|
214
|
+
var commaTok = TokenType(',', {
|
|
215
|
+
expectNext: function (next) {
|
|
216
|
+
return (next === nameTok ||
|
|
217
|
+
next === bracketDLTok ||
|
|
218
|
+
next === bracketLTok ||
|
|
219
|
+
next === braceLTok);
|
|
220
|
+
},
|
|
221
|
+
});
|
|
222
|
+
var ignoreTok = TokenType('ignore', {
|
|
223
|
+
expectNext: function (next) {
|
|
224
|
+
return next === bracketDRTok;
|
|
225
|
+
},
|
|
226
|
+
expectPrev: function (prev) {
|
|
227
|
+
return prev == bracketDLTok;
|
|
228
|
+
},
|
|
229
|
+
});
|
|
230
|
+
var expandTok = TokenType('expandTok', {
|
|
231
|
+
expectNext: function (next) {
|
|
232
|
+
return (next === dotTok ||
|
|
233
|
+
next === eofTok ||
|
|
234
|
+
next === commaTok ||
|
|
235
|
+
next === parenRTok);
|
|
236
|
+
},
|
|
237
|
+
});
|
|
238
|
+
var eofTok = TokenType('eof');
|
|
239
|
+
|
|
240
|
+
export { bangTok, braceLTok, braceRTok, bracketDLTok, bracketDRTok, bracketLTok, bracketRTok, colonTok, commaTok, dbStarTok, dotTok, eofTok, expandTok, ignoreTok, nameTok, parenLTok, parenRTok, starTok };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
var isType = function (type) {
|
|
2
|
+
return function (obj) {
|
|
3
|
+
return obj && obj.type === type;
|
|
4
|
+
};
|
|
5
|
+
};
|
|
6
|
+
var isIdentifier = isType('Identifier');
|
|
7
|
+
var isIgnoreExpression = isType('IgnoreExpression');
|
|
8
|
+
var isDotOperator = isType('DotOperator');
|
|
9
|
+
var isWildcardOperator = isType('WildcardOperator');
|
|
10
|
+
var isExpandOperator = isType('ExpandOperator');
|
|
11
|
+
var isGroupExpression = isType('GroupExpression');
|
|
12
|
+
var isRangeExpression = isType('RangeExpression');
|
|
13
|
+
var isDestructorExpression = isType('DestructorExpression');
|
|
14
|
+
var isObjectPattern = isType('ObjectPattern');
|
|
15
|
+
var isArrayPattern = isType('ArrayPattern');
|
|
16
|
+
|
|
17
|
+
export { isArrayPattern, isDestructorExpression, isDotOperator, isExpandOperator, isGroupExpression, isIdentifier, isIgnoreExpression, isObjectPattern, isRangeExpression, isType, isWildcardOperator };
|
|
@@ -1109,7 +1109,9 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1109
1109
|
textColorFocusWarning: string;
|
|
1110
1110
|
textColorDisabledWarning: string;
|
|
1111
1111
|
textColorTextWarning: string;
|
|
1112
|
-
textColorTextHoverWarning: string;
|
|
1112
|
+
textColorTextHoverWarning: string; /**
|
|
1113
|
+
* 删除选中scan数据
|
|
1114
|
+
*/
|
|
1113
1115
|
textColorTextPressedWarning: string;
|
|
1114
1116
|
textColorTextFocusWarning: string;
|
|
1115
1117
|
textColorTextDisabledWarning: string;
|
|
@@ -1151,7 +1153,9 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1151
1153
|
borderDisabledError: string;
|
|
1152
1154
|
rippleColorError: string;
|
|
1153
1155
|
waveOpacity: string;
|
|
1154
|
-
fontWeight: string;
|
|
1156
|
+
fontWeight: string;
|
|
1157
|
+
fontWeightStrong: string;
|
|
1158
|
+
/**
|
|
1155
1159
|
* 初始化props
|
|
1156
1160
|
* @param {*} unionItem
|
|
1157
1161
|
* @param {*} row
|
|
@@ -1159,7 +1163,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1159
1163
|
* @param {*} $rowIndex
|
|
1160
1164
|
* @returns
|
|
1161
1165
|
*/
|
|
1162
|
-
fontWeightStrong: string;
|
|
1163
1166
|
paddingTiny: string;
|
|
1164
1167
|
paddingSmall: string;
|
|
1165
1168
|
paddingMedium: string;
|
|
@@ -1211,7 +1214,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1211
1214
|
colorDisabled: string;
|
|
1212
1215
|
textColor: string;
|
|
1213
1216
|
textColorTertiary: string;
|
|
1214
|
-
textColorHover: string;
|
|
1217
|
+
textColorHover: string; /**
|
|
1218
|
+
* 单个form提交成功数据
|
|
1219
|
+
* @param {*} obj formData
|
|
1220
|
+
*/
|
|
1215
1221
|
textColorPressed: string;
|
|
1216
1222
|
textColorFocus: string;
|
|
1217
1223
|
textColorDisabled: string;
|
|
@@ -1251,10 +1257,11 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1251
1257
|
textColorGhostPressedPrimary: string;
|
|
1252
1258
|
textColorGhostFocusPrimary: string;
|
|
1253
1259
|
textColorGhostDisabledPrimary: string;
|
|
1254
|
-
borderPrimary: string;
|
|
1260
|
+
borderPrimary: string;
|
|
1261
|
+
borderHoverPrimary: string;
|
|
1262
|
+
/**
|
|
1255
1263
|
* tsx渲染表格
|
|
1256
1264
|
*/
|
|
1257
|
-
borderHoverPrimary: string;
|
|
1258
1265
|
borderPressedPrimary: string;
|
|
1259
1266
|
borderFocusPrimary: string;
|
|
1260
1267
|
borderDisabledPrimary: string;
|
|
@@ -424,7 +424,7 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
424
424
|
};
|
|
425
425
|
}
|
|
426
426
|
const currentColumns = fieldList.map((item, index) => {
|
|
427
|
-
var _a2, _b2, _c, _d, _e;
|
|
427
|
+
var _a2, _b2, _c, _d, _e, _f, _g;
|
|
428
428
|
let filterField = false;
|
|
429
429
|
let filterItems = [];
|
|
430
430
|
try {
|
|
@@ -452,8 +452,8 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
452
452
|
fixed,
|
|
453
453
|
sortable,
|
|
454
454
|
headerClassName: "mycolumn",
|
|
455
|
-
resizable: true,
|
|
456
|
-
showOverflow: "title",
|
|
455
|
+
resizable: (_e = item.resizable) != null ? _e : true,
|
|
456
|
+
showOverflow: (_f = item.showOverflow) != null ? _f : "title",
|
|
457
457
|
treeNode,
|
|
458
458
|
type,
|
|
459
459
|
slots: {
|
|
@@ -508,7 +508,7 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
508
508
|
if (!isScanMultiTable2) {
|
|
509
509
|
col.slots.footer = "tooltip_footer";
|
|
510
510
|
}
|
|
511
|
-
if (props.showNestTable && state.isTree == 0 && ((
|
|
511
|
+
if (props.showNestTable && state.isTree == 0 && ((_g = props.curNestColumnConfig) == null ? void 0 : _g.isTree) == 0) {
|
|
512
512
|
col.slots.content = "nest_table_content";
|
|
513
513
|
}
|
|
514
514
|
return col;
|
|
@@ -599,6 +599,7 @@ const setTableConfig = (config, state) => {
|
|
|
599
599
|
state.openOnly = config.openOnly;
|
|
600
600
|
state.isExpand = config.spreadAllBtn;
|
|
601
601
|
state.levelLazyLoadSetting = Object.assign({}, config.levelLazyLoadSetting);
|
|
602
|
+
state.checkWidth = Object.assign({}, state.checkWidth, config.checkWidth);
|
|
602
603
|
};
|
|
603
604
|
const setTreeGroupTitle = (formatList, key, GROUP_TITLE_KEY) => {
|
|
604
605
|
formatList.forEach((row) => {
|