vxe-gantt 3.2.8 → 3.3.1

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.
@@ -49,14 +49,17 @@ export default defineVxeComponent({
49
49
  const cellOpts = $xeTable.computeCellOpts
50
50
  const rowOpts = $xeTable.computeRowOpts
51
51
  const defaultRowHeight = $xeTable.computeDefaultRowHeight
52
+ const treeOpts = $xeTable.computeTreeOpts
53
+ const childrenField = treeOpts.children || treeOpts.childrenField
52
54
 
53
55
  const ganttProps = $xeGantt
54
56
  const ganttReactData = $xeGantt.reactData
55
57
  const ganttInternalData = $xeGantt.internalData
56
58
  const ganttSlots = $xeGantt.$scopedSlots
57
59
  const taskBarSlot = ganttSlots.taskBar || ganttSlots['task-bar']
60
+ const taskBarOverviewSlot = ganttSlots.taskBarOverview || ganttSlots['task-bar-overview']
58
61
 
59
- const { taskBarMilestoneConfig, taskBarSubviewConfig } = ganttProps
62
+ const { treeConfig, taskBarMilestoneConfig, taskBarSubviewConfig } = ganttProps
60
63
  const { activeLink, activeBarRowid } = ganttReactData
61
64
  const titleField = $xeGantt.computeTitleField
62
65
  const progressField = $xeGantt.computeProgressField
@@ -77,8 +80,6 @@ export default defineVxeComponent({
77
80
  let title = getStringValue(XEUtils.get(row, titleField))
78
81
  const progressValue = showProgress ? Math.min(100, Math.max(0, XEUtils.toNumber(XEUtils.get(row, progressField)))) : 0
79
82
  const renderTaskType = getTaskType(XEUtils.get(row, typeField))
80
- const isMilestone = !!(hasEnableConf(taskBarMilestoneConfig, taskBarMilestoneOpts) && hasMilestoneTask(renderTaskType))
81
- const isSubview = !!(hasEnableConf(taskBarSubviewConfig, taskBarSubviewOpts) && hasSubviewTask(renderTaskType))
82
83
 
83
84
  const vbStyle: VxeComponentStyleType = {}
84
85
  const vpStyle: VxeComponentStyleType = {
@@ -94,10 +95,6 @@ export default defineVxeComponent({
94
95
  }
95
96
  }
96
97
 
97
- if (contentMethod) {
98
- title = getStringValue(contentMethod({ row, title, scaleType: scaleUnit }))
99
- }
100
-
101
98
  const ctParams = {
102
99
  $gantt: $xeGantt,
103
100
  source: sourceType,
@@ -108,177 +105,247 @@ export default defineVxeComponent({
108
105
  rowIndex,
109
106
  _rowIndex
110
107
  }
111
- const ctOns: {
112
- mouseover?: any
113
- mouseleave?: any
114
- } = {}
115
- if (showTooltip) {
116
- ctOns.mouseover = (evnt: MouseEvent) => {
117
- const { dragBarRow } = ganttInternalData
118
- const ttParams = Object.assign({ $event: evnt }, ctParams)
119
- if (!dragBarRow) {
120
- $xeGantt.triggerTaskBarTooltipEvent(evnt, ttParams)
121
- }
122
- $xeGantt.dispatchEvent('task-bar-mouseenter', ttParams, evnt)
123
- }
124
- ctOns.mouseleave = (evnt: MouseEvent) => {
125
- const { dragBarRow } = ganttInternalData
126
- const ttParams = Object.assign({ $event: evnt }, ctParams)
127
- if (!dragBarRow) {
128
- $xeGantt.handleTaskBarTooltipLeaveEvent(evnt, ttParams)
129
- }
130
- $xeGantt.dispatchEvent('task-bar-mouseleave', ttParams, evnt)
131
- }
132
- }
133
108
 
134
109
  let cbVNs: VNode[] = []
135
110
  if ($xeGantt.renderGanttTaskBarContent) {
136
111
  cbVNs = $xeGantt.renderGanttTaskBarContent(h, ctParams, {
137
- isMilestone,
138
- title,
139
- vbStyle,
140
- vpStyle,
141
- rowid,
142
- ctOns
112
+ $gantt: $xeGantt,
113
+ $table: $xeTable,
114
+ rowid
143
115
  })
144
- } else if (taskBarSlot) {
145
- cbVNs.push(
146
- h('div', {
147
- key: 'cbc',
148
- class: 'vxe-gantt-view--chart-custom-bar-content-wrapper',
149
- on: ctOns
150
- }, $xeGantt.callSlot(taskBarSlot, barParams, h))
151
- )
152
116
  } else {
153
- if (isSubview && rowChildren && rowChildren.length) {
117
+ const isMilestone = !!(hasEnableConf(taskBarMilestoneConfig, taskBarMilestoneOpts) && hasMilestoneTask(renderTaskType))
118
+ const isSubview = !!(hasEnableConf(taskBarSubviewConfig, taskBarSubviewOpts) && hasSubviewTask(renderTaskType))
119
+
120
+ if (contentMethod) {
121
+ title = getStringValue(contentMethod({ row, title, scaleType: scaleUnit }))
122
+ }
123
+
124
+ const ctOns: {
125
+ mouseover?: any
126
+ mouseleave?: any
127
+ } = {}
128
+ if (showTooltip) {
129
+ ctOns.mouseover = (evnt: MouseEvent) => {
130
+ const { dragBarRow } = ganttInternalData
131
+ const ttParams = Object.assign({ $event: evnt }, ctParams)
132
+ if (!dragBarRow) {
133
+ $xeGantt.triggerTaskBarTooltipEvent(evnt, ttParams)
134
+ }
135
+ $xeGantt.dispatchEvent('task-bar-mouseenter', ttParams, evnt)
136
+ }
137
+ ctOns.mouseleave = (evnt: MouseEvent) => {
138
+ const { dragBarRow } = ganttInternalData
139
+ const ttParams = Object.assign({ $event: evnt }, ctParams)
140
+ if (!dragBarRow) {
141
+ $xeGantt.handleTaskBarTooltipLeaveEvent(evnt, ttParams)
142
+ }
143
+ $xeGantt.dispatchEvent('task-bar-mouseleave', ttParams, evnt)
144
+ }
145
+ }
146
+
147
+ if (isSubview && treeConfig && rowChildren && rowChildren.length) {
154
148
  if (isExpandTree) {
155
149
  if (taskBarSubviewOpts.showOverview) {
156
150
  cbVNs.push(
157
151
  h('div', {
158
152
  key: 'vcso',
159
- class: ['vxe-gantt-view--chart-subview-wrapper is--overview', {
160
- 'is--round': round,
161
- 'is--move': moveable
162
- }]
153
+ class: 'vxe-gantt-view--chart-subview-wrapper is--overview'
163
154
  }, [
164
155
  h('div', {
165
156
  key: rowid,
166
157
  attrs: {
167
158
  rowid: rowid
168
159
  },
169
- class: 'vxe-gantt-view--chart-subview-bar'
160
+ class: ['vxe-gantt-view--chart-subview-row', {
161
+ 'is--progress': showProgress,
162
+ 'is--round': round,
163
+ 'is--move': moveable
164
+ }]
170
165
  }, [
171
166
  h('div', {
172
- class: 'vxe-gantt-view--chart-subview-bar-content-wrapper'
167
+ attrs: {
168
+ rowid: rowid
169
+ },
170
+ class: [taskBarOverviewSlot ? 'vxe-gantt-view--chart-subview-custom-bar' : 'vxe-gantt-view--chart-subview-bar', `is--${renderTaskType}`]
173
171
  }, [
174
- showContent
172
+ taskBarOverviewSlot
175
173
  ? h('div', {
176
- class: 'vxe-gantt-view--chart-content'
177
- }, title)
178
- : renderEmptyElement($xeGantt)
174
+ key: 'cbc',
175
+ class: 'vxe-gantt-view--chart-subview-custom-bar-content-wrapper'
176
+ }, $xeGantt.callSlot(taskBarOverviewSlot, barParams, h))
177
+ : h('div', {
178
+ class: 'vxe-gantt-view--chart-subview-bar-content-wrapper'
179
+ }, [
180
+ showContent
181
+ ? h('div', {
182
+ class: 'vxe-gantt-view--chart-content'
183
+ }, title)
184
+ : renderEmptyElement($xeGantt)
185
+ ])
179
186
  ])
180
187
  ])
181
188
  ])
182
189
  )
183
190
  }
184
191
  } else {
185
- cbVNs.push(
186
- h('div', {
187
- key: 'vcsc',
188
- class: ['vxe-gantt-view--chart-subview-wrapper is--inline', {
189
- 'is--round': round,
190
- 'is--move': moveable
191
- }]
192
- }, rowChildren.map(childRow => {
193
- const childRowid = $xeTable.getRowid(childRow)
194
- let childTitle = getStringValue(XEUtils.get(childRow, titleField))
195
- const childProgressValue = showProgress ? Math.min(100, Math.max(0, XEUtils.toNumber(XEUtils.get(childRow, progressField)))) : 0
196
- const childRenderTaskType = getTaskType(XEUtils.get(childRow, typeField))
197
-
198
- const vpcStyle: VxeComponentStyleType = {
199
- width: `${childProgressValue || 0}%`
192
+ const cbcVNs: VNode[] = []
193
+ XEUtils.eachTree(rowChildren, childRow => {
194
+ const childBarParams = { $gantt: $xeGantt, row: childRow, scaleType: scaleUnit }
195
+ const childBarStyObj = (barStyle ? (isBarRowStyle ? barStyle(childBarParams) : barStyle) : {}) || {}
196
+ const { round } = childBarStyObj
197
+
198
+ const childRowid = $xeTable.getRowid(childRow)
199
+ let childTitle = getStringValue(XEUtils.get(childRow, titleField))
200
+ const childProgressValue = showProgress ? Math.min(100, Math.max(0, XEUtils.toNumber(XEUtils.get(childRow, progressField)))) : 0
201
+ const childRenderTaskType = getTaskType(XEUtils.get(childRow, typeField))
202
+ const isChildSubview = !!(hasEnableConf(taskBarSubviewConfig, taskBarSubviewOpts) && hasSubviewTask(childRenderTaskType))
203
+
204
+ if (isChildSubview) {
205
+ return
206
+ }
207
+
208
+ const childVbStyle: VxeComponentStyleType = {}
209
+ const childVpStyle: VxeComponentStyleType = {
210
+ width: `${childProgressValue || 0}%`
211
+ }
212
+ if (isBarRowStyle) {
213
+ const { bgColor, completedBgColor } = childBarStyObj
214
+ if (bgColor) {
215
+ childVbStyle.backgroundColor = bgColor
200
216
  }
201
- if (isBarRowStyle) {
202
- const { completedBgColor } = barStyObj
203
- if (completedBgColor) {
204
- vpcStyle.backgroundColor = completedBgColor
205
- }
217
+ if (completedBgColor) {
218
+ childVpStyle.backgroundColor = completedBgColor
206
219
  }
220
+ }
207
221
 
208
- if (contentMethod) {
209
- childTitle = getStringValue(contentMethod({ row: childRow, title: childTitle, scaleType: scaleUnit }))
210
- }
222
+ if (contentMethod) {
223
+ childTitle = getStringValue(contentMethod({ row: childRow, title: childTitle, scaleType: scaleUnit }))
224
+ }
211
225
 
212
- return h('div', {
226
+ cbcVNs.push(
227
+ h('div', {
213
228
  key: childRowid,
214
229
  attrs: {
215
230
  rowid: childRowid
216
231
  },
217
- class: ['vxe-gantt-view--chart-subview-bar', `is--${childRenderTaskType}`]
232
+ class: ['vxe-gantt-view--chart-subview-row', `is--${childRenderTaskType}`, {
233
+ 'is--progress': showProgress,
234
+ 'is--round': round,
235
+ 'is--move': moveable,
236
+ 'row--pending': !!pendingRowFlag && !!pendingRowMaps[childRowid]
237
+ }]
218
238
  }, [
219
239
  h('div', {
220
- class: 'vxe-gantt-view--chart-subview-bar-content-wrapper'
240
+ attrs: {
241
+ rowid: childRowid
242
+ },
243
+ class: [taskBarSlot ? 'vxe-gantt-view--chart-subview-custom-bar' : 'vxe-gantt-view--chart-subview-bar', `is--${childRenderTaskType}`],
244
+ on: {
245
+ click (evnt: MouseEvent) {
246
+ evnt.stopPropagation()
247
+ $xeGantt.handleTaskBarClickEvent(evnt, barParams)
248
+ },
249
+ dblclick (evnt: MouseEvent) {
250
+ evnt.stopPropagation()
251
+ $xeGantt.handleTaskBarDblclickEvent(evnt, barParams)
252
+ },
253
+ mousedown (evnt: MouseEvent) {
254
+ evnt.stopPropagation()
255
+ if ($xeGantt.handleTaskBarMousedownEvent) {
256
+ $xeGantt.handleTaskBarMousedownEvent(evnt, barParams)
257
+ }
258
+ }
259
+ }
221
260
  }, [
222
- showProgress
261
+ taskBarSlot
223
262
  ? h('div', {
224
- class: 'vxe-gantt-view--chart-progress',
225
- style: vpcStyle
226
- })
227
- : renderEmptyElement($xeGantt),
228
- showContent
229
- ? h('div', {
230
- class: 'vxe-gantt-view--chart-content'
231
- }, childTitle)
232
- : renderEmptyElement($xeGantt)
263
+ key: 'cbc',
264
+ class: 'vxe-gantt-view--chart-subview-custom-bar-content-wrapper',
265
+ on: ctOns
266
+ }, $xeGantt.callSlot(taskBarSlot, childBarParams, h))
267
+ : h('div', {
268
+ class: 'vxe-gantt-view--chart-subview-bar-content-wrapper',
269
+ on: ctOns
270
+ }, [
271
+ showProgress
272
+ ? h('div', {
273
+ class: 'vxe-gantt-view--chart-progress',
274
+ style: childVpStyle
275
+ })
276
+ : renderEmptyElement($xeGantt),
277
+ showContent
278
+ ? h('div', {
279
+ class: 'vxe-gantt-view--chart-content'
280
+ }, childTitle)
281
+ : renderEmptyElement($xeGantt)
282
+ ])
233
283
  ])
234
284
  ])
235
- }))
285
+ )
286
+ }, { children: childrenField })
287
+
288
+ cbVNs.push(
289
+ h('div', {
290
+ key: 'vcsc',
291
+ class: 'vxe-gantt-view--chart-subview-wrappe is--inliner'
292
+ }, cbcVNs)
236
293
  )
237
294
  }
238
- } else if (isMilestone) {
239
- const { icon, iconStatus, iconStyle } = taskBarMilestoneOpts
240
- const tbmParams = { $gantt: $xeGantt, row }
241
- cbVNs.push(
242
- h('div', {
243
- key: 'vcm',
244
- class: 'vxe-gantt-view--chart-milestone-wrapper',
245
- on: ctOns
246
- }, [
295
+ } else {
296
+ if (taskBarSlot) {
297
+ cbVNs.push(
298
+ h('div', {
299
+ key: 'cbc',
300
+ class: 'vxe-gantt-view--chart-custom-bar-content-wrapper',
301
+ on: ctOns
302
+ }, $xeGantt.callSlot(taskBarSlot, barParams, h))
303
+ )
304
+ } else if (isMilestone) {
305
+ const { icon, iconStatus, iconStyle } = taskBarMilestoneOpts
306
+ const tbmParams = { $gantt: $xeGantt, row }
307
+ cbVNs.push(
247
308
  h('div', {
248
- class: ['vxe-gantt-view--chart-milestone-icon', iconStatus ? `theme--${XEUtils.isFunction(iconStatus) ? iconStatus(tbmParams) : iconStatus}` : ''],
249
- style: iconStyle ? Object.assign({}, XEUtils.isFunction(iconStyle) ? iconStyle(tbmParams) : iconStyle) : undefined
309
+ key: 'vcm',
310
+ class: 'vxe-gantt-view--chart-milestone-wrapper',
311
+ on: ctOns
250
312
  }, [
251
- h('i', {
252
- class: (icon ? (XEUtils.isFunction(icon) ? icon(tbmParams) : icon) : '') || getIcon().GANTT_VIEW_TASK_MILESTONE
253
- })
254
- ]),
255
- showContent
256
- ? h('div', {
257
- class: 'vxe-gantt-view--chart-milestone-content'
258
- }, title)
259
- : renderEmptyElement($xeGantt)
260
- ])
261
- )
262
- } else {
263
- cbVNs.push(
264
- h('div', {
265
- key: 'vbc',
266
- class: 'vxe-gantt-view--chart-bar-content-wrapper',
267
- on: ctOns
268
- }, [
269
- showProgress
270
- ? h('div', {
271
- class: 'vxe-gantt-view--chart-progress',
272
- style: vpStyle
273
- })
274
- : renderEmptyElement($xeGantt),
275
- showContent
276
- ? h('div', {
277
- class: 'vxe-gantt-view--chart-content'
278
- }, title)
279
- : renderEmptyElement($xeGantt)
280
- ])
281
- )
313
+ h('div', {
314
+ class: ['vxe-gantt-view--chart-milestone-icon', iconStatus ? `theme--${XEUtils.isFunction(iconStatus) ? iconStatus(tbmParams) : iconStatus}` : ''],
315
+ style: iconStyle ? Object.assign({}, XEUtils.isFunction(iconStyle) ? iconStyle(tbmParams) : iconStyle) : undefined
316
+ }, [
317
+ h('i', {
318
+ class: (icon ? (XEUtils.isFunction(icon) ? icon(tbmParams) : icon) : '') || getIcon().GANTT_VIEW_TASK_MILESTONE
319
+ })
320
+ ]),
321
+ showContent
322
+ ? h('div', {
323
+ class: 'vxe-gantt-view--chart-milestone-content'
324
+ }, title)
325
+ : renderEmptyElement($xeGantt)
326
+ ])
327
+ )
328
+ } else {
329
+ cbVNs.push(
330
+ h('div', {
331
+ key: 'vbc',
332
+ class: 'vxe-gantt-view--chart-bar-content-wrapper',
333
+ on: ctOns
334
+ }, [
335
+ showProgress
336
+ ? h('div', {
337
+ class: 'vxe-gantt-view--chart-progress',
338
+ style: vpStyle
339
+ })
340
+ : renderEmptyElement($xeGantt),
341
+ showContent
342
+ ? h('div', {
343
+ class: 'vxe-gantt-view--chart-content'
344
+ }, title)
345
+ : renderEmptyElement($xeGantt)
346
+ ])
347
+ )
348
+ }
282
349
  }
283
350
  }
284
351
 
@@ -288,6 +355,7 @@ export default defineVxeComponent({
288
355
  rowid
289
356
  },
290
357
  class: ['vxe-gantt-view--chart-row', `is--${renderTaskType}`, {
358
+ 'is--progress': showProgress,
291
359
  'row--pending': !!pendingRowFlag && !!pendingRowMaps[rowid],
292
360
  'is--round': round,
293
361
  'is--move': moveable
@@ -767,8 +767,8 @@ function updateTaskChartStyle ($xeGanttView: VxeGanttViewConstructor & VxeGanttV
767
767
  if (childWrapperEl) {
768
768
  // 行内展示
769
769
  if (hasClass(childWrapperEl, 'is--inline')) {
770
- XEUtils.arrayEach(childWrapperEl.children, (childEl) => {
771
- const childBarEl = childEl as HTMLDivElement
770
+ XEUtils.arrayEach(childWrapperEl.children, (childRowEl) => {
771
+ const childBarEl = childRowEl.children[0] as HTMLDivElement
772
772
  const childRowid = childBarEl.getAttribute('rowid') || ''
773
773
  const childChartRest = childRowid ? chartMaps[childRowid] : null
774
774
  if (childChartRest) {
@@ -790,7 +790,8 @@ function updateTaskChartStyle ($xeGanttView: VxeGanttViewConstructor & VxeGanttV
790
790
  })
791
791
  } else {
792
792
  // 如果展开子任务
793
- const childBarEl = childWrapperEl.firstElementChild as HTMLDivElement
793
+ const childRowEl = childWrapperEl.children[0] as HTMLDivElement
794
+ const childBarEl = childRowEl ? childRowEl.children[0] as HTMLDivElement : null
794
795
  if (childBarEl) {
795
796
  const rowChildren: any[] = row ? row[childrenField] : []
796
797
  const { minSize: minChildLeftSize, maxSize: maxChildLeftSize } = handleSubTaskMinMaxSize($xeGanttView, $xeTable, rowChildren)
@@ -8,13 +8,15 @@
8
8
  pointer-events: none;
9
9
  }
10
10
 
11
- .vxe-gantt-view--chart-row {
11
+ .vxe-gantt-view--chart-row,
12
+ .vxe-gantt-view--chart-subview-row {
12
13
  position: relative;
13
14
  width: 100%;
14
15
  height: 0;
16
+ }
17
+ .vxe-gantt-view--chart-row {
15
18
  &.row--pending {
16
- .vxe-gantt-view--chart-bar,
17
- .vxe-gantt-view--chart-subview-bar {
19
+ .vxe-gantt-view--chart-bar {
18
20
  color: var(--vxe-ui-font-disabled-color);
19
21
  opacity: 0.5;
20
22
  text-decoration: line-through;
@@ -36,11 +38,21 @@
36
38
  }
37
39
  }
38
40
  }
39
- .vxe-gantt-view--chart-subview-wrapper {
41
+ .vxe-gantt-view--chart-subview-row {
42
+ &.row--pending {
43
+ .vxe-gantt-view--chart-subview-bar,
44
+ .vxe-gantt-view--chart-subview-custom-bar {
45
+ color: var(--vxe-ui-font-disabled-color);
46
+ opacity: 0.5;
47
+ text-decoration: line-through;
48
+ }
49
+ }
40
50
  &.is--round {
41
- & > .vxe-gantt-view--chart-subview-bar {
51
+ & > .vxe-gantt-view--chart-subview-bar,
52
+ & > .vxe-gantt-view--chart-subview-custom-bar {
42
53
  border-radius: var(--vxe-ui-gantt-view-task-bar-border-radius);
43
- .vxe-gantt-view--chart-subview-bar-content-wrapper {
54
+ .vxe-gantt-view--chart-subview-bar-content-wrapper,
55
+ .vxe-gantt-view--chart-subview-custom-bar-content-wrapper {
44
56
  border-radius: var(--vxe-ui-gantt-view-task-bar-border-radius);
45
57
  }
46
58
  &:hover {
@@ -50,17 +62,22 @@
50
62
  }
51
63
  }
52
64
  }
65
+ }
66
+ .vxe-gantt-view--chart-subview-wrapper {
53
67
  &.is--overview {
54
- & > .vxe-gantt-view--chart-subview-bar {
55
- color: #ffffff;
56
- background-color: var(--vxe-ui-gantt-view-task-bar-overview-background-color);
68
+ & > .vxe-gantt-view--chart-subview-row {
69
+ .vxe-gantt-view--chart-subview-bar {
70
+ color: #ffffff;
71
+ background-color: var(--vxe-ui-gantt-view-task-bar-overview-background-color);
72
+ }
57
73
  }
58
74
  }
59
75
  }
60
76
 
61
77
  .vxe-gantt-view--chart-bar,
78
+ .vxe-gantt-view--chart-custom-bar,
62
79
  .vxe-gantt-view--chart-subview-bar,
63
- .vxe-gantt-view--chart-custom-bar {
80
+ .vxe-gantt-view--chart-subview-custom-bar {
64
81
  display: flex;
65
82
  flex-direction: row;
66
83
  position: absolute;
@@ -68,18 +85,61 @@
68
85
  left: 0;
69
86
  transform: translateY(-50%);
70
87
  pointer-events: all;
71
- &.is--default {
72
- color: #ffffff;
73
- background-color: var(--vxe-ui-gantt-view-task-bar-background-color);
88
+ }
89
+
90
+ .vxe-gantt-view--chart-row {
91
+ &.is--progress {
92
+ & > .vxe-gantt-view--chart-bar,
93
+ & > .vxe-gantt-view--chart-custom-bar {
94
+ &.is--default {
95
+ color: #ffffff;
96
+ background-color: var(--vxe-ui-gantt-view-task-bar-background-color);
97
+ }
98
+ }
99
+ }
100
+ &:not(.is--progress) {
101
+ & > .vxe-gantt-view--chart-bar,
102
+ & > .vxe-gantt-view--chart-custom-bar {
103
+ &.is--default {
104
+ color: #ffffff;
105
+ background-color: var(--vxe-ui-gantt-view-task-bar-completed-background-color);
106
+ }
107
+ }
108
+ }
109
+ }
110
+ .vxe-gantt-view--chart-subview-row {
111
+ &.is--progress {
112
+ & > .vxe-gantt-view--chart-subview-bar,
113
+ & > .vxe-gantt-view--chart-subview-custom-bar {
114
+ &.is--subview {
115
+ color: #ffffff;
116
+ background-color: var(--vxe-ui-gantt-view-task-bar-overview-background-color);
117
+ }
118
+ &.is--default {
119
+ color: #ffffff;
120
+ background-color: var(--vxe-ui-gantt-view-task-bar-background-color);
121
+ }
122
+ }
74
123
  }
75
- &.is--subview {
76
- color: #ffffff;
77
- background-color: var(--vxe-ui-gantt-view-task-bar-overview-background-color);
124
+ &:not(.is--progress) {
125
+ & > .vxe-gantt-view--chart-subview-bar,
126
+ & > .vxe-gantt-view--chart-subview-custom-bar {
127
+ &.is--subview {
128
+ color: #ffffff;
129
+ background-color: var(--vxe-ui-gantt-view-task-bar-overview-background-color);
130
+ }
131
+ &.is--default {
132
+ color: #ffffff;
133
+ background-color: var(--vxe-ui-gantt-view-task-bar-completed-background-color);
134
+ }
135
+ }
78
136
  }
79
137
  }
138
+
80
139
  .vxe-gantt-view--chart-bar-content-wrapper,
81
140
  .vxe-gantt-view--chart-custom-bar-content-wrapper,
82
- .vxe-gantt-view--chart-subview-bar-content-wrapper {
141
+ .vxe-gantt-view--chart-subview-bar-content-wrapper,
142
+ .vxe-gantt-view--chart-subview-custom-bar-content-wrapper {
83
143
  width: 100%;
84
144
  overflow: hidden;
85
145
  }
@@ -183,7 +243,8 @@ $iconThemeList: (
183
243
  }
184
244
 
185
245
  /*行拖拽*/
186
- .vxe-gantt-view--chart-row {
246
+ .vxe-gantt-view--chart-row,
247
+ .vxe-gantt-view--chart-subview-row {
187
248
  &.row--drag-move {
188
249
  transition: transform 0.5s ease;
189
250
  }
@@ -8,7 +8,7 @@
8
8
  --vxe-ui-gantt-view-task-bar-border-radius: calc(var(--vxe-ui-gantt-view-split-bar-height) / 2);
9
9
  --vxe-ui-gantt-view-task-bar-background-color: var(--vxe-ui-font-primary-lighten-color);
10
10
  --vxe-ui-gantt-view-task-bar-completed-background-color: var(--vxe-ui-font-primary-color);
11
- --vxe-ui-gantt-view-task-bar-overview-background-color: var(--vxe-ui-font-primary-darken-color);
11
+ --vxe-ui-gantt-view-task-bar-overview-background-color: var(--vxe-ui-font-disabled-color);
12
12
  --vxe-ui-gantt-view-task-line-color: var(--vxe-ui-font-primary-color);
13
13
  --vxe-ui-gantt-view-task-line-width: 2px;
14
14
  --vxe-ui-gantt-view-task-line-arrow-width: 5;