vxe-gantt 3.9.4 → 3.9.5
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/components.d.ts +2 -1
- package/es/components.js +3 -4
- package/es/gantt/src/gantt-body.js +103 -79
- package/es/gantt/src/gantt-chart.js +376 -252
- package/es/gantt/src/gantt-footer.js +22 -14
- package/es/gantt/src/gantt-header.js +141 -110
- package/es/gantt/src/gantt-view.js +243 -198
- package/es/gantt/src/gantt.js +295 -187
- package/es/index.esm.js +4 -2
- package/es/index.js +4 -2
- package/es/ui/index.d.ts +0 -1
- package/es/ui/index.js +1 -2
- package/es/ui/src/log.js +1 -1
- package/es/ui/src/utils.d.ts +1 -1
- package/lib/components.js +5 -6
- package/lib/gantt/src/gantt-body.js +103 -79
- package/lib/gantt/src/gantt-chart.js +376 -252
- package/lib/gantt/src/gantt-footer.js +22 -14
- package/lib/gantt/src/gantt-header.js +141 -110
- package/lib/gantt/src/gantt-view.js +243 -198
- package/lib/gantt/src/gantt.js +295 -187
- package/lib/index.common.js +4 -2
- package/lib/index.js +4 -2
- package/lib/index.umd.js +1369 -1029
- package/lib/index.umd.min.js +1 -1
- package/lib/ui/index.js +1 -2
- package/lib/ui/src/log.js +1 -1
- package/package.json +7 -7
- package/packages/components.ts +21 -22
- package/packages/gantt/index.ts +32 -32
- package/packages/gantt/src/gantt-body.ts +349 -325
- package/packages/gantt/src/gantt-chart.ts +699 -575
- package/packages/gantt/src/gantt-footer.ts +81 -73
- package/packages/gantt/src/gantt-header.ts +218 -187
- package/packages/gantt/src/gantt-view.ts +2861 -2823
- package/packages/gantt/src/gantt.ts +3308 -3192
- package/packages/gantt/src/static.ts +35 -35
- package/packages/gantt/src/util.ts +35 -35
- package/packages/index.ts +15 -13
- package/packages/ui/index.ts +132 -135
- package/packages/ui/src/comp.ts +3 -3
- package/packages/ui/src/depend.ts +14 -14
- package/packages/ui/src/dom.ts +202 -202
- package/packages/ui/src/log.ts +19 -19
- package/packages/ui/src/utils.ts +68 -68
- package/packages/ui/src/vn.ts +13 -13
- package/types/all.d.ts +29 -29
- package/types/index.d.ts +4 -4
package/es/components.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { VueConstructor } from 'vue';
|
|
2
|
-
import VxeUI from '
|
|
2
|
+
import { VxeUI } from '@vxe-ui/core';
|
|
3
|
+
import './ui';
|
|
3
4
|
import type { VxeGlobalConfig } from 'vxe-pc-ui';
|
|
4
5
|
export declare function install(app: VueConstructor, options?: VxeGlobalConfig): void;
|
|
5
6
|
export { VxeUI };
|
package/es/components.js
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import VxeUI from "
|
|
1
|
+
import { VxeUI } from "@vxe-ui/core";
|
|
2
2
|
import VxeGantt from "./gantt";
|
|
3
|
+
import "./ui";
|
|
3
4
|
const { setConfig } = VxeUI;
|
|
4
|
-
const components = [
|
|
5
|
-
VxeGantt
|
|
6
|
-
];
|
|
5
|
+
const components = [VxeGantt];
|
|
7
6
|
function install(app, options) {
|
|
8
7
|
setConfig(options);
|
|
9
8
|
components.forEach((component) => app.use(component));
|
|
@@ -98,32 +98,36 @@ var gantt_body_default = defineVxeComponent({
|
|
|
98
98
|
rowIndex,
|
|
99
99
|
_rowIndex
|
|
100
100
|
};
|
|
101
|
-
return h(
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
"
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
click(evnt) {
|
|
117
|
-
$xeGantt.handleTaskCellClickEvent(evnt, { row, column });
|
|
118
|
-
},
|
|
119
|
-
dblclick(evnt) {
|
|
120
|
-
$xeGantt.handleTaskCellDblclickEvent(evnt, { row, column });
|
|
101
|
+
return h(
|
|
102
|
+
"td",
|
|
103
|
+
{
|
|
104
|
+
key: cellClassName || cellStyle ? field : $columnIndex,
|
|
105
|
+
class: [
|
|
106
|
+
"vxe-gantt-view--body-column",
|
|
107
|
+
{
|
|
108
|
+
"is--now": showNowLine && todayValue === field
|
|
109
|
+
},
|
|
110
|
+
getClass(cellClassName, ctParams)
|
|
111
|
+
],
|
|
112
|
+
style: cellStyle ? Object.assign({}, XEUtils.isFunction(cellStyle) ? cellStyle(ctParams) : cellStyle, {
|
|
113
|
+
height: `${cellHeight}px`
|
|
114
|
+
}) : {
|
|
115
|
+
height: `${cellHeight}px`
|
|
121
116
|
},
|
|
122
|
-
|
|
123
|
-
|
|
117
|
+
on: {
|
|
118
|
+
click(evnt) {
|
|
119
|
+
$xeGantt.handleTaskCellClickEvent(evnt, { row, column });
|
|
120
|
+
},
|
|
121
|
+
dblclick(evnt) {
|
|
122
|
+
$xeGantt.handleTaskCellDblclickEvent(evnt, { row, column });
|
|
123
|
+
},
|
|
124
|
+
contextmenu(evnt) {
|
|
125
|
+
$xeGantt.handleTaskBodyContextmenuEvent(evnt, ctParams);
|
|
126
|
+
}
|
|
124
127
|
}
|
|
125
|
-
}
|
|
126
|
-
|
|
128
|
+
},
|
|
129
|
+
tdVNs
|
|
130
|
+
);
|
|
127
131
|
},
|
|
128
132
|
renderRows(h, $xeTable, tableData) {
|
|
129
133
|
const _vm = this;
|
|
@@ -186,25 +190,29 @@ var gantt_body_default = defineVxeComponent({
|
|
|
186
190
|
_rowIndex
|
|
187
191
|
};
|
|
188
192
|
trVNs.push(
|
|
189
|
-
h(
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
"row
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
193
|
+
h(
|
|
194
|
+
"tr",
|
|
195
|
+
{
|
|
196
|
+
key: rowClassName || rowStyle || cellClassName || cellStyle ? rowid : $rowIndex,
|
|
197
|
+
class: [
|
|
198
|
+
"vxe-gantt-view--body-row",
|
|
199
|
+
{
|
|
200
|
+
"row--stripe": stripe && (_rowIndex + 1) % 2 === 0,
|
|
201
|
+
"is--new": isNewRow,
|
|
202
|
+
"row--radio": radioOpts.highlight && $xeTable.eqRow(selectRadioRow, row),
|
|
203
|
+
"row--checked": checkboxOpts.highlight && $xeTable.isCheckedByCheckboxRow(row),
|
|
204
|
+
"row--pending": !!pendingRowFlag && !!pendingRowMaps[rowid]
|
|
205
|
+
},
|
|
206
|
+
getClass(rowClassName, rowParams)
|
|
207
|
+
],
|
|
208
|
+
style: rowStyle ? XEUtils.isFunction(rowStyle) ? rowStyle(rowParams) || void 0 : rowStyle : void 0,
|
|
209
|
+
attrs: {
|
|
210
|
+
rowid
|
|
199
211
|
},
|
|
200
|
-
|
|
201
|
-
],
|
|
202
|
-
style: rowStyle ? XEUtils.isFunction(rowStyle) ? rowStyle(rowParams) || void 0 : rowStyle : void 0,
|
|
203
|
-
attrs: {
|
|
204
|
-
rowid
|
|
212
|
+
on: trOns
|
|
205
213
|
},
|
|
206
|
-
|
|
207
|
-
|
|
214
|
+
tableColumn.map((column, $columnIndex) => _vm.renderColumn(h, $xeTable, row, rowid, rowIndex, $rowIndex, _rowIndex, column, $columnIndex))
|
|
215
|
+
)
|
|
208
216
|
);
|
|
209
217
|
let isExpandTree = false;
|
|
210
218
|
let rowChildren = [];
|
|
@@ -225,45 +233,61 @@ var gantt_body_default = defineVxeComponent({
|
|
|
225
233
|
const { reactData } = $xeGanttView;
|
|
226
234
|
const $xeTable = $xeGanttView.internalData.xeTable;
|
|
227
235
|
const { tableData, tableColumn, viewCellWidth } = reactData;
|
|
228
|
-
return h(
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
class: "vxe-body--x-space"
|
|
245
|
-
}),
|
|
246
|
-
h("div", {
|
|
247
|
-
ref: "refBodyYSpace",
|
|
248
|
-
class: "vxe-body--y-space"
|
|
249
|
-
}),
|
|
250
|
-
h("table", {
|
|
251
|
-
ref: "refBodyTable",
|
|
252
|
-
class: "vxe-gantt-view--body-table"
|
|
253
|
-
}, [
|
|
254
|
-
h("colgroup", {}, tableColumn.map((column, cIndex) => {
|
|
255
|
-
return h("col", {
|
|
256
|
-
key: cIndex,
|
|
257
|
-
style: {
|
|
258
|
-
width: `${viewCellWidth}px`
|
|
236
|
+
return h(
|
|
237
|
+
"div",
|
|
238
|
+
{
|
|
239
|
+
ref: "refElem",
|
|
240
|
+
class: "vxe-gantt-view--body-wrapper"
|
|
241
|
+
},
|
|
242
|
+
[
|
|
243
|
+
h(
|
|
244
|
+
"div",
|
|
245
|
+
{
|
|
246
|
+
ref: "refBodyScroll",
|
|
247
|
+
class: "vxe-gantt-view--body-inner-wrapper",
|
|
248
|
+
on: {
|
|
249
|
+
scroll: $xeGanttView.triggerBodyScrollEvent,
|
|
250
|
+
contextmenu(evnt) {
|
|
251
|
+
$xeGantt.handleTaskBodyContextmenuEvent(evnt, { source: sourceType, type: viewType, rowIndex: -1, $rowIndex: -1, _rowIndex: -1 });
|
|
259
252
|
}
|
|
260
|
-
}
|
|
261
|
-
}
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
253
|
+
}
|
|
254
|
+
},
|
|
255
|
+
[
|
|
256
|
+
h("div", {
|
|
257
|
+
ref: "refBodyXSpace",
|
|
258
|
+
class: "vxe-body--x-space"
|
|
259
|
+
}),
|
|
260
|
+
h("div", {
|
|
261
|
+
ref: "refBodyYSpace",
|
|
262
|
+
class: "vxe-body--y-space"
|
|
263
|
+
}),
|
|
264
|
+
h(
|
|
265
|
+
"table",
|
|
266
|
+
{
|
|
267
|
+
ref: "refBodyTable",
|
|
268
|
+
class: "vxe-gantt-view--body-table"
|
|
269
|
+
},
|
|
270
|
+
[
|
|
271
|
+
h(
|
|
272
|
+
"colgroup",
|
|
273
|
+
{},
|
|
274
|
+
tableColumn.map((column, cIndex) => {
|
|
275
|
+
return h("col", {
|
|
276
|
+
key: cIndex,
|
|
277
|
+
style: {
|
|
278
|
+
width: `${viewCellWidth}px`
|
|
279
|
+
}
|
|
280
|
+
});
|
|
281
|
+
})
|
|
282
|
+
),
|
|
283
|
+
h("tbody", {}, $xeTable ? _vm.renderRows(h, $xeTable, tableData) : [])
|
|
284
|
+
]
|
|
285
|
+
),
|
|
286
|
+
h(GanttViewChartComponent)
|
|
287
|
+
]
|
|
288
|
+
)
|
|
289
|
+
]
|
|
290
|
+
);
|
|
267
291
|
}
|
|
268
292
|
},
|
|
269
293
|
mounted() {
|