evui 3.4.207 → 3.4.209
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/README.md +18 -33
- package/dist/404.html +44 -0
- package/dist/favicon.ico +0 -0
- package/dist/index.js +22738 -0
- package/dist/index.umd.cjs +28 -0
- package/dist/style.css +1 -0
- package/package.json +46 -43
- package/dist/evui.common.js +0 -63681
- package/dist/evui.common.js.map +0 -1
- package/dist/evui.umd.js +0 -63691
- package/dist/evui.umd.js.map +0 -1
- package/dist/evui.umd.min.js +0 -2
- package/dist/evui.umd.min.js.map +0 -1
- package/dist/img/EVUI.b82ee81a.svg +0 -293
- package/src/assets/logo.png +0 -0
- package/src/common/emitter.js +0 -20
- package/src/common/utils.bignumber.js +0 -67
- package/src/common/utils.debounce.js +0 -223
- package/src/common/utils.js +0 -151
- package/src/common/utils.table.js +0 -78
- package/src/common/utils.throttle.js +0 -83
- package/src/common/utils.tree.js +0 -18
- package/src/components/button/Button.vue +0 -195
- package/src/components/button/index.js +0 -7
- package/src/components/buttonGroup/ButtonGroup.vue +0 -11
- package/src/components/buttonGroup/index.js +0 -7
- package/src/components/calendar/Calendar.vue +0 -725
- package/src/components/calendar/index.js +0 -7
- package/src/components/calendar/uses.js +0 -1410
- package/src/components/chart/Chart.vue +0 -363
- package/src/components/chart/ChartToolbar.vue +0 -52
- package/src/components/chart/chart.core.js +0 -1170
- package/src/components/chart/chartZoom.core.js +0 -540
- package/src/components/chart/element/element.bar.js +0 -672
- package/src/components/chart/element/element.bar.time.js +0 -166
- package/src/components/chart/element/element.heatmap.js +0 -743
- package/src/components/chart/element/element.line.js +0 -611
- package/src/components/chart/element/element.pie.js +0 -197
- package/src/components/chart/element/element.scatter.js +0 -320
- package/src/components/chart/element/element.tip.js +0 -717
- package/src/components/chart/helpers/helpers.canvas.js +0 -265
- package/src/components/chart/helpers/helpers.constant.js +0 -235
- package/src/components/chart/helpers/helpers.util.js +0 -400
- package/src/components/chart/index.js +0 -9
- package/src/components/chart/model/index.js +0 -50
- package/src/components/chart/model/model.series.js +0 -125
- package/src/components/chart/model/model.store.js +0 -1427
- package/src/components/chart/plugins/plugins.interaction.js +0 -1659
- package/src/components/chart/plugins/plugins.legend.gradient.js +0 -606
- package/src/components/chart/plugins/plugins.legend.js +0 -1543
- package/src/components/chart/plugins/plugins.pie.js +0 -254
- package/src/components/chart/plugins/plugins.scrollbar.js +0 -732
- package/src/components/chart/plugins/plugins.title.js +0 -61
- package/src/components/chart/plugins/plugins.tooltip.js +0 -1041
- package/src/components/chart/scale/scale.js +0 -951
- package/src/components/chart/scale/scale.linear.js +0 -268
- package/src/components/chart/scale/scale.logarithmic.js +0 -135
- package/src/components/chart/scale/scale.step.js +0 -430
- package/src/components/chart/scale/scale.time.category.js +0 -338
- package/src/components/chart/scale/scale.time.js +0 -49
- package/src/components/chart/style/chart.scss +0 -405
- package/src/components/chart/uses.js +0 -721
- package/src/components/chartBrush/ChartBrush.vue +0 -323
- package/src/components/chartBrush/chartBrush.core.js +0 -691
- package/src/components/chartBrush/index.js +0 -9
- package/src/components/chartBrush/uses.js +0 -23
- package/src/components/chartGroup/ChartGroup.vue +0 -144
- package/src/components/chartGroup/index.js +0 -9
- package/src/components/chartGroup/style/chartGroup.scss +0 -5
- package/src/components/chartGroup/uses.js +0 -53
- package/src/components/checkbox/Checkbox.vue +0 -229
- package/src/components/checkbox/index.js +0 -7
- package/src/components/checkboxGroup/CheckboxGroup.vue +0 -44
- package/src/components/checkboxGroup/index.js +0 -7
- package/src/components/contextMenu/ContextMenu.vue +0 -95
- package/src/components/contextMenu/MenuList.vue +0 -182
- package/src/components/contextMenu/index.js +0 -7
- package/src/components/contextMenu/uses.js +0 -223
- package/src/components/datePicker/DatePicker.vue +0 -504
- package/src/components/datePicker/index.js +0 -7
- package/src/components/datePicker/uses.js +0 -460
- package/src/components/grid/Grid.vue +0 -1535
- package/src/components/grid/GridColumnSetting.vue +0 -358
- package/src/components/grid/GridFilterSetting.vue +0 -323
- package/src/components/grid/GridPagination.vue +0 -75
- package/src/components/grid/GridSummary.vue +0 -314
- package/src/components/grid/GridToolbar.vue +0 -35
- package/src/components/grid/icon/icon-option-button.vue +0 -17
- package/src/components/grid/icon/icon-sort-button.vue +0 -67
- package/src/components/grid/index.js +0 -11
- package/src/components/grid/style/grid.scss +0 -417
- package/src/components/grid/uses.js +0 -1629
- package/src/components/icon/Icon.vue +0 -53
- package/src/components/icon/index.js +0 -8
- package/src/components/inputNumber/InputNumber.vue +0 -212
- package/src/components/inputNumber/index.js +0 -7
- package/src/components/inputNumber/uses.js +0 -217
- package/src/components/loading/Loading.vue +0 -125
- package/src/components/loading/index.js +0 -7
- package/src/components/menu/Menu.vue +0 -79
- package/src/components/menu/MenuItem.vue +0 -201
- package/src/components/menu/index.js +0 -7
- package/src/components/message/Message.vue +0 -229
- package/src/components/message/index.js +0 -34
- package/src/components/messageBox/MessageBox.vue +0 -358
- package/src/components/messageBox/index.js +0 -22
- package/src/components/notification/Notification.vue +0 -316
- package/src/components/notification/index.js +0 -49
- package/src/components/pagination/Pagination.vue +0 -317
- package/src/components/pagination/index.js +0 -7
- package/src/components/pagination/pageButton.vue +0 -31
- package/src/components/progress/Progress.vue +0 -139
- package/src/components/progress/index.js +0 -7
- package/src/components/radio/Radio.vue +0 -159
- package/src/components/radio/index.js +0 -7
- package/src/components/radioGroup/RadioGroup.vue +0 -41
- package/src/components/radioGroup/index.js +0 -7
- package/src/components/scheduler/Scheduler.vue +0 -149
- package/src/components/scheduler/index.js +0 -7
- package/src/components/scheduler/uses.js +0 -183
- package/src/components/select/Select.vue +0 -556
- package/src/components/select/index.js +0 -7
- package/src/components/select/uses.js +0 -379
- package/src/components/slider/Slider.vue +0 -505
- package/src/components/slider/index.js +0 -7
- package/src/components/slider/uses.js +0 -391
- package/src/components/tabPanel/TabPanel.vue +0 -74
- package/src/components/tabPanel/index.js +0 -7
- package/src/components/tabs/Tabs.vue +0 -517
- package/src/components/tabs/index.js +0 -7
- package/src/components/textField/TextField.vue +0 -399
- package/src/components/textField/index.js +0 -7
- package/src/components/timePicker/TimePicker.vue +0 -364
- package/src/components/timePicker/index.js +0 -7
- package/src/components/toggle/Toggle.vue +0 -115
- package/src/components/toggle/index.js +0 -7
- package/src/components/tree/Tree.vue +0 -338
- package/src/components/tree/TreeNode.vue +0 -293
- package/src/components/tree/index.js +0 -7
- package/src/components/treeGrid/TreeGrid.vue +0 -1074
- package/src/components/treeGrid/TreeGridNode.vue +0 -349
- package/src/components/treeGrid/TreeGridToolbar.vue +0 -35
- package/src/components/treeGrid/icon/icon-tree.png +0 -0
- package/src/components/treeGrid/index.js +0 -9
- package/src/components/treeGrid/style/treeGrid.scss +0 -277
- package/src/components/treeGrid/uses.js +0 -1178
- package/src/components/window/Window.vue +0 -329
- package/src/components/window/index.js +0 -7
- package/src/components/window/uses.js +0 -908
- package/src/directives/clickoutside.js +0 -90
- package/src/main.js +0 -120
- package/src/style/components/input.scss +0 -108
- package/src/style/functions.scss +0 -3
- package/src/style/index.scss +0 -6
- package/src/style/lib/fonts/EVUI.eot +0 -0
- package/src/style/lib/fonts/EVUI.svg +0 -293
- package/src/style/lib/fonts/EVUI.ttf +0 -0
- package/src/style/lib/fonts/EVUI.woff +0 -0
- package/src/style/lib/icon.css +0 -888
- package/src/style/mixins.scss +0 -94
- package/src/style/themes.scss +0 -69
- package/src/style/variables.scss +0 -22
|
@@ -1,254 +0,0 @@
|
|
|
1
|
-
const modules = {
|
|
2
|
-
pieDataSet: [],
|
|
3
|
-
/**
|
|
4
|
-
* Draw series data
|
|
5
|
-
*
|
|
6
|
-
* @params hitInfo
|
|
7
|
-
*
|
|
8
|
-
* @returns {undefined}
|
|
9
|
-
*/
|
|
10
|
-
drawPie(hitInfo) {
|
|
11
|
-
const ctx = this.bufferCtx;
|
|
12
|
-
const chartRect = this.chartRect;
|
|
13
|
-
const pieDataSet = this.pieDataSet;
|
|
14
|
-
const pieOption = this.options;
|
|
15
|
-
const padding = this.options.padding;
|
|
16
|
-
const isDoughnut = !!pieOption.doughnutHoleSize;
|
|
17
|
-
|
|
18
|
-
let slice;
|
|
19
|
-
let value;
|
|
20
|
-
let sliceAngle;
|
|
21
|
-
let startAngle = 1.5 * Math.PI;
|
|
22
|
-
let endAngle;
|
|
23
|
-
let series;
|
|
24
|
-
let percentage;
|
|
25
|
-
|
|
26
|
-
const centerX = chartRect.width / 2;
|
|
27
|
-
const centerY = chartRect.height / 2;
|
|
28
|
-
|
|
29
|
-
const chartWidth = centerX - (padding.left + padding.right);
|
|
30
|
-
const chartHeight = centerY - (padding.bottom + padding.top);
|
|
31
|
-
if ((typeof chartWidth === 'number' && chartWidth < 0)
|
|
32
|
-
|| (typeof chartHeight === 'number' && chartHeight < 0)) {
|
|
33
|
-
return;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
const innerRadius = Math.min(chartWidth, chartHeight) * pieOption.doughnutHoleSize;
|
|
37
|
-
const outerRadius = Math.min(chartWidth, chartHeight);
|
|
38
|
-
|
|
39
|
-
for (let ix = 0; ix < pieDataSet.length; ix++) {
|
|
40
|
-
const pie = pieDataSet[ix];
|
|
41
|
-
if (!pie) {
|
|
42
|
-
return;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
let radius = outerRadius - (((outerRadius - innerRadius) / pieDataSet.length) * ix);
|
|
46
|
-
if (pieOption?.pieStroke?.use) {
|
|
47
|
-
radius -= pieOption.pieStroke.lineWidth;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
if (radius < 0) {
|
|
51
|
-
return;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
pie.or = radius;
|
|
55
|
-
if (ix < pieDataSet.length - 1) {
|
|
56
|
-
pie.ir = outerRadius - (((outerRadius - innerRadius) / pieDataSet.length) * (ix + 1));
|
|
57
|
-
} else {
|
|
58
|
-
pie.ir = 1;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
if (pie.total) {
|
|
62
|
-
for (let jx = 0; jx < pie.data.length; jx++) {
|
|
63
|
-
slice = pie.data[jx];
|
|
64
|
-
value = slice.value;
|
|
65
|
-
percentage = (value / pie.total) * 100;
|
|
66
|
-
sliceAngle = 2 * Math.PI * (value / pie.total);
|
|
67
|
-
endAngle = startAngle + sliceAngle;
|
|
68
|
-
|
|
69
|
-
slice.sa = startAngle;
|
|
70
|
-
slice.ea = endAngle;
|
|
71
|
-
series = this.seriesList[slice.id];
|
|
72
|
-
|
|
73
|
-
if (value) {
|
|
74
|
-
const strokeOptions = { ...pieOption.pieStroke };
|
|
75
|
-
if (pie.data.length === 1 && pieOption.pieStroke.use) {
|
|
76
|
-
strokeOptions.use = false;
|
|
77
|
-
|
|
78
|
-
ctx.lineWidth = pieOption.pieStroke.lineWidth;
|
|
79
|
-
ctx.strokeStyle = pieOption.pieStroke.color;
|
|
80
|
-
ctx.arc(centerX, centerY, radius, 0, 2 * Math.PI);
|
|
81
|
-
ctx.stroke();
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
const { selectInfo, legendHitInfo } = hitInfo;
|
|
85
|
-
series.isSelect = selectInfo?.sId === slice.id;
|
|
86
|
-
series.isDownplay = (legendHitInfo && legendHitInfo.sId !== slice.id);
|
|
87
|
-
series.type = isDoughnut ? 'doughnut' : 'pie';
|
|
88
|
-
series.centerX = centerX;
|
|
89
|
-
series.centerY = centerY;
|
|
90
|
-
series.radius = radius;
|
|
91
|
-
series.doughnutHoleSize = radius * (pieOption.doughnutHoleSize ?? 0);
|
|
92
|
-
series.startAngle = startAngle;
|
|
93
|
-
series.endAngle = endAngle;
|
|
94
|
-
series.data = { o: value, percentage };
|
|
95
|
-
|
|
96
|
-
series.draw(ctx, strokeOptions);
|
|
97
|
-
startAngle += sliceAngle;
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
},
|
|
103
|
-
|
|
104
|
-
/**
|
|
105
|
-
* Draw series data
|
|
106
|
-
*
|
|
107
|
-
* @params hitInfo
|
|
108
|
-
*
|
|
109
|
-
* @returns {undefined}
|
|
110
|
-
*/
|
|
111
|
-
drawSunburst(hitInfo) {
|
|
112
|
-
const ctx = this.bufferCtx;
|
|
113
|
-
const { width, height } = this.chartRect;
|
|
114
|
-
const pieDataSet = this.pieDataSet;
|
|
115
|
-
const pieOption = this.options;
|
|
116
|
-
const padding = this.options.padding;
|
|
117
|
-
|
|
118
|
-
this.calculateAngle();
|
|
119
|
-
|
|
120
|
-
let slice;
|
|
121
|
-
let series;
|
|
122
|
-
|
|
123
|
-
const centerX = width / 2;
|
|
124
|
-
const centerY = height / 2;
|
|
125
|
-
|
|
126
|
-
const chartWidth = centerX - (padding.left + padding.right);
|
|
127
|
-
const chartHeight = centerY - (padding.bottom + padding.top);
|
|
128
|
-
if ((typeof chartWidth === 'number' && chartWidth < 0)
|
|
129
|
-
|| (typeof chartHeight === 'number' && chartHeight < 0)) {
|
|
130
|
-
return;
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
const innerRadius = Math.min(chartWidth, chartHeight) * pieOption.doughnutHoleSize;
|
|
134
|
-
const outerRadius = Math.min(chartWidth, chartHeight);
|
|
135
|
-
|
|
136
|
-
for (let ix = 0; ix < pieDataSet.length; ix++) {
|
|
137
|
-
const pie = pieDataSet[ix];
|
|
138
|
-
if (!pie) {
|
|
139
|
-
return;
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
let radius = outerRadius - (((outerRadius - innerRadius) / pieDataSet.length) * ix);
|
|
143
|
-
if (pieOption?.pieStroke?.use) {
|
|
144
|
-
radius -= pieOption.pieStroke.lineWidth;
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
if (radius < 0) {
|
|
148
|
-
return;
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
pie.or = radius;
|
|
152
|
-
if (ix < pieDataSet.length - 1) {
|
|
153
|
-
pie.ir = outerRadius - (((outerRadius - innerRadius) / pieDataSet.length) * (ix + 1));
|
|
154
|
-
} else {
|
|
155
|
-
pie.ir = 1;
|
|
156
|
-
}
|
|
157
|
-
|
|
158
|
-
for (let jx = 0; jx < pie.data.length; jx++) {
|
|
159
|
-
slice = pie.data[jx];
|
|
160
|
-
|
|
161
|
-
if (slice.id === 'dummy') {
|
|
162
|
-
ctx.save();
|
|
163
|
-
ctx.globalCompositeOperation = 'destination-out';
|
|
164
|
-
ctx.beginPath();
|
|
165
|
-
ctx.fillStyle = '#fff';
|
|
166
|
-
ctx.lineWidth = 2;
|
|
167
|
-
ctx.strokeStyle = '#fff';
|
|
168
|
-
ctx.moveTo(centerX, centerY);
|
|
169
|
-
ctx.arc(centerX, centerY, radius, slice.sa, slice.ea);
|
|
170
|
-
ctx.stroke();
|
|
171
|
-
ctx.fill();
|
|
172
|
-
ctx.closePath();
|
|
173
|
-
ctx.restore();
|
|
174
|
-
} else {
|
|
175
|
-
series = this.seriesList[slice.id];
|
|
176
|
-
|
|
177
|
-
if (slice.value) {
|
|
178
|
-
const strokeOptions = { ...pieOption.pieStroke };
|
|
179
|
-
if (pie.data.length === 1 && pieOption.pieStroke.use) {
|
|
180
|
-
strokeOptions.use = false;
|
|
181
|
-
|
|
182
|
-
ctx.lineWidth = pieOption.pieStroke.lineWidth;
|
|
183
|
-
ctx.strokeStyle = pieOption.pieStroke.color;
|
|
184
|
-
ctx.arc(centerX, centerY, radius, 0, 2 * Math.PI);
|
|
185
|
-
ctx.stroke();
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
const { selectInfo, legendHitInfo } = hitInfo;
|
|
189
|
-
series.isSelect = selectInfo?.sId === slice.id;
|
|
190
|
-
series.isDownplay = (legendHitInfo && legendHitInfo.sId !== slice.id);
|
|
191
|
-
series.type = 'sunburst';
|
|
192
|
-
series.centerX = centerX;
|
|
193
|
-
series.centerY = centerY;
|
|
194
|
-
series.radius = radius;
|
|
195
|
-
series.doughnutHoleSize = radius * (pieOption.doughnutHoleSize ?? 0);
|
|
196
|
-
series.startAngle = slice.sa;
|
|
197
|
-
series.endAngle = slice.ea;
|
|
198
|
-
series.data = { o: slice.value };
|
|
199
|
-
|
|
200
|
-
series.draw(ctx, strokeOptions);
|
|
201
|
-
}
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
}
|
|
205
|
-
},
|
|
206
|
-
|
|
207
|
-
/**
|
|
208
|
-
* Draw doughnut hole
|
|
209
|
-
* @param ctx
|
|
210
|
-
*/
|
|
211
|
-
drawDoughnutHole(ctx = this.bufferCtx) {
|
|
212
|
-
const pieOption = this.options;
|
|
213
|
-
const { width, height } = this.chartRect;
|
|
214
|
-
const padding = this.options.padding;
|
|
215
|
-
|
|
216
|
-
const centerX = width / 2;
|
|
217
|
-
const centerY = height / 2;
|
|
218
|
-
|
|
219
|
-
const chartWidth = centerX - (padding.left + padding.right);
|
|
220
|
-
const chartHeight = centerY - (padding.bottom + padding.top);
|
|
221
|
-
if ((typeof chartWidth === 'number' && chartWidth < 0)
|
|
222
|
-
|| (typeof chartHeight === 'number' && chartHeight < 0)) {
|
|
223
|
-
return;
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
const radius = Math.min(chartWidth, chartHeight) * pieOption.doughnutHoleSize;
|
|
227
|
-
|
|
228
|
-
ctx.save();
|
|
229
|
-
ctx.globalCompositeOperation = 'destination-out';
|
|
230
|
-
ctx.beginPath();
|
|
231
|
-
ctx.fillStyle = '#fff';
|
|
232
|
-
ctx.fillOpacity = 0;
|
|
233
|
-
ctx.arc(centerX, centerY, radius, 0, 2 * Math.PI);
|
|
234
|
-
ctx.fill();
|
|
235
|
-
ctx.strokeStyle = '#fff';
|
|
236
|
-
ctx.stroke();
|
|
237
|
-
ctx.closePath();
|
|
238
|
-
ctx.restore();
|
|
239
|
-
|
|
240
|
-
// inner stroke
|
|
241
|
-
if (pieOption?.pieStroke?.use) {
|
|
242
|
-
ctx.beginPath();
|
|
243
|
-
ctx.strokeStyle = pieOption.pieStroke.color;
|
|
244
|
-
ctx.lineWidth = pieOption.pieStroke.lineWidth;
|
|
245
|
-
ctx.arc(centerX, centerY, radius, 0, Math.PI * 2);
|
|
246
|
-
ctx.stroke();
|
|
247
|
-
ctx.closePath();
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
this.pieDataSet[this.pieDataSet.length - 1].ir = radius;
|
|
251
|
-
},
|
|
252
|
-
};
|
|
253
|
-
|
|
254
|
-
export default modules;
|