vxe-gantt 4.9.7 → 4.9.8
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/dist/all.esm.js +5 -2
- package/es/components.d.ts +2 -0
- package/es/components.js +1 -0
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/lib/components.js +1 -0
- package/lib/index.umd.js +4 -2
- package/lib/index.umd.min.js +1 -1
- package/lib/ui/index.js +1 -1
- package/lib/ui/src/log.js +1 -1
- package/package.json +2 -2
- package/packages/components.ts +4 -0
package/dist/all.esm.js
CHANGED
|
@@ -23,6 +23,7 @@ __export(index_exports, {
|
|
|
23
23
|
VxeGantt: () => VxeGantt,
|
|
24
24
|
VxeGanttDependencyType: () => VxeGanttDependencyType,
|
|
25
25
|
VxeGanttTaskType: () => VxeGanttTaskType,
|
|
26
|
+
VxeUI: () => VxeUI10,
|
|
26
27
|
default: () => index_default,
|
|
27
28
|
install: () => install
|
|
28
29
|
});
|
|
@@ -34,6 +35,7 @@ __export(components_exports, {
|
|
|
34
35
|
VxeGantt: () => VxeGantt,
|
|
35
36
|
VxeGanttDependencyType: () => VxeGanttDependencyType,
|
|
36
37
|
VxeGanttTaskType: () => VxeGanttTaskType,
|
|
38
|
+
VxeUI: () => VxeUI10,
|
|
37
39
|
install: () => install
|
|
38
40
|
});
|
|
39
41
|
import { VxeUI as VxeUI10 } from "@vxe-ui/core";
|
|
@@ -47,7 +49,7 @@ import { VxeUI as VxeUI2 } from "@vxe-ui/core";
|
|
|
47
49
|
// packages_temp/ui/src/log.ts
|
|
48
50
|
import { VxeUI } from "@vxe-ui/core";
|
|
49
51
|
var { log } = VxeUI;
|
|
50
|
-
var ganttVersion = `gantt v${"4.9.
|
|
52
|
+
var ganttVersion = `gantt v${"4.9.8"}`;
|
|
51
53
|
function createComponentLog(name) {
|
|
52
54
|
const uiVersion = VxeUI.uiVersion ? `ui v${VxeUI.uiVersion}` : "";
|
|
53
55
|
const tableVersion = VxeUI.tableVersion ? `table v${VxeUI.tableVersion}` : "";
|
|
@@ -6965,7 +6967,7 @@ var gantt_default2 = VxeGantt;
|
|
|
6965
6967
|
// packages_temp/ui/index.ts
|
|
6966
6968
|
import { VxeUI as VxeUI9 } from "@vxe-ui/core";
|
|
6967
6969
|
var { setConfig, setIcon } = VxeUI9;
|
|
6968
|
-
VxeUI9.ganttVersion = "4.9.
|
|
6970
|
+
VxeUI9.ganttVersion = "4.9.8";
|
|
6969
6971
|
var ymdFormat = "yyyy-MM-dd";
|
|
6970
6972
|
var ymdhmsFormat = "yyyy-MM-dd HH:mm:ss";
|
|
6971
6973
|
setConfig({
|
|
@@ -7106,6 +7108,7 @@ export {
|
|
|
7106
7108
|
VxeGantt,
|
|
7107
7109
|
VxeGanttDependencyType,
|
|
7108
7110
|
VxeGanttTaskType,
|
|
7111
|
+
VxeUI10 as VxeUI,
|
|
7109
7112
|
index_default as default,
|
|
7110
7113
|
install
|
|
7111
7114
|
};
|
package/es/components.d.ts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { App } from 'vue';
|
|
2
|
+
import { VxeUI } from '@vxe-ui/core';
|
|
2
3
|
import './ui';
|
|
3
4
|
import type { VxeGlobalConfig } from 'vxe-pc-ui';
|
|
4
5
|
export declare function install(app: App, options?: VxeGlobalConfig): void;
|
|
6
|
+
export { VxeUI };
|
|
5
7
|
export * from '@vxe-ui/core';
|
|
6
8
|
export * from './gantt';
|
package/es/components.js
CHANGED
package/es/ui/index.js
CHANGED
package/es/ui/src/log.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { VxeUI } from "@vxe-ui/core";
|
|
2
2
|
const { log } = VxeUI;
|
|
3
|
-
const ganttVersion = `gantt v${"4.9.
|
|
3
|
+
const ganttVersion = `gantt v${"4.9.8"}`;
|
|
4
4
|
function createComponentLog(name) {
|
|
5
5
|
const uiVersion = VxeUI.uiVersion ? `ui v${VxeUI.uiVersion}` : "";
|
|
6
6
|
const tableVersion = VxeUI.tableVersion ? `table v${VxeUI.tableVersion}` : "";
|
package/lib/components.js
CHANGED
|
@@ -29,6 +29,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
29
29
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
30
30
|
var components_exports = {};
|
|
31
31
|
__export(components_exports, {
|
|
32
|
+
VxeUI: () => import_core.VxeUI,
|
|
32
33
|
install: () => install
|
|
33
34
|
});
|
|
34
35
|
module.exports = __toCommonJS(components_exports);
|
package/lib/index.umd.js
CHANGED
|
@@ -62,6 +62,7 @@ __export(index_exports, {
|
|
|
62
62
|
VxeGantt: () => VxeGantt,
|
|
63
63
|
VxeGanttDependencyType: () => VxeGanttDependencyType,
|
|
64
64
|
VxeGanttTaskType: () => VxeGanttTaskType,
|
|
65
|
+
VxeUI: () => import_core10.VxeUI,
|
|
65
66
|
default: () => index_default,
|
|
66
67
|
install: () => install
|
|
67
68
|
});
|
|
@@ -74,6 +75,7 @@ __export(components_exports, {
|
|
|
74
75
|
VxeGantt: () => VxeGantt,
|
|
75
76
|
VxeGanttDependencyType: () => VxeGanttDependencyType,
|
|
76
77
|
VxeGanttTaskType: () => VxeGanttTaskType,
|
|
78
|
+
VxeUI: () => import_core10.VxeUI,
|
|
77
79
|
install: () => install
|
|
78
80
|
});
|
|
79
81
|
var import_core10 = require("@vxe-ui/core");
|
|
@@ -87,7 +89,7 @@ var import_core2 = require("@vxe-ui/core");
|
|
|
87
89
|
// packages_temp/ui/src/log.ts
|
|
88
90
|
var import_core = require("@vxe-ui/core");
|
|
89
91
|
var { log } = import_core.VxeUI;
|
|
90
|
-
var ganttVersion = `gantt v${"4.9.
|
|
92
|
+
var ganttVersion = `gantt v${"4.9.8"}`;
|
|
91
93
|
function createComponentLog(name) {
|
|
92
94
|
const uiVersion = import_core.VxeUI.uiVersion ? `ui v${import_core.VxeUI.uiVersion}` : "";
|
|
93
95
|
const tableVersion = import_core.VxeUI.tableVersion ? `table v${import_core.VxeUI.tableVersion}` : "";
|
|
@@ -7005,7 +7007,7 @@ var gantt_default2 = VxeGantt;
|
|
|
7005
7007
|
// packages_temp/ui/index.ts
|
|
7006
7008
|
var import_core9 = require("@vxe-ui/core");
|
|
7007
7009
|
var { setConfig, setIcon } = import_core9.VxeUI;
|
|
7008
|
-
import_core9.VxeUI.ganttVersion = "4.9.
|
|
7010
|
+
import_core9.VxeUI.ganttVersion = "4.9.8";
|
|
7009
7011
|
var ymdFormat = "yyyy-MM-dd";
|
|
7010
7012
|
var ymdhmsFormat = "yyyy-MM-dd HH:mm:ss";
|
|
7011
7013
|
setConfig({
|
package/lib/index.umd.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(no,ta){typeof module=="object"&&typeof module.exports=="object"?module.exports=ta(require("vue"),require("xe-utils"),require("@vxe-ui/core"),require("vxe-table")):typeof define=="function"&&define.amd?define(["vue","xe-utils","@vxe-ui/core","vxe-table"],ta):(no=typeof globalThis!="undefined"?globalThis:no||self,no.VxeUIGantt=ta(no.Vue,no.XEUtils,no.VxeUI,no.VxeUITable))})(this,function(no,ta,Or,Rr){var Oa={vue:no,"xe-utils":ta,"@vxe-ui/core":Or,"vxe-table":Rr},ge=function(o){return Oa[o]!==void 0?Oa[o]:typeof window!="undefined"&&window[o]?window[o]:typeof globalThis!="undefined"&&globalThis[o]?globalThis[o]:Oa[o]},ca={exports:{}},On=ca.exports,$r=Object.create,ua=Object.defineProperty,Mr=Object.getOwnPropertyDescriptor,Vr=Object.getOwnPropertyNames,Lr=Object.getPrototypeOf,Fr=Object.prototype.hasOwnProperty,Xa=(o,F)=>{for(var W in F)ua(o,W,{get:F[W],enumerable:!0})},da=(o,F,W,me)=>{if(F&&typeof F=="object"||typeof F=="function")for(let ee of Vr(F))!Fr.call(o,ee)&&ee!==W&&ua(o,ee,{get:()=>F[ee],enumerable:!(me=Mr(F,ee))||me.enumerable});return o},Ua=(o,F,W)=>(da(o,F,"default"),W&&da(W,F,"default")),yo=(o,F,W)=>(W=o!=null?$r(Lr(o)):{},da(F||!o||!o.__esModule?ua(W,"default",{value:o,enumerable:!0}):W,o)),Pr=o=>da(ua({},"__esModule",{value:!0}),o),Ra={};Xa(Ra,{Gantt:()=>Sr,VxeGantt:()=>ra,VxeGanttDependencyType:()=>wa,VxeGanttTaskType:()=>Ia,default:()=>Dn,install:()=>Tr}),ca.exports=Pr(Ra);var fa={};Xa(fa,{Gantt:()=>Sr,VxeGantt:()=>ra,VxeGanttDependencyType:()=>wa,VxeGanttTaskType:()=>Ia,install:()=>Tr});var Wr=ge("@vxe-ui/core"),$a=ge("@vxe-ui/core"),pa=ge("@vxe-ui/core"),Vo=ge("@vxe-ui/core"),{log:ga}=Vo.VxeUI,Ma="gantt v4.9.7";function Ir(o){const F=Vo.VxeUI.uiVersion?`ui v${Vo.VxeUI.uiVersion}`:"",W=Vo.VxeUI.tableVersion?`table v${Vo.VxeUI.tableVersion}`:"",me=Vo.VxeUI.designVersion?`design v${Vo.VxeUI.designVersion}`:"",ee=[F,W,Ma,me].filter(Ne=>Ne).join(" ");return{warnLog:ga.create("warn",ee+"] ["+o),errLog:ga.create("error",ee+"] ["+o)}}var Rn=ga.create("warn",Ma),Ga=ga.create("error",Ma);function Br(){pa.VxeUI.checkVersion?pa.VxeUI.checkVersion(pa.VxeUI.tableVersion,4,23)||Ga("vxe.error.errorVersion",[`vxe-table@${pa.VxeUI.tableVersion||"?"}`,"vxe-table v4.23+"]):Ga("Requires vxe-table v4.23+")}var n=ge("vue"),zr=ge("vue"),Yo=zr.defineComponent,B=yo(ge("xe-utils")),Va=yo(ge("xe-utils")),qa=ge("@vxe-ui/core"),{zIndex:Qa}=qa.VxeUI;function ne(o){return o&&o.enabled!==!1}function oa(o,F){return F&&(o?F.enabled!==!1:F.enabled)}function Hr(o){return o==null||o===""}function _r(){return Qa.next()}function jr(){return Qa.getLast()}function Za(o,F){return""+(Hr(o)?F?qa.VxeUI.getConfig().emptyCell:"":o)}function Yr(o){return o===""||Va.default.eqNull(o)}function ha(o){return Yr(o)?"":o}function Ka(o,F){return o?Va.default.isFunction(o)?o(F):o:""}function ot(o,F){return Va.default.eqNull(o)?F:o}var La=yo(ge("xe-utils")),Fa={};function Ja(o){return Fa[o]||(Fa[o]=new RegExp(`(?:^|\\s)${o}(?!\\S)`,"g")),Fa[o]}function So(o,F){return o?o.classList?o.classList.contains(F):!!(o.className&&o.className.match&&o.className.match(Ja(F))):!1}function va(o,F){o&&So(o,F)&&(o.className=o.className.replace(Ja(F),""))}function Pa(o,F){o&&!So(o,F)&&(va(o,F),o.className=`${o.className} ${F}`)}function Lo(o,F="px"){return La.default.isNumber(o)||/^\d+$/.test(`${o}`)?`${o}${F}`:`${o||""}`}function Nr(){const o=document.documentElement,F=document.body;return{scrollTop:o.scrollTop||F.scrollTop,scrollLeft:o.scrollLeft||F.scrollLeft,visibleHeight:o.clientHeight||F.clientHeight,visibleWidth:o.clientWidth||F.clientWidth}}function aa(o){return o?o.offsetHeight:0}function er(o){if(o){const F=getComputedStyle(o),W=La.default.toNumber(F.paddingTop),me=La.default.toNumber(F.paddingBottom);return W+me}return 0}function tr(o,F){o&&(o.scrollTop=F)}function No(o,F){o&&(o.scrollLeft=F)}var Ar=yo(ge("xe-utils"));function Xr(o){return Ar.default.isArray(o)?o:o?[o]:[]}var Se=ge("@vxe-ui/core"),or=["ready","init-rendered","data-rendered","update:data","keydown-start","keydown","keydown-end","paste","copy","cut","undo","redo","context-menu","columns-change","data-change","footer-data-change","current-change","current-row-change","current-row-disabled","current-column-change","current-column-disabled","radio-change","checkbox-change","checkbox-all","checkbox-range-start","checkbox-range-change","checkbox-range-end","checkbox-range-select","cell-click","cell-dblclick","cell-menu","cell-mouseenter","cell-mouseleave","cell-selected","cell-delete-value","cell-backspace-value","header-cell-click","header-cell-dblclick","header-cell-menu","footer-cell-click","footer-cell-dblclick","footer-cell-menu","clear-merge","sort-change","clear-sort","clear-all-sort","filter-change","filter-visible","clear-filter","clear-all-filter","resizable-change","column-resizable-change","row-resizable-change","toggle-row-group-expand","toggle-row-expand","toggle-tree-expand","menu-click","edit-closed","row-dragstart","row-dragover","row-dragend","row-remove-dragend","row-insert-dragend","column-dragstart","column-dragover","column-dragend","enter-append-row","tab-append-row","edit-actived","edit-activated","edit-disabled","valid-error","scroll","scroll-boundary","custom","custom-open","custom-close","custom-cancel","custom-reset","custom-confirm","custom-visible-change","custom-visible-all","custom-fixed-change","custom-sort-change","custom-align-change","custom-header-align-change","custom-footer-align-change","change-fnr","open-fnr","show-fnr","hide-fnr","fnr-change","fnr-find","fnr-find-all","fnr-replace","fnr-replace-all","cell-area-copy","cell-area-cut","cell-area-paste","cell-area-merge","clear-cell-area-selection","clear-cell-area-merge","header-cell-area-selection","cell-area-selection-invalid","cell-area-selection-start","cell-area-selection-drag","cell-area-selection-end","cell-area-extension-start","cell-area-extension-drag","cell-area-extension-end","cell-area-extension-fill","cell-area-selection-all-start","cell-area-selection-all-end","cell-area-arrows-start","cell-area-arrows-end","cell-area-fill-copy","active-cell-change-start","active-cell-change-end"],Ur=[...or,"page-change","form-submit","form-submit-invalid","form-reset","form-collapse","form-toggle-collapse","proxy-query","proxy-delete","proxy-save","toolbar-button-click","toolbar-tool-click","zoom"],Gr=[...Ur,"task-cell-click","task-cell-dblclick","task-bar-mouseenter","task-bar-mouseleave","task-bar-click","task-bar-dblclick","task-view-cell-click","task-view-cell-dblclick","task-move-start","task-move-drag","task-move-end","task-resize-start","task-resize-drag","task-resize-end","task-link-click","task-link-dblclick","task-link-remove"];function le(o){if(o){const F=o.value;if(F)return F.$el||F}return null}function ar(o,F,W,me){return o.resizeHeight||F.height||W.height||o.height||me}function rr(o,F){return o?F*o.oLeftSize:0}function nr(o,F){return o&&o.oWidthSize?Math.max(1,o?Math.floor(F*o.oWidthSize)-1:0):0}var qr={milestone:!0,subview:!0};function ma(o){return o==="milestone"}function ba(o){return o==="subview"}function Wa(o){return qr[o]?o:"default"}var O=ge("vue"),sr=ge("@vxe-ui/core"),wa=(o=>(o[o.FinishToStart=0]="FinishToStart",o[o.StartToFinish=1]="StartToFinish",o[o.StartToStart=2]="StartToStart",o[o.FinishToFinish=3]="FinishToFinish",o))(wa||{}),Ia=(o=>(o.Milestone="milestone",o.Subview="subview",o))(Ia||{}),i=yo(ge("xe-utils")),ct=ge("vue"),Qr=ge("@vxe-ui/core"),lr=yo(ge("xe-utils")),{getI18n:so}=Qr.VxeUI,Zr="gantt",Kr="header",Jr=Yo({name:"VxeGanttViewHeader",setup(){const o=(0,ct.inject)("$xeGantt",{}),F=(0,ct.inject)("$xeGanttView",{}),{computeTaskViewOpts:W,computeScaleStep:me,computeMinScale:ee}=o.getComputeMaps(),{reactData:Ne,internalData:N}=F,Oe=(0,ct.ref)(),Wt=(0,ct.ref)(),Yt=(0,ct.ref)(),St=(0,ct.ref)(),It=()=>{const{headerGroups:we,viewCellWidth:y}=Ne,{todayDateMaps:P,visibleColumn:ae}=N,Z=W.value,ie=ee.value,at=me.value,{showNowLine:Ee}=Z;return(0,ct.h)("div",{ref:Oe,class:"vxe-gantt-view--header-wrapper"},[(0,ct.h)("div",{ref:Wt,class:"vxe-gantt-view--header-inner-wrapper",onScroll:F.triggerHeaderScrollEvent},[(0,ct.h)("div",{ref:St,class:"vxe-body--x-space"}),(0,ct.h)("table",{ref:Yt,class:"vxe-gantt-view--header-table"},[(0,ct.h)("colgroup",{},ae.map((qe,Fe)=>(0,ct.h)("col",{key:Fe,style:{width:`${y}px`}}))),(0,ct.h)("thead",{},we.map(({scaleItem:qe,columns:Fe},Pe)=>{const{type:Re,titleFormat:dt,titleMethod:A,headerCellStyle:te,slots:se}=qe,Ae=se?se.title:null,Xe=Pe===we.length-1,ft=Xe&&Ee?P[Re]:null;return(0,ct.h)("tr",{key:Pe},Fe.map((be,Qe)=>{const{field:pt,childCount:gt,dateObj:V,startDateObj:M,endDateObj:Ze}=be;let re=`${be.title}`;(Xe||ie&&(ie.type==="date"||ie.type==="day")&&(Re==="date"||Re==="day"))&&at>1?re=so(`vxe.gantt.stepFormat.${Re}`,{start:M,end:Ze,eStartLabel:so(`vxe.gantt.dayss.w${M.e}`),eEndLabel:so(`vxe.gantt.dayss.w${Ze.e}`)}):Re==="day"?Pe?re=so(`vxe.gantt.tSimpleFormat.${Re}`,{eLabel:so(`vxe.gantt.dayss.w${V.e}`)}):re=so(`vxe.gantt.tFullFormat.${Re}`,{eLabel:so(`vxe.gantt.dayss.w${V.e}`)}):Pe?re=so(`vxe.gantt.tSimpleFormat.${Re}`,V):re=so(`vxe.gantt.tFullFormat.${Re}`,V);let he=re;const ke={source:Zr,type:Kr,column:be,scaleObj:qe,title:re,dateObj:V,startDateObj:M,endDateObj:Ze,$rowIndex:Pe};Ae?he=o.callSlot(Ae,ke):A?he=`${A(ke)}`:dt&&(he=lr.default.toDateString(V.date,dt));let rt={};return te&&(lr.default.isFunction(te)?rt=te(ke)||null:rt=te),(0,ct.h)("th",{key:Qe,class:["vxe-gantt-view--header-column",{"is--now":Ee&&ft&&ft===pt}],colspan:gt||null,title:Ae?null:re,style:rt||void 0,onContextmenu(De){o.handleTaskHeaderContextmenuEvent(De,ke)}},he)}))}))])])])};return(0,ct.onMounted)(()=>{const{elemStore:we}=N,y="main-header-";we[`${y}wrapper`]=Oe,we[`${y}scroll`]=Wt,we[`${y}table`]=Yt,we[`${y}xSpace`]=St}),(0,ct.onUnmounted)(()=>{const{elemStore:we}=N,y="main-header-";we[`${y}wrapper`]=null,we[`${y}scroll`]=null,we[`${y}table`]=null,we[`${y}xSpace`]=null}),It}}),Le=ge("vue"),ir=yo(ge("xe-utils")),J=ge("vue"),en=ge("@vxe-ui/core"),ut=yo(ge("xe-utils")),{getIcon:tn,renderEmptyElement:lo}=en.VxeUI,cr="gantt",ur="chart",on=Yo({name:"VxeGanttViewChart",setup(){const o=(0,J.inject)("$xeGantt",{}),F=(0,J.inject)("$xeGanttView",{}),{props:W,context:me,reactData:ee,internalData:Ne}=o,{reactData:N,internalData:Oe}=F,{computeProgressField:Wt,computeTitleField:Yt,computeTypeField:St,computeTaskBarOpts:It,computeScaleUnit:we,computeTaskLinkOpts:y,computeTaskBarMilestoneOpts:P,computeTaskBarSubviewOpts:ae}=o.getComputeMaps(),{computeNowLineLeft:Z}=F.getComputeMaps(),ie=(0,J.ref)(),at=(0,J.ref)(),Ee=(0,J.ref)(),qe=(0,J.ref)(),Fe=(0,J.ref)(),Pe=(A,te,se,Ae,Xe,ft,be,Qe)=>{const pt=A.reactData,{resizeHeightFlag:gt,pendingRowFlag:V}=pt,M=A.internalData,{fullAllDataRowIdData:Ze,pendingRowMaps:re}=M,{computeCellOpts:he,computeRowOpts:ke,computeDefaultRowHeight:rt}=A.getComputeMaps(),De=he.value,Ke=ke.value,We=rt.value,{computeTreeOpts:nt}=A.getComputeMaps(),st=nt.value,Ie=st.children||st.childrenField,Be=o.context.slots,mt=Be.taskBar||Be["task-bar"],Je=Be.taskBarOverview||Be["task-bar-overview"],{treeConfig:ht,taskBarMilestoneConfig:bt,taskBarSubviewConfig:Te}=W,{activeLink:xe,activeBarRowid:vt,criticalPathFlag:Bt}=ee,{criticalRowMaps:io}=Ne,co=Yt.value,zt=Wt.value,Nt=St.value,uo=It.value,Ht=P.value,Fo=ae.value,{showOverview:At,barStyle:To}=Fo,Co=we.value,de={$gantt:o,source:cr,type:ur,scaleType:Co,row:te,$rowIndex:Xe,rowIndex:Ae,_rowIndex:ft},{showProgress:Xt,showCriticalPath:_t,showContent:Tt,contentMethod:jt,barStyle:Ut,moveable:Po,showTooltip:Go}=uo,Wo=ut.default.isFunction(Ut),Kt=(Ut?Wo?Ut(de)||void 0:Ut:{})||{},Eo=Kt.round,qo=Kt.bgColor,Do=Kt.completedBgColor,Io=Kt.style,sa=Ze[se]||{},Bo=gt?ar(sa,De,Ke,We):0;let Ct=ha(ut.default.get(te,co));const Qo=Xt?Math.min(100,Math.max(0,ut.default.toNumber(ut.default.get(te,zt)))):0,fo=Wa(ut.default.get(te,Nt)),Oo=!!(oa(bt,Ht)&&ma(fo)),Jt={...de},po={},la={width:`${Qo||0}%`};Oo||Wo&&(qo&&(po["--vxe-ui-gantt-view-task-bar-background-color"]=qo),Do&&(po["--vxe-ui-gantt-view-task-bar-completed-background-color"]=Do)),Io&&ut.default.assign(po,Io);let $t=[];if(o.renderGanttTaskBarContent)$t=o.renderGanttTaskBarContent(Jt,{$gantt:o,$table:A,rowid:se});else{const b=!!(oa(Te,Fo)&&ba(fo));jt&&(Ct=ha(jt({row:te,title:Ct,scaleType:Co})));const Mt={};if(Go&&(Mt.onMouseover=Ue=>{const{dragBarRow:$e}=Ne,ze=Object.assign({$event:Ue},Jt);$e||o.triggerTaskBarTooltipEvent(Ue,ze),o.dispatchEvent("task-bar-mouseenter",ze,Ue)},Mt.onMouseleave=Ue=>{const{dragBarRow:$e}=Ne,ze=Object.assign({$event:Ue},Jt);$e||o.handleTaskBarTooltipLeaveEvent(Ue,ze),o.dispatchEvent("task-bar-mouseleave",ze,Ue)}),b&&ht&&be&&be.length)if(Qe)At&&$t.push((0,J.h)("div",{key:"vcso",class:"vxe-gantt-view--chart-subview-wrapper is--overview"},[(0,J.h)("div",{key:se,rowid:se,class:["vxe-gantt-view--chart-subview-row",{"is--progress":Xt,"is--round":Eo,"is--move":Po}]},[(0,J.h)("div",{rowid:se,class:[Je?"vxe-gantt-view--chart-subview-custom-bar":"vxe-gantt-view--chart-subview-bar",`is--${fo}`]},[Je?(0,J.h)("div",{key:"cbc",class:"vxe-gantt-view--chart-subview-custom-bar-content-wrapper"},o.callSlot(Je,de)):(0,J.h)("div",{class:"vxe-gantt-view--chart-subview-bar-content-wrapper"},[Tt?(0,J.h)("div",{class:"vxe-gantt-view--chart-content"},Ct):lo(o)])])])]));else{const Ue=[];ut.default.eachTree(be,$e=>{const ze={$gantt:o,source:cr,type:ur,scaleType:Co,row:$e,$rowIndex:A.getRowIndex($e),rowIndex:A.getVMRowIndex($e),_rowIndex:A.getVTRowIndex($e)},Et=ut.default.isFunction(To),eo=ut.default.assign({},(Ut?Wo?Ut(ze):Ut:{})||{},(To?Et?To(ze):To:{})||{}),go=eo.round,zo=eo.bgColor,ho=eo.completedBgColor,Ho=eo.style,to=A.getRowid($e);let Ro=ha(ut.default.get($e,co));const _o=Xt?Math.min(100,Math.max(0,ut.default.toNumber(ut.default.get($e,zt)))):0,oo=Wa(ut.default.get($e,Nt)),Zo=!!(oa(bt,Ht)&&ma(oo));if(!!(oa(Te,Fo)&&ba(oo)))return;const $o={},Dt={width:`${_o||0}%`};Zo||(zo&&($o["--vxe-ui-gantt-view-task-bar-background-color"]=zo),ho&&(Dt["--vxe-ui-gantt-view-task-bar-completed-background-color"]=ho)),eo.top&&($o.top=eo.top),Ho&&ut.default.assign($o,Ho);const r={...ze};jt&&(Ro=ha(jt({row:$e,title:Ro,scaleType:Co}))),Ue.push((0,J.h)("div",{key:to,rowid:to,class:["vxe-gantt-view--chart-subview-row",`is--${oo}`,{"is--progress":Xt,"is--critical":_t&&Bt&&io.has(to),"is--round":go,"is--move":Po,"row--pending":!!V&&!!re[to]}]},[(0,J.h)("div",{rowid:to,class:[mt?"vxe-gantt-view--chart-subview-custom-bar":"vxe-gantt-view--chart-subview-bar",`is--${oo}`],style:$o,onClick(l){l.stopPropagation(),o.handleTaskBarClickEvent(l,r)},onDblclick(l){l.stopPropagation(),o.handleTaskBarDblclickEvent(l,r)},onMousedown(l){l.stopPropagation(),o.handleTaskBarModnEvent&&o.handleTaskBarModnEvent(l,r)}},[mt?(0,J.h)("div",{key:"cbc",class:"vxe-gantt-view--chart-subview-custom-bar-content-wrapper",...Mt},o.callSlot(mt,r)):(0,J.h)("div",{class:"vxe-gantt-view--chart-subview-bar-content-wrapper",...Mt},[Xt?(0,J.h)("div",{class:"vxe-gantt-view--chart-progress",style:Dt}):lo(o),Tt?(0,J.h)("div",{class:"vxe-gantt-view--chart-content"},Ro):lo(o)])])]))},{children:Ie}),$t.push((0,J.h)("div",{key:"vcsc",class:"vxe-gantt-view--chart-subview-wrapper is--inline"},Ue))}else if(mt)$t.push((0,J.h)("div",{key:"cbc",class:"vxe-gantt-view--chart-custom-bar-content-wrapper",...Mt},o.callSlot(mt,de)));else if(Oo){const{icon:Ue,iconStatus:$e,iconStyle:ze}=Ht,Et={$gantt:o,row:te};$t.push((0,J.h)("div",{key:"vcm",class:"vxe-gantt-view--chart-milestone-wrapper",...Mt},[(0,J.h)("div",{class:["vxe-gantt-view--chart-milestone-icon",$e?`theme--${ut.default.isFunction($e)?$e(Et):$e}`:""],style:ze?Object.assign({},ut.default.isFunction(ze)?ze(Et):ze):void 0},[(0,J.h)("i",{class:(Ue?ut.default.isFunction(Ue)?Ue(Et):Ue:"")||tn().GANTT_VIEW_TASK_MILESTONE})]),Tt?(0,J.h)("div",{class:"vxe-gantt-view--chart-milestone-content"},Ct):lo(o)]))}else $t.push((0,J.h)("div",{key:"vbc",class:"vxe-gantt-view--chart-bar-content-wrapper",...Mt},[Xt?(0,J.h)("div",{class:"vxe-gantt-view--chart-progress",style:la}):lo(o),Tt?(0,J.h)("div",{class:"vxe-gantt-view--chart-content"},Ct):lo(o)]))}return(0,J.h)("div",{key:se,rowid:se,class:["vxe-gantt-view--chart-row",`is--${fo}`,{"is--progress":Xt,"is--critical":_t&&Bt&&io.has(se),"row--pending":!!V&&!!re[se],"is--round":Eo,"is--move":Po}],style:{height:`${Bo}px`},onDragstart(b){Ne.dragBarRow&&b.preventDefault()},onContextmenu(b){o.handleTaskBarContextmenuEvent(b,Jt)}},[(0,J.h)("div",{class:[mt?"vxe-gantt-view--chart-custom-bar":"vxe-gantt-view--chart-bar",`is--${fo}`,{"is--active":vt===se,"active--link":xe&&(se===`${xe.from}`||se===`${xe.to}`)}],style:po,rowid:se,onClick(b){o.handleTaskBarClickEvent(b,de)},onDblclick(b){o.handleTaskBarDblclickEvent(b,de)},onMousedown(b){o.handleTaskBarModnEvent&&o.handleTaskBarModnEvent(b,de)}},$t)])},Re=(A,te)=>{const se=A.props,{treeConfig:Ae}=se,Xe=A.reactData,{treeExpandedFlag:ft}=Xe,be=A.internalData,{fullAllDataRowIdData:Qe,treeExpandedMaps:pt}=be,{computeTreeOpts:gt}=A.getComputeMaps(),V=gt.value,{transform:M}=V,Ze=V.children||V.childrenField,{scrollYLoad:re}=N,he=[];return te.forEach((ke,rt)=>{const De=A.getRowid(ke),Ke=Qe[De]||{};let We=rt,nt=-1;Ke&&(We=Ke.index,nt=Ke._index);let st=!1,Ie=[];Ae&&(Ie=ke[Ze],st=!!ft&&Ie&&Ie.length>0&&!!pt[De]),he.push(Pe(A,ke,De,We,rt,nt,Ie,st)),Ae&&st&&!re&&!M&&he.push(...Re(A,Ie))}),he},dt=()=>{const A=Oe.xeTable,{slots:te}=me,{dragLinkFromStore:se}=ee,{tableData:Ae}=N,Xe=y.value,ft=It.value,be=Z.value,{isCurrent:Qe,isHover:pt}=Xe,{linkCreatable:gt}=ft,V=te.taskNowLine||te["task-now-line"];return(0,J.h)("div",{ref:ie,class:["vxe-gantt-view--chart-wrapper",{"is--cl-drag":se.rowid}]},[be>0?(0,J.h)("div",{ref:Fe,class:"vxe-gantt-view--chart-now-line",style:{left:be+"px"}},V?V({}):[]):lo(o),o.renderGanttTaskChartBefores?(0,J.h)("div",{ref:Ee,class:["vxe-gantt-view--chart-before-wrapper",{"link--current":Qe,"link--hover":pt}]},A&&ne(Xe)?o.renderGanttTaskChartBefores():[]):lo(o),(0,J.h)("div",{ref:at,class:["vxe-gantt-view--chart-task-wrapper",{"link--current":Qe,"link--create":gt}]},A?Re(A,Ae):[]),o.renderGanttTaskChartAfters?(0,J.h)("div",{ref:qe,class:"vxe-gantt-view--chart-after-wrapper"},A&&ne(Xe)?o.renderGanttTaskChartAfters():[]):lo(o)])};return(0,J.onMounted)(()=>{const{elemStore:A}=Oe,te="main-chart-";A[`${te}now-line`]=Fe,A[`${te}task-wrapper`]=at,A[`${te}before-wrapper`]=Ee,A[`${te}after-wrapper`]=qe}),(0,J.onUnmounted)(()=>{const{elemStore:A}=Oe,te="main-chart-";A[`${te}now-line`]=null,A[`${te}task-wrapper`]=null,A[`${te}before-wrapper`]=null,A[`${te}after-wrapper`]=null}),dt}}),xa="gantt",ya="body",an=Yo({name:"VxeGanttViewBody",setup(){const o=(0,Le.inject)("$xeGantt",{}),F=(0,Le.inject)("$xeGanttView",{}),{computeTaskViewOpts:W,computeScaleUnit:me}=o.getComputeMaps(),{reactData:ee,internalData:Ne}=F,N=(0,Le.ref)(),Oe=(0,Le.ref)(),Wt=(0,Le.ref)(),Yt=(0,Le.ref)(),St=(0,Le.ref)(),It=(P,ae,Z,ie,at,Ee,qe,Fe)=>{const Pe=P.reactData,{resizeHeightFlag:Re}=Pe,dt=P.internalData,{fullAllDataRowIdData:A,visibleColumn:te}=dt,{computeCellOpts:se,computeRowOpts:Ae,computeDefaultRowHeight:Xe,computeResizableOpts:ft}=P.getComputeMaps(),be=se.value,Qe=Ae.value,pt=Xe.value,gt=ft.value,{isAllRowDrag:V}=gt,{headerGroups:M}=ee,{todayDateMaps:Ze}=Ne,re=W.value,{showNowLine:he,viewStyle:ke}=re,rt=me.value,{scaleItem:De}=M[M.length-1]||{},{field:Ke,dateObj:We,startDateObj:nt,endDateObj:st}=qe,{cellClassName:Ie,cellStyle:Be}=ke||{},mt=he&&De?Ze[De.type]:null,Je=A[Z]||{},ht=Re?ar(Je,be,Qe,pt):0,bt=[];if(V&&Qe.resizable){const xe={$table:P,$grid:null,$gantt:o,seq:-1,rowid:Z,row:ae,rowIndex:ie,$rowIndex:at,_rowIndex:Ee,column:te[0],columnIndex:0,$columnIndex:0,_columnIndex:0,fixed:"",source:xa,type:ya,isHidden:!1,isEdit:!1,level:-1,visibleData:[],data:[],items:[]};bt.push((0,Le.h)("div",{class:"vxe-gantt-view-cell--row-resizable",onMousedown:vt=>P.handleRowResizeMousedownEvent(vt,xe),onDblclick:vt=>P.handleRowResizeDblclickEvent(vt,xe)}))}const Te={$gantt:o,source:xa,type:ya,scaleType:rt,dateObj:We,startDateObj:nt,endDateObj:st,row:ae,column:qe,$rowIndex:at,rowIndex:ie,_rowIndex:Ee};return(0,Le.h)("td",{key:Ie||Be?Ke:Fe,class:["vxe-gantt-view--body-column",{"is--now":he&&mt===Ke},Ka(Ie,Te)],style:Be?Object.assign({},ir.default.isFunction(Be)?Be(Te):Be,{height:`${ht}px`}):{height:`${ht}px`},onClick(xe){o.handleTaskCellClickEvent(xe,{row:ae,column:qe})},onDblclick(xe){o.handleTaskCellDblclickEvent(xe,{row:ae,column:qe})},onContextmenu(xe){o.handleTaskBodyContextmenuEvent(xe,Te)}},bt)},we=(P,ae)=>{const Z=P.props,{treeConfig:ie,stripe:at,highlightHoverRow:Ee,editConfig:qe}=Z,Fe=P.reactData,{treeExpandedFlag:Pe,selectRadioRow:Re,pendingRowFlag:dt,isRowGroupStatus:A}=Fe,te=P.internalData,{fullAllDataRowIdData:se,treeExpandedMaps:Ae,pendingRowMaps:Xe}=te,{computeRadioOpts:ft,computeCheckboxOpts:be,computeTreeOpts:Qe,computeRowOpts:pt}=P.getComputeMaps(),gt=ft.value,V=be.value,M=pt.value,Ze=Qe.value,{transform:re}=Ze,he=Ze.children||Ze.childrenField,ke=me.value,rt=W.value,{viewStyle:De}=rt,{rowClassName:Ke,rowStyle:We,cellClassName:nt,cellStyle:st}=De||{},{tableColumn:Ie,scrollYLoad:Be}=ee,mt=[];return ae.forEach((Je,ht)=>{const bt=P.getRowid(Je),Te=se[bt]||{},xe={};let vt=ht,Bt=-1;Te&&(vt=Te.index,Bt=Te._index);let io=!1;qe&&(io=P.isInsertByRow(Je)),(M.isHover||Ee)&&(xe.onMouseenter=uo=>{P.triggerHoverEvent(uo,{row:Je,rowIndex:vt})},xe.onMouseleave=()=>{P.clearHoverRow()}),M.drag&&!A&&(!ie||re)&&(xe.onDragstart=P.handleRowDragDragstartEvent,xe.onDragend=P.handleRowDragDragendEvent,xe.onDragover=P.handleRowDragDragoverEvent);const co={$gantt:o,source:xa,type:ya,scaleType:ke,row:Je,rowIndex:vt,$rowIndex:ht,_rowIndex:Bt};mt.push((0,Le.h)("tr",{key:Ke||We||nt||st?bt:ht,class:["vxe-gantt-view--body-row",{"row--stripe":at&&(Bt+1)%2===0,"is--new":io,"row--radio":gt.highlight&&P.eqRow(Re,Je),"row--checked":V.highlight&&P.isCheckedByCheckboxRow(Je),"row--pending":!!dt&&!!Xe[bt]},Ka(Ke,co)],rowid:bt,style:We?ir.default.isFunction(We)?We(co)||void 0:We:void 0,...xe},Ie.map((uo,Ht)=>It(P,Je,bt,vt,ht,Bt,uo,Ht))));let zt=!1,Nt=[];ie&&!Be&&!re&&(Nt=Je[he],zt=!!Pe&&Nt&&Nt.length>0&&!!Ae[bt]),zt&&mt.push(...we(P,Nt))}),mt},y=()=>{const P=F.internalData.xeTable,{tableData:ae,tableColumn:Z,viewCellWidth:ie}=ee;return(0,Le.h)("div",{ref:N,class:"vxe-gantt-view--body-wrapper"},[(0,Le.h)("div",{ref:Oe,class:"vxe-gantt-view--body-inner-wrapper",onScroll:F.triggerBodyScrollEvent,onContextmenu(at){o.handleTaskBodyContextmenuEvent(at,{source:xa,type:ya,rowIndex:-1,$rowIndex:-1,_rowIndex:-1})}},[(0,Le.h)("div",{ref:Yt,class:"vxe-body--x-space"}),(0,Le.h)("div",{ref:St,class:"vxe-body--y-space"}),(0,Le.h)("table",{ref:Wt,class:"vxe-gantt-view--body-table"},[(0,Le.h)("colgroup",{},Z.map((at,Ee)=>(0,Le.h)("col",{key:Ee,style:{width:`${ie}px`}}))),(0,Le.h)("tbody",{},P?we(P,ae):[])]),(0,Le.h)(on)])])};return(0,Le.onMounted)(()=>{const{elemStore:P}=Ne,ae="main-body-";P[`${ae}wrapper`]=N,P[`${ae}scroll`]=Oe,P[`${ae}table`]=Wt,P[`${ae}xSpace`]=Yt,P[`${ae}ySpace`]=St}),(0,Le.onUnmounted)(()=>{const{elemStore:P}=Ne,ae="main-body-";P[`${ae}wrapper`]=null,P[`${ae}scroll`]=null,P[`${ae}table`]=null,P[`${ae}xSpace`]=null,P[`${ae}ySpace`]=null}),y}}),ko=ge("vue"),rn="gantt",nn="footer",sn=Yo({name:"VxeGanttViewFooter",setup(){const o=(0,ko.inject)("$xeGantt",{}),F=(0,ko.inject)("$xeGanttView",{}),{internalData:W}=F,me=(0,ko.ref)(),ee=(0,ko.ref)(),Ne=()=>(0,ko.h)("div",{ref:me,class:"vxe-gantt-view--footer-wrapper",onContextmenu(N){o.handleTaskFooterContextmenuEvent(N,{source:rn,type:nn,$rowIndex:-1})}},[(0,ko.h)("div",{ref:ee,class:"vxe-gantt-view--footer-inner-wrapper"})]);return(0,ko.onMounted)(()=>{const{elemStore:N}=W,Oe="main-footer-";N[`${Oe}wrapper`]=me,N[`${Oe}scroll`]=ee}),(0,ko.onUnmounted)(()=>{const{elemStore:N}=W,Oe="main-footer-";N[`${Oe}wrapper`]=null,N[`${Oe}scroll`]=null}),Ne}}),{getConfig:ln,domUtils:cn,globalResize:un,globalEvents:dr,renderEmptyElement:fr}=sr.VxeUI,{FinishToStart:Ba,StartToFinish:za,StartToStart:Ha,FinishToFinish:_a}=wa,dn="gantt",pr=1e3,gr=1e3*60,ja=1e3*60*60,Zt=ja*24;function fn(o,F,W){return o+"_"+F+"_"+(W||0)}function hr(){return{xeTable:null,visibleColumn:[],startMaps:{},endMaps:{},chartMaps:{},todayDateMaps:{},elemStore:{},scrollXStore:{preloadSize:0,offsetSize:0,visibleSize:0,visibleStartIndex:0,visibleEndIndex:0,startIndex:0,endIndex:0},thumbDragOffset:0,yThumbTop:0,xThumbLeft:0,lastScrollTop:0,lastScrollLeft:0}}function vr(){return{scrollXLoad:!1,scrollYLoad:!1,overflowY:!0,overflowX:!0,scrollbarWidth:0,scrollbarHeight:0,lastScrollTime:0,lazScrollLoading:!1,yThumbHeight:0,xThumbWidth:0,scrollVMLoading:!1,scrollYHeight:0,scrollYTop:0,isScrollYBig:!1,scrollXLeft:0,scrollXWidth:0,isScrollXBig:!1,minViewDate:null,maxViewDate:null,tableData:[],tableColumn:[],headerGroups:[],viewCellWidth:40}}var Sa=5e6,pn=Yo({name:"VxeGanttView",setup(o,F){const W=i.default.uniqueId(),me=Object.assign({},ln().scrollbar),ee=(0,O.inject)("$xeGantt",{}),Ne=ee.props,N=ee.reactData,Oe=ee.internalData,{computeDateFormat:Wt,computeTaskBarOpts:Yt,computeTaskViewOpts:St,computeStartField:It,computeEndField:we,computeTypeField:y,computeScrollbarOpts:P,computeScaleUnit:ae,computeWeekScale:Z,computeMinScale:ie,computeTaskNowLineOpts:at,computeScaleStep:Ee,computeIsVScrollbar:qe}=ee.getComputeMaps(),Fe=(0,O.ref)(),Pe=(0,O.ref)(),Re=(0,O.ref)(),dt=(0,O.ref)(),A=(0,O.ref)(),te=(0,O.ref)(),se=(0,O.ref)(),Ae=(0,O.ref)(),Xe=(0,O.ref)(),ft=(0,O.ref)(),be=(0,O.ref)(),Qe=(0,O.ref)(),pt=(0,O.ref)(),gt=(0,O.ref)(),V=(0,O.reactive)(vr()),M=hr(),Ze={refElem:Fe,refScrollXHandleElem:dt,refScrollYHandleElem:se},re=(0,O.computed)(()=>qe.value),he=(0,O.computed)(()=>{const r=P.value;return r.x?Object.assign({},r.x,r.xConfig):r.xConfig||{}}),ke=(0,O.computed)(()=>{const r=P.value;return r.y?Object.assign({},r.y,r.yConfig):r.yConfig||{}}),rt=(0,O.computed)(()=>{const r=P.value,l=he.value;return i.default.toNumber(ot(ot(l.height,r.height),me.height))}),De=(0,O.computed)(()=>{const r=P.value,l=ke.value;return i.default.toNumber(ot(ot(l.width,r.width),me.width))}),Ke=(0,O.computed)(()=>{const r=P.value,l=he.value;return ot(l.visible,r.visible)}),We=(0,O.computed)(()=>{const r=P.value,l=ke.value;return ot(l.visible,r.visible)}),nt=(0,O.computed)(()=>{const r=P.value,l=he.value;return ot(ot(l.autoHide,r.autoHide),me.autoHide)}),st=(0,O.computed)(()=>{const r=P.value,l=ke.value;return ot(ot(l.autoHide,r.autoHide),me.autoHide)}),Ie=(0,O.computed)(()=>he.value.position==="top"),Be=(0,O.computed)(()=>ke.value.position==="left"),mt=(0,O.computed)(()=>{const{yThumbHeight:r,xThumbWidth:l}=V,s=P.value,v=Ie.value,S=Be.value,h=Ke.value,d=We.value;return cn.buildClass(["vxe-scrollbar is--virtual",s.fluentOverlay?"is--fluent-overlay":"is--default-mode",`ov-x--${h===!1?"hidden":"visible"}`,`ov-y--${d===!1?"hidden":"visible"}`,`sx-pos--${v?"top":"bottom"}`,`sy-pos--${S?"left":"right"}`],{"overflow-y":r,"overflow-x":l})}),Je=(0,O.computed)(()=>{const{minViewDate:r,maxViewDate:l}=V,s=St.value,v=ie.value,S=Ee.value,{gridding:h}=s,d=[];if(!v||!r||!l)return d;const{type:k,startDay:C}=v;let f=-(N.currLeftSpacing+i.default.toNumber(h&&h.leftSpacing||0)),w=N.currRightSpacing+i.default.toNumber(h&&h.rightSpacing||0);switch(S>0&&(f*=S,w*=S),k){case"year":{let u=i.default.getWhatYear(r,f,"first");const g=i.default.getWhatYear(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatYear(u,S)}break}case"quarter":{let u=i.default.getWhatQuarter(r,f,"first");const g=i.default.getWhatQuarter(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatQuarter(u,S)}break}case"month":{let u=i.default.getWhatMonth(r,f,"first");const g=i.default.getWhatMonth(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatMonth(u,S)}break}case"week":{let u=i.default.getWhatWeek(r,f,C,C);const g=i.default.getWhatWeek(l,w,C,C);for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatWeek(u,S)}break}case"day":case"date":{let u=i.default.getWhatDay(r,f,"first");const g=i.default.getWhatDay(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatDay(u,S)}break}case"hour":{let u=i.default.getWhatHours(r,f,"first");const g=i.default.getWhatHours(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatHours(u,S)}break}case"minute":{let u=i.default.getWhatMinutes(r,f,"first");const g=i.default.getWhatMinutes(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatMinutes(u,S)}break}case"second":{let u=i.default.getWhatSeconds(r,f,"first");const g=i.default.getWhatSeconds(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatSeconds(u,S)}break}}return d}),ht=(0,O.computed)(()=>{const{minViewDate:r,maxViewDate:l,viewCellWidth:s}=V,{visibleColumn:v,todayDateMaps:S}=M,h=ie.value,d=St.value,k=at.value,{showNowLine:C}=d,{mode:f}=k,{nowTime:w}=N;let u=0;if(C&&h&&r&&l&&w>=r.getTime()&&w<=l.getTime()){const g=S[h.type],c=i.default.toStringDate(g);let D=null,$=null;for(let R=0;R<v.length;R++){const x=v[R],{startDateObj:T,endDateObj:L}=x;if(T.date<=c&&L.date>=c){D=x,u=R*s,$=v[R+1];break}}if(f==="progress"){if(D&&$){const R=D.dateObj.date.getTime(),x=w-R,T=Math.max(0,Math.min(1,x/($.dateObj.date.getTime()-R)));u+=T*s}}else f==="center"?u+=s/2:f==="end"&&(u+=s-1)}return u}),bt={computeScrollXHeight:rt,computeScrollYWidth:De,computeScrollXVisible:Ke,computeScrollYVisible:We,computeScrollXAutoHide:nt,computeScrollYAutoHide:st,computeScrollbarXToTop:Ie,computeScrollbarYToLeft:Be,computeScaleDateList:Je,computeNowLineLeft:ht},Te={xID:W,props:o,context:F,reactData:V,internalData:M,getRefMaps:()=>Ze,getComputeMaps:()=>bt},{refTrackXElem:xe,refTrackYElem:vt,refThumbXElem:Bt,refThumbYElem:io,updateThumbSize:co,updateThumbOffset:zt,clickTrackXEvent:Nt,clickTrackYEvent:uo,pointerdownThumbXEvent:Ht,pointermoveThumbXEvent:Fo,cleatPointerThumbEvent:At,pointerdownThumbYEvent:To,pointermoveThumbYEvent:Co}=sr.useFns.useInitVScrollbar(Te),de=r=>{const l=Wt.value;return i.default.toStringDate(r,l)},Xt=()=>{const{taskScaleList:r}=N,l=ie.value;if(l){const s=r.find(R=>R.type==="week"),v=l.type==="week",S=new Date;let[h,d,k,C,f,w,u]=i.default.toDateString(S,"yyyy-M-MM-dd-HH-mm-ss").split("-");const c=S.getDay()+1,D=Math.ceil((S.getMonth()+1)/3),$=`${i.default.getYearWeek(S,s?s.startDay:void 0)}`;v&&Tt($,d)&&(h=`${Number(h)+1}`,d="1",k="0"+d),N.nowTime=S.getTime(),M.todayDateMaps={year:h,quarter:`${h}_q${D}`,month:`${h}_${k}`,week:`${h}_W${$}`,day:`${h}_${k}_${C}_E${c}`,date:`${h}_${k}_${C}`,hour:`${h}_${k}_${C}_${f}`,minute:`${h}_${k}_${C}_${f}_${w}`,second:`${h}_${k}_${C}_${f}_${w}_${u}`}}},_t=()=>{const{taskScaleList:r}=N,l=ae.value,s=ie.value,v=Z.value,S=Je.value,h=Ee.value,d=v?v.startDay:void 0,k=[],C=[];if(s&&l&&S.length){const f={year:[],quarter:[],month:[],week:[],day:[],date:[],hour:[],minute:[],second:[]},w={year:{},quarter:{},month:{},week:{},day:{},date:{},hour:{},minute:{},second:{}},u=s.type==="week",g=(D,$,R)=>{if(s.type===D)return;const x=$[D],T=`${x.field}`;let L=w[D][T];L||(L=x,w[D][T]=L,f[D].push(L)),L&&(L.children||(L.children=[]),L.children.push(R))},c=D=>{let[$,R,x,T,L,I,z,Y,fe,ce,ue,X]=i.default.toDateString(D,"yy-yyyy-M-MM-d-dd-H-HH-m-mm-s-ss").split("-");const q=D.getDay(),ye=q+1,Vt=Math.ceil((D.getMonth()+1)/3),lt=`${i.default.getYearWeek(D,v?v.startDay:void 0)}`,Ot=i.default.padStart(lt,2,"0");return u&&Tt(lt,x)&&(R=`${Number(R)+1}`,x="1",T="0"+x),{date:D,yy:$,yyyy:R,M:x,MM:T,d:L,dd:I,H:z,HH:Y,m:fe,mm:ce,s:ue,ss:X,q:Vt,W:lt,WW:Ot,E:ye,e:q}};for(let D=0;D<S.length;D++){const $=S[D],R=c($),{yyyy:x,MM:T,dd:L,HH:I,mm:z,ss:Y,q:fe,W:ce,E:ue}=R,X=R,q={year:{field:x,title:x,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatYear($,h-1)):X},quarter:{field:`${x}_q${fe}`,title:`${fe}`,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatQuarter($,h-1)):X},month:{field:`${x}_${T}`,title:T,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatMonth($,h-1)):X},week:{field:`${x}_W${ce}`,title:`${ce}`,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatWeek($,h-1,d,d)):X},day:{field:`${x}_${T}_${L}_E${ue}`,title:`${ue}`,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatDay($,h-1)):X},date:{field:`${x}_${T}_${L}`,title:L,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatDay($,h-1)):X},hour:{field:`${x}_${T}_${L}_${I}`,title:I,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatHours($,h-1)):X},minute:{field:`${x}_${T}_${L}_${I}_${z}`,title:z,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatMinutes($,h-1)):X},second:{field:`${x}_${T}_${L}_${I}_${z}_${Y}`,title:Y,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatSeconds($,h-1)):X}},ye=q[s.type];s.level<19&&g("year",q,ye),s.level<17&&g("quarter",q,ye),s.level<15&&g("month",q,ye),s.level<13&&g("week",q,ye),s.level<11&&g("day",q,ye),s.level<9&&g("date",q,ye),s.level<7&&g("hour",q,ye),s.level<5&&g("minute",q,ye),s.level<3&&g("second",q,ye),k.push(ye)}r.forEach(D=>{if(D.type===s.type){C.push({scaleItem:D,columns:k});return}const $=f[D.type]||[];$&&$.forEach(R=>{R.childCount=R.children?R.children.length:0,R.children=void 0}),C.push({scaleItem:D,columns:$})})}return{fullCols:k,groupCols:C}},Tt=(r,l)=>`${r}`=="1"&&`${l}`=="12",jt=(r,l)=>{const s=i.default.toStringDate(r);let v=s.getFullYear();const S=s.getMonth(),h=i.default.getYearWeek(s,l);return Tt(h,S+1)&&v++,{yyyy:v,W:h}},Ut=r=>{const l=ie.value,s=Ee.value,v=ae.value,S=Z.value,h=Wt.value;if(l){const d=s>1?1/s:0;switch(v){case"year":{const k=/M|d|H|m|s|S/.test(h),C="yyyy",f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,"yyyy");if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatYear(w.date,s-c),C);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,C),$=k?g:i.default.getWhatYear(g,0,"first"),R=i.default.getWhatYear(g,0,"first"),x=i.default.toDateString(c,C),T=k?c:i.default.getWhatYear(c,0,"last"),L=i.default.getWhatYear(T,0,"first");let I=0,z=1;if(k){const fe=i.default.getDayOfYear($,0);I=($.getTime()-R.getTime())/Zt/fe;const ce=i.default.getDayOfYear(T,0);z=(T.getTime()-L.getTime())/Zt/ce,d&&(I*=d,z*=d)}const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"quarter":{const k=/M|d|H|m|ss|S/.test(h),C="yyyy-q",f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,C);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatQuarter(w.date,s-c),C);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,C),$=k?g:i.default.getWhatQuarter(g,0,"first"),R=i.default.getWhatQuarter(g,0,"first"),x=i.default.toDateString(c,C),T=k?c:i.default.getWhatQuarter(c,0,"last"),L=i.default.getWhatQuarter(T,0,"first");let I=0,z=1;if(k){const fe=i.default.getDayOfQuarter($,0);I=($.getTime()-R.getTime())/Zt/fe;const ce=i.default.getDayOfQuarter(T,0);z=(T.getTime()-L.getTime())/Zt/ce,d&&(I*=d,z*=d)}const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"month":{const k="yyyy-MM",C=/d|H|m|ss|S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,k);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatMonth(w.date,s-c),k);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,k),$=C?g:i.default.getWhatMonth(g,0,"first"),R=i.default.getWhatMonth(g,0,"first"),x=i.default.toDateString(c,k),T=C?c:i.default.getWhatMonth(c,0,"last"),L=i.default.getWhatMonth(T,0,"first");let I=0,z=1;if(C){const fe=i.default.getDayOfMonth($,0);I=($.getTime()-R.getTime())/Zt/fe;const ce=i.default.getDayOfMonth(T,0);z=(T.getTime()-L.getTime())/Zt/ce,d&&(I*=d,z*=d)}const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"week":{const k=S?S.startDay:void 0,C=/d|H|m|s|S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=`${w.yyyy}-${w.W}`;if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.getWhatWeek(w.date,s-c,k,k);let[$,R]=i.default.toDateString(D,"yyyy-M-MM-dd-HH-mm-ss").split("-");const x=`${i.default.getYearWeek(D,S?S.startDay:void 0)}`;Tt(x,R)&&($=`${Number($)+1}`);const T=`${$}-${x}`;f[T]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=C?g:i.default.getWhatWeek(g,0,"first",k),$=jt(D,k),R=`${$.yyyy}-${$.W}`,x=i.default.getWhatWeek(D,0,"first",k),T=C?c:i.default.getWhatWeek(c,0,"first",k),L=jt(T,k),I=`${L.yyyy}-${L.W}`,z=i.default.getWhatWeek(T,0,"first",k);let Y=0,fe=1;C&&(Y=(D.getTime()-x.getTime())/Zt/7,fe=(T.getTime()-z.getTime())/Zt/7,d&&(Y*=d,fe*=d));const ce=(f[R]||0)+Y;return{offsetLeftSize:ce,offsetWidthSize:(f[I]||0)-ce+fe}}}case"day":case"date":{const k="yyyy-MM-dd",C=/H|m|s|S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,k);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatDay(w.date,s-c),k);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,k),$=C?g:i.default.getWhatDay(g,0,"first"),R=i.default.getWhatDay($,0,"first"),x=i.default.toDateString(c,k),T=C?c:i.default.getWhatDay(c,0,"last"),L=i.default.getWhatDay(T,0,"first");let I=0,z=1;C&&(I=($.getTime()-R.getTime())/Zt,z=(T.getTime()-L.getTime())/Zt,d&&(I*=d,z*=d));const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"hour":{const k="yyyy-MM-dd HH",C=/m|s|S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,k);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatHours(w.date,s-c),k);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,k),$=C?g:i.default.getWhatHours(g,0,"first"),R=i.default.getWhatHours($,0,"first"),x=i.default.toDateString(c,k),T=C?c:i.default.getWhatHours(c,0,"last"),L=i.default.getWhatHours(T,0,"first");let I=0,z=1;C&&(I=($.getTime()-R.getTime())/ja,z=(T.getTime()-L.getTime())/ja,d&&(I*=d,z*=d));const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"minute":{const k="yyyy-MM-dd HH:mm",C=/s|S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,k);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatMinutes(w.date,s-c),k);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,k),$=C?g:i.default.getWhatMinutes(g,0,"first"),R=i.default.getWhatMinutes($,0,"first"),x=i.default.toDateString(c,k),T=C?c:i.default.getWhatMinutes(c,0,"last"),L=i.default.getWhatMinutes(T,0,"first");let I=0,z=1;C&&(I=($.getTime()-R.getTime())/gr,z=(T.getTime()-L.getTime())/gr,d&&(I*=d,z*=d));const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"second":{const k="yyyy-MM-dd HH:mm:ss",C=/S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,k);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatSeconds(w.date,s-c),k);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,k),$=C?g:i.default.getWhatSeconds(g,0,"first"),R=i.default.getWhatSeconds($,0,"first"),x=i.default.toDateString(c,k),T=C?c:i.default.getWhatSeconds(c,0,"last"),L=i.default.getWhatSeconds(T,0,"first");let I=0,z=1;C&&(I=($.getTime()-R.getTime())/pr,z=(T.getTime()-L.getTime())/pr,d&&(I*=d,z*=d));const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}}}return()=>({offsetLeftSize:0,offsetWidthSize:0})},Po=()=>{const r=ee.props,{treeConfig:l}=r,{minViewDate:s,maxViewDate:v}=V,{fullCols:S,groupCols:h}=_t();if(s&&v&&S.length){const d=M.xeTable;if(d){const k=It.value,C=we.value,f=y.value,{computeAggregateOpts:w,computeTreeOpts:u}=d.getComputeMaps(),g=d.reactData,{isRowGroupStatus:c}=g,D=d.internalData,{afterFullData:$,afterTreeFullData:R,afterGroupFullData:x}=D,T=w.value,L=u.value,{transform:I}=L,z=L.children||L.childrenField,Y={},fe=Ut(S),ce=ue=>{const X=d.getRowid(ue);let q=i.default.get(ue,k),ye=i.default.get(ue,C);const Vt=Wa(i.default.get(ue,f)),lt=ma(Vt),Ot=ba(Vt);if(lt&&(q||(q=ye),ye=q),Ot)Y[X]={row:ue,rowid:X,oLeftSize:0,oWidthSize:0};else if(q&&ye){const{offsetLeftSize:e,offsetWidthSize:t}=fe(q,ye);Y[X]={row:ue,rowid:X,oLeftSize:e,oWidthSize:t}}};if(c){const ue=T.mapChildrenField;ue&&i.default.eachTree(x,ce,{children:ue})}else l?i.default.eachTree(R,ce,{children:I?L.mapChildrenField:z}):$.forEach(ce);M.chartMaps=Y}}M.visibleColumn=S,V.headerGroups=h,Xt(),la(),$t()},Go=()=>{const{linkList:r}=N,{treeConfig:l}=Ne,{scrollXStore:s}=M,v=M.xeTable,S={},h={};let d=null,k=null;const C=[];if(v){const f=It.value,w=we.value,u=y.value,{computeAggregateOpts:g,computeTreeOpts:c}=v.getComputeMaps(),D=v.reactData,{isRowGroupStatus:$}=D,R=v.internalData,{afterFullData:x,afterTreeFullData:T,afterGroupFullData:L}=R,I=g.value,z=c.value,{transform:Y}=z,fe=z.children||z.childrenField,ce=ue=>{let X=i.default.get(ue,f),q=i.default.get(ue,w);const ye=i.default.get(ue,u),Vt=ma(ye);if(X||(X=q),(Vt||!q)&&(q=X),X){const lt=de(X);(!d||d.getTime()>lt.getTime())&&(d=lt)}if(q){const lt=de(q);(!k||k.getTime()<lt.getTime())&&(k=lt)}C.push(ue)};if($){const ue=I.mapChildrenField;ue&&i.default.eachTree(L,ce,{children:ue})}else l?i.default.eachTree(T,ce,{children:Y?z.mapChildrenField:fe}):x.forEach(ce)}s.startIndex=0,s.endIndex=Math.max(1,s.visibleSize),V.minViewDate=d,V.maxViewDate=k,M.startMaps=S,M.endMaps=h,Po(),qo(C,r)};function Wo(r,l,s,v){switch(r){case Ba:return s;case za:return l-v;case Ha:return l;case _a:return s-v;default:return 0}}function Kt(r,l,s,v){switch(r){case Ba:return l;case za:return s+v;case Ha:return l+v;case _a:return s;default:return-1}}function Eo(r,l,s,v,S,h){switch(r){case Ba:return Math.abs(s-v)<h;case za:return Math.abs(l-S)<h;case Ha:return Math.abs(l-v)<h;case _a:return Math.abs(s-S)<h;default:return!1}}function qo(r,l){const s=Yt.value,v=M.xeTable,S=[],h=new Map,d=new Map;if(Oe.criticalRowList=S,Oe.criticalRowMaps=h,Oe.criticalLinkKeyMaps=d,!s.showCriticalPath||!l.length||!r.length||!v){(N.criticalRowIds.length||N.criticalLinks.length)&&N.criticalPathFlag++,N.criticalLinks=[],N.criticalRowIds=[];return}const{chartMaps:k}=M,C=1e-6,f=new Map;for(const x of r){const T=v.getRowid(x),L=k[T];f.set(T,{row:x,rowid:T,duration:L?L.oWidthSize:0,incoming:[],outgoing:[],indeg:0,ES:0,EF:0,LS:0,LF:0})}const w=[];for(const x of l){const T=""+x.from,L=""+x.to;if(!f.has(T)||!f.has(L)||T===L)continue;const I={from:x.from,to:x.to,type:i.default.toNumber(x.type)||0,raw:x};w.push(I);const z=f.get(""+x.to),Y=f.get(""+x.from);Y&&Y.outgoing.push(I),z&&(z.incoming.push(I),z.indeg++)}const u=[];f.forEach(x=>{x.indeg===0&&u.push(x)});const g=[];for(let x=0;x<u.length;x++){const T=u[x];g.push(T);for(const L of T.outgoing){const I=f.get(""+L.to);if(I){const z=I.indeg-1;I.indeg=z,z===0&&u.push(f.get(""+L.to))}}}if(g.length!==f.size){(N.criticalRowIds.length||N.criticalLinks.length)&&N.criticalPathFlag++,N.criticalLinks=[],N.criticalRowIds=[];return}let c=0;for(const x of g){let T=0;for(const L of x.incoming){const I=f.get(""+L.from);if(I){const z=Wo(L.type,I.ES,I.EF,x.duration);z>T&&(T=z)}}x.ES=T,x.EF=T+x.duration,x.EF>c&&(c=x.EF)}for(let x=g.length-1;x>=0;x--){const T=g[x];let L=c;for(const I of T.outgoing){const z=f.get(""+I.to);if(z){const Y=Kt(I.type,z.LS,z.LF,T.duration);Y<L&&(L=Y)}}T.LF=L,T.LS=L-T.duration}const D=new Set,$=[];for(const x of g)Math.abs(x.LS-x.ES)<C&&(D.add(x.rowid),$.push(x.rowid),S.push(x.row),h.set(x.rowid,x.row));const R=[];for(const x of w){const T=f.get(""+x.to),L=f.get(""+x.from);!T||!L||!D.has(L.rowid)||!D.has(T.rowid)||Eo(x.type,L.ES,L.EF,T.ES,T.EF,C)&&(R.push(x.raw),d.set(fn(x.from,x.to,x.type),x.raw))}N.criticalLinks=R,N.criticalRowIds=$,N.criticalPathFlag++}const Do=()=>{const{scrollXWidth:r,scrollYHeight:l}=V,{elemStore:s}=M,v=P.value,S=le(s["main-body-wrapper"]),h=dt.value,d=se.value;let k=!1,C=!1;if(S){if(k=l>S.clientHeight,d){const f=v.width||d.offsetWidth-d.clientWidth||14;V.scrollbarWidth=f,N.scrollbarWidth=f}if(V.overflowY=k,N.overflowY=k,C=r>S.clientWidth,h){const f=v.height||h.offsetHeight-h.clientHeight||14;V.scrollbarHeight=f,N.scrollbarHeight=f}V.overflowX=C,N.overflowX=C}},Io=(r,l)=>{const{chartMaps:s}=M,{computeTreeOpts:v}=r.getComputeMaps(),S=v.value,h=S.children||S.childrenField,d=y.value;let k=0,C=0;return i.default.eachTree(l,f=>{const w=r.getRowid(f),u=i.default.get(f,d);if(ba(u))return;const g=w?s[w]:null;g&&(C=Math.max(C,g.oLeftSize+g.oWidthSize),k=k?Math.min(k,g.oLeftSize):g.oLeftSize)},{children:h}),{minSize:k,maxSize:C}},sa=()=>{const{dragBarRow:r}=Oe,{viewCellWidth:l}=V,{elemStore:s,chartMaps:v}=M,S=M.xeTable,h=le(s["main-chart-task-wrapper"]);if(h&&S){const{computeTreeOpts:d}=S.getComputeMaps(),k=d.value,C=k.children||k.childrenField;i.default.arrayEach(h.children,f=>{const w=f.children[0];if(!w)return;const u=f.getAttribute("rowid");if(r&&S.getRowid(r)===u)return;const g=u?v[u]:null,c=g?g.row:null;if(So(w,"is--subview")){const D=w.firstElementChild;if(D)if(So(D,"is--inline"))i.default.arrayEach(D.children,$=>{const R=$.children[0],x=R.getAttribute("rowid")||"",T=x?v[x]:null;if(T){const L=T.row;if(So(R,"is--subview")){const I=L[C],{minSize:z,maxSize:Y}=Io(S,I);R.style.left=`${l*z}px`,R.style.width=`${l*(Y-z)}px`}else R.style.left=`${rr(T,l)}px`,So(R,"is--milestone")||(R.style.width=`${nr(T,l)}px`)}});else{const $=D.children[0],R=$?$.children[0]:null;if(R){const x=c?c[C]:[],{minSize:T,maxSize:L}=Io(S,x);R.style.left=`${l*T}px`,R.style.width=`${l*(L-T)}px`}}}else w.style.left=`${rr(g,l)}px`,So(w,"is--milestone")||(w.style.width=`${nr(g,l)}px`)})}return(0,O.nextTick)()},Bo=()=>{const{showLeftView:r}=N,{scrollbarWidth:l,scrollbarHeight:s,headerGroups:v,tableColumn:S}=V,{elemStore:h,visibleColumn:d}=M,k=M.xeTable,C=Fe.value;if(!C||!ee)return;const f=We.value,w=Ie.value,u=Be.value,g=A.value,c=te.value,D=Pe.value;let $=l;const R=s;let x=0,T=0,L=0;if(k){const m=k.internalData;x=m.tBodyHeight,T=m.tHeaderHeight,L=m.tFooterHeight}let I="visible";(f===!1||f==="hidden"||u&&r)&&($=0,I="hidden");const Y=le(h["main-header-scroll"]);Y&&(Y.style.height=`${T}px`,Y.style.setProperty("--vxe-ui-gantt-view-cell-height",`${T/v.length}px`));const fe=le(h["main-body-scroll"]);fe&&(fe.style.height=`${x}px`);const ce=le(h["main-footer-scroll"]);ce&&(ce.style.height=`${L}px`),D&&(D.style.height=`${R}px`,D.style.visibility="visible");const ue=Xe.value;ue&&(ue.style.left=w?`${$}px`:"",ue.style.width=`${C.clientWidth-$}px`),g&&(g.style.width=w?`${$}px`:"",g.style.display=w&&R?"block":""),c&&(c.style.width=w?"":`${$}px`,c.style.display=w?"":R?"block":"");const X=Re.value;X&&(X.style.width=`${$}px`,X.style.height=`${x+T+L}px`,X.style.visibility=I);const q=Ae.value;q&&(q.style.height=`${T}px`,q.style.display=T?"block":"");const ye=ft.value;ye&&(ye.style.height=`${x}px`,ye.style.top=`${T}px`);const Vt=be.value;Vt&&(Vt.style.height=`${L}px`,Vt.style.top=`${T+x}px`,Vt.style.display=L?"block":"");const lt=gt.value;let Ot=40;lt&&(Ot=lt.clientWidth||40);let e=Ot;if(d.length&&(e=Math.max(0,Ot*d.length),fe)){const m=fe.clientWidth,E=m-e;E>0&&(Ot+=Math.max(0,E/d.length),e=m)}V.viewCellWidth=Ot;const t=le(h["main-header-table"]),a=le(h["main-body-table"]),p=Ot*S.length;return t&&(t.style.width=`${e}px`),a&&(a.style.width=`${p}px`),V.scrollXWidth=e,Promise.all([sa(),ee.handleUpTaskLinkStyle?ee.handleUpTaskLinkStyle(Te):null])},Ct=()=>{const r=Fe.value;return M.rceRunTime=Date.now(),!r||!r.clientWidth||!ee?(0,O.nextTick)():(Do(),Bo(),fo())},Qo=()=>new Promise(r=>{const{rceTimeout:l,rceRunTime:s}=M,v=M.xeTable;let S=30;if(v){const{computeResizeOpts:h}=v.getComputeMaps();S=h.value.refreshDelay||S}ho(),l?(clearTimeout(l),s&&s+(S-5)<Date.now()?r(Ct()):(0,O.nextTick)(()=>{r()})):r(Ct()),M.rceTimeout=setTimeout(()=>{M.rceTimeout=void 0,Ct()},S)}),fo=()=>(0,O.nextTick)().then(()=>{const{scrollXLoad:r}=V,{scrollXStore:l}=M;if(r){const{toVisibleIndex:s,visibleSize:v}=Oo(),S=2;l.preloadSize=1,l.offsetSize=S,l.visibleSize=v,l.endIndex=Math.max(l.startIndex+l.visibleSize+S,l.endIndex),l.visibleStartIndex=Math.max(l.startIndex,s),l.visibleEndIndex=Math.min(l.endIndex,s+v),po().then(()=>{Jt()})}else b()}),Oo=()=>{const{viewCellWidth:r}=V,{elemStore:l}=M,s=le(l["main-body-scroll"]);if(s){const v=s.clientWidth,S=s.scrollLeft,h=Math.floor(S/r)-1,d=Math.ceil(v/r)+1;return{toVisibleIndex:Math.max(0,h),visibleSize:Math.max(1,d)}}return{toVisibleIndex:0,visibleSize:6}},Jt=()=>{const{isScrollXBig:r}=V,{scrollXStore:l}=M,{preloadSize:s,startIndex:v,endIndex:S,offsetSize:h}=l,{toVisibleIndex:d,visibleSize:k}=Oo(),C={startIndex:Math.max(0,r?d-1:d-1-h-s),endIndex:r?d+k:d+k+h+s};l.visibleStartIndex=d-1,l.visibleEndIndex=d+k+1;const{startIndex:f,endIndex:w}=C;(d<=v||d>=S-k-1)&&(v!==f||S!==w)&&(l.startIndex=f,l.endIndex=w,po())},po=()=>($t(),b(),(0,O.nextTick)()),la=()=>(V.scrollXLoad=!0,!0),$t=()=>{const{scrollXLoad:r}=V,{visibleColumn:l,scrollXStore:s}=M,v=r?l.slice(s.startIndex,s.endIndex):l.slice(0);V.tableColumn=v},b=()=>{const{scrollXLoad:r,scrollXWidth:l,viewCellWidth:s}=V,{elemStore:v,scrollXStore:S}=M,h=le(v["main-body-table"]),{startIndex:d}=S;let k=0;r&&(k=Math.max(0,d*s)),h&&(h.style.transform=`translate(${k}px, ${V.scrollYTop||0}px)`);const C=l;["header","body","footer"].forEach($=>{const R=le(v[`main-${$}-xSpace`]);R&&(R.style.width=r?`${C}px`:"")});const w=Qe.value;w&&(w.style.width=`${C}px`);const u=le(v["main-chart-before-wrapper"]),g=u?u.firstElementChild:null;g&&(g.style.width=`${C}px`);const c=le(v["main-chart-after-wrapper"]),D=c?c.firstElementChild:null;return D&&(D.style.width=`${C}px`),V.scrollXLeft=k,V.scrollXWidth=C,Do(),(0,O.nextTick)()},Mt=()=>{Jt()},Ue=()=>{const{scrollYLoad:r,overflowY:l}=V,{elemStore:s}=M,v=M.xeTable,S=le(s["main-body-scroll"]),h=le(s["main-body-table"]);let d=0,k=0,C=!1;if(v){const I=v.reactData;d=I.scrollYTop,k=I.scrollYHeight,C=I.isScrollYBig}let f=k,w=d,u=0;S&&(u=S.clientHeight),C&&(S&&h&&S.scrollTop+u>=Sa?w=Sa-h.clientHeight:w=(Sa-u)*(d/(k-u)),f=Sa),r&&l||(w=0);const g=le(s["main-chart-task-wrapper"]);h&&(h.style.transform=`translate(${V.scrollXLeft||0}px, ${w}px)`),g&&(g.style.transform=`translateY(${w}px)`);const c=le(s["main-body-ySpace"]);c&&(c.style.height=f?`${f}px`:"");const D=pt.value;D&&(D.style.height=f?`${f}px`:"");const $=le(s["main-chart-before-wrapper"]),R=$?$.firstElementChild:null;R&&(R.style.height=f?`${f}px`:"");const x=le(s["main-chart-after-wrapper"]),T=x?x.firstElementChild:null;T&&(T.style.height=f?`${f}px`:"");const L=le(s["main-chart-now-line"]);return L&&(L.style.height=f?`${f}px`:""),V.scrollYTop=w,V.scrollYHeight=k,V.isScrollYBig=C,Do(),(0,O.nextTick)().then(()=>{Bo()})},$e=(r,l)=>{const{lcsTimeout:s}=M;V.lazScrollLoading=!0,s&&clearTimeout(s),M.lcsTimeout=setTimeout(()=>{const v=M.xeTable;if(M.lcsRunTime=Date.now(),M.lcsTimeout=void 0,M.intoRunScroll=!1,M.inVirtualScroll=!1,M.inWheelScroll=!1,M.inHeaderScroll=!1,M.inBodyScroll=!1,M.inFooterScroll=!1,V.lazScrollLoading=!1,v){const S=v.internalData;S.isSyncGanttScrollTop=!1}},200)},ze=(r,l,s,v)=>{l&&(M.lastScrollLeft=v),r&&(M.lastScrollTop=s),V.lastScrollTime=Date.now(),$e(l,r)},Et=(r,l,s,v,S)=>{const h=M.xeTable,{elemStore:d,lastScrollLeft:k,lastScrollTop:C}=M,f=le(d["main-body-scroll"]);if(!f||!h)return;const{computeScrollXThreshold:w,computeScrollYThreshold:u}=h.getComputeMaps(),g=f.clientHeight,c=f.clientWidth,D=f.scrollHeight,$=f.scrollWidth;let R=!1,x=!1,T=!1,L=!1,I="",z=!1,Y=!1,fe=!1,ce=!1;if(s){const q=w.value;T=S<=0,T||(L=S+c>=$-1),S>k?(I="right",S+c>=$-q&&(ce=!0)):(I="left",S<=q&&(fe=!0))}if(l){const q=u.value;R=v<=0,R||(x=v+g>=D-1),v>C?(I="bottom",v+g>=D-q&&(Y=!0)):(I="top",v<=q&&(z=!0))}re.value&&zt(),ze(l,s,v,S);const X={source:dn,scrollTop:v,scrollLeft:S,bodyHeight:g,bodyWidth:c,scrollHeight:D,scrollWidth:$,isX:s,isY:l,isTop:R,isBottom:x,isLeft:T,isRight:L,direction:I};(Y||z||ce||fe)&&ee.dispatchEvent("scroll-boundary",X,r),ee.dispatchEvent("scroll",X,r)},eo={getScrollViewElem(){const{elemStore:r}=M;return le(r["main-body-scroll"])},refreshData(){return Go(),Ct(),(0,O.nextTick)().then(()=>{const r=M.xeTable;if(Ct(),r)return r.recalculate()})},updateViewData(r){const l=M.xeTable;if(l){const s=l.reactData,{tableData:v}=s;V.tableData=v,r&&(N.currLeftSpacing=0,N.currRightSpacing=0,Go()),Ct()}return(0,O.nextTick)()},connectUpdate({$table:r}){return r&&(M.xeTable=r),(0,O.nextTick)()}},go=r=>{const{isSyncTableScrollTop:l}=M;if(l)return;const s=M.xeTable;if(s){const v=s.internalData;v.isSyncGanttScrollTop=!0,s.handleSyncScrollTop({scrollTop:r})}},zo={handleUpdateStyle:Bo,handleLazyRecalculate:Qo,handleUpdateCurrentRow(r){const l=M.xeTable,s=Fe.value;if(l&&s)if(r){const v=l.props,{computeRowOpts:S}=l.getComputeMaps();(S.value.isCurrent||v.highlightCurrentRow)&&i.default.arrayEach(s.querySelectorAll(`.vxe-gantt-view--body-row[rowid="${l.getRowid(r)}"]`),d=>Pa(d,"row--current"))}else i.default.arrayEach(s.querySelectorAll(".vxe-gantt-view--body-row.row--current"),v=>va(v,"row--current"))},handleUpdateHoverRow(r){const l=M.xeTable,s=Fe.value;l&&s&&(r?i.default.arrayEach(s.querySelectorAll(`.vxe-gantt-view--body-row[rowid="${l.getRowid(r)}"]`),v=>Pa(v,"row--hover")):i.default.arrayEach(s.querySelectorAll(".vxe-gantt-view--body-row.row--hover"),v=>va(v,"row--hover")))},handleSyncScrollTop(r){const{scrollTop:l}=r,{elemStore:s}=M,v=le(s["main-body-scroll"]);v&&(v.scrollTop=l)},triggerHeaderScrollEvent(r){const{elemStore:l,inVirtualScroll:s,inBodyScroll:v,inFooterScroll:S}=M;if(s||v||S)return;const h=r.currentTarget,d=le(l["main-body-scroll"]),k=dt.value;if(d&&h){const w=h.scrollLeft;M.inHeaderScroll=!0,No(k,w),No(d,w),Et(r,!1,!0,h.scrollTop,w)}},triggerBodyScrollEvent(r){const{scrollXLoad:l}=V,{elemStore:s,inVirtualScroll:v,inHeaderScroll:S,inFooterScroll:h,lastScrollLeft:d,lastScrollTop:k}=M;if(v||S||h)return;const C=r.currentTarget,f=le(s["main-header-scroll"]),w=dt.value,u=se.value,g=C.scrollLeft,c=C.scrollTop,D=g!==d,$=c!==k;M.inBodyScroll=!0,M.scrollRenderType="",$&&(tr(u,c),go(c)),D&&(M.inBodyScroll=!0,No(w,g),No(f,g),l&&Mt()),Et(r,$,D,C.scrollTop,g)},triggerVirtualScrollXEvent(r){const{scrollXLoad:l}=V,{elemStore:s,inHeaderScroll:v,inBodyScroll:S}=M;if(v||S)return;const h=r.currentTarget,d=le(s["main-header-scroll"]),k=le(s["main-body-scroll"]);if(h){const w=h.scrollLeft;M.inVirtualScroll=!0,No(d,w),No(k,w),l&&Mt(),Et(r,!1,!0,h.scrollTop,w)}},triggerVirtualScrollYEvent(r){const{elemStore:l,inHeaderScroll:s,inBodyScroll:v}=M;if(s||v)return;const S=r.currentTarget,h=le(l["main-body-scroll"]);if(S){const C=S.scrollTop;M.inVirtualScroll=!0,tr(h,C),go(C),ze(!0,!1,C,S.scrollLeft)}},handleUpdateSXSpace(){return b()},handleUpdateSYSpace(){return Ue()},handleUpdateSYStatus(r){V.scrollYLoad=r},updateScrollbar(){return ho()}},ho=()=>re.value?(0,O.nextTick)().then(()=>{co(),zt()}):Promise.resolve(),Ho=()=>{Qo()},to=()=>{const{elemStore:r,scrollObserver:l}=M;if(re.value&&!l){const v=Fe.value,S=le(r["main-body-xSpace"]),h=le(r["main-body-xSpace"]),d=un.create(()=>{Dt.value++});v&&d.observe(v),S&&d.observe(S),h&&d.observe(h),M.scrollObserver=d}};Object.assign(Te,eo,zo);const Ro=()=>(0,O.h)("div",{key:"vsx",ref:Pe,class:"vxe-gantt-view--scroll-x-virtual"},[(0,O.h)("div",{ref:A,class:"vxe-gantt-view--scroll-x-left-corner"}),(0,O.h)("div",{ref:Xe,class:"vxe-gantt-view--scroll-x-wrapper"},[(0,O.h)("div",{ref:dt,class:"vxe-gantt-view--scroll-x-handle",onScroll:Te.triggerVirtualScrollXEvent},[(0,O.h)("div",{ref:Qe,class:"vxe-gantt-view--scroll-x-space"})]),(0,O.h)("div",{class:"vxe-gantt-view--scroll-x-handle-appearance"})]),(0,O.h)("div",{ref:te,class:"vxe-gantt-view--scroll-x-right-corner"})]),_o=()=>(0,O.h)("div",{key:"vsy",ref:Re,class:"vxe-gantt-view--scroll-y-virtual"},[(0,O.h)("div",{ref:Ae,class:"vxe-gantt-view--scroll-y-top-corner"}),(0,O.h)("div",{ref:ft,class:"vxe-gantt-view--scroll-y-wrapper"},[(0,O.h)("div",{ref:se,class:"vxe-gantt-view--scroll-y-handle",onScroll:Te.triggerVirtualScrollYEvent},[(0,O.h)("div",{ref:pt,class:"vxe-gantt-view--scroll-y-space"})]),(0,O.h)("div",{class:"vxe-gantt-view--scroll-y-handle-appearance"})]),(0,O.h)("div",{ref:be,class:"vxe-gantt-view--scroll-y-bottom-corner"})]),oo=()=>(0,O.h)("div",{key:"tvw",class:"vxe-gantt-view--viewport-wrapper"},[(0,O.h)(Jr),(0,O.h)(an),(0,O.h)(sn)]),Zo=()=>{const r=Be.value;return(0,O.h)("div",{key:"lnb",class:"vxe-gantt-view--layout-wrapper"},r?[_o(),oo()]:[oo(),_o()])},Ea=()=>{const{showLeftView:r}=N,{xThumbWidth:l,yThumbHeight:s}=V,v=re.value,S=P.value,h=nt.value,d=st.value,k=Ke.value,C=We.value,f=Ie.value,w=Be.value,u=mt.value;return(0,O.h)("div",{key:"lvb",class:["vxe-gantt--layout-wrapper",`sx-pos--${f?"top":"bottom"}`,`sy-pos--${w?"left":"right"}`,{"is--virtual-scrollbar":v,"ov-padding":v&&S.padding,"ov-x--auto-hide":v&&h,"ov-y--auto-hide":v&&d,"overflow-y":s,"overflow-x":l}]},[oo(),(0,O.h)("div",{class:u},[k===!1?fr(ee):(0,O.h)("div",{ref:xe,class:"vxe-scrollbar--track-x",onClick:Nt},[(0,O.h)("div",{ref:Bt,class:"vxe-scrollbar--thumb-x",onPointerdown:Ht,onPointermove:Fo,onPointerup:At,onPointercancel:At,onLostpointercapture:At})]),w&&r||C===!1?fr(ee):(0,O.h)("div",{ref:vt,class:"vxe-scrollbar--track-y",onClick:uo},[(0,O.h)("div",{ref:io,class:"vxe-scrollbar--thumb-y",onPointerdown:To,onPointermove:Co,onPointerup:At,onPointercancel:At,onLostpointercapture:At})])])])},$o=()=>{const{overflowX:r,overflowY:l,scrollXLoad:s,scrollYLoad:v}=V,S=re.value,h=Ie.value;return(0,O.h)("div",{ref:Fe,class:["vxe-gantt-view",{"is--scroll-y":l,"is--scroll-x":r,"is--virtual-x":s,"is--virtual-y":v}]},[(0,O.h)("div",{class:"vxe-gantt-view--render-wrapper"},S?[Ea()]:h?[Ro(),Zo()]:[Zo(),Ro()]),(0,O.h)("div",{class:"vxe-gantt-view--render-vars"},[(0,O.h)("div",{ref:gt,class:"vxe-gantt-view--column-info"})])])},Dt=(0,O.ref)(0);return(0,O.watch)(re,()=>{(0,O.nextTick)(()=>{to(),(0,O.nextTick)(()=>{Dt.value++})})}),(0,O.watch)(Ie,()=>{Dt.value++}),(0,O.watch)(Be,()=>{Dt.value++}),(0,O.watch)(Ke,()=>{Dt.value++}),(0,O.watch)(We,()=>{Dt.value++}),(0,O.watch)(rt,()=>{Dt.value++}),(0,O.watch)(De,()=>{Dt.value++}),(0,O.watch)(Dt,()=>{(0,O.nextTick)(()=>{ho(),(0,O.nextTick)(()=>{ho()})})}),(0,O.onMounted)(()=>{(0,O.nextTick)(()=>{to()}),dr.on(Te,"resize",Ho)}),(0,O.onBeforeUnmount)(()=>{const{scrollObserver:r}=M;r&&r.disconnect(),i.default.assign(V,vr()),i.default.assign(M,hr())}),(0,O.onUnmounted)(()=>{dr.off(Te,"keydown")}),Te.renderVN=$o,(0,O.provide)("$xeGanttView",Te),Te},render(){return this.renderVN()}}),gn=ge("vxe-table"),{warnLog:Ao,errLog:xt}=Ir("gantt"),{getConfig:ve,getIcon:ka,getI18n:Xo,commands:hn,hooks:vn,useFns:mr,createEvent:mn,globalEvents:Ya,GLOBAL_EVENT_KEYS:bn,renderEmptyElement:yt}=Se.VxeUI,br=gn.VxeTable.props,wn=Object.keys(br),wr=["clearAll","syncData","updateData","loadData","reloadData","reloadRow","loadColumn","reloadColumn","getRowNode","getColumnNode","getRowIndex","getVTRowIndex","getVMRowIndex","getColumnIndex","getVTColumnIndex","getVMColumnIndex","setRow","createData","createRow","revertData","clearData","isRemoveByRow","isInsertByRow","isUpdateByRow","getColumns","getColumnById","getColumnByField","getTableColumn","getFullColumns","getData","getCheckboxRecords","getParentRow","getTreeRowChildren","getTreeRowLevel","getTreeParentRow","getRowSeq","getRowById","getRowid","getTableData","getFullData","setColumnFixed","clearColumnFixed","setColumnWidth","getColumnWidth","recalcRowHeight","setRowHeightConf","getRowHeightConf","setRowHeight","getRowHeight","hideColumn","showColumn","resetColumn","refreshColumn","refreshScroll","recalculate","closeTooltip","isAllCheckboxChecked","isAllCheckboxIndeterminate","getCheckboxIndeterminateRecords","setCheckboxRow","setCheckboxRowKey","isCheckedByCheckboxRow","isCheckedByCheckboxRowKey","isIndeterminateByCheckboxRow","isIndeterminateByCheckboxRowKey","toggleCheckboxRow","setAllCheckboxRow","getRadioReserveRecord","clearRadioReserve","getCheckboxReserveRecords","clearCheckboxReserve","toggleAllCheckboxRow","clearCheckboxRow","setCurrentRow","isCheckedByRadioRow","isCheckedByRadioRowKey","setRadioRow","setRadioRowKey","clearCurrentRow","clearRadioRow","getCurrentRecord","getRadioRecord","getCurrentColumn","setCurrentColumn","clearCurrentColumn","setPendingRow","togglePendingRow","hasPendingByRow","isPendingByRow","getPendingRecords","clearPendingRow","setFilterByEvent","sort","setSort","setSortByEvent","clearSort","clearSortByEvent","isSort","getSortColumns","closeFilter","isFilter","clearFilterByEvent","isActiveFilterByColumn","isRowExpandLoaded","clearRowExpandLoaded","reloadRowExpand","reloadRowExpand","toggleRowExpand","setAllRowExpand","setRowExpand","isExpandByRow","isRowExpandByRow","clearRowExpand","clearRowExpandReserve","getRowExpandRecords","getTreeExpandRecords","isTreeExpandLoaded","clearTreeExpandLoaded","reloadTreeExpand","reloadTreeChilds","toggleTreeExpand","setAllTreeExpand","setTreeExpand","isTreeExpandByRow","clearTreeExpand","clearTreeExpandReserve","getScroll","scrollTo","scrollToStartRow","scrollToEndRow","scrollToRow","scrollToStartColumn","scrollToEndColumn","scrollToColumn","clearScroll","updateFooter","updateStatus","setMergeCells","removeInsertRow","removeMergeCells","getMergeCells","clearMergeCells","setMergeFooterItems","removeMergeFooterItems","getMergeFooterItems","clearMergeFooterItems","getCustomStoreData","setRowGroupExpand","setRowGroupExpandByField","setAllRowGroupExpand","clearRowGroupExpand","isRowGroupExpandByRow","isRowGroupRecord","isAggregateRecord","isAggregateExpandByRow","getAggregateContentByRow","getAggregateRowChildren","setRowGroups","clearRowGroups","openTooltip","moveColumnTo","moveRowTo","getCellLabel","undo","redo","getCellElement","focus","blur","connect"],xn=[["Form"],["Toolbar","Top","Gantt","Bottom","Pager"]];function xr(){return{linkFromConfMaps:{},linkToConfMaps:{},linkUniqueMaps:{},uFoot:!1,resizeTableWidth:0,dragLinkToStore:{rowid:null,type:0},criticalRowList:[],criticalRowMaps:new Map,criticalLinkKeyMaps:new Map}}function yr(){var o;return{tableLoading:!1,proxyInited:!1,overflowY:!1,overflowX:!1,scrollbarWidth:0,scrollbarHeight:0,isZMax:!1,tableLinks:[],tableData:[],filterData:[],formData:{},sortData:[],footerData:[],tZindex:0,tablePage:{total:0,pageSize:((o=ve().pager)==null?void 0:o.pageSize)||10,currentPage:1},showLeftView:!0,showRightView:!0,taskScaleList:[],barTipStore:{row:null,content:"",visible:!1,params:null},dragLinkFromStore:{rowid:null,type:0},activeBarRowid:null,activeLink:null,isActiveCeLe:!1,linkList:[],upLinkFlag:0,showSplitAnimat:!1,nowTime:0,currLeftSpacing:0,currRightSpacing:0,criticalLinks:[],criticalRowIds:[],criticalPathFlag:0}}var Ta={year:19,quarter:17,month:15,week:13,day:11,date:9,hour:7,minute:5,second:3};function yn(o){return Ta[o||"date"]||Ta.date}var Ca=Yo({name:"VxeGantt",mixins:[],props:{...br,columns:Array,pagerConfig:Object,proxyConfig:Object,toolbarConfig:Object,formConfig:Object,zoomConfig:Object,links:Array,layouts:Array,taskConfig:Object,taskViewScaleConfig:Object,taskNowLineConfig:Object,taskViewConfig:Object,taskLinkConfig:Object,taskBarConfig:Object,taskBarMilestoneConfig:Object,taskCriticalPathConfig:Object,taskBarSubviewConfig:Object,taskBarTooltipConfig:Object,taskSplitConfig:Object,taskBarResizeConfig:Object,taskBarResizeTooltipConfig:Object,taskBarMoveConfig:Object,taskBarMoveTooltipConfig:Object,size:{type:String,default:()=>ve().gantt.size||ve().size}},emits:Gr,setup(o,F){const{slots:W,emit:me}=F,ee=B.default.uniqueId(),Ne=Se.VxeUI.getComponent("VxeForm"),N=Se.VxeUI.getComponent("VxePager"),Oe=Se.VxeUI.getComponent("VxeTable"),Wt=Se.VxeUI.getComponent("VxeToolbar"),Yt=Se.VxeUI.getComponent("VxeTooltip"),St=Object.assign({},ve().scrollbar),{computeSize:It}=mr.useSize(o),{computeIsVScrollbar:we}=mr.useVScrollbar(o),y=(0,n.reactive)(yr()),P=xr(),ae=(0,n.ref)(),Z=(0,n.ref)(),ie=(0,n.ref)(),at=(0,n.ref)(),Ee=(0,n.ref)(),qe=(0,n.ref)(),Fe=(0,n.ref)(),Pe=(0,n.ref)(),Re=(0,n.ref)(),dt=(0,n.ref)(),A=(0,n.ref)(),te=(0,n.ref)(),se=(0,n.ref)(),Ae=(0,n.ref)(),Xe=(0,n.ref)(),ft=(0,n.ref)(),be=(0,n.ref)(),Qe=(0,n.ref)(),pt=e=>{const t={};return e.forEach(a=>{t[a]=(...p)=>{const m=Z.value;if(m&&m[a])return m[a](...p)}}),t},gt=pt(wr);wr.forEach(e=>{gt[e]=(...t)=>{const a=Z.value;if(a&&a[e])return a&&a[e](...t)}});const V=(0,n.computed)(()=>B.default.merge({},B.default.clone(ve().gantt.proxyConfig,!0),o.proxyConfig)),M=(0,n.computed)(()=>{const e=V.value;return!!(B.default.isBoolean(e.message)?e.message:e.showResponseMsg)}),Ze=(0,n.computed)(()=>{const e=V.value;return B.default.isBoolean(e.showActionMsg)?e.showActionMsg:!!e.showActiveMsg}),re=(0,n.computed)(()=>Object.assign({},ve().gantt.pagerConfig,o.pagerConfig)),he=(0,n.computed)(()=>Object.assign({},ve().gantt.formConfig,o.formConfig)),ke=(0,n.computed)(()=>Object.assign({},ve().gantt.toolbarConfig,o.toolbarConfig)),rt=(0,n.computed)(()=>Object.assign({},ve().gantt.zoomConfig,o.zoomConfig)),De=(0,n.computed)(()=>Object.assign({},ve().gantt.taskConfig,o.taskConfig)),Ke=(0,n.computed)(()=>B.default.merge({},ve().gantt.taskViewScaleConfig,o.taskViewScaleConfig)),We=(0,n.computed)(()=>Object.assign({},ve().gantt.taskNowLineConfig,o.taskNowLineConfig)),nt=(0,n.computed)(()=>Object.assign({},ve().gantt.taskViewConfig,o.taskViewConfig)),st=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarConfig,o.taskBarConfig)),Ie=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarMoveConfig,o.taskBarMoveConfig)),Be=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarMoveTooltipConfig,o.taskBarMoveTooltipConfig)),mt=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarResizeConfig,o.taskBarResizeConfig)),Je=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarResizeTooltipConfig,o.taskBarResizeTooltipConfig)),ht=(0,n.computed)(()=>Object.assign({},ve().gantt.taskSplitConfig,o.taskSplitConfig)),bt=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarMilestoneConfig,o.taskBarMilestoneConfig)),Te=(0,n.computed)(()=>Object.assign({},ve().gantt.taskCriticalPathConfig,o.taskCriticalPathConfig)),xe=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarSubviewConfig,o.taskBarSubviewConfig)),vt=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarTooltipConfig,o.taskBarTooltipConfig)),Bt=(0,n.computed)(()=>Object.assign({},ve().gantt.taskLinkConfig,o.taskLinkConfig)),io=(0,n.computed)(()=>{const e=De.value,{dateFormat:t}=e;return t||""}),co=(0,n.computed)(()=>{const e=zt.value;return e?e.type:"date"}),zt=(0,n.computed)(()=>{const{taskScaleList:e}=y;return B.default.last(e)}),Nt=(0,n.computed)(()=>{const e=zt.value,{step:t}=e;return B.default.toNumber(t||1)||1}),uo=(0,n.computed)(()=>{const{taskScaleList:e}=y;return e.find(t=>t.type==="week")}),Ht=(0,n.computed)(()=>{const e=nt.value,{scales:t}=e;return t}),Fo=(0,n.computed)(()=>{const{lineType:e,lineWidth:t,lineStatus:a,lineColor:p}=Bt.value;return`${e||""}_${t||""}_${a||""}_${p||""}`}),At=(0,n.computed)(()=>De.value.titleField||"title"),To=(0,n.computed)(()=>De.value.startField||"start"),Co=(0,n.computed)(()=>De.value.endField||"end"),de=(0,n.computed)(()=>De.value.typeField||"type"),Xt=(0,n.computed)(()=>De.value.progressField||"progress"),_t=(0,n.computed)(()=>Object.assign({},ve().gantt.scrollbarConfig,o.scrollbarConfig)),Tt=(0,n.computed)(()=>{const e=_t.value;return e.x?Object.assign({},e.x,e.xConfig):e.xConfig||{}}),jt=(0,n.computed)(()=>{const e=_t.value;return e.y?Object.assign({},e.y,e.yConfig):e.yConfig||{}}),Ut=(0,n.computed)(()=>{const e=_t.value,t=Tt.value;return B.default.toNumber(ot(ot(t.height,e.height),St.height))}),Po=(0,n.computed)(()=>{const e=_t.value,t=jt.value;return B.default.toNumber(ot(ot(t.width,e.width),St.width))}),Go=(0,n.computed)(()=>{const e=_t.value,t=Tt.value;return ot(ot(t.autoHide,e.autoHide),St.autoHide)}),Wo=(0,n.computed)(()=>{const e=_t.value,t=jt.value;return ot(ot(t.autoHide,e.autoHide),St.autoHide)}),Kt=(0,n.computed)(()=>Tt.value.position==="top"),Eo=(0,n.computed)(()=>jt.value.position==="left"),qo=(0,n.computed)(()=>st.value.showCriticalPath),Do=(0,n.computed)(()=>{const{height:e,maxHeight:t,taskBarSubviewConfig:a}=o,{isZMax:p,tZindex:m,overflowY:E,scrollbarWidth:H}=y,_=we.value,j=nt.value,{viewStyle:Q,tableStyle:U}=j,K=st.value,{barStyle:pe}=K,Lt=Te.value,{lineColor:Me}=Lt,wt=xe.value,vo=We.value,{fontColor:Gt,bgColor:mo,width:jo}=vo,ia=Po.value,Ko=Ut.value,oe={"--vxe-ui-gantt-scrollbar-width":E?_?"var(--vxe-ui-scrollbar-y-width)":H+"px":""};if(Me&&(oe["--vxe-ui-gantt-view-bar-critical-path-line-color"]=Me),p?oe.zIndex=m:(e&&(oe.height=e==="auto"||e==="100%"?"100%":Lo(e)),t&&(oe.maxHeight=t==="auto"||t==="100%"?"100%":Lo(t))),(ia||Ko)&&(oe["--vxe-ui-scrollbar-y-width"]=Lo(ia||Ko),oe["--vxe-ui-scrollbar-x-height"]=Lo(Ko||ia)),pe&&!B.default.isFunction(pe)){const{bgColor:Ft,completedBgColor:G,overviewBgColor:bo}=pe;Ft&&(oe["--vxe-ui-gantt-view-task-bar-background-color"]=Ft),G&&(oe["--vxe-ui-gantt-view-task-bar-completed-background-color"]=G),bo&&oa(a,wt)&&(oe["--vxe-ui-gantt-view-task-bar-overview-background-color"]=bo)}if(Gt&&(oe["--vxe-ui-gantt-view-task-now-line-color"]=Gt),mo&&(oe["--vxe-ui-gantt-view-task-now-line-background-color"]=mo),jo&&(oe["--vxe-ui-gantt-view-task-now-line-width"]=Lo(jo)),Q){const{cellWidth:Ft}=Q;Ft&&(oe["--vxe-ui-gantt-view-default-cell-width"]=Lo(Ft))}if(U){const{width:Ft}=U;Ft&&(oe["--vxe-ui-gantt-view-table-default-width"]=Lo(Ft))}return oe}),Io=(0,n.computed)(()=>{const e={},t=o;return wn.forEach(a=>{t[a]!==void 0&&(e[a]=t[a])}),e}),sa=(0,n.computed)(()=>{const{showFooter:e,seqConfig:t,pagerConfig:a,editConfig:p,proxyConfig:m}=o,{isZMax:E,tablePage:H,footerData:_}=y,j=nt.value,{tableStyle:Q}=j,U=Io.value,K=V.value,pe=re.value,Lt=Jt.value,Me=Object.assign({},U,{showOverflow:!0,showHeaderOverflow:!0,showFooterOverflow:!0});if(Q){const{border:wt}=Q;B.default.eqNull(wt)||(Me.border=wt)}return(e&&!Me.footerData||K.footer&&_.length)&&(Me.footerData=_),E&&(Me.maxHeight?Me.maxHeight="100%":Me.height="100%"),m&&ne(K)&&(Me.loading=Lt,a&&K.seq&&ne(pe)&&(Me.seqConfig=Object.assign({},t,{startIndex:(H.currentPage-1)*H.pageSize}))),p&&(Me.editConfig=Object.assign({},p)),Me}),Bo=(0,n.computed)(()=>{const{layouts:e}=o;let t=[];e&&e.length?t=e:t=ve().gantt.layouts||xn;let a=[],p=[],m=[];return t.length&&(B.default.isArray(t[0])?(a=t[0],p=t[1]||[],m=t[2]||[]):p=t),{headKeys:a,bodyKeys:p,footKeys:m}}),Ct=(0,n.computed)(()=>re.value.currentPage),Qo=(0,n.computed)(()=>re.value.pageSize),fo=(0,n.computed)(()=>re.value.total),Oo=(0,n.computed)(()=>{const{tablePage:e}=y;return Math.max(Math.ceil(e.total/e.pageSize),1)}),Jt=(0,n.computed)(()=>{const{loading:e,proxyConfig:t}=o,{tableLoading:a}=y,p=V.value,{showLoading:m}=p;return e||a&&m&&t&&ne(p)}),po=(0,n.computed)(()=>{let{border:e}=o;const t=nt.value,{viewStyle:a}=t;return a&&(B.default.eqNull(a.border)||(e=a.border)),e===!0?"full":e||"default"}),la={refElem:ae,refTable:Z,refForm:ie,refToolbar:at,refPager:Ee,refGanttView:Pe,refGanttContainerElem:qe,refClassifyWrapperElem:Fe,refPopupContainerElem:Re},$t={computeSize:It,computeIsVScrollbar:we,computeProxyOpts:V,computePagerOpts:re,computeFormOpts:he,computeToolbarOpts:ke,computeZoomOpts:rt,computeTaskOpts:De,computeTaskViewScaleOpts:Ke,computeTaskNowLineOpts:We,computeTaskViewOpts:nt,computeTaskBarOpts:st,computeTaskBarMoveOpts:Ie,computeTaskBarMoveTooltipOpts:Be,computeTaskBarResizeOpts:mt,computeTaskBarResizeTooltipOpts:Je,computeTaskSplitOpts:ht,computeTaskBarMilestoneOpts:bt,computeTaskCriticalPathOpts:Te,computeTaskBarSubviewOpts:xe,computeTaskBarTooltipOpts:vt,computeTaskLinkOpts:Bt,computeTaskViewScales:Ht,computeScaleUnit:co,computeDateFormat:io,computeMinScale:zt,computeScaleStep:Nt,computeWeekScale:uo,computeTitleField:At,computeStartField:To,computeEndField:Co,computeTypeField:de,computeProgressField:Xt,computeScrollbarOpts:_t,computeScrollbarXOpts:Tt,computeScrollbarYOpts:jt,computeScrollbarXToTop:Kt,computeScrollbarYToLeft:Eo};$t.computeTaskScaleConfs=Ht;const b={xID:ee,props:o,context:F,reactData:y,internalData:P,getRefMaps:()=>la,getComputeMaps:()=>$t},Mt=()=>{const e=Ht.value,t=Ke.value,a=[],p={};(e&&e.length?e:["month","date"]).forEach(E=>{const H=!E||B.default.isString(E)?{type:E}:E,_=H.type,j=yn(_);if(!_||!Ta[_]){xt("vxe.error.errProp",[`type=${_}`,B.default.keys(Ta).join(",")]);return}if(p[_]){xt("vxe.error.repeatProp",["type",_]);return}const Q=Object.assign({},_?t[_]||{}:{},H,{level:j});p[_]=!0,a.push(Q)}),y.taskScaleList=B.default.orderBy(a,{field:"level",order:"desc"})},Ue=()=>{const e=ke.value;o.toolbarConfig&&ne(e)&&(0,n.nextTick)(()=>{const t=Z.value,a=at.value;t&&a&&t.connectToolbar(a)})},$e=()=>{const e=Z.value,t=Pe.value;e&&t&&e.handleConnectGanttView(t)},ze=()=>{const{proxyConfig:e}=o,{formData:t}=y,a=V.value,p=he.value;return e&&ne(a)&&a.form?t:p.data},Et=e=>{const{tablePage:t}=y,{pagerConfig:a}=o,p=re.value;if(a&&ne(p))if(e)p[e]&&(t[e]=B.default.toNumber(p[e]));else{const{currentPage:m,pageSize:E,total:H}=p;m&&(t.currentPage=m),E&&(t.pageSize=E),H&&(t.total=H)}},eo=e=>{const t=Ze.value,a=Z.value,p=a?a.getCheckboxRecords():[];p.length?(a&&a.togglePendingRow(p),b.clearCheckboxRow()):t&&Se.VxeUI.modal&&Se.VxeUI.modal.message({id:e,content:Xo("vxe.grid.selectOneRecord"),status:"warning"})},go=(e,t)=>{const a=V.value,m=(a.response||a.props||{}).message,E=Z.value;let H;return e&&m&&(H=B.default.isFunction(m)?m({data:e,$table:E,$grid:null,$gantt:b}):B.default.get(e,m)),H||Xo(t)},zo=(e,t,a)=>{const p=Ze.value,m=b.getCheckboxRecords();if(p)if(m.length){if(Se.VxeUI.modal)return Se.VxeUI.modal.confirm({id:`cfm_${e}`,content:Xo(t),escClosable:!0}).then(E=>{if(E==="confirm")return a()})}else Se.VxeUI.modal&&Se.VxeUI.modal.message({id:`msg_${e}`,content:Xo("vxe.grid.selectOneRecord"),status:"warning"});else m.length&&a();return Promise.resolve()},ho=e=>{const{proxyConfig:t}=o,{tablePage:a}=y,{$event:p,currentPage:m,pageSize:E}=e,H=V.value;a.currentPage=m,a.pageSize=E,b.dispatchEvent("page-change",e,p),t&&ne(H)&&b.commitProxy("query").then(_=>{b.dispatchEvent("proxy-query",_,p)})},Ho=e=>{const t=Z.value,{proxyConfig:a}=o;if(!t)return;const{computeSortOpts:p}=t.getComputeMaps(),m=V.value;p.value.remote&&(y.sortData=e.sortList,a&&ne(m)&&(y.tablePage.currentPage=1,b.commitProxy("query").then(H=>{b.dispatchEvent("proxy-query",H,e.$event)})))},to=e=>{Ho(e),b.dispatchEvent("sort-change",e,e.$event)},Ro=e=>{Ho(e),b.dispatchEvent("clear-all-sort",e,e.$event)},_o=e=>{const t=Z.value,{proxyConfig:a}=o;if(!t)return;const{computeFilterOpts:p}=t.getComputeMaps(),m=V.value;p.value.remote&&(y.filterData=e.filterList,a&&ne(m)&&(y.tablePage.currentPage=1,P.uFoot=!0,b.commitProxy("query").then(H=>{b.dispatchEvent("proxy-query",H,e.$event)}),P.uFoot=!1,u()))},oo=e=>{_o(e),b.dispatchEvent("filter-change",e,e.$event)},Zo=e=>{_o(e),b.dispatchEvent("clear-all-filter",e,e.$event)},Ea=e=>{const{proxyConfig:t}=o,a=V.value;y.tableLoading||(t&&ne(a)&&(P.uFoot=!0,b.commitProxy("reload").then(p=>{b.dispatchEvent("proxy-query",{...p,isReload:!0},e.$event)}),P.uFoot=!1,u()),b.dispatchEvent("form-submit",e,e.$event))},$o=e=>{const t=Z.value,{proxyConfig:a}=o,{$event:p}=e,m=V.value;a&&ne(m)&&(t&&t.clearScroll(),P.uFoot=!0,b.commitProxy("reload").then(E=>{b.dispatchEvent("proxy-query",{...E,isReload:!0},p)}),P.uFoot=!1,u()),b.dispatchEvent("form-reset",e,p)},Dt=e=>{b.dispatchEvent("form-submit-invalid",e,e.$event)},r=e=>{const{$event:t}=e;b.dispatchEvent("form-toggle-collapse",e,t),b.dispatchEvent("form-collapse",e,t)},l=e=>{const{isZMax:t}=y;return(e?!t:t)&&(y.isZMax=!t,y.tZindex<jr()&&(y.tZindex=_r())),(0,n.nextTick)().then(()=>b.recalculate(!0)).then(()=>(setTimeout(()=>b.recalculate(!0),15),y.isZMax))},s=(e,t)=>{const a=e[t];if(a)if(B.default.isString(a)){if(W[a])return W[a];xt("vxe.error.notSlot",[a])}else return a;return null},v=e=>{const t={};return B.default.objectMap(e,(a,p)=>{a&&(B.default.isString(a)?W[a]?t[p]=W[a]:xt("vxe.error.notSlot",[a]):t[p]=a)}),t},S=e=>{const t=ae.value;if(!t)return;const a=qe.value;if(!a)return;const p=Xe.value;if(!p)return;const m=Qe.value;if(!m)return;const E=nt.value,H=a.getBoundingClientRect(),_=m.children[0],j=e.clientX,Q=a.clientWidth,U=p.clientWidth,K=E.tableStyle&&B.default.toNumber(E.tableStyle.minWidth)||80;let pe=U,Lt=-1;Pa(t,"is--split-drag");const Me=wt=>{const vo=_.children[0],Gt=_.children[1];let mo=0;vo&&(Lt<0?vo.style.display="none":(vo.textContent=`${pe}px`,vo.style.display="block",mo=vo.offsetHeight)),Gt&&(Lt<0?(Gt.textContent=`${Math.floor(H.width-pe)}px`,Gt.style.display="block",mo=Gt.offsetHeight):Gt.style.display="none");const jo=wt.clientY-H.top-mo/2;m.style.left=`${pe}px`,_.style.top=`${Math.min(H.height-mo-1,Math.max(1,jo))}px`};document.onmousemove=wt=>{wt.preventDefault(),Lt=wt.clientX-j,pe=Math.min(Q-80,Math.max(K,U+Lt)),Me(wt)},document.onmouseup=()=>{document.onmousemove=null,document.onmouseup=null,m.style.display="",p.style.width=`${pe}px`,va(t,"is--split-drag");const wt=Z.value;wt&&wt.recalculate(!0)},m.style.display="block",Me(e)},h=()=>{const e=ht.value,{animation:t}=e;if(t){const{_taTime:a}=P;a&&clearTimeout(a),y.showSplitAnimat=!0,P._taTime=setTimeout(()=>{y.showSplitAnimat=!1,P._taTime=null},350)}},d=()=>{h(),y.showLeftView=!y.showLeftView},k=()=>{h(),y.showRightView=!y.showRightView},C={};or.forEach(e=>{const t=B.default.camelCase(`on-${e}`);C[t]=(...a)=>me(e,...a)});const f=()=>{const e=he.value;if(e.items){const t={};return e.items.forEach(a=>{const{field:p,itemRender:m}=a;if(p){let E=null;if(m){const{startField:H,endField:_,defaultValue:j}=m;B.default.isFunction(j)?E=j({item:a}):B.default.isUndefined(j)||(E=j),H&&_&&(B.default.set(t,H,null),B.default.set(t,_,null))}t[p]=E}}),t}return{}},w=()=>{const{proxyConfig:e,formConfig:t}=o,{proxyInited:a}=y,p=V.value,m=he.value;e&&ne(p)&&(t&&ne(m)&&p.form&&m.items&&(y.formData=f()),a||(y.proxyInited=!0,p.autoLoad!==!1&&(0,n.nextTick)().then(()=>{P.uFoot=!0;const E=b.commitProxy("initial");return P.uFoot=!1,u(),E}).then(E=>{c("proxy-query",{...E,isInited:!0},new Event("initial"))})))},u=()=>{const e=V.value,{ajax:t}=e;if(t&&t.queryFooter)return b.commitProxy("queryFooter")},g=e=>{const t=rt.value;Ya.hasKey(e,bn.ESCAPE)&&y.isZMax&&t.escRestore!==!1&&b.triggerZoomEvent(e)},c=(e,t,a)=>{me(e,mn(a,{$grid:null,$gantt:b},t))},D=e=>{const t=be.value;clearTimeout(P.barTipTimeout),e?b.closeTaskBarTooltip():t&&t.setActived&&t.setActived(!0)},$={dispatchEvent:c,getEl(){return ae.value},commitProxy(e,...t){const{showFooter:a,proxyConfig:p,toolbarConfig:m,pagerConfig:E,editRules:H,validConfig:_}=o,{tablePage:j}=y,Q=Ze.value,U=M.value,K=V.value,pe=re.value,Lt=ke.value,{beforeQuery:Me,afterQuery:wt,beforeQueryFooter:vo,afterQueryFooter:Gt,beforeDelete:mo,afterDelete:jo,beforeSave:ia,afterSave:Ko,ajax:oe={}}=K,Ft=K.response||K.props||{},G=Z.value;if(!G)return(0,n.nextTick)();let bo=ze(),ao=null,et=null;if(B.default.isString(e)){const{buttons:Ve}=Lt,He=m&&ne(Lt)&&Ve?B.default.findTree(Ve,_e=>_e.code===e,{children:"dropdowns"}):null;ao=He?He.item:null,et=e}else ao=e,et=ao.code;const Da=ao?ao.params:null;switch(et){case"insert":return G.insert({});case"insert_edit":return G.insert({}).then(({row:Ve})=>G.setEditRow(Ve,!0));case"insert_actived":return G.insert({}).then(({row:Ve})=>G.setEditRow(Ve,!0));case"mark_cancel":eo(et);break;case"remove":return zo(et,"vxe.grid.removeSelectRecord",()=>G.removeCheckboxRow());case"import":G.importData(Da);break;case"open_import":G.openImport(Da);break;case"export":G.exportData(Da);break;case"open_export":G.openExport(Da);break;case"reset_custom":return G.resetCustom(!0);case"initial":case"reload":case"query":{const Ve=oe.beforeQuery,He=oe.query,_e=oe.afterQuery,qt=oe.querySuccess,Qt=oe.queryError;if(He){const tt=et==="initial",Rt=et==="reload";if(!tt&&y.tableLoading)return(0,n.nextTick)();let Pt=null,Ge=[],Ce=[],je={};if(E&&((tt||Rt)&&(j.currentPage=1),ne(pe)&&(je={...j})),tt){if(p&&ne(K)&&K.form&&(bo=f(),y.formData=bo),G){const Ye=G.internalData,{tableFullColumn:it,fullColumnFieldData:wo}=Ye,{computeSortOpts:kt}=G.getComputeMaps();let xo=kt.value.defaultSort;it.forEach(ea=>{ea.order=null}),xo&&(B.default.isArray(xo)||(xo=[xo]),Ge=xo.map(ea=>{const{field:Aa,order:Cr}=ea,Er=wo[Aa];if(Er){const Dr=Er.column;Dr&&(Dr.order=Cr)}return{field:Aa,property:Aa,order:Cr}})),Ce=G.getCheckedFilters()}}else G&&(Rt?Pt=G.clearAll():(Ge=G.getSortColumns(),Ce=G.getCheckedFilters()));const ro={$table:G,$grid:null,$gantt:b,code:et,button:ao,isInited:tt,isReload:Rt,page:je,sort:Ge.length?Ge[0]:{},sorts:Ge,filters:Ce,form:bo,options:He},Mo=()=>(y.sortData=Ge,y.filterData=Ce,y.tableLoading=!0,Promise.all([Promise.resolve((Me||He)(ro,...t)),Pt]).then(([Ye])=>{if(y.tableLoading=!1,_e)_e({...ro,response:Ye,status:"success"},...t);else{let it=[];if(Ye){const wo={data:Ye,$table:G,$grid:null,$gantt:b};if(E&&ne(pe)){const kt=Ft.total,Jo=(B.default.isFunction(kt)?kt(wo):B.default.get(Ye,kt||"page.total"))||0;j.total=B.default.toNumber(Jo);const xo=Ft.result;it=(B.default.isFunction(xo)?xo(wo):B.default.get(Ye,xo||"result"))||[];const ea=Math.max(Math.ceil(Jo/j.pageSize),1);j.currentPage>ea&&(j.currentPage=ea)}else{const kt=Ft.list;B.default.isArray(Ye)?it=Ye:kt&&(it=(B.default.isFunction(kt)?kt(wo):B.default.get(Ye,kt))||[])}if(a){const kt=Ft.footerData,Jo=kt?B.default.isFunction(kt)?kt(wo):B.default.get(Ye,kt):[];B.default.isArray(Jo)&&(y.footerData=Jo)}}G?G.loadData(it):(0,n.nextTick)(()=>{const wo=Z.value;wo&&wo.loadData(it)}),wt&&wt({...ro,response:Ye},...t)}return qt&&qt({...ro,response:Ye}),{status:!0}}).catch(Ye=>(y.tableLoading=!1,_e&&_e({...ro,response:Ye,status:"error"},...t),Qt&&Qt({...ro,response:Ye}),{status:!1})));return Ve?Promise.resolve(Ve(ro,...t)).then(Ye=>{if(Ye!==!1)return Mo()}):Mo()}else xt("vxe.error.notFunc",["proxy-config.ajax.query"]);break}case"queryFooter":{const Ve=oe.beforeQueryFooter,He=oe.queryFooter,_e=oe.afterQueryFooter,qt=oe.queryFooterSuccess,Qt=oe.queryFooterError;if(He){let tt=[];G&&(tt=G.getCheckedFilters());let Rt={};E&&ne(pe)&&(Rt={...j});const Pt={$table:G,$grid:null,$gantt:b,code:et,button:ao,page:Rt,filters:tt,form:bo,options:He},Ge=()=>Promise.resolve((vo||He)(Pt,...t)).then(Ce=>(_e?_e({...Pt,response:Ce,status:"success"},...t):(y.footerData=B.default.isArray(Ce)?Ce:[],Gt&&Gt({...Pt,response:Ce},...t)),qt&&qt({...Pt,response:Ce}),{status:!0})).catch(Ce=>(_e&&_e({...Pt,response:Ce,status:"error"},...t),Qt&&Qt({...Pt,response:Ce}),{status:!1}));return Ve?Promise.resolve(Ve(Pt,...t)).then(Ce=>{if(Ce!==!1)return Ge()}):Ge()}else xt("vxe.error.notFunc",["proxy-config.ajax.queryFooter"]);break}case"delete":{const Ve=oe.beforeDelete,He=oe.delete,_e=oe.afterDelete,qt=oe.deleteSuccess,Qt=oe.deleteError;if(He){const tt=b.getCheckboxRecords(),Rt=tt.filter(Ce=>!G.isInsertByRow(Ce)),Ge={$table:G,$grid:null,$gantt:b,code:et,button:ao,body:{removeRecords:Rt},form:bo,options:He};if(tt.length)return zo(et,"vxe.grid.deleteSelectRecord",()=>{if(!Rt.length)return G.remove(tt);const Ce=()=>(y.tableLoading=!0,Promise.resolve((mo||He)(Ge,...t)).then(je=>(y.tableLoading=!1,_e?_e({...Ge,response:je,status:"success"},...t):(G.setPendingRow(Rt,!1),U&&Se.VxeUI.modal&&Se.VxeUI.modal.message({content:go(je,"vxe.grid.delSuccess"),status:"success"}),jo?jo({...Ge,response:je},...t):(P.uFoot=!0,b.commitProxy("query"),P.uFoot=!1,u())),qt&&qt({...Ge,response:je}),{status:!0})).catch(je=>(y.tableLoading=!1,_e?_e({...Ge,response:je,status:"error"},...t):U&&Se.VxeUI.modal&&Se.VxeUI.modal.message({id:et,content:go(je,"vxe.grid.operError"),status:"error"}),Qt&&Qt({...Ge,response:je}),{status:!1})));return Ve?Promise.resolve(Ve(Ge,...t)).then(je=>{if(je!==!1)return Ce()}):Ce()});Q&&Se.VxeUI.modal&&Se.VxeUI.modal.message({id:et,content:Xo("vxe.grid.selectOneRecord"),status:"warning"})}else xt("vxe.error.notFunc",["proxy-config.ajax.delete"]);break}case"save":{const Ve=oe.beforeSave,He=oe.save,_e=oe.afterSave,qt=oe.saveSuccess,Qt=oe.saveError;if(He){const tt=G.getRecordset(),{insertRecords:Rt,removeRecords:Pt,updateRecords:Ge,pendingRecords:Ce}=tt,je={$table:G,$grid:null,$gantt:b,code:et,button:ao,body:tt,form:bo,options:He};Rt.length&&(tt.pendingRecords=Ce.filter(Mo=>G.findRowIndexOf(Rt,Mo)===-1)),Ce.length&&(tt.insertRecords=Rt.filter(Mo=>G.findRowIndexOf(Ce,Mo)===-1));let ro=Promise.resolve();return H&&(ro=G[_&&_.msgMode==="full"?"fullValidate":"validate"](tt.insertRecords.concat(Ge))),ro.then(Mo=>{if(!Mo)if(tt.insertRecords.length||Pt.length||Ge.length||tt.pendingRecords.length){const Ye=()=>(y.tableLoading=!0,Promise.resolve((ia||He)(je,...t)).then(it=>(y.tableLoading=!1,_e?_e({...je,response:it,status:"success"},...t):(G.clearPendingRow(),U&&Se.VxeUI.modal&&Se.VxeUI.modal.message({content:go(it,"vxe.grid.saveSuccess"),status:"success"}),Ko?Ko({...je,response:it},...t):(P.uFoot=!0,b.commitProxy("query"),P.uFoot=!1,u())),qt&&qt({...je,response:it}),{status:!0})).catch(it=>(y.tableLoading=!1,_e?_e({...je,response:it,status:"error"},...t):U&&Se.VxeUI.modal&&Se.VxeUI.modal.message({id:et,content:go(it,"vxe.grid.operError"),status:"error"}),Qt&&Qt({...je,response:it}),{status:!1})));return Ve?Promise.resolve(Ve(je,...t)).then(it=>{if(it!==!1)return Ye()}):Ye()}else Q&&Se.VxeUI.modal&&Se.VxeUI.modal.message({id:et,content:Xo("vxe.grid.dataUnchanged"),status:"info"})})}else xt("vxe.error.notFunc",["proxy-config.ajax.save"]);break}default:{const Ve=hn.get(et);if(Ve){const He=Ve.tableCommandMethod||Ve.commandMethod;He?He({code:et,button:ao,$table:G,$grid:null,$gantt:b},...t):xt("vxe.error.notCommands",[et])}}}return(0,n.nextTick)()},getParams(){return o.params},zoom(){return y.isZMax?b.revert():b.maximize()},isMaximized(){return y.isZMax},maximize(){return l(!0)},revert(){return l()},getFormData:ze,getFormItems(e){const t=he.value,{formConfig:a}=o,{items:p}=t,m=[];return B.default.eachTree(a&&ne(t)&&p?p:[],E=>{m.push(E)},{children:"children"}),B.default.isUndefined(e)?m:m[e]},getFormFlatItems(){const e=ie.value;return e?e.getFlatItems():[]},getFormNestedItems(){const e=ie.value;return e?e.getNestedItems():[]},getFormItemByField(e){const t=ie.value;return t?t.getItemByField(e):null},resetForm(){const e=ie.value;return e?e.reset():(0,n.nextTick)()},validateForm(){const e=ie.value;return e?e.validate():(0,n.nextTick)()},validateFormField(e){const t=ie.value;return t?t.validateField(e):(0,n.nextTick)()},clearFormValidate(e){const t=ie.value;return t?t.clearValidate(e):(0,n.nextTick)()},homePage(){const{tablePage:e}=y;return e.currentPage=1,(0,n.nextTick)()},homePageByEvent(e){const t=Ee.value;t&&t.homePageByEvent(e)},endPage(){const{tablePage:e}=y,t=Oo.value;return e.currentPage=t,(0,n.nextTick)()},endPageByEvent(e){const t=Ee.value;t&&t.endPageByEvent(e)},getCurrentPage(){const{tablePage:e}=y;return e.currentPage},setCurrentPage(e){const{tablePage:t}=y,a=Oo.value;return t.currentPage=Math.min(a,Math.max(1,B.default.toNumber(e))),(0,n.nextTick)()},setCurrentPageByEvent(e,t){const a=Ee.value;a&&a.setCurrentPageByEvent(e,t)},getPageSize(){const{tablePage:e}=y;return e.pageSize},setPageSize(e){const{tablePage:t}=y;return t.pageSize=Math.max(1,B.default.toNumber(e)),(0,n.nextTick)()},setPageSizeByEvent(e,t){const a=Ee.value;a&&a.setPageSizeByEvent(e,t)},getProxyInfo(){const e=Z.value;if(o.proxyConfig){const{sortData:t}=y;return{data:e?e.getFullData():[],filter:y.filterData,form:ze(),sort:t.length?t[0]:{},sorts:t,pager:y.tablePage,pendingRecords:e?e.getPendingRecords():[]}}return null},getCustomPagerData(){const{pagerConfig:e}=o,{tablePage:t}=y,a=re.value;return e&&ne(a)?{pSize:t.pageSize}:{}},refreshTaskView(){const e=Pe.value;return e?e.refreshData():(0,n.nextTick)()},hasTableViewVisible(){return y.showLeftView},showTableView(){return y.showLeftView=!0,(0,n.nextTick)()},hideTableView(){return y.showLeftView=!1,y.showRightView||(y.showRightView=!0),(0,n.nextTick)()},hasTaskViewVisible(){return y.showRightView},showTaskView(){return y.showRightView=!0,(0,n.nextTick)()},hideTaskView(){return y.showRightView=!1,y.showLeftView||(y.showLeftView=!0),(0,n.nextTick)()},closeTaskBarTooltip(){const{barTipStore:e}=y,t=be.value;return e.visible&&(Object.assign(e,{row:null,content:null,visible:!1,params:{}}),t&&t.close&&t.close()),(0,n.nextTick)()},scrollToDateView(e){const t=Pe.value;if(t){const a=t.reactData,p=t.internalData,{viewCellWidth:m}=a,{visibleColumn:E,elemStore:H}=p,j=B.default.toStringDate(e).getTime(),Q=B.default.findIndexOf(E,K=>j===K.dateObj.date.getTime()),U=le(H["main-body-scroll"]);Q>-1&&U&&(U.scrollLeft=B.default.floor(Q*m))}return(0,n.nextTick)()},scrollToTaskView(e){const t=Z.value;if(t){const a=B.default.isString(e)||B.default.isNumber(e)?e:t.getRowid(e);return t.scrollToRow(e).then(()=>{const p=Pe.value;if(p){const m=p.reactData,E=p.internalData,{viewCellWidth:H}=m,{chartMaps:_,elemStore:j}=E,Q=a?_[a]:null;if(Q){const U=le(j["main-body-scroll"]);U&&(U.scrollLeft=B.default.floor(Q.oLeftSize*H))}}})}return(0,n.nextTick)()},getCriticalPath(){const{criticalRowIds:e,criticalLinks:t}=y,{criticalRowMaps:a}=P;return{rowIds:e.slice(0),rows:Array.from(a.values()),links:t.slice(0)}}},R={extendTableMethods:pt,callSlot(e,t){return e&&(B.default.isString(e)&&(e=W[e]||null),B.default.isFunction(e))?Xr(e(t)):[]},getExcludeHeight(){const{height:e}=o,{isZMax:t}=y,a=ae.value;if(a){const p=dt.value,m=A.value,E=te.value,H=se.value,_=Ae.value,j=a.parentElement;let Q=0;return j&&(e==="100%"||e==="auto")&&(Q=t?0:er(j)),Q+er(a)+aa(p)+aa(m)+aa(E)+aa(H)+aa(_)}return 0},getParentElem(){const e=ae.value;if(!e)return null;let t=e.parentElement;return t&&So(t,"vxe-scrollbar--view-inner")&&(t=t.parentElement),t},getParentHeight(){if(ae.value){const t=b.getParentElem();return(y.isZMax?Nr().visibleHeight:t?B.default.toNumber(getComputedStyle(t).height):0)-R.getExcludeHeight()}return 0},triggerToolbarCommitEvent(e,t){const{code:a}=e;if(a){const p=["reload","delete","save"].includes(a);p&&(P.uFoot=!0);const m=b.commitProxy(e,t).then(E=>{E&&E.status&&["query","reload","delete","save"].includes(a)&&b.dispatchEvent(a==="delete"||a==="save"?`proxy-${a}`:"proxy-query",{...E,isReload:a==="reload"},t)});return P.uFoot=!1,p&&u(),m}return(0,n.nextTick)()},triggerToolbarBtnEvent(e,t){b.triggerToolbarCommitEvent(e,t),b.dispatchEvent("toolbar-button-click",{code:e.code,button:e},t)},triggerToolbarTolEvent(e,t){b.triggerToolbarCommitEvent(e,t),b.dispatchEvent("toolbar-tool-click",{code:e.code,tool:e},t)},triggerZoomEvent(e){b.zoom(),b.dispatchEvent("zoom",{type:y.isZMax?"max":"revert"},e)},handleTaskCellClickEvent(e,t){const a=Z.value;if(a){const p=a.props,{highlightCurrentRow:m}=p,E=a.reactData,{radioColumn:H,checkboxColumn:_}=E,{computeRadioOpts:j,computeCheckboxOpts:Q,computeRowOpts:U}=a.getComputeMaps(),K=j.value,pe=Q.value,Lt=U.value,{row:Me}=t;(Lt.isCurrent||m)&&a.triggerCurrentRowEvent(e,Object.assign({$table:a,rowIndex:a.getRowIndex(Me),$rowIndex:a.getVMRowIndex(Me)},t)),H&&K.trigger==="row"&&a.triggerRadioRowEvent(e,t),_&&pe.trigger==="row"&&a.handleToggleCheckRowEvent(e,t)}y.isActiveCeLe=!1,y.activeBarRowid=null,y.activeLink=null,b.dispatchEvent("task-cell-click",t,e)},handleTaskCellDblclickEvent(e,t){b.dispatchEvent("task-cell-dblclick",t,e)},handleTaskBarClickEvent(e,t){const a=Z.value,p=st.value,{linkCreatable:m}=p,{row:E}=t;y.isActiveCeLe=!!m,y.activeBarRowid=a?a.getRowid(E):E,y.activeLink=null,b.dispatchEvent("task-bar-click",t,e)},handleTaskBarDblclickEvent(e,t){b.dispatchEvent("task-bar-dblclick",t,e)},triggerTaskBarTooltipEvent(e,t){const{barTipStore:a,activeLink:p}=y,{dragBarRow:m,dragLineRow:E}=P;if(m||E||p)return;const H=vt.value,_=At.value,{contentMethod:j}=H,{row:Q}=t;let U=Za(B.default.get(Q,_));if(j){const pe=j(t);B.default.eqNull(pe)||(U=`${pe}`)}D(a.row!==Q);const K=Za(U);Object.assign(a,{row:Q,visible:!0,content:K,params:t}),(0,n.nextTick)(()=>{const pe=be.value;pe&&(pe.openByEvent?pe.openByEvent(e,e.currentTarget,K):pe.open&&pe.open(e.currentTarget,K))})},handleTaskBarTooltipLeaveEvent(){const e=vt.value;let t=be.value;t&&t.setActived&&t.setActived(!1),e.enterable?P.barTipTimeout=setTimeout(()=>{t=be.value,t&&t.isActived&&!t.isActived()&&b.closeTaskBarTooltip()},e.leaveDelay):b.closeTaskBarTooltip()},handleTaskHeaderContextmenuEvent(e,t){const a=Z.value;if(a){const p=a.props,{menuConfig:m}=p;ne(m)&&(e.stopPropagation(),a.handleOpenMenuEvent(e,"header",t),a.dispatchEvent("header-cell-menu",t,e))}},handleTaskBodyContextmenuEvent(e,t){const a=Z.value;if(a){const p=a.props,{menuConfig:m}=p;ne(m)&&(e.stopPropagation(),a.handleOpenMenuEvent(e,"body",t),a.dispatchEvent("cell-menu",t,e))}},handleTaskFooterContextmenuEvent(e,t){const a=Z.value;if(a){const p=a.props,{menuConfig:m}=p;ne(m)&&(e.stopPropagation(),a.handleOpenMenuEvent(e,"footer",t),a.dispatchEvent("footer-cell-menu",t,e))}},handleTaskBarContextmenuEvent(e,t){const a=Z.value;if(a){const p=a.props,{menuConfig:m}=p;ne(m)&&(e.stopPropagation(),a.handleOpenMenuEvent(e,"body",t),a.dispatchEvent("cell-menu",t,e))}}};Object.assign(b,gt,$,R,{loadColumn(e){const t=Z.value;return B.default.eachTree(e,a=>{const{type:p}=a;a.slots&&B.default.each(a.slots,m=>{B.default.isFunction(m)||W[m]||xt("vxe.error.notSlot",[m])}),p==="expand"&&xt("vxe.error.errProp",["type=expand","type=seq,radio,checkbox,html"])}),y.currLeftSpacing=0,y.currRightSpacing=0,t?t.loadColumn(e):(0,n.nextTick)()},reloadColumn(e){return b.clearAll(),b.loadColumn(e)}});const x=()=>{const{formConfig:e,proxyConfig:t}=o,{formData:a}=y,p=V.value,m=he.value;if(e&&ne(m)||W.form){let E=[];if(W.form)E=W.form({$grid:null,$gantt:b});else if(m.items){const H={};if(!m.inited){m.inited=!0;const _=p.beforeItem;p&&_&&m.items.forEach(j=>{_({$grid:null,$gantt:b,item:j})})}m.items.forEach(_=>{B.default.each(_.slots,j=>{j&&!B.default.isFunction(j)&&W[j]&&(H[j]=W[j])})}),Ne&&E.push((0,n.h)(Ne,{ref:ie,...Object.assign({},m,{data:t&&ne(p)&&p.form?a:m.data}),onSubmit:Ea,onReset:$o,onSubmitInvalid:Dt,onCollapse:r},H))}return(0,n.h)("div",{ref:dt,key:"form",class:"vxe-gantt--form-wrapper"},E)}return yt(b)},T=()=>{const{toolbarConfig:e}=o,t=ke.value,a=W.toolbar;if(e&&ne(t)||a){let p=[];if(W.toolbar)p=W.toolbar({$grid:null,$gantt:b});else{const m=t.slots,E={};if(m){const H=s(m,"buttons"),_=s(m,"buttonPrefix"),j=s(m,"buttonSuffix"),Q=s(m,"tools"),U=s(m,"toolPrefix"),K=s(m,"toolSuffix");H&&(E.buttons=H),_&&(E.buttonPrefix=_),j&&(E.buttonSuffix=j),Q&&(E.tools=Q),U&&(E.toolPrefix=U),K&&(E.toolSuffix=K)}p.push((0,n.h)(Wt,{ref:at,...t,slots:void 0},E))}return(0,n.h)("div",{ref:A,key:"toolbar",class:"vxe-gantt--toolbar-wrapper"},p)}return yt(b)},L=()=>{const e=W.top;return e?(0,n.h)("div",{ref:te,key:"top",class:"vxe-gantt--top-wrapper"},e({$grid:null,$gantt:b})):yt(b)},I=()=>{const e=W.left;return e?(0,n.h)("div",{class:"vxe-gantt--left-wrapper"},e({$grid:null,$gantt:b})):yt(b)},z=()=>{const e=W.right;return e?(0,n.h)("div",{class:"vxe-gantt--right-wrapper"},e({$grid:null,$gantt:b})):yt(b)},Y=()=>{const{proxyConfig:e}=o,t=sa.value,a=V.value,p=Object.assign({},C),m=W.empty,E=W.loading,H=W.rowDragIcon||W["row-drag-icon"],_=W.columnDragIcon||W["column-drag-icon"],j=W.headerTooltip||W["header-tooltip"],Q=W.tooltip,U=W.footerTooltip||W["footer-tooltip"];e&&ne(a)&&(a.sort&&(p.onSortChange=to,p.onClearAllSort=Ro),a.filter&&(p.onFilterChange=oo,p.onClearAllFilter=Zo));const K={};return m&&(K.empty=m),E&&(K.loading=E),H&&(K.rowDragIcon=H),_&&(K.columnDragIcon=_),j&&(K.headerTooltip=j),Q&&(K.tooltip=Q),U&&(K.footerTooltip=U),(0,n.h)("div",{ref:Xe,class:"vxe-gantt--table-wrapper"},[(0,n.h)(Oe,{ref:Z,...t,...p},K)])},fe=()=>W.bottom?(0,n.h)("div",{ref:se,key:"bottom",class:"vxe-gantt--bottom-wrapper"},W.bottom({$grid:null,$gantt:b})):yt(b),ce=()=>{const{proxyConfig:e,pagerConfig:t}=o,a=V.value,p=re.value,m=W.pager;return t&&ne(p)||W.pager?(0,n.h)("div",{ref:Ae,key:"pager",class:"vxe-gantt--pager-wrapper"},m?m({$grid:null,$gantt:b}):[N?(0,n.h)(N,{ref:Ee,...p,...e&&ne(a)?y.tablePage:{},onPageChange:ho},v(p.slots)):yt(b)]):yt(b)},ue=()=>(0,n.h)("div",{ref:ft,class:"vxe-gantt--view-wrapper"},[(0,n.h)(pn,{ref:Pe})]),X=()=>{const{showLeftView:e,showRightView:t}=y,a=ht.value,{enabled:p,resize:m,showCollapseTableButton:E,showCollapseTaskButton:H}=a;if(!p)return yt(b);const _=m&&e&&t,j={};return _&&(j.onMousedown=S),(0,n.h)("div",{class:["vxe-gantt--view-split-bar",{"is--resize":_}]},[(0,n.h)("div",{class:"vxe-gantt--view-split-bar-handle",...j}),E||H?(0,n.h)("div",{class:"vxe-gantt--view-split-bar-btn-wrapper"},[E&&t?(0,n.h)("div",{class:["vxe-gantt--view-split-bar-action-btn",e?"is--prev":"is--next"],onClick:d},[(0,n.h)("i",{class:e?ka().GANTT_VIEW_LEFT_OPEN:ka().GANTT_VIEW_LEFT_CLOSE})]):yt(b),H&&e?(0,n.h)("div",{class:["vxe-gantt--view-split-bar-action-btn",t?"is--next":"is--prev"],onClick:k},[(0,n.h)("i",{class:t?ka().GANTT_VIEW_RIGHT_OPEN:ka().GANTT_VIEW_RIGHT_CLOSE})]):yt(b)]):yt(b)])},q=e=>{const{showLeftView:t,showRightView:a}=y,p=we.value,m=ht.value,E=Kt.value,H=Eo.value,_=Go.value,j=Wo.value,{autoHideCollapseButton:Q}=m,U=[];return e.forEach(K=>{switch(K){case"Form":U.push(x());break;case"Toolbar":U.push(T());break;case"Top":U.push(L());break;case"Gantt":U.push((0,n.h)("div",{ref:qe,key:"tv",class:["vxe-gantt--gantt-container",`sx-pos--${E?"top":"bottom"}`,`sy-pos--${H?"left":"right"}`,{"is--virtual-scrollbar":p,"ov-x--auto-hide":p&&_,"ov-y--auto-hide":p&&j,"show--left":t,"hide--left":!t,"show--right":a,"hide--right":!a,"is--ah-split-btn":Q}]},[I(),Y(),X(),ue(),z(),(0,n.h)("div",{ref:Fe}),(0,n.h)("div",{ref:Qe,class:"vxe-gantt--resizable-split-tip"},[(0,n.h)("div",{class:"vxe-gantt--resizable-split-tip-number"},[(0,n.h)("div",{class:"vxe-gantt--resizable-split-number-left"}),(0,n.h)("div",{class:"vxe-gantt--resizable-split-number-right"})])]),(0,n.h)("div",{class:"vxe-gantt--border-line"})]));break;case"Bottom":U.push(fe());break;case"Pager":U.push(ce());break;default:xt("vxe.error.notProp",[`layouts -> ${K}`]);break}}),U},ye=()=>{const{barTipStore:e}=y,t=Bo.value,{headKeys:a,bodyKeys:p,footKeys:m}=t,E=vt.value,H=W.asideLeft||W["aside-left"],_=W.asideRight||W["aside-right"],j=W.taskBarTooltip||W["task-bar-tooltip"];return[(0,n.h)("div",{class:"vxe-gantt--layout-header-wrapper"},q(a)),(0,n.h)("div",{class:"vxe-gantt--layout-body-wrapper"},[H?(0,n.h)("div",{class:"vxe-gantt--layout-aside-left-wrapper"},H({})):yt(b),(0,n.h)("div",{class:"vxe-gantt--layout-body-content-wrapper"},q(p)),_?(0,n.h)("div",{class:"vxe-gantt--layout-aside-right-wrapper"},_({})):yt(b)]),(0,n.h)("div",{class:"vxe-gantt--layout-footer-wrapper"},q(m)),(0,n.h)("div",{ref:Re}),(0,n.h)("div",{},[(0,n.h)(Yt,{key:"gtp",ref:be,theme:E.theme,enterable:E.enterable,enterDelay:E.enterDelay,leaveDelay:E.leaveDelay,useHtml:B.default.isBoolean(E.useHtml)?E.useHtml:E.useHTML,width:E.width,height:E.height,minWidth:E.minWidth,minHeight:E.minHeight,maxWidth:E.maxWidth,maxHeight:E.maxHeight,isArrow:!1},j?{content:()=>{const{row:Q,content:U}=e;return Q?(0,n.h)("div",{},j(Object.assign({tooltipContent:U,$gantt:b},e.params))):yt(b)}}:{})])]},Vt=()=>{const{showLeftView:e,showRightView:t,overflowY:a,overflowX:p,showSplitAnimat:m}=y,E=It.value,H=we.value,_=Do.value,j=Jt.value,Q=ht.value,U=po.value,K=Kt.value,pe=Eo.value;return(0,n.h)("div",{ref:ae,class:["vxe-gantt",`border--${U}`,`sx-pos--${K?"top":"bottom"}`,`sy-pos--${pe?"left":"right"}`,{[`size--${E}`]:E,"is--virtual-scrollbar":H,"is--round":o.round,"show--animat":Q.animation,"is--maximize":y.isZMax,"is--loading":j,"is--animat":m,"show--left":e,"hide--left":!e,"show--right":t,"hide--right":!t,"is--scroll-y":a,"is--scroll-x":p}],style:_},ye())},lt=(0,n.ref)(0);(0,n.watch)(()=>o.columns?o.columns.length:-1,()=>{lt.value++}),(0,n.watch)(()=>o.columns,()=>{lt.value++}),(0,n.watch)(lt,()=>{(0,n.nextTick)(()=>b.loadColumn(o.columns||[]))}),(0,n.watch)(()=>o.toolbarConfig,()=>{Ue()}),(0,n.watch)(Ct,()=>{Et("currentPage")}),(0,n.watch)(Qo,()=>{Et("pageSize")}),(0,n.watch)(fo,()=>{Et("total")}),(0,n.watch)(()=>o.proxyConfig,()=>{w()});const Ot=(0,n.ref)(0);return(0,n.watch)(Ht,()=>{Mt(),Ot.value++}),(0,n.watch)(qo,()=>{Ot.value++}),(0,n.watch)(Ot,()=>{b.refreshTaskView()}),(0,n.watch)(Fo,()=>{b.handleUpTaskLinkData&&b.handleUpTaskLinkData()}),vn.forEach(e=>{const{setupGantt:t}=e;if(t){const a=t(b);a&&B.default.isObject(a)&&Object.assign(b,a)}}),b.handleTaskLoadLinks&&o.links&&b.handleTaskLoadLinks(o.links),Mt(),Et(),(0,n.onMounted)(()=>{const e=xe.value,{barStyle:t}=e;t&&(t.top&&Ao("vxe.error.delProp",["task-bar-subview-config.barStyle.top","task-bar-subview-config.barStyle.style.top"]),t.backgroundColor&&Ao("vxe.error.delProp",["task-bar-subview-config.barStyle.backgroundColor","task-bar-subview-config.barStyle.style.backgroundColor"])),b.handleUpTaskLinkData||(o.links&&Ao("vxe.error.notProp",["links"]),o.taskLinkConfig&&Ao("vxe.error.notProp",["task-link-config"])),(0,n.nextTick)(()=>{const{columns:a}=o,p=V.value;if(o.formConfig&&(Ne||xt("vxe.error.reqComp",["vxe-form"])),o.pagerConfig&&(N||xt("vxe.error.reqComp",["vxe-pager"])),o.treeConfig&&o.links){const m=Z.value;if(m){const{computeTreeOpts:E}=m.getComputeMaps();E.value.transform||xt("vxe.error.notSupportProp",["links","tree-config.transform=false","tree-config.transform=true"])}}p.props&&Ao("vxe.error.delProp",["proxy-config.props","proxy-config.response"]),o.expandConfig&&Ao("vxe.error.notProp",["expand-config"]),a&&a.length&&b.loadColumn(a),Ue(),w()}),$e(),Ya.on(b,"keydown",g)}),(0,n.onBeforeUnmount)(()=>{B.default.assign(y,yr()),B.default.assign(P,xr())}),(0,n.onUnmounted)(()=>{Ya.off(b,"keydown")}),b.renderVN=Vt,(0,n.provide)("$xeGrid",null),(0,n.provide)("$xeGantt",b),b},render(){return this.renderVN()}}),ra=Object.assign({},Ca,{install(o){Br(),o.component(Ca.name,Ca)}});$a.VxeUI.dynamicApp&&$a.VxeUI.dynamicApp.use(ra),$a.VxeUI.component(Ca);var Sr=ra,Sn=ra,kr=ge("@vxe-ui/core"),{setConfig:kn,setIcon:Tn}=kr.VxeUI;kr.VxeUI.ganttVersion="4.9.7";var Uo="yyyy-MM-dd",Na="yyyy-MM-dd HH:mm:ss";kn({gantt:{formConfig:{enabled:!0},pagerConfig:{enabled:!0},toolbarConfig:{enabled:!0},proxyConfig:{enabled:!0,autoLoad:!0,showLoading:!0,showResponseMsg:!0,showActionMsg:!0,response:{list:null,result:"result",total:"page.total",message:"message"}},taskBarTooltipConfig:{enterable:!0},taskLinkConfig:{enabled:!0,isHover:!0,showArrow:!0},taskViewScaleConfig:{year:{valueFormat:Uo},quarter:{valueFormat:Uo},month:{valueFormat:Uo},week:{startDay:1,valueFormat:Uo},day:{valueFormat:Uo},date:{valueFormat:Uo},hour:{valueFormat:Na},minute:{valueFormat:Na},second:{valueFormat:Na}},taskViewConfig:{showNowLine:!0,gridding:{leftSpacing:1,rightSpacing:1}},taskSplitConfig:{enabled:!0,resize:!0,autoHideCollapseButton:!0,showCollapseTableButton:!0,showCollapseTaskButton:!0},taskBarSubviewConfig:{},taskBarMoveConfig:{isLimitByLink:!0},taskBarResizeConfig:{minWidthSize:.5,isLimitByLink:!0},taskBarMoveTooltipConfig:{enterable:!0,enterDelay:0},taskBarResizeTooltipConfig:{enterable:!0,enterDelay:0}}});var na="vxe-icon-";Tn({GANTT_VIEW_LEFT_OPEN:na+"arrow-left",GANTT_VIEW_LEFT_CLOSE:na+"arrow-right",GANTT_VIEW_RIGHT_OPEN:na+"arrow-right",GANTT_VIEW_RIGHT_CLOSE:na+"arrow-left",GANTT_VIEW_TASK_MILESTONE:na+"square-fill rotate45"}),Ua(fa,ge("@vxe-ui/core"));var{setConfig:Cn}=Wr.VxeUI,En=[Sn];function Tr(o,F){Cn(F),En.forEach(W=>o.use(W))}Ua(Ra,fa,ca.exports);var Dn=fa;return ca.exports});
|
|
1
|
+
(function(no,ta){typeof module=="object"&&typeof module.exports=="object"?module.exports=ta(require("vue"),require("xe-utils"),require("@vxe-ui/core"),require("vxe-table")):typeof define=="function"&&define.amd?define(["vue","xe-utils","@vxe-ui/core","vxe-table"],ta):(no=typeof globalThis!="undefined"?globalThis:no||self,no.VxeUIGantt=ta(no.Vue,no.XEUtils,no.VxeUI,no.VxeUITable))})(this,function(no,ta,Rr,$r){var Oa={vue:no,"xe-utils":ta,"@vxe-ui/core":Rr,"vxe-table":$r},ge=function(o){return Oa[o]!==void 0?Oa[o]:typeof window!="undefined"&&window[o]?window[o]:typeof globalThis!="undefined"&&globalThis[o]?globalThis[o]:Oa[o]},ca={exports:{}},On=ca.exports,Vr=Object.create,ua=Object.defineProperty,Mr=Object.getOwnPropertyDescriptor,Lr=Object.getOwnPropertyNames,Fr=Object.getPrototypeOf,Pr=Object.prototype.hasOwnProperty,Ua=(o,F)=>{for(var W in F)ua(o,W,{get:F[W],enumerable:!0})},da=(o,F,W,me)=>{if(F&&typeof F=="object"||typeof F=="function")for(let ee of Lr(F))!Pr.call(o,ee)&&ee!==W&&ua(o,ee,{get:()=>F[ee],enumerable:!(me=Mr(F,ee))||me.enumerable});return o},Ga=(o,F,W)=>(da(o,F,"default"),W&&da(W,F,"default")),yo=(o,F,W)=>(W=o!=null?Vr(Fr(o)):{},da(F||!o||!o.__esModule?ua(W,"default",{value:o,enumerable:!0}):W,o)),Wr=o=>da(ua({},"__esModule",{value:!0}),o),Ra={};Ua(Ra,{Gantt:()=>kr,VxeGantt:()=>ra,VxeGanttDependencyType:()=>wa,VxeGanttTaskType:()=>Ba,VxeUI:()=>$a.VxeUI,default:()=>Dn,install:()=>Cr}),ca.exports=Wr(Ra);var fa={};Ua(fa,{Gantt:()=>kr,VxeGantt:()=>ra,VxeGanttDependencyType:()=>wa,VxeGanttTaskType:()=>Ba,VxeUI:()=>$a.VxeUI,install:()=>Cr});var $a=ge("@vxe-ui/core"),Va=ge("@vxe-ui/core"),pa=ge("@vxe-ui/core"),Mo=ge("@vxe-ui/core"),{log:ga}=Mo.VxeUI,Ma="gantt v4.9.8";function Ir(o){const F=Mo.VxeUI.uiVersion?`ui v${Mo.VxeUI.uiVersion}`:"",W=Mo.VxeUI.tableVersion?`table v${Mo.VxeUI.tableVersion}`:"",me=Mo.VxeUI.designVersion?`design v${Mo.VxeUI.designVersion}`:"",ee=[F,W,Ma,me].filter(Ne=>Ne).join(" ");return{warnLog:ga.create("warn",ee+"] ["+o),errLog:ga.create("error",ee+"] ["+o)}}var Rn=ga.create("warn",Ma),qa=ga.create("error",Ma);function Br(){pa.VxeUI.checkVersion?pa.VxeUI.checkVersion(pa.VxeUI.tableVersion,4,23)||qa("vxe.error.errorVersion",[`vxe-table@${pa.VxeUI.tableVersion||"?"}`,"vxe-table v4.23+"]):qa("Requires vxe-table v4.23+")}var n=ge("vue"),zr=ge("vue"),Yo=zr.defineComponent,B=yo(ge("xe-utils")),La=yo(ge("xe-utils")),Qa=ge("@vxe-ui/core"),{zIndex:Za}=Qa.VxeUI;function ne(o){return o&&o.enabled!==!1}function oa(o,F){return F&&(o?F.enabled!==!1:F.enabled)}function Hr(o){return o==null||o===""}function _r(){return Za.next()}function jr(){return Za.getLast()}function Ka(o,F){return""+(Hr(o)?F?Qa.VxeUI.getConfig().emptyCell:"":o)}function Yr(o){return o===""||La.default.eqNull(o)}function ha(o){return Yr(o)?"":o}function Ja(o,F){return o?La.default.isFunction(o)?o(F):o:""}function ot(o,F){return La.default.eqNull(o)?F:o}var Fa=yo(ge("xe-utils")),Pa={};function er(o){return Pa[o]||(Pa[o]=new RegExp(`(?:^|\\s)${o}(?!\\S)`,"g")),Pa[o]}function So(o,F){return o?o.classList?o.classList.contains(F):!!(o.className&&o.className.match&&o.className.match(er(F))):!1}function va(o,F){o&&So(o,F)&&(o.className=o.className.replace(er(F),""))}function Wa(o,F){o&&!So(o,F)&&(va(o,F),o.className=`${o.className} ${F}`)}function Lo(o,F="px"){return Fa.default.isNumber(o)||/^\d+$/.test(`${o}`)?`${o}${F}`:`${o||""}`}function Nr(){const o=document.documentElement,F=document.body;return{scrollTop:o.scrollTop||F.scrollTop,scrollLeft:o.scrollLeft||F.scrollLeft,visibleHeight:o.clientHeight||F.clientHeight,visibleWidth:o.clientWidth||F.clientWidth}}function aa(o){return o?o.offsetHeight:0}function tr(o){if(o){const F=getComputedStyle(o),W=Fa.default.toNumber(F.paddingTop),me=Fa.default.toNumber(F.paddingBottom);return W+me}return 0}function or(o,F){o&&(o.scrollTop=F)}function No(o,F){o&&(o.scrollLeft=F)}var Ar=yo(ge("xe-utils"));function Xr(o){return Ar.default.isArray(o)?o:o?[o]:[]}var Se=ge("@vxe-ui/core"),ar=["ready","init-rendered","data-rendered","update:data","keydown-start","keydown","keydown-end","paste","copy","cut","undo","redo","context-menu","columns-change","data-change","footer-data-change","current-change","current-row-change","current-row-disabled","current-column-change","current-column-disabled","radio-change","checkbox-change","checkbox-all","checkbox-range-start","checkbox-range-change","checkbox-range-end","checkbox-range-select","cell-click","cell-dblclick","cell-menu","cell-mouseenter","cell-mouseleave","cell-selected","cell-delete-value","cell-backspace-value","header-cell-click","header-cell-dblclick","header-cell-menu","footer-cell-click","footer-cell-dblclick","footer-cell-menu","clear-merge","sort-change","clear-sort","clear-all-sort","filter-change","filter-visible","clear-filter","clear-all-filter","resizable-change","column-resizable-change","row-resizable-change","toggle-row-group-expand","toggle-row-expand","toggle-tree-expand","menu-click","edit-closed","row-dragstart","row-dragover","row-dragend","row-remove-dragend","row-insert-dragend","column-dragstart","column-dragover","column-dragend","enter-append-row","tab-append-row","edit-actived","edit-activated","edit-disabled","valid-error","scroll","scroll-boundary","custom","custom-open","custom-close","custom-cancel","custom-reset","custom-confirm","custom-visible-change","custom-visible-all","custom-fixed-change","custom-sort-change","custom-align-change","custom-header-align-change","custom-footer-align-change","change-fnr","open-fnr","show-fnr","hide-fnr","fnr-change","fnr-find","fnr-find-all","fnr-replace","fnr-replace-all","cell-area-copy","cell-area-cut","cell-area-paste","cell-area-merge","clear-cell-area-selection","clear-cell-area-merge","header-cell-area-selection","cell-area-selection-invalid","cell-area-selection-start","cell-area-selection-drag","cell-area-selection-end","cell-area-extension-start","cell-area-extension-drag","cell-area-extension-end","cell-area-extension-fill","cell-area-selection-all-start","cell-area-selection-all-end","cell-area-arrows-start","cell-area-arrows-end","cell-area-fill-copy","active-cell-change-start","active-cell-change-end"],Ur=[...ar,"page-change","form-submit","form-submit-invalid","form-reset","form-collapse","form-toggle-collapse","proxy-query","proxy-delete","proxy-save","toolbar-button-click","toolbar-tool-click","zoom"],Gr=[...Ur,"task-cell-click","task-cell-dblclick","task-bar-mouseenter","task-bar-mouseleave","task-bar-click","task-bar-dblclick","task-view-cell-click","task-view-cell-dblclick","task-move-start","task-move-drag","task-move-end","task-resize-start","task-resize-drag","task-resize-end","task-link-click","task-link-dblclick","task-link-remove"];function le(o){if(o){const F=o.value;if(F)return F.$el||F}return null}function rr(o,F,W,me){return o.resizeHeight||F.height||W.height||o.height||me}function nr(o,F){return o?F*o.oLeftSize:0}function sr(o,F){return o&&o.oWidthSize?Math.max(1,o?Math.floor(F*o.oWidthSize)-1:0):0}var qr={milestone:!0,subview:!0};function ma(o){return o==="milestone"}function ba(o){return o==="subview"}function Ia(o){return qr[o]?o:"default"}var O=ge("vue"),lr=ge("@vxe-ui/core"),wa=(o=>(o[o.FinishToStart=0]="FinishToStart",o[o.StartToFinish=1]="StartToFinish",o[o.StartToStart=2]="StartToStart",o[o.FinishToFinish=3]="FinishToFinish",o))(wa||{}),Ba=(o=>(o.Milestone="milestone",o.Subview="subview",o))(Ba||{}),i=yo(ge("xe-utils")),ct=ge("vue"),Qr=ge("@vxe-ui/core"),ir=yo(ge("xe-utils")),{getI18n:so}=Qr.VxeUI,Zr="gantt",Kr="header",Jr=Yo({name:"VxeGanttViewHeader",setup(){const o=(0,ct.inject)("$xeGantt",{}),F=(0,ct.inject)("$xeGanttView",{}),{computeTaskViewOpts:W,computeScaleStep:me,computeMinScale:ee}=o.getComputeMaps(),{reactData:Ne,internalData:N}=F,Oe=(0,ct.ref)(),Wt=(0,ct.ref)(),Yt=(0,ct.ref)(),St=(0,ct.ref)(),It=()=>{const{headerGroups:we,viewCellWidth:y}=Ne,{todayDateMaps:P,visibleColumn:ae}=N,Z=W.value,ie=ee.value,at=me.value,{showNowLine:Ee}=Z;return(0,ct.h)("div",{ref:Oe,class:"vxe-gantt-view--header-wrapper"},[(0,ct.h)("div",{ref:Wt,class:"vxe-gantt-view--header-inner-wrapper",onScroll:F.triggerHeaderScrollEvent},[(0,ct.h)("div",{ref:St,class:"vxe-body--x-space"}),(0,ct.h)("table",{ref:Yt,class:"vxe-gantt-view--header-table"},[(0,ct.h)("colgroup",{},ae.map((qe,Fe)=>(0,ct.h)("col",{key:Fe,style:{width:`${y}px`}}))),(0,ct.h)("thead",{},we.map(({scaleItem:qe,columns:Fe},Pe)=>{const{type:Re,titleFormat:dt,titleMethod:A,headerCellStyle:te,slots:se}=qe,Ae=se?se.title:null,Xe=Pe===we.length-1,ft=Xe&&Ee?P[Re]:null;return(0,ct.h)("tr",{key:Pe},Fe.map((be,Qe)=>{const{field:pt,childCount:gt,dateObj:M,startDateObj:V,endDateObj:Ze}=be;let re=`${be.title}`;(Xe||ie&&(ie.type==="date"||ie.type==="day")&&(Re==="date"||Re==="day"))&&at>1?re=so(`vxe.gantt.stepFormat.${Re}`,{start:V,end:Ze,eStartLabel:so(`vxe.gantt.dayss.w${V.e}`),eEndLabel:so(`vxe.gantt.dayss.w${Ze.e}`)}):Re==="day"?Pe?re=so(`vxe.gantt.tSimpleFormat.${Re}`,{eLabel:so(`vxe.gantt.dayss.w${M.e}`)}):re=so(`vxe.gantt.tFullFormat.${Re}`,{eLabel:so(`vxe.gantt.dayss.w${M.e}`)}):Pe?re=so(`vxe.gantt.tSimpleFormat.${Re}`,M):re=so(`vxe.gantt.tFullFormat.${Re}`,M);let he=re;const ke={source:Zr,type:Kr,column:be,scaleObj:qe,title:re,dateObj:M,startDateObj:V,endDateObj:Ze,$rowIndex:Pe};Ae?he=o.callSlot(Ae,ke):A?he=`${A(ke)}`:dt&&(he=ir.default.toDateString(M.date,dt));let rt={};return te&&(ir.default.isFunction(te)?rt=te(ke)||null:rt=te),(0,ct.h)("th",{key:Qe,class:["vxe-gantt-view--header-column",{"is--now":Ee&&ft&&ft===pt}],colspan:gt||null,title:Ae?null:re,style:rt||void 0,onContextmenu(De){o.handleTaskHeaderContextmenuEvent(De,ke)}},he)}))}))])])])};return(0,ct.onMounted)(()=>{const{elemStore:we}=N,y="main-header-";we[`${y}wrapper`]=Oe,we[`${y}scroll`]=Wt,we[`${y}table`]=Yt,we[`${y}xSpace`]=St}),(0,ct.onUnmounted)(()=>{const{elemStore:we}=N,y="main-header-";we[`${y}wrapper`]=null,we[`${y}scroll`]=null,we[`${y}table`]=null,we[`${y}xSpace`]=null}),It}}),Le=ge("vue"),cr=yo(ge("xe-utils")),J=ge("vue"),en=ge("@vxe-ui/core"),ut=yo(ge("xe-utils")),{getIcon:tn,renderEmptyElement:lo}=en.VxeUI,ur="gantt",dr="chart",on=Yo({name:"VxeGanttViewChart",setup(){const o=(0,J.inject)("$xeGantt",{}),F=(0,J.inject)("$xeGanttView",{}),{props:W,context:me,reactData:ee,internalData:Ne}=o,{reactData:N,internalData:Oe}=F,{computeProgressField:Wt,computeTitleField:Yt,computeTypeField:St,computeTaskBarOpts:It,computeScaleUnit:we,computeTaskLinkOpts:y,computeTaskBarMilestoneOpts:P,computeTaskBarSubviewOpts:ae}=o.getComputeMaps(),{computeNowLineLeft:Z}=F.getComputeMaps(),ie=(0,J.ref)(),at=(0,J.ref)(),Ee=(0,J.ref)(),qe=(0,J.ref)(),Fe=(0,J.ref)(),Pe=(A,te,se,Ae,Xe,ft,be,Qe)=>{const pt=A.reactData,{resizeHeightFlag:gt,pendingRowFlag:M}=pt,V=A.internalData,{fullAllDataRowIdData:Ze,pendingRowMaps:re}=V,{computeCellOpts:he,computeRowOpts:ke,computeDefaultRowHeight:rt}=A.getComputeMaps(),De=he.value,Ke=ke.value,We=rt.value,{computeTreeOpts:nt}=A.getComputeMaps(),st=nt.value,Ie=st.children||st.childrenField,Be=o.context.slots,mt=Be.taskBar||Be["task-bar"],Je=Be.taskBarOverview||Be["task-bar-overview"],{treeConfig:ht,taskBarMilestoneConfig:bt,taskBarSubviewConfig:Te}=W,{activeLink:xe,activeBarRowid:vt,criticalPathFlag:Bt}=ee,{criticalRowMaps:io}=Ne,co=Yt.value,zt=Wt.value,Nt=St.value,uo=It.value,Ht=P.value,Fo=ae.value,{showOverview:At,barStyle:To}=Fo,Co=we.value,de={$gantt:o,source:ur,type:dr,scaleType:Co,row:te,$rowIndex:Xe,rowIndex:Ae,_rowIndex:ft},{showProgress:Xt,showCriticalPath:_t,showContent:Tt,contentMethod:jt,barStyle:Ut,moveable:Po,showTooltip:Go}=uo,Wo=ut.default.isFunction(Ut),Kt=(Ut?Wo?Ut(de)||void 0:Ut:{})||{},Eo=Kt.round,qo=Kt.bgColor,Do=Kt.completedBgColor,Io=Kt.style,sa=Ze[se]||{},Bo=gt?rr(sa,De,Ke,We):0;let Ct=ha(ut.default.get(te,co));const Qo=Xt?Math.min(100,Math.max(0,ut.default.toNumber(ut.default.get(te,zt)))):0,fo=Ia(ut.default.get(te,Nt)),Oo=!!(oa(bt,Ht)&&ma(fo)),Jt={...de},po={},la={width:`${Qo||0}%`};Oo||Wo&&(qo&&(po["--vxe-ui-gantt-view-task-bar-background-color"]=qo),Do&&(po["--vxe-ui-gantt-view-task-bar-completed-background-color"]=Do)),Io&&ut.default.assign(po,Io);let $t=[];if(o.renderGanttTaskBarContent)$t=o.renderGanttTaskBarContent(Jt,{$gantt:o,$table:A,rowid:se});else{const b=!!(oa(Te,Fo)&&ba(fo));jt&&(Ct=ha(jt({row:te,title:Ct,scaleType:Co})));const Vt={};if(Go&&(Vt.onMouseover=Ue=>{const{dragBarRow:$e}=Ne,ze=Object.assign({$event:Ue},Jt);$e||o.triggerTaskBarTooltipEvent(Ue,ze),o.dispatchEvent("task-bar-mouseenter",ze,Ue)},Vt.onMouseleave=Ue=>{const{dragBarRow:$e}=Ne,ze=Object.assign({$event:Ue},Jt);$e||o.handleTaskBarTooltipLeaveEvent(Ue,ze),o.dispatchEvent("task-bar-mouseleave",ze,Ue)}),b&&ht&&be&&be.length)if(Qe)At&&$t.push((0,J.h)("div",{key:"vcso",class:"vxe-gantt-view--chart-subview-wrapper is--overview"},[(0,J.h)("div",{key:se,rowid:se,class:["vxe-gantt-view--chart-subview-row",{"is--progress":Xt,"is--round":Eo,"is--move":Po}]},[(0,J.h)("div",{rowid:se,class:[Je?"vxe-gantt-view--chart-subview-custom-bar":"vxe-gantt-view--chart-subview-bar",`is--${fo}`]},[Je?(0,J.h)("div",{key:"cbc",class:"vxe-gantt-view--chart-subview-custom-bar-content-wrapper"},o.callSlot(Je,de)):(0,J.h)("div",{class:"vxe-gantt-view--chart-subview-bar-content-wrapper"},[Tt?(0,J.h)("div",{class:"vxe-gantt-view--chart-content"},Ct):lo(o)])])])]));else{const Ue=[];ut.default.eachTree(be,$e=>{const ze={$gantt:o,source:ur,type:dr,scaleType:Co,row:$e,$rowIndex:A.getRowIndex($e),rowIndex:A.getVMRowIndex($e),_rowIndex:A.getVTRowIndex($e)},Et=ut.default.isFunction(To),eo=ut.default.assign({},(Ut?Wo?Ut(ze):Ut:{})||{},(To?Et?To(ze):To:{})||{}),go=eo.round,zo=eo.bgColor,ho=eo.completedBgColor,Ho=eo.style,to=A.getRowid($e);let Ro=ha(ut.default.get($e,co));const _o=Xt?Math.min(100,Math.max(0,ut.default.toNumber(ut.default.get($e,zt)))):0,oo=Ia(ut.default.get($e,Nt)),Zo=!!(oa(bt,Ht)&&ma(oo));if(!!(oa(Te,Fo)&&ba(oo)))return;const $o={},Dt={width:`${_o||0}%`};Zo||(zo&&($o["--vxe-ui-gantt-view-task-bar-background-color"]=zo),ho&&(Dt["--vxe-ui-gantt-view-task-bar-completed-background-color"]=ho)),eo.top&&($o.top=eo.top),Ho&&ut.default.assign($o,Ho);const r={...ze};jt&&(Ro=ha(jt({row:$e,title:Ro,scaleType:Co}))),Ue.push((0,J.h)("div",{key:to,rowid:to,class:["vxe-gantt-view--chart-subview-row",`is--${oo}`,{"is--progress":Xt,"is--critical":_t&&Bt&&io.has(to),"is--round":go,"is--move":Po,"row--pending":!!M&&!!re[to]}]},[(0,J.h)("div",{rowid:to,class:[mt?"vxe-gantt-view--chart-subview-custom-bar":"vxe-gantt-view--chart-subview-bar",`is--${oo}`],style:$o,onClick(l){l.stopPropagation(),o.handleTaskBarClickEvent(l,r)},onDblclick(l){l.stopPropagation(),o.handleTaskBarDblclickEvent(l,r)},onMousedown(l){l.stopPropagation(),o.handleTaskBarModnEvent&&o.handleTaskBarModnEvent(l,r)}},[mt?(0,J.h)("div",{key:"cbc",class:"vxe-gantt-view--chart-subview-custom-bar-content-wrapper",...Vt},o.callSlot(mt,r)):(0,J.h)("div",{class:"vxe-gantt-view--chart-subview-bar-content-wrapper",...Vt},[Xt?(0,J.h)("div",{class:"vxe-gantt-view--chart-progress",style:Dt}):lo(o),Tt?(0,J.h)("div",{class:"vxe-gantt-view--chart-content"},Ro):lo(o)])])]))},{children:Ie}),$t.push((0,J.h)("div",{key:"vcsc",class:"vxe-gantt-view--chart-subview-wrapper is--inline"},Ue))}else if(mt)$t.push((0,J.h)("div",{key:"cbc",class:"vxe-gantt-view--chart-custom-bar-content-wrapper",...Vt},o.callSlot(mt,de)));else if(Oo){const{icon:Ue,iconStatus:$e,iconStyle:ze}=Ht,Et={$gantt:o,row:te};$t.push((0,J.h)("div",{key:"vcm",class:"vxe-gantt-view--chart-milestone-wrapper",...Vt},[(0,J.h)("div",{class:["vxe-gantt-view--chart-milestone-icon",$e?`theme--${ut.default.isFunction($e)?$e(Et):$e}`:""],style:ze?Object.assign({},ut.default.isFunction(ze)?ze(Et):ze):void 0},[(0,J.h)("i",{class:(Ue?ut.default.isFunction(Ue)?Ue(Et):Ue:"")||tn().GANTT_VIEW_TASK_MILESTONE})]),Tt?(0,J.h)("div",{class:"vxe-gantt-view--chart-milestone-content"},Ct):lo(o)]))}else $t.push((0,J.h)("div",{key:"vbc",class:"vxe-gantt-view--chart-bar-content-wrapper",...Vt},[Xt?(0,J.h)("div",{class:"vxe-gantt-view--chart-progress",style:la}):lo(o),Tt?(0,J.h)("div",{class:"vxe-gantt-view--chart-content"},Ct):lo(o)]))}return(0,J.h)("div",{key:se,rowid:se,class:["vxe-gantt-view--chart-row",`is--${fo}`,{"is--progress":Xt,"is--critical":_t&&Bt&&io.has(se),"row--pending":!!M&&!!re[se],"is--round":Eo,"is--move":Po}],style:{height:`${Bo}px`},onDragstart(b){Ne.dragBarRow&&b.preventDefault()},onContextmenu(b){o.handleTaskBarContextmenuEvent(b,Jt)}},[(0,J.h)("div",{class:[mt?"vxe-gantt-view--chart-custom-bar":"vxe-gantt-view--chart-bar",`is--${fo}`,{"is--active":vt===se,"active--link":xe&&(se===`${xe.from}`||se===`${xe.to}`)}],style:po,rowid:se,onClick(b){o.handleTaskBarClickEvent(b,de)},onDblclick(b){o.handleTaskBarDblclickEvent(b,de)},onMousedown(b){o.handleTaskBarModnEvent&&o.handleTaskBarModnEvent(b,de)}},$t)])},Re=(A,te)=>{const se=A.props,{treeConfig:Ae}=se,Xe=A.reactData,{treeExpandedFlag:ft}=Xe,be=A.internalData,{fullAllDataRowIdData:Qe,treeExpandedMaps:pt}=be,{computeTreeOpts:gt}=A.getComputeMaps(),M=gt.value,{transform:V}=M,Ze=M.children||M.childrenField,{scrollYLoad:re}=N,he=[];return te.forEach((ke,rt)=>{const De=A.getRowid(ke),Ke=Qe[De]||{};let We=rt,nt=-1;Ke&&(We=Ke.index,nt=Ke._index);let st=!1,Ie=[];Ae&&(Ie=ke[Ze],st=!!ft&&Ie&&Ie.length>0&&!!pt[De]),he.push(Pe(A,ke,De,We,rt,nt,Ie,st)),Ae&&st&&!re&&!V&&he.push(...Re(A,Ie))}),he},dt=()=>{const A=Oe.xeTable,{slots:te}=me,{dragLinkFromStore:se}=ee,{tableData:Ae}=N,Xe=y.value,ft=It.value,be=Z.value,{isCurrent:Qe,isHover:pt}=Xe,{linkCreatable:gt}=ft,M=te.taskNowLine||te["task-now-line"];return(0,J.h)("div",{ref:ie,class:["vxe-gantt-view--chart-wrapper",{"is--cl-drag":se.rowid}]},[be>0?(0,J.h)("div",{ref:Fe,class:"vxe-gantt-view--chart-now-line",style:{left:be+"px"}},M?M({}):[]):lo(o),o.renderGanttTaskChartBefores?(0,J.h)("div",{ref:Ee,class:["vxe-gantt-view--chart-before-wrapper",{"link--current":Qe,"link--hover":pt}]},A&&ne(Xe)?o.renderGanttTaskChartBefores():[]):lo(o),(0,J.h)("div",{ref:at,class:["vxe-gantt-view--chart-task-wrapper",{"link--current":Qe,"link--create":gt}]},A?Re(A,Ae):[]),o.renderGanttTaskChartAfters?(0,J.h)("div",{ref:qe,class:"vxe-gantt-view--chart-after-wrapper"},A&&ne(Xe)?o.renderGanttTaskChartAfters():[]):lo(o)])};return(0,J.onMounted)(()=>{const{elemStore:A}=Oe,te="main-chart-";A[`${te}now-line`]=Fe,A[`${te}task-wrapper`]=at,A[`${te}before-wrapper`]=Ee,A[`${te}after-wrapper`]=qe}),(0,J.onUnmounted)(()=>{const{elemStore:A}=Oe,te="main-chart-";A[`${te}now-line`]=null,A[`${te}task-wrapper`]=null,A[`${te}before-wrapper`]=null,A[`${te}after-wrapper`]=null}),dt}}),xa="gantt",ya="body",an=Yo({name:"VxeGanttViewBody",setup(){const o=(0,Le.inject)("$xeGantt",{}),F=(0,Le.inject)("$xeGanttView",{}),{computeTaskViewOpts:W,computeScaleUnit:me}=o.getComputeMaps(),{reactData:ee,internalData:Ne}=F,N=(0,Le.ref)(),Oe=(0,Le.ref)(),Wt=(0,Le.ref)(),Yt=(0,Le.ref)(),St=(0,Le.ref)(),It=(P,ae,Z,ie,at,Ee,qe,Fe)=>{const Pe=P.reactData,{resizeHeightFlag:Re}=Pe,dt=P.internalData,{fullAllDataRowIdData:A,visibleColumn:te}=dt,{computeCellOpts:se,computeRowOpts:Ae,computeDefaultRowHeight:Xe,computeResizableOpts:ft}=P.getComputeMaps(),be=se.value,Qe=Ae.value,pt=Xe.value,gt=ft.value,{isAllRowDrag:M}=gt,{headerGroups:V}=ee,{todayDateMaps:Ze}=Ne,re=W.value,{showNowLine:he,viewStyle:ke}=re,rt=me.value,{scaleItem:De}=V[V.length-1]||{},{field:Ke,dateObj:We,startDateObj:nt,endDateObj:st}=qe,{cellClassName:Ie,cellStyle:Be}=ke||{},mt=he&&De?Ze[De.type]:null,Je=A[Z]||{},ht=Re?rr(Je,be,Qe,pt):0,bt=[];if(M&&Qe.resizable){const xe={$table:P,$grid:null,$gantt:o,seq:-1,rowid:Z,row:ae,rowIndex:ie,$rowIndex:at,_rowIndex:Ee,column:te[0],columnIndex:0,$columnIndex:0,_columnIndex:0,fixed:"",source:xa,type:ya,isHidden:!1,isEdit:!1,level:-1,visibleData:[],data:[],items:[]};bt.push((0,Le.h)("div",{class:"vxe-gantt-view-cell--row-resizable",onMousedown:vt=>P.handleRowResizeMousedownEvent(vt,xe),onDblclick:vt=>P.handleRowResizeDblclickEvent(vt,xe)}))}const Te={$gantt:o,source:xa,type:ya,scaleType:rt,dateObj:We,startDateObj:nt,endDateObj:st,row:ae,column:qe,$rowIndex:at,rowIndex:ie,_rowIndex:Ee};return(0,Le.h)("td",{key:Ie||Be?Ke:Fe,class:["vxe-gantt-view--body-column",{"is--now":he&&mt===Ke},Ja(Ie,Te)],style:Be?Object.assign({},cr.default.isFunction(Be)?Be(Te):Be,{height:`${ht}px`}):{height:`${ht}px`},onClick(xe){o.handleTaskCellClickEvent(xe,{row:ae,column:qe})},onDblclick(xe){o.handleTaskCellDblclickEvent(xe,{row:ae,column:qe})},onContextmenu(xe){o.handleTaskBodyContextmenuEvent(xe,Te)}},bt)},we=(P,ae)=>{const Z=P.props,{treeConfig:ie,stripe:at,highlightHoverRow:Ee,editConfig:qe}=Z,Fe=P.reactData,{treeExpandedFlag:Pe,selectRadioRow:Re,pendingRowFlag:dt,isRowGroupStatus:A}=Fe,te=P.internalData,{fullAllDataRowIdData:se,treeExpandedMaps:Ae,pendingRowMaps:Xe}=te,{computeRadioOpts:ft,computeCheckboxOpts:be,computeTreeOpts:Qe,computeRowOpts:pt}=P.getComputeMaps(),gt=ft.value,M=be.value,V=pt.value,Ze=Qe.value,{transform:re}=Ze,he=Ze.children||Ze.childrenField,ke=me.value,rt=W.value,{viewStyle:De}=rt,{rowClassName:Ke,rowStyle:We,cellClassName:nt,cellStyle:st}=De||{},{tableColumn:Ie,scrollYLoad:Be}=ee,mt=[];return ae.forEach((Je,ht)=>{const bt=P.getRowid(Je),Te=se[bt]||{},xe={};let vt=ht,Bt=-1;Te&&(vt=Te.index,Bt=Te._index);let io=!1;qe&&(io=P.isInsertByRow(Je)),(V.isHover||Ee)&&(xe.onMouseenter=uo=>{P.triggerHoverEvent(uo,{row:Je,rowIndex:vt})},xe.onMouseleave=()=>{P.clearHoverRow()}),V.drag&&!A&&(!ie||re)&&(xe.onDragstart=P.handleRowDragDragstartEvent,xe.onDragend=P.handleRowDragDragendEvent,xe.onDragover=P.handleRowDragDragoverEvent);const co={$gantt:o,source:xa,type:ya,scaleType:ke,row:Je,rowIndex:vt,$rowIndex:ht,_rowIndex:Bt};mt.push((0,Le.h)("tr",{key:Ke||We||nt||st?bt:ht,class:["vxe-gantt-view--body-row",{"row--stripe":at&&(Bt+1)%2===0,"is--new":io,"row--radio":gt.highlight&&P.eqRow(Re,Je),"row--checked":M.highlight&&P.isCheckedByCheckboxRow(Je),"row--pending":!!dt&&!!Xe[bt]},Ja(Ke,co)],rowid:bt,style:We?cr.default.isFunction(We)?We(co)||void 0:We:void 0,...xe},Ie.map((uo,Ht)=>It(P,Je,bt,vt,ht,Bt,uo,Ht))));let zt=!1,Nt=[];ie&&!Be&&!re&&(Nt=Je[he],zt=!!Pe&&Nt&&Nt.length>0&&!!Ae[bt]),zt&&mt.push(...we(P,Nt))}),mt},y=()=>{const P=F.internalData.xeTable,{tableData:ae,tableColumn:Z,viewCellWidth:ie}=ee;return(0,Le.h)("div",{ref:N,class:"vxe-gantt-view--body-wrapper"},[(0,Le.h)("div",{ref:Oe,class:"vxe-gantt-view--body-inner-wrapper",onScroll:F.triggerBodyScrollEvent,onContextmenu(at){o.handleTaskBodyContextmenuEvent(at,{source:xa,type:ya,rowIndex:-1,$rowIndex:-1,_rowIndex:-1})}},[(0,Le.h)("div",{ref:Yt,class:"vxe-body--x-space"}),(0,Le.h)("div",{ref:St,class:"vxe-body--y-space"}),(0,Le.h)("table",{ref:Wt,class:"vxe-gantt-view--body-table"},[(0,Le.h)("colgroup",{},Z.map((at,Ee)=>(0,Le.h)("col",{key:Ee,style:{width:`${ie}px`}}))),(0,Le.h)("tbody",{},P?we(P,ae):[])]),(0,Le.h)(on)])])};return(0,Le.onMounted)(()=>{const{elemStore:P}=Ne,ae="main-body-";P[`${ae}wrapper`]=N,P[`${ae}scroll`]=Oe,P[`${ae}table`]=Wt,P[`${ae}xSpace`]=Yt,P[`${ae}ySpace`]=St}),(0,Le.onUnmounted)(()=>{const{elemStore:P}=Ne,ae="main-body-";P[`${ae}wrapper`]=null,P[`${ae}scroll`]=null,P[`${ae}table`]=null,P[`${ae}xSpace`]=null,P[`${ae}ySpace`]=null}),y}}),ko=ge("vue"),rn="gantt",nn="footer",sn=Yo({name:"VxeGanttViewFooter",setup(){const o=(0,ko.inject)("$xeGantt",{}),F=(0,ko.inject)("$xeGanttView",{}),{internalData:W}=F,me=(0,ko.ref)(),ee=(0,ko.ref)(),Ne=()=>(0,ko.h)("div",{ref:me,class:"vxe-gantt-view--footer-wrapper",onContextmenu(N){o.handleTaskFooterContextmenuEvent(N,{source:rn,type:nn,$rowIndex:-1})}},[(0,ko.h)("div",{ref:ee,class:"vxe-gantt-view--footer-inner-wrapper"})]);return(0,ko.onMounted)(()=>{const{elemStore:N}=W,Oe="main-footer-";N[`${Oe}wrapper`]=me,N[`${Oe}scroll`]=ee}),(0,ko.onUnmounted)(()=>{const{elemStore:N}=W,Oe="main-footer-";N[`${Oe}wrapper`]=null,N[`${Oe}scroll`]=null}),Ne}}),{getConfig:ln,domUtils:cn,globalResize:un,globalEvents:fr,renderEmptyElement:pr}=lr.VxeUI,{FinishToStart:za,StartToFinish:Ha,StartToStart:_a,FinishToFinish:ja}=wa,dn="gantt",gr=1e3,hr=1e3*60,Ya=1e3*60*60,Zt=Ya*24;function fn(o,F,W){return o+"_"+F+"_"+(W||0)}function vr(){return{xeTable:null,visibleColumn:[],startMaps:{},endMaps:{},chartMaps:{},todayDateMaps:{},elemStore:{},scrollXStore:{preloadSize:0,offsetSize:0,visibleSize:0,visibleStartIndex:0,visibleEndIndex:0,startIndex:0,endIndex:0},thumbDragOffset:0,yThumbTop:0,xThumbLeft:0,lastScrollTop:0,lastScrollLeft:0}}function mr(){return{scrollXLoad:!1,scrollYLoad:!1,overflowY:!0,overflowX:!0,scrollbarWidth:0,scrollbarHeight:0,lastScrollTime:0,lazScrollLoading:!1,yThumbHeight:0,xThumbWidth:0,scrollVMLoading:!1,scrollYHeight:0,scrollYTop:0,isScrollYBig:!1,scrollXLeft:0,scrollXWidth:0,isScrollXBig:!1,minViewDate:null,maxViewDate:null,tableData:[],tableColumn:[],headerGroups:[],viewCellWidth:40}}var Sa=5e6,pn=Yo({name:"VxeGanttView",setup(o,F){const W=i.default.uniqueId(),me=Object.assign({},ln().scrollbar),ee=(0,O.inject)("$xeGantt",{}),Ne=ee.props,N=ee.reactData,Oe=ee.internalData,{computeDateFormat:Wt,computeTaskBarOpts:Yt,computeTaskViewOpts:St,computeStartField:It,computeEndField:we,computeTypeField:y,computeScrollbarOpts:P,computeScaleUnit:ae,computeWeekScale:Z,computeMinScale:ie,computeTaskNowLineOpts:at,computeScaleStep:Ee,computeIsVScrollbar:qe}=ee.getComputeMaps(),Fe=(0,O.ref)(),Pe=(0,O.ref)(),Re=(0,O.ref)(),dt=(0,O.ref)(),A=(0,O.ref)(),te=(0,O.ref)(),se=(0,O.ref)(),Ae=(0,O.ref)(),Xe=(0,O.ref)(),ft=(0,O.ref)(),be=(0,O.ref)(),Qe=(0,O.ref)(),pt=(0,O.ref)(),gt=(0,O.ref)(),M=(0,O.reactive)(mr()),V=vr(),Ze={refElem:Fe,refScrollXHandleElem:dt,refScrollYHandleElem:se},re=(0,O.computed)(()=>qe.value),he=(0,O.computed)(()=>{const r=P.value;return r.x?Object.assign({},r.x,r.xConfig):r.xConfig||{}}),ke=(0,O.computed)(()=>{const r=P.value;return r.y?Object.assign({},r.y,r.yConfig):r.yConfig||{}}),rt=(0,O.computed)(()=>{const r=P.value,l=he.value;return i.default.toNumber(ot(ot(l.height,r.height),me.height))}),De=(0,O.computed)(()=>{const r=P.value,l=ke.value;return i.default.toNumber(ot(ot(l.width,r.width),me.width))}),Ke=(0,O.computed)(()=>{const r=P.value,l=he.value;return ot(l.visible,r.visible)}),We=(0,O.computed)(()=>{const r=P.value,l=ke.value;return ot(l.visible,r.visible)}),nt=(0,O.computed)(()=>{const r=P.value,l=he.value;return ot(ot(l.autoHide,r.autoHide),me.autoHide)}),st=(0,O.computed)(()=>{const r=P.value,l=ke.value;return ot(ot(l.autoHide,r.autoHide),me.autoHide)}),Ie=(0,O.computed)(()=>he.value.position==="top"),Be=(0,O.computed)(()=>ke.value.position==="left"),mt=(0,O.computed)(()=>{const{yThumbHeight:r,xThumbWidth:l}=M,s=P.value,v=Ie.value,S=Be.value,h=Ke.value,d=We.value;return cn.buildClass(["vxe-scrollbar is--virtual",s.fluentOverlay?"is--fluent-overlay":"is--default-mode",`ov-x--${h===!1?"hidden":"visible"}`,`ov-y--${d===!1?"hidden":"visible"}`,`sx-pos--${v?"top":"bottom"}`,`sy-pos--${S?"left":"right"}`],{"overflow-y":r,"overflow-x":l})}),Je=(0,O.computed)(()=>{const{minViewDate:r,maxViewDate:l}=M,s=St.value,v=ie.value,S=Ee.value,{gridding:h}=s,d=[];if(!v||!r||!l)return d;const{type:k,startDay:C}=v;let f=-(N.currLeftSpacing+i.default.toNumber(h&&h.leftSpacing||0)),w=N.currRightSpacing+i.default.toNumber(h&&h.rightSpacing||0);switch(S>0&&(f*=S,w*=S),k){case"year":{let u=i.default.getWhatYear(r,f,"first");const g=i.default.getWhatYear(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatYear(u,S)}break}case"quarter":{let u=i.default.getWhatQuarter(r,f,"first");const g=i.default.getWhatQuarter(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatQuarter(u,S)}break}case"month":{let u=i.default.getWhatMonth(r,f,"first");const g=i.default.getWhatMonth(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatMonth(u,S)}break}case"week":{let u=i.default.getWhatWeek(r,f,C,C);const g=i.default.getWhatWeek(l,w,C,C);for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatWeek(u,S)}break}case"day":case"date":{let u=i.default.getWhatDay(r,f,"first");const g=i.default.getWhatDay(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatDay(u,S)}break}case"hour":{let u=i.default.getWhatHours(r,f,"first");const g=i.default.getWhatHours(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatHours(u,S)}break}case"minute":{let u=i.default.getWhatMinutes(r,f,"first");const g=i.default.getWhatMinutes(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatMinutes(u,S)}break}case"second":{let u=i.default.getWhatSeconds(r,f,"first");const g=i.default.getWhatSeconds(l,w,"first");for(;u<=g;){const c=u;d.push(c),u=i.default.getWhatSeconds(u,S)}break}}return d}),ht=(0,O.computed)(()=>{const{minViewDate:r,maxViewDate:l,viewCellWidth:s}=M,{visibleColumn:v,todayDateMaps:S}=V,h=ie.value,d=St.value,k=at.value,{showNowLine:C}=d,{mode:f}=k,{nowTime:w}=N;let u=0;if(C&&h&&r&&l&&w>=r.getTime()&&w<=l.getTime()){const g=S[h.type],c=i.default.toStringDate(g);let D=null,$=null;for(let R=0;R<v.length;R++){const x=v[R],{startDateObj:T,endDateObj:L}=x;if(T.date<=c&&L.date>=c){D=x,u=R*s,$=v[R+1];break}}if(f==="progress"){if(D&&$){const R=D.dateObj.date.getTime(),x=w-R,T=Math.max(0,Math.min(1,x/($.dateObj.date.getTime()-R)));u+=T*s}}else f==="center"?u+=s/2:f==="end"&&(u+=s-1)}return u}),bt={computeScrollXHeight:rt,computeScrollYWidth:De,computeScrollXVisible:Ke,computeScrollYVisible:We,computeScrollXAutoHide:nt,computeScrollYAutoHide:st,computeScrollbarXToTop:Ie,computeScrollbarYToLeft:Be,computeScaleDateList:Je,computeNowLineLeft:ht},Te={xID:W,props:o,context:F,reactData:M,internalData:V,getRefMaps:()=>Ze,getComputeMaps:()=>bt},{refTrackXElem:xe,refTrackYElem:vt,refThumbXElem:Bt,refThumbYElem:io,updateThumbSize:co,updateThumbOffset:zt,clickTrackXEvent:Nt,clickTrackYEvent:uo,pointerdownThumbXEvent:Ht,pointermoveThumbXEvent:Fo,cleatPointerThumbEvent:At,pointerdownThumbYEvent:To,pointermoveThumbYEvent:Co}=lr.useFns.useInitVScrollbar(Te),de=r=>{const l=Wt.value;return i.default.toStringDate(r,l)},Xt=()=>{const{taskScaleList:r}=N,l=ie.value;if(l){const s=r.find(R=>R.type==="week"),v=l.type==="week",S=new Date;let[h,d,k,C,f,w,u]=i.default.toDateString(S,"yyyy-M-MM-dd-HH-mm-ss").split("-");const c=S.getDay()+1,D=Math.ceil((S.getMonth()+1)/3),$=`${i.default.getYearWeek(S,s?s.startDay:void 0)}`;v&&Tt($,d)&&(h=`${Number(h)+1}`,d="1",k="0"+d),N.nowTime=S.getTime(),V.todayDateMaps={year:h,quarter:`${h}_q${D}`,month:`${h}_${k}`,week:`${h}_W${$}`,day:`${h}_${k}_${C}_E${c}`,date:`${h}_${k}_${C}`,hour:`${h}_${k}_${C}_${f}`,minute:`${h}_${k}_${C}_${f}_${w}`,second:`${h}_${k}_${C}_${f}_${w}_${u}`}}},_t=()=>{const{taskScaleList:r}=N,l=ae.value,s=ie.value,v=Z.value,S=Je.value,h=Ee.value,d=v?v.startDay:void 0,k=[],C=[];if(s&&l&&S.length){const f={year:[],quarter:[],month:[],week:[],day:[],date:[],hour:[],minute:[],second:[]},w={year:{},quarter:{},month:{},week:{},day:{},date:{},hour:{},minute:{},second:{}},u=s.type==="week",g=(D,$,R)=>{if(s.type===D)return;const x=$[D],T=`${x.field}`;let L=w[D][T];L||(L=x,w[D][T]=L,f[D].push(L)),L&&(L.children||(L.children=[]),L.children.push(R))},c=D=>{let[$,R,x,T,L,I,z,Y,fe,ce,ue,X]=i.default.toDateString(D,"yy-yyyy-M-MM-d-dd-H-HH-m-mm-s-ss").split("-");const q=D.getDay(),ye=q+1,Mt=Math.ceil((D.getMonth()+1)/3),lt=`${i.default.getYearWeek(D,v?v.startDay:void 0)}`,Ot=i.default.padStart(lt,2,"0");return u&&Tt(lt,x)&&(R=`${Number(R)+1}`,x="1",T="0"+x),{date:D,yy:$,yyyy:R,M:x,MM:T,d:L,dd:I,H:z,HH:Y,m:fe,mm:ce,s:ue,ss:X,q:Mt,W:lt,WW:Ot,E:ye,e:q}};for(let D=0;D<S.length;D++){const $=S[D],R=c($),{yyyy:x,MM:T,dd:L,HH:I,mm:z,ss:Y,q:fe,W:ce,E:ue}=R,X=R,q={year:{field:x,title:x,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatYear($,h-1)):X},quarter:{field:`${x}_q${fe}`,title:`${fe}`,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatQuarter($,h-1)):X},month:{field:`${x}_${T}`,title:T,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatMonth($,h-1)):X},week:{field:`${x}_W${ce}`,title:`${ce}`,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatWeek($,h-1,d,d)):X},day:{field:`${x}_${T}_${L}_E${ue}`,title:`${ue}`,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatDay($,h-1)):X},date:{field:`${x}_${T}_${L}`,title:L,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatDay($,h-1)):X},hour:{field:`${x}_${T}_${L}_${I}`,title:I,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatHours($,h-1)):X},minute:{field:`${x}_${T}_${L}_${I}_${z}`,title:z,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatMinutes($,h-1)):X},second:{field:`${x}_${T}_${L}_${I}_${z}_${Y}`,title:Y,dateObj:R,startDateObj:X,endDateObj:h>1?c(i.default.getWhatSeconds($,h-1)):X}},ye=q[s.type];s.level<19&&g("year",q,ye),s.level<17&&g("quarter",q,ye),s.level<15&&g("month",q,ye),s.level<13&&g("week",q,ye),s.level<11&&g("day",q,ye),s.level<9&&g("date",q,ye),s.level<7&&g("hour",q,ye),s.level<5&&g("minute",q,ye),s.level<3&&g("second",q,ye),k.push(ye)}r.forEach(D=>{if(D.type===s.type){C.push({scaleItem:D,columns:k});return}const $=f[D.type]||[];$&&$.forEach(R=>{R.childCount=R.children?R.children.length:0,R.children=void 0}),C.push({scaleItem:D,columns:$})})}return{fullCols:k,groupCols:C}},Tt=(r,l)=>`${r}`=="1"&&`${l}`=="12",jt=(r,l)=>{const s=i.default.toStringDate(r);let v=s.getFullYear();const S=s.getMonth(),h=i.default.getYearWeek(s,l);return Tt(h,S+1)&&v++,{yyyy:v,W:h}},Ut=r=>{const l=ie.value,s=Ee.value,v=ae.value,S=Z.value,h=Wt.value;if(l){const d=s>1?1/s:0;switch(v){case"year":{const k=/M|d|H|m|s|S/.test(h),C="yyyy",f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,"yyyy");if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatYear(w.date,s-c),C);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,C),$=k?g:i.default.getWhatYear(g,0,"first"),R=i.default.getWhatYear(g,0,"first"),x=i.default.toDateString(c,C),T=k?c:i.default.getWhatYear(c,0,"last"),L=i.default.getWhatYear(T,0,"first");let I=0,z=1;if(k){const fe=i.default.getDayOfYear($,0);I=($.getTime()-R.getTime())/Zt/fe;const ce=i.default.getDayOfYear(T,0);z=(T.getTime()-L.getTime())/Zt/ce,d&&(I*=d,z*=d)}const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"quarter":{const k=/M|d|H|m|ss|S/.test(h),C="yyyy-q",f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,C);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatQuarter(w.date,s-c),C);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,C),$=k?g:i.default.getWhatQuarter(g,0,"first"),R=i.default.getWhatQuarter(g,0,"first"),x=i.default.toDateString(c,C),T=k?c:i.default.getWhatQuarter(c,0,"last"),L=i.default.getWhatQuarter(T,0,"first");let I=0,z=1;if(k){const fe=i.default.getDayOfQuarter($,0);I=($.getTime()-R.getTime())/Zt/fe;const ce=i.default.getDayOfQuarter(T,0);z=(T.getTime()-L.getTime())/Zt/ce,d&&(I*=d,z*=d)}const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"month":{const k="yyyy-MM",C=/d|H|m|ss|S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,k);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatMonth(w.date,s-c),k);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,k),$=C?g:i.default.getWhatMonth(g,0,"first"),R=i.default.getWhatMonth(g,0,"first"),x=i.default.toDateString(c,k),T=C?c:i.default.getWhatMonth(c,0,"last"),L=i.default.getWhatMonth(T,0,"first");let I=0,z=1;if(C){const fe=i.default.getDayOfMonth($,0);I=($.getTime()-R.getTime())/Zt/fe;const ce=i.default.getDayOfMonth(T,0);z=(T.getTime()-L.getTime())/Zt/ce,d&&(I*=d,z*=d)}const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"week":{const k=S?S.startDay:void 0,C=/d|H|m|s|S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=`${w.yyyy}-${w.W}`;if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.getWhatWeek(w.date,s-c,k,k);let[$,R]=i.default.toDateString(D,"yyyy-M-MM-dd-HH-mm-ss").split("-");const x=`${i.default.getYearWeek(D,S?S.startDay:void 0)}`;Tt(x,R)&&($=`${Number($)+1}`);const T=`${$}-${x}`;f[T]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=C?g:i.default.getWhatWeek(g,0,"first",k),$=jt(D,k),R=`${$.yyyy}-${$.W}`,x=i.default.getWhatWeek(D,0,"first",k),T=C?c:i.default.getWhatWeek(c,0,"first",k),L=jt(T,k),I=`${L.yyyy}-${L.W}`,z=i.default.getWhatWeek(T,0,"first",k);let Y=0,fe=1;C&&(Y=(D.getTime()-x.getTime())/Zt/7,fe=(T.getTime()-z.getTime())/Zt/7,d&&(Y*=d,fe*=d));const ce=(f[R]||0)+Y;return{offsetLeftSize:ce,offsetWidthSize:(f[I]||0)-ce+fe}}}case"day":case"date":{const k="yyyy-MM-dd",C=/H|m|s|S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,k);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatDay(w.date,s-c),k);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,k),$=C?g:i.default.getWhatDay(g,0,"first"),R=i.default.getWhatDay($,0,"first"),x=i.default.toDateString(c,k),T=C?c:i.default.getWhatDay(c,0,"last"),L=i.default.getWhatDay(T,0,"first");let I=0,z=1;C&&(I=($.getTime()-R.getTime())/Zt,z=(T.getTime()-L.getTime())/Zt,d&&(I*=d,z*=d));const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"hour":{const k="yyyy-MM-dd HH",C=/m|s|S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,k);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatHours(w.date,s-c),k);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,k),$=C?g:i.default.getWhatHours(g,0,"first"),R=i.default.getWhatHours($,0,"first"),x=i.default.toDateString(c,k),T=C?c:i.default.getWhatHours(c,0,"last"),L=i.default.getWhatHours(T,0,"first");let I=0,z=1;C&&(I=($.getTime()-R.getTime())/Ya,z=(T.getTime()-L.getTime())/Ya,d&&(I*=d,z*=d));const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"minute":{const k="yyyy-MM-dd HH:mm",C=/s|S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,k);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatMinutes(w.date,s-c),k);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,k),$=C?g:i.default.getWhatMinutes(g,0,"first"),R=i.default.getWhatMinutes($,0,"first"),x=i.default.toDateString(c,k),T=C?c:i.default.getWhatMinutes(c,0,"last"),L=i.default.getWhatMinutes(T,0,"first");let I=0,z=1;C&&(I=($.getTime()-R.getTime())/hr,z=(T.getTime()-L.getTime())/hr,d&&(I*=d,z*=d));const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}case"second":{const k="yyyy-MM-dd HH:mm:ss",C=/S/.test(h),f={};return r.forEach(({dateObj:w},u)=>{const g=i.default.toDateString(w.date,k);if(f[g]=u,d){let c=s-1;for(;c;){const D=i.default.toDateString(i.default.getWhatSeconds(w.date,s-c),k);f[D]=u+(s-c)*d,c--}}}),(w,u)=>{const g=de(w),c=de(u),D=i.default.toDateString(g,k),$=C?g:i.default.getWhatSeconds(g,0,"first"),R=i.default.getWhatSeconds($,0,"first"),x=i.default.toDateString(c,k),T=C?c:i.default.getWhatSeconds(c,0,"last"),L=i.default.getWhatSeconds(T,0,"first");let I=0,z=1;C&&(I=($.getTime()-R.getTime())/gr,z=(T.getTime()-L.getTime())/gr,d&&(I*=d,z*=d));const Y=(f[D]||0)+I;return{offsetLeftSize:Y,offsetWidthSize:(f[x]||0)-Y+z}}}}}return()=>({offsetLeftSize:0,offsetWidthSize:0})},Po=()=>{const r=ee.props,{treeConfig:l}=r,{minViewDate:s,maxViewDate:v}=M,{fullCols:S,groupCols:h}=_t();if(s&&v&&S.length){const d=V.xeTable;if(d){const k=It.value,C=we.value,f=y.value,{computeAggregateOpts:w,computeTreeOpts:u}=d.getComputeMaps(),g=d.reactData,{isRowGroupStatus:c}=g,D=d.internalData,{afterFullData:$,afterTreeFullData:R,afterGroupFullData:x}=D,T=w.value,L=u.value,{transform:I}=L,z=L.children||L.childrenField,Y={},fe=Ut(S),ce=ue=>{const X=d.getRowid(ue);let q=i.default.get(ue,k),ye=i.default.get(ue,C);const Mt=Ia(i.default.get(ue,f)),lt=ma(Mt),Ot=ba(Mt);if(lt&&(q||(q=ye),ye=q),Ot)Y[X]={row:ue,rowid:X,oLeftSize:0,oWidthSize:0};else if(q&&ye){const{offsetLeftSize:e,offsetWidthSize:t}=fe(q,ye);Y[X]={row:ue,rowid:X,oLeftSize:e,oWidthSize:t}}};if(c){const ue=T.mapChildrenField;ue&&i.default.eachTree(x,ce,{children:ue})}else l?i.default.eachTree(R,ce,{children:I?L.mapChildrenField:z}):$.forEach(ce);V.chartMaps=Y}}V.visibleColumn=S,M.headerGroups=h,Xt(),la(),$t()},Go=()=>{const{linkList:r}=N,{treeConfig:l}=Ne,{scrollXStore:s}=V,v=V.xeTable,S={},h={};let d=null,k=null;const C=[];if(v){const f=It.value,w=we.value,u=y.value,{computeAggregateOpts:g,computeTreeOpts:c}=v.getComputeMaps(),D=v.reactData,{isRowGroupStatus:$}=D,R=v.internalData,{afterFullData:x,afterTreeFullData:T,afterGroupFullData:L}=R,I=g.value,z=c.value,{transform:Y}=z,fe=z.children||z.childrenField,ce=ue=>{let X=i.default.get(ue,f),q=i.default.get(ue,w);const ye=i.default.get(ue,u),Mt=ma(ye);if(X||(X=q),(Mt||!q)&&(q=X),X){const lt=de(X);(!d||d.getTime()>lt.getTime())&&(d=lt)}if(q){const lt=de(q);(!k||k.getTime()<lt.getTime())&&(k=lt)}C.push(ue)};if($){const ue=I.mapChildrenField;ue&&i.default.eachTree(L,ce,{children:ue})}else l?i.default.eachTree(T,ce,{children:Y?z.mapChildrenField:fe}):x.forEach(ce)}s.startIndex=0,s.endIndex=Math.max(1,s.visibleSize),M.minViewDate=d,M.maxViewDate=k,V.startMaps=S,V.endMaps=h,Po(),qo(C,r)};function Wo(r,l,s,v){switch(r){case za:return s;case Ha:return l-v;case _a:return l;case ja:return s-v;default:return 0}}function Kt(r,l,s,v){switch(r){case za:return l;case Ha:return s+v;case _a:return l+v;case ja:return s;default:return-1}}function Eo(r,l,s,v,S,h){switch(r){case za:return Math.abs(s-v)<h;case Ha:return Math.abs(l-S)<h;case _a:return Math.abs(l-v)<h;case ja:return Math.abs(s-S)<h;default:return!1}}function qo(r,l){const s=Yt.value,v=V.xeTable,S=[],h=new Map,d=new Map;if(Oe.criticalRowList=S,Oe.criticalRowMaps=h,Oe.criticalLinkKeyMaps=d,!s.showCriticalPath||!l.length||!r.length||!v){(N.criticalRowIds.length||N.criticalLinks.length)&&N.criticalPathFlag++,N.criticalLinks=[],N.criticalRowIds=[];return}const{chartMaps:k}=V,C=1e-6,f=new Map;for(const x of r){const T=v.getRowid(x),L=k[T];f.set(T,{row:x,rowid:T,duration:L?L.oWidthSize:0,incoming:[],outgoing:[],indeg:0,ES:0,EF:0,LS:0,LF:0})}const w=[];for(const x of l){const T=""+x.from,L=""+x.to;if(!f.has(T)||!f.has(L)||T===L)continue;const I={from:x.from,to:x.to,type:i.default.toNumber(x.type)||0,raw:x};w.push(I);const z=f.get(""+x.to),Y=f.get(""+x.from);Y&&Y.outgoing.push(I),z&&(z.incoming.push(I),z.indeg++)}const u=[];f.forEach(x=>{x.indeg===0&&u.push(x)});const g=[];for(let x=0;x<u.length;x++){const T=u[x];g.push(T);for(const L of T.outgoing){const I=f.get(""+L.to);if(I){const z=I.indeg-1;I.indeg=z,z===0&&u.push(f.get(""+L.to))}}}if(g.length!==f.size){(N.criticalRowIds.length||N.criticalLinks.length)&&N.criticalPathFlag++,N.criticalLinks=[],N.criticalRowIds=[];return}let c=0;for(const x of g){let T=0;for(const L of x.incoming){const I=f.get(""+L.from);if(I){const z=Wo(L.type,I.ES,I.EF,x.duration);z>T&&(T=z)}}x.ES=T,x.EF=T+x.duration,x.EF>c&&(c=x.EF)}for(let x=g.length-1;x>=0;x--){const T=g[x];let L=c;for(const I of T.outgoing){const z=f.get(""+I.to);if(z){const Y=Kt(I.type,z.LS,z.LF,T.duration);Y<L&&(L=Y)}}T.LF=L,T.LS=L-T.duration}const D=new Set,$=[];for(const x of g)Math.abs(x.LS-x.ES)<C&&(D.add(x.rowid),$.push(x.rowid),S.push(x.row),h.set(x.rowid,x.row));const R=[];for(const x of w){const T=f.get(""+x.to),L=f.get(""+x.from);!T||!L||!D.has(L.rowid)||!D.has(T.rowid)||Eo(x.type,L.ES,L.EF,T.ES,T.EF,C)&&(R.push(x.raw),d.set(fn(x.from,x.to,x.type),x.raw))}N.criticalLinks=R,N.criticalRowIds=$,N.criticalPathFlag++}const Do=()=>{const{scrollXWidth:r,scrollYHeight:l}=M,{elemStore:s}=V,v=P.value,S=le(s["main-body-wrapper"]),h=dt.value,d=se.value;let k=!1,C=!1;if(S){if(k=l>S.clientHeight,d){const f=v.width||d.offsetWidth-d.clientWidth||14;M.scrollbarWidth=f,N.scrollbarWidth=f}if(M.overflowY=k,N.overflowY=k,C=r>S.clientWidth,h){const f=v.height||h.offsetHeight-h.clientHeight||14;M.scrollbarHeight=f,N.scrollbarHeight=f}M.overflowX=C,N.overflowX=C}},Io=(r,l)=>{const{chartMaps:s}=V,{computeTreeOpts:v}=r.getComputeMaps(),S=v.value,h=S.children||S.childrenField,d=y.value;let k=0,C=0;return i.default.eachTree(l,f=>{const w=r.getRowid(f),u=i.default.get(f,d);if(ba(u))return;const g=w?s[w]:null;g&&(C=Math.max(C,g.oLeftSize+g.oWidthSize),k=k?Math.min(k,g.oLeftSize):g.oLeftSize)},{children:h}),{minSize:k,maxSize:C}},sa=()=>{const{dragBarRow:r}=Oe,{viewCellWidth:l}=M,{elemStore:s,chartMaps:v}=V,S=V.xeTable,h=le(s["main-chart-task-wrapper"]);if(h&&S){const{computeTreeOpts:d}=S.getComputeMaps(),k=d.value,C=k.children||k.childrenField;i.default.arrayEach(h.children,f=>{const w=f.children[0];if(!w)return;const u=f.getAttribute("rowid");if(r&&S.getRowid(r)===u)return;const g=u?v[u]:null,c=g?g.row:null;if(So(w,"is--subview")){const D=w.firstElementChild;if(D)if(So(D,"is--inline"))i.default.arrayEach(D.children,$=>{const R=$.children[0],x=R.getAttribute("rowid")||"",T=x?v[x]:null;if(T){const L=T.row;if(So(R,"is--subview")){const I=L[C],{minSize:z,maxSize:Y}=Io(S,I);R.style.left=`${l*z}px`,R.style.width=`${l*(Y-z)}px`}else R.style.left=`${nr(T,l)}px`,So(R,"is--milestone")||(R.style.width=`${sr(T,l)}px`)}});else{const $=D.children[0],R=$?$.children[0]:null;if(R){const x=c?c[C]:[],{minSize:T,maxSize:L}=Io(S,x);R.style.left=`${l*T}px`,R.style.width=`${l*(L-T)}px`}}}else w.style.left=`${nr(g,l)}px`,So(w,"is--milestone")||(w.style.width=`${sr(g,l)}px`)})}return(0,O.nextTick)()},Bo=()=>{const{showLeftView:r}=N,{scrollbarWidth:l,scrollbarHeight:s,headerGroups:v,tableColumn:S}=M,{elemStore:h,visibleColumn:d}=V,k=V.xeTable,C=Fe.value;if(!C||!ee)return;const f=We.value,w=Ie.value,u=Be.value,g=A.value,c=te.value,D=Pe.value;let $=l;const R=s;let x=0,T=0,L=0;if(k){const m=k.internalData;x=m.tBodyHeight,T=m.tHeaderHeight,L=m.tFooterHeight}let I="visible";(f===!1||f==="hidden"||u&&r)&&($=0,I="hidden");const Y=le(h["main-header-scroll"]);Y&&(Y.style.height=`${T}px`,Y.style.setProperty("--vxe-ui-gantt-view-cell-height",`${T/v.length}px`));const fe=le(h["main-body-scroll"]);fe&&(fe.style.height=`${x}px`);const ce=le(h["main-footer-scroll"]);ce&&(ce.style.height=`${L}px`),D&&(D.style.height=`${R}px`,D.style.visibility="visible");const ue=Xe.value;ue&&(ue.style.left=w?`${$}px`:"",ue.style.width=`${C.clientWidth-$}px`),g&&(g.style.width=w?`${$}px`:"",g.style.display=w&&R?"block":""),c&&(c.style.width=w?"":`${$}px`,c.style.display=w?"":R?"block":"");const X=Re.value;X&&(X.style.width=`${$}px`,X.style.height=`${x+T+L}px`,X.style.visibility=I);const q=Ae.value;q&&(q.style.height=`${T}px`,q.style.display=T?"block":"");const ye=ft.value;ye&&(ye.style.height=`${x}px`,ye.style.top=`${T}px`);const Mt=be.value;Mt&&(Mt.style.height=`${L}px`,Mt.style.top=`${T+x}px`,Mt.style.display=L?"block":"");const lt=gt.value;let Ot=40;lt&&(Ot=lt.clientWidth||40);let e=Ot;if(d.length&&(e=Math.max(0,Ot*d.length),fe)){const m=fe.clientWidth,E=m-e;E>0&&(Ot+=Math.max(0,E/d.length),e=m)}M.viewCellWidth=Ot;const t=le(h["main-header-table"]),a=le(h["main-body-table"]),p=Ot*S.length;return t&&(t.style.width=`${e}px`),a&&(a.style.width=`${p}px`),M.scrollXWidth=e,Promise.all([sa(),ee.handleUpTaskLinkStyle?ee.handleUpTaskLinkStyle(Te):null])},Ct=()=>{const r=Fe.value;return V.rceRunTime=Date.now(),!r||!r.clientWidth||!ee?(0,O.nextTick)():(Do(),Bo(),fo())},Qo=()=>new Promise(r=>{const{rceTimeout:l,rceRunTime:s}=V,v=V.xeTable;let S=30;if(v){const{computeResizeOpts:h}=v.getComputeMaps();S=h.value.refreshDelay||S}ho(),l?(clearTimeout(l),s&&s+(S-5)<Date.now()?r(Ct()):(0,O.nextTick)(()=>{r()})):r(Ct()),V.rceTimeout=setTimeout(()=>{V.rceTimeout=void 0,Ct()},S)}),fo=()=>(0,O.nextTick)().then(()=>{const{scrollXLoad:r}=M,{scrollXStore:l}=V;if(r){const{toVisibleIndex:s,visibleSize:v}=Oo(),S=2;l.preloadSize=1,l.offsetSize=S,l.visibleSize=v,l.endIndex=Math.max(l.startIndex+l.visibleSize+S,l.endIndex),l.visibleStartIndex=Math.max(l.startIndex,s),l.visibleEndIndex=Math.min(l.endIndex,s+v),po().then(()=>{Jt()})}else b()}),Oo=()=>{const{viewCellWidth:r}=M,{elemStore:l}=V,s=le(l["main-body-scroll"]);if(s){const v=s.clientWidth,S=s.scrollLeft,h=Math.floor(S/r)-1,d=Math.ceil(v/r)+1;return{toVisibleIndex:Math.max(0,h),visibleSize:Math.max(1,d)}}return{toVisibleIndex:0,visibleSize:6}},Jt=()=>{const{isScrollXBig:r}=M,{scrollXStore:l}=V,{preloadSize:s,startIndex:v,endIndex:S,offsetSize:h}=l,{toVisibleIndex:d,visibleSize:k}=Oo(),C={startIndex:Math.max(0,r?d-1:d-1-h-s),endIndex:r?d+k:d+k+h+s};l.visibleStartIndex=d-1,l.visibleEndIndex=d+k+1;const{startIndex:f,endIndex:w}=C;(d<=v||d>=S-k-1)&&(v!==f||S!==w)&&(l.startIndex=f,l.endIndex=w,po())},po=()=>($t(),b(),(0,O.nextTick)()),la=()=>(M.scrollXLoad=!0,!0),$t=()=>{const{scrollXLoad:r}=M,{visibleColumn:l,scrollXStore:s}=V,v=r?l.slice(s.startIndex,s.endIndex):l.slice(0);M.tableColumn=v},b=()=>{const{scrollXLoad:r,scrollXWidth:l,viewCellWidth:s}=M,{elemStore:v,scrollXStore:S}=V,h=le(v["main-body-table"]),{startIndex:d}=S;let k=0;r&&(k=Math.max(0,d*s)),h&&(h.style.transform=`translate(${k}px, ${M.scrollYTop||0}px)`);const C=l;["header","body","footer"].forEach($=>{const R=le(v[`main-${$}-xSpace`]);R&&(R.style.width=r?`${C}px`:"")});const w=Qe.value;w&&(w.style.width=`${C}px`);const u=le(v["main-chart-before-wrapper"]),g=u?u.firstElementChild:null;g&&(g.style.width=`${C}px`);const c=le(v["main-chart-after-wrapper"]),D=c?c.firstElementChild:null;return D&&(D.style.width=`${C}px`),M.scrollXLeft=k,M.scrollXWidth=C,Do(),(0,O.nextTick)()},Vt=()=>{Jt()},Ue=()=>{const{scrollYLoad:r,overflowY:l}=M,{elemStore:s}=V,v=V.xeTable,S=le(s["main-body-scroll"]),h=le(s["main-body-table"]);let d=0,k=0,C=!1;if(v){const I=v.reactData;d=I.scrollYTop,k=I.scrollYHeight,C=I.isScrollYBig}let f=k,w=d,u=0;S&&(u=S.clientHeight),C&&(S&&h&&S.scrollTop+u>=Sa?w=Sa-h.clientHeight:w=(Sa-u)*(d/(k-u)),f=Sa),r&&l||(w=0);const g=le(s["main-chart-task-wrapper"]);h&&(h.style.transform=`translate(${M.scrollXLeft||0}px, ${w}px)`),g&&(g.style.transform=`translateY(${w}px)`);const c=le(s["main-body-ySpace"]);c&&(c.style.height=f?`${f}px`:"");const D=pt.value;D&&(D.style.height=f?`${f}px`:"");const $=le(s["main-chart-before-wrapper"]),R=$?$.firstElementChild:null;R&&(R.style.height=f?`${f}px`:"");const x=le(s["main-chart-after-wrapper"]),T=x?x.firstElementChild:null;T&&(T.style.height=f?`${f}px`:"");const L=le(s["main-chart-now-line"]);return L&&(L.style.height=f?`${f}px`:""),M.scrollYTop=w,M.scrollYHeight=k,M.isScrollYBig=C,Do(),(0,O.nextTick)().then(()=>{Bo()})},$e=(r,l)=>{const{lcsTimeout:s}=V;M.lazScrollLoading=!0,s&&clearTimeout(s),V.lcsTimeout=setTimeout(()=>{const v=V.xeTable;if(V.lcsRunTime=Date.now(),V.lcsTimeout=void 0,V.intoRunScroll=!1,V.inVirtualScroll=!1,V.inWheelScroll=!1,V.inHeaderScroll=!1,V.inBodyScroll=!1,V.inFooterScroll=!1,M.lazScrollLoading=!1,v){const S=v.internalData;S.isSyncGanttScrollTop=!1}},200)},ze=(r,l,s,v)=>{l&&(V.lastScrollLeft=v),r&&(V.lastScrollTop=s),M.lastScrollTime=Date.now(),$e(l,r)},Et=(r,l,s,v,S)=>{const h=V.xeTable,{elemStore:d,lastScrollLeft:k,lastScrollTop:C}=V,f=le(d["main-body-scroll"]);if(!f||!h)return;const{computeScrollXThreshold:w,computeScrollYThreshold:u}=h.getComputeMaps(),g=f.clientHeight,c=f.clientWidth,D=f.scrollHeight,$=f.scrollWidth;let R=!1,x=!1,T=!1,L=!1,I="",z=!1,Y=!1,fe=!1,ce=!1;if(s){const q=w.value;T=S<=0,T||(L=S+c>=$-1),S>k?(I="right",S+c>=$-q&&(ce=!0)):(I="left",S<=q&&(fe=!0))}if(l){const q=u.value;R=v<=0,R||(x=v+g>=D-1),v>C?(I="bottom",v+g>=D-q&&(Y=!0)):(I="top",v<=q&&(z=!0))}re.value&&zt(),ze(l,s,v,S);const X={source:dn,scrollTop:v,scrollLeft:S,bodyHeight:g,bodyWidth:c,scrollHeight:D,scrollWidth:$,isX:s,isY:l,isTop:R,isBottom:x,isLeft:T,isRight:L,direction:I};(Y||z||ce||fe)&&ee.dispatchEvent("scroll-boundary",X,r),ee.dispatchEvent("scroll",X,r)},eo={getScrollViewElem(){const{elemStore:r}=V;return le(r["main-body-scroll"])},refreshData(){return Go(),Ct(),(0,O.nextTick)().then(()=>{const r=V.xeTable;if(Ct(),r)return r.recalculate()})},updateViewData(r){const l=V.xeTable;if(l){const s=l.reactData,{tableData:v}=s;M.tableData=v,r&&(N.currLeftSpacing=0,N.currRightSpacing=0,Go()),Ct()}return(0,O.nextTick)()},connectUpdate({$table:r}){return r&&(V.xeTable=r),(0,O.nextTick)()}},go=r=>{const{isSyncTableScrollTop:l}=V;if(l)return;const s=V.xeTable;if(s){const v=s.internalData;v.isSyncGanttScrollTop=!0,s.handleSyncScrollTop({scrollTop:r})}},zo={handleUpdateStyle:Bo,handleLazyRecalculate:Qo,handleUpdateCurrentRow(r){const l=V.xeTable,s=Fe.value;if(l&&s)if(r){const v=l.props,{computeRowOpts:S}=l.getComputeMaps();(S.value.isCurrent||v.highlightCurrentRow)&&i.default.arrayEach(s.querySelectorAll(`.vxe-gantt-view--body-row[rowid="${l.getRowid(r)}"]`),d=>Wa(d,"row--current"))}else i.default.arrayEach(s.querySelectorAll(".vxe-gantt-view--body-row.row--current"),v=>va(v,"row--current"))},handleUpdateHoverRow(r){const l=V.xeTable,s=Fe.value;l&&s&&(r?i.default.arrayEach(s.querySelectorAll(`.vxe-gantt-view--body-row[rowid="${l.getRowid(r)}"]`),v=>Wa(v,"row--hover")):i.default.arrayEach(s.querySelectorAll(".vxe-gantt-view--body-row.row--hover"),v=>va(v,"row--hover")))},handleSyncScrollTop(r){const{scrollTop:l}=r,{elemStore:s}=V,v=le(s["main-body-scroll"]);v&&(v.scrollTop=l)},triggerHeaderScrollEvent(r){const{elemStore:l,inVirtualScroll:s,inBodyScroll:v,inFooterScroll:S}=V;if(s||v||S)return;const h=r.currentTarget,d=le(l["main-body-scroll"]),k=dt.value;if(d&&h){const w=h.scrollLeft;V.inHeaderScroll=!0,No(k,w),No(d,w),Et(r,!1,!0,h.scrollTop,w)}},triggerBodyScrollEvent(r){const{scrollXLoad:l}=M,{elemStore:s,inVirtualScroll:v,inHeaderScroll:S,inFooterScroll:h,lastScrollLeft:d,lastScrollTop:k}=V;if(v||S||h)return;const C=r.currentTarget,f=le(s["main-header-scroll"]),w=dt.value,u=se.value,g=C.scrollLeft,c=C.scrollTop,D=g!==d,$=c!==k;V.inBodyScroll=!0,V.scrollRenderType="",$&&(or(u,c),go(c)),D&&(V.inBodyScroll=!0,No(w,g),No(f,g),l&&Vt()),Et(r,$,D,C.scrollTop,g)},triggerVirtualScrollXEvent(r){const{scrollXLoad:l}=M,{elemStore:s,inHeaderScroll:v,inBodyScroll:S}=V;if(v||S)return;const h=r.currentTarget,d=le(s["main-header-scroll"]),k=le(s["main-body-scroll"]);if(h){const w=h.scrollLeft;V.inVirtualScroll=!0,No(d,w),No(k,w),l&&Vt(),Et(r,!1,!0,h.scrollTop,w)}},triggerVirtualScrollYEvent(r){const{elemStore:l,inHeaderScroll:s,inBodyScroll:v}=V;if(s||v)return;const S=r.currentTarget,h=le(l["main-body-scroll"]);if(S){const C=S.scrollTop;V.inVirtualScroll=!0,or(h,C),go(C),ze(!0,!1,C,S.scrollLeft)}},handleUpdateSXSpace(){return b()},handleUpdateSYSpace(){return Ue()},handleUpdateSYStatus(r){M.scrollYLoad=r},updateScrollbar(){return ho()}},ho=()=>re.value?(0,O.nextTick)().then(()=>{co(),zt()}):Promise.resolve(),Ho=()=>{Qo()},to=()=>{const{elemStore:r,scrollObserver:l}=V;if(re.value&&!l){const v=Fe.value,S=le(r["main-body-xSpace"]),h=le(r["main-body-xSpace"]),d=un.create(()=>{Dt.value++});v&&d.observe(v),S&&d.observe(S),h&&d.observe(h),V.scrollObserver=d}};Object.assign(Te,eo,zo);const Ro=()=>(0,O.h)("div",{key:"vsx",ref:Pe,class:"vxe-gantt-view--scroll-x-virtual"},[(0,O.h)("div",{ref:A,class:"vxe-gantt-view--scroll-x-left-corner"}),(0,O.h)("div",{ref:Xe,class:"vxe-gantt-view--scroll-x-wrapper"},[(0,O.h)("div",{ref:dt,class:"vxe-gantt-view--scroll-x-handle",onScroll:Te.triggerVirtualScrollXEvent},[(0,O.h)("div",{ref:Qe,class:"vxe-gantt-view--scroll-x-space"})]),(0,O.h)("div",{class:"vxe-gantt-view--scroll-x-handle-appearance"})]),(0,O.h)("div",{ref:te,class:"vxe-gantt-view--scroll-x-right-corner"})]),_o=()=>(0,O.h)("div",{key:"vsy",ref:Re,class:"vxe-gantt-view--scroll-y-virtual"},[(0,O.h)("div",{ref:Ae,class:"vxe-gantt-view--scroll-y-top-corner"}),(0,O.h)("div",{ref:ft,class:"vxe-gantt-view--scroll-y-wrapper"},[(0,O.h)("div",{ref:se,class:"vxe-gantt-view--scroll-y-handle",onScroll:Te.triggerVirtualScrollYEvent},[(0,O.h)("div",{ref:pt,class:"vxe-gantt-view--scroll-y-space"})]),(0,O.h)("div",{class:"vxe-gantt-view--scroll-y-handle-appearance"})]),(0,O.h)("div",{ref:be,class:"vxe-gantt-view--scroll-y-bottom-corner"})]),oo=()=>(0,O.h)("div",{key:"tvw",class:"vxe-gantt-view--viewport-wrapper"},[(0,O.h)(Jr),(0,O.h)(an),(0,O.h)(sn)]),Zo=()=>{const r=Be.value;return(0,O.h)("div",{key:"lnb",class:"vxe-gantt-view--layout-wrapper"},r?[_o(),oo()]:[oo(),_o()])},Ea=()=>{const{showLeftView:r}=N,{xThumbWidth:l,yThumbHeight:s}=M,v=re.value,S=P.value,h=nt.value,d=st.value,k=Ke.value,C=We.value,f=Ie.value,w=Be.value,u=mt.value;return(0,O.h)("div",{key:"lvb",class:["vxe-gantt--layout-wrapper",`sx-pos--${f?"top":"bottom"}`,`sy-pos--${w?"left":"right"}`,{"is--virtual-scrollbar":v,"ov-padding":v&&S.padding,"ov-x--auto-hide":v&&h,"ov-y--auto-hide":v&&d,"overflow-y":s,"overflow-x":l}]},[oo(),(0,O.h)("div",{class:u},[k===!1?pr(ee):(0,O.h)("div",{ref:xe,class:"vxe-scrollbar--track-x",onClick:Nt},[(0,O.h)("div",{ref:Bt,class:"vxe-scrollbar--thumb-x",onPointerdown:Ht,onPointermove:Fo,onPointerup:At,onPointercancel:At,onLostpointercapture:At})]),w&&r||C===!1?pr(ee):(0,O.h)("div",{ref:vt,class:"vxe-scrollbar--track-y",onClick:uo},[(0,O.h)("div",{ref:io,class:"vxe-scrollbar--thumb-y",onPointerdown:To,onPointermove:Co,onPointerup:At,onPointercancel:At,onLostpointercapture:At})])])])},$o=()=>{const{overflowX:r,overflowY:l,scrollXLoad:s,scrollYLoad:v}=M,S=re.value,h=Ie.value;return(0,O.h)("div",{ref:Fe,class:["vxe-gantt-view",{"is--scroll-y":l,"is--scroll-x":r,"is--virtual-x":s,"is--virtual-y":v}]},[(0,O.h)("div",{class:"vxe-gantt-view--render-wrapper"},S?[Ea()]:h?[Ro(),Zo()]:[Zo(),Ro()]),(0,O.h)("div",{class:"vxe-gantt-view--render-vars"},[(0,O.h)("div",{ref:gt,class:"vxe-gantt-view--column-info"})])])},Dt=(0,O.ref)(0);return(0,O.watch)(re,()=>{(0,O.nextTick)(()=>{to(),(0,O.nextTick)(()=>{Dt.value++})})}),(0,O.watch)(Ie,()=>{Dt.value++}),(0,O.watch)(Be,()=>{Dt.value++}),(0,O.watch)(Ke,()=>{Dt.value++}),(0,O.watch)(We,()=>{Dt.value++}),(0,O.watch)(rt,()=>{Dt.value++}),(0,O.watch)(De,()=>{Dt.value++}),(0,O.watch)(Dt,()=>{(0,O.nextTick)(()=>{ho(),(0,O.nextTick)(()=>{ho()})})}),(0,O.onMounted)(()=>{(0,O.nextTick)(()=>{to()}),fr.on(Te,"resize",Ho)}),(0,O.onBeforeUnmount)(()=>{const{scrollObserver:r}=V;r&&r.disconnect(),i.default.assign(M,mr()),i.default.assign(V,vr())}),(0,O.onUnmounted)(()=>{fr.off(Te,"keydown")}),Te.renderVN=$o,(0,O.provide)("$xeGanttView",Te),Te},render(){return this.renderVN()}}),gn=ge("vxe-table"),{warnLog:Ao,errLog:xt}=Ir("gantt"),{getConfig:ve,getIcon:ka,getI18n:Xo,commands:hn,hooks:vn,useFns:br,createEvent:mn,globalEvents:Na,GLOBAL_EVENT_KEYS:bn,renderEmptyElement:yt}=Se.VxeUI,wr=gn.VxeTable.props,wn=Object.keys(wr),xr=["clearAll","syncData","updateData","loadData","reloadData","reloadRow","loadColumn","reloadColumn","getRowNode","getColumnNode","getRowIndex","getVTRowIndex","getVMRowIndex","getColumnIndex","getVTColumnIndex","getVMColumnIndex","setRow","createData","createRow","revertData","clearData","isRemoveByRow","isInsertByRow","isUpdateByRow","getColumns","getColumnById","getColumnByField","getTableColumn","getFullColumns","getData","getCheckboxRecords","getParentRow","getTreeRowChildren","getTreeRowLevel","getTreeParentRow","getRowSeq","getRowById","getRowid","getTableData","getFullData","setColumnFixed","clearColumnFixed","setColumnWidth","getColumnWidth","recalcRowHeight","setRowHeightConf","getRowHeightConf","setRowHeight","getRowHeight","hideColumn","showColumn","resetColumn","refreshColumn","refreshScroll","recalculate","closeTooltip","isAllCheckboxChecked","isAllCheckboxIndeterminate","getCheckboxIndeterminateRecords","setCheckboxRow","setCheckboxRowKey","isCheckedByCheckboxRow","isCheckedByCheckboxRowKey","isIndeterminateByCheckboxRow","isIndeterminateByCheckboxRowKey","toggleCheckboxRow","setAllCheckboxRow","getRadioReserveRecord","clearRadioReserve","getCheckboxReserveRecords","clearCheckboxReserve","toggleAllCheckboxRow","clearCheckboxRow","setCurrentRow","isCheckedByRadioRow","isCheckedByRadioRowKey","setRadioRow","setRadioRowKey","clearCurrentRow","clearRadioRow","getCurrentRecord","getRadioRecord","getCurrentColumn","setCurrentColumn","clearCurrentColumn","setPendingRow","togglePendingRow","hasPendingByRow","isPendingByRow","getPendingRecords","clearPendingRow","setFilterByEvent","sort","setSort","setSortByEvent","clearSort","clearSortByEvent","isSort","getSortColumns","closeFilter","isFilter","clearFilterByEvent","isActiveFilterByColumn","isRowExpandLoaded","clearRowExpandLoaded","reloadRowExpand","reloadRowExpand","toggleRowExpand","setAllRowExpand","setRowExpand","isExpandByRow","isRowExpandByRow","clearRowExpand","clearRowExpandReserve","getRowExpandRecords","getTreeExpandRecords","isTreeExpandLoaded","clearTreeExpandLoaded","reloadTreeExpand","reloadTreeChilds","toggleTreeExpand","setAllTreeExpand","setTreeExpand","isTreeExpandByRow","clearTreeExpand","clearTreeExpandReserve","getScroll","scrollTo","scrollToStartRow","scrollToEndRow","scrollToRow","scrollToStartColumn","scrollToEndColumn","scrollToColumn","clearScroll","updateFooter","updateStatus","setMergeCells","removeInsertRow","removeMergeCells","getMergeCells","clearMergeCells","setMergeFooterItems","removeMergeFooterItems","getMergeFooterItems","clearMergeFooterItems","getCustomStoreData","setRowGroupExpand","setRowGroupExpandByField","setAllRowGroupExpand","clearRowGroupExpand","isRowGroupExpandByRow","isRowGroupRecord","isAggregateRecord","isAggregateExpandByRow","getAggregateContentByRow","getAggregateRowChildren","setRowGroups","clearRowGroups","openTooltip","moveColumnTo","moveRowTo","getCellLabel","undo","redo","getCellElement","focus","blur","connect"],xn=[["Form"],["Toolbar","Top","Gantt","Bottom","Pager"]];function yr(){return{linkFromConfMaps:{},linkToConfMaps:{},linkUniqueMaps:{},uFoot:!1,resizeTableWidth:0,dragLinkToStore:{rowid:null,type:0},criticalRowList:[],criticalRowMaps:new Map,criticalLinkKeyMaps:new Map}}function Sr(){var o;return{tableLoading:!1,proxyInited:!1,overflowY:!1,overflowX:!1,scrollbarWidth:0,scrollbarHeight:0,isZMax:!1,tableLinks:[],tableData:[],filterData:[],formData:{},sortData:[],footerData:[],tZindex:0,tablePage:{total:0,pageSize:((o=ve().pager)==null?void 0:o.pageSize)||10,currentPage:1},showLeftView:!0,showRightView:!0,taskScaleList:[],barTipStore:{row:null,content:"",visible:!1,params:null},dragLinkFromStore:{rowid:null,type:0},activeBarRowid:null,activeLink:null,isActiveCeLe:!1,linkList:[],upLinkFlag:0,showSplitAnimat:!1,nowTime:0,currLeftSpacing:0,currRightSpacing:0,criticalLinks:[],criticalRowIds:[],criticalPathFlag:0}}var Ta={year:19,quarter:17,month:15,week:13,day:11,date:9,hour:7,minute:5,second:3};function yn(o){return Ta[o||"date"]||Ta.date}var Ca=Yo({name:"VxeGantt",mixins:[],props:{...wr,columns:Array,pagerConfig:Object,proxyConfig:Object,toolbarConfig:Object,formConfig:Object,zoomConfig:Object,links:Array,layouts:Array,taskConfig:Object,taskViewScaleConfig:Object,taskNowLineConfig:Object,taskViewConfig:Object,taskLinkConfig:Object,taskBarConfig:Object,taskBarMilestoneConfig:Object,taskCriticalPathConfig:Object,taskBarSubviewConfig:Object,taskBarTooltipConfig:Object,taskSplitConfig:Object,taskBarResizeConfig:Object,taskBarResizeTooltipConfig:Object,taskBarMoveConfig:Object,taskBarMoveTooltipConfig:Object,size:{type:String,default:()=>ve().gantt.size||ve().size}},emits:Gr,setup(o,F){const{slots:W,emit:me}=F,ee=B.default.uniqueId(),Ne=Se.VxeUI.getComponent("VxeForm"),N=Se.VxeUI.getComponent("VxePager"),Oe=Se.VxeUI.getComponent("VxeTable"),Wt=Se.VxeUI.getComponent("VxeToolbar"),Yt=Se.VxeUI.getComponent("VxeTooltip"),St=Object.assign({},ve().scrollbar),{computeSize:It}=br.useSize(o),{computeIsVScrollbar:we}=br.useVScrollbar(o),y=(0,n.reactive)(Sr()),P=yr(),ae=(0,n.ref)(),Z=(0,n.ref)(),ie=(0,n.ref)(),at=(0,n.ref)(),Ee=(0,n.ref)(),qe=(0,n.ref)(),Fe=(0,n.ref)(),Pe=(0,n.ref)(),Re=(0,n.ref)(),dt=(0,n.ref)(),A=(0,n.ref)(),te=(0,n.ref)(),se=(0,n.ref)(),Ae=(0,n.ref)(),Xe=(0,n.ref)(),ft=(0,n.ref)(),be=(0,n.ref)(),Qe=(0,n.ref)(),pt=e=>{const t={};return e.forEach(a=>{t[a]=(...p)=>{const m=Z.value;if(m&&m[a])return m[a](...p)}}),t},gt=pt(xr);xr.forEach(e=>{gt[e]=(...t)=>{const a=Z.value;if(a&&a[e])return a&&a[e](...t)}});const M=(0,n.computed)(()=>B.default.merge({},B.default.clone(ve().gantt.proxyConfig,!0),o.proxyConfig)),V=(0,n.computed)(()=>{const e=M.value;return!!(B.default.isBoolean(e.message)?e.message:e.showResponseMsg)}),Ze=(0,n.computed)(()=>{const e=M.value;return B.default.isBoolean(e.showActionMsg)?e.showActionMsg:!!e.showActiveMsg}),re=(0,n.computed)(()=>Object.assign({},ve().gantt.pagerConfig,o.pagerConfig)),he=(0,n.computed)(()=>Object.assign({},ve().gantt.formConfig,o.formConfig)),ke=(0,n.computed)(()=>Object.assign({},ve().gantt.toolbarConfig,o.toolbarConfig)),rt=(0,n.computed)(()=>Object.assign({},ve().gantt.zoomConfig,o.zoomConfig)),De=(0,n.computed)(()=>Object.assign({},ve().gantt.taskConfig,o.taskConfig)),Ke=(0,n.computed)(()=>B.default.merge({},ve().gantt.taskViewScaleConfig,o.taskViewScaleConfig)),We=(0,n.computed)(()=>Object.assign({},ve().gantt.taskNowLineConfig,o.taskNowLineConfig)),nt=(0,n.computed)(()=>Object.assign({},ve().gantt.taskViewConfig,o.taskViewConfig)),st=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarConfig,o.taskBarConfig)),Ie=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarMoveConfig,o.taskBarMoveConfig)),Be=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarMoveTooltipConfig,o.taskBarMoveTooltipConfig)),mt=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarResizeConfig,o.taskBarResizeConfig)),Je=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarResizeTooltipConfig,o.taskBarResizeTooltipConfig)),ht=(0,n.computed)(()=>Object.assign({},ve().gantt.taskSplitConfig,o.taskSplitConfig)),bt=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarMilestoneConfig,o.taskBarMilestoneConfig)),Te=(0,n.computed)(()=>Object.assign({},ve().gantt.taskCriticalPathConfig,o.taskCriticalPathConfig)),xe=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarSubviewConfig,o.taskBarSubviewConfig)),vt=(0,n.computed)(()=>Object.assign({},ve().gantt.taskBarTooltipConfig,o.taskBarTooltipConfig)),Bt=(0,n.computed)(()=>Object.assign({},ve().gantt.taskLinkConfig,o.taskLinkConfig)),io=(0,n.computed)(()=>{const e=De.value,{dateFormat:t}=e;return t||""}),co=(0,n.computed)(()=>{const e=zt.value;return e?e.type:"date"}),zt=(0,n.computed)(()=>{const{taskScaleList:e}=y;return B.default.last(e)}),Nt=(0,n.computed)(()=>{const e=zt.value,{step:t}=e;return B.default.toNumber(t||1)||1}),uo=(0,n.computed)(()=>{const{taskScaleList:e}=y;return e.find(t=>t.type==="week")}),Ht=(0,n.computed)(()=>{const e=nt.value,{scales:t}=e;return t}),Fo=(0,n.computed)(()=>{const{lineType:e,lineWidth:t,lineStatus:a,lineColor:p}=Bt.value;return`${e||""}_${t||""}_${a||""}_${p||""}`}),At=(0,n.computed)(()=>De.value.titleField||"title"),To=(0,n.computed)(()=>De.value.startField||"start"),Co=(0,n.computed)(()=>De.value.endField||"end"),de=(0,n.computed)(()=>De.value.typeField||"type"),Xt=(0,n.computed)(()=>De.value.progressField||"progress"),_t=(0,n.computed)(()=>Object.assign({},ve().gantt.scrollbarConfig,o.scrollbarConfig)),Tt=(0,n.computed)(()=>{const e=_t.value;return e.x?Object.assign({},e.x,e.xConfig):e.xConfig||{}}),jt=(0,n.computed)(()=>{const e=_t.value;return e.y?Object.assign({},e.y,e.yConfig):e.yConfig||{}}),Ut=(0,n.computed)(()=>{const e=_t.value,t=Tt.value;return B.default.toNumber(ot(ot(t.height,e.height),St.height))}),Po=(0,n.computed)(()=>{const e=_t.value,t=jt.value;return B.default.toNumber(ot(ot(t.width,e.width),St.width))}),Go=(0,n.computed)(()=>{const e=_t.value,t=Tt.value;return ot(ot(t.autoHide,e.autoHide),St.autoHide)}),Wo=(0,n.computed)(()=>{const e=_t.value,t=jt.value;return ot(ot(t.autoHide,e.autoHide),St.autoHide)}),Kt=(0,n.computed)(()=>Tt.value.position==="top"),Eo=(0,n.computed)(()=>jt.value.position==="left"),qo=(0,n.computed)(()=>st.value.showCriticalPath),Do=(0,n.computed)(()=>{const{height:e,maxHeight:t,taskBarSubviewConfig:a}=o,{isZMax:p,tZindex:m,overflowY:E,scrollbarWidth:H}=y,_=we.value,j=nt.value,{viewStyle:Q,tableStyle:U}=j,K=st.value,{barStyle:pe}=K,Lt=Te.value,{lineColor:Ve}=Lt,wt=xe.value,vo=We.value,{fontColor:Gt,bgColor:mo,width:jo}=vo,ia=Po.value,Ko=Ut.value,oe={"--vxe-ui-gantt-scrollbar-width":E?_?"var(--vxe-ui-scrollbar-y-width)":H+"px":""};if(Ve&&(oe["--vxe-ui-gantt-view-bar-critical-path-line-color"]=Ve),p?oe.zIndex=m:(e&&(oe.height=e==="auto"||e==="100%"?"100%":Lo(e)),t&&(oe.maxHeight=t==="auto"||t==="100%"?"100%":Lo(t))),(ia||Ko)&&(oe["--vxe-ui-scrollbar-y-width"]=Lo(ia||Ko),oe["--vxe-ui-scrollbar-x-height"]=Lo(Ko||ia)),pe&&!B.default.isFunction(pe)){const{bgColor:Ft,completedBgColor:G,overviewBgColor:bo}=pe;Ft&&(oe["--vxe-ui-gantt-view-task-bar-background-color"]=Ft),G&&(oe["--vxe-ui-gantt-view-task-bar-completed-background-color"]=G),bo&&oa(a,wt)&&(oe["--vxe-ui-gantt-view-task-bar-overview-background-color"]=bo)}if(Gt&&(oe["--vxe-ui-gantt-view-task-now-line-color"]=Gt),mo&&(oe["--vxe-ui-gantt-view-task-now-line-background-color"]=mo),jo&&(oe["--vxe-ui-gantt-view-task-now-line-width"]=Lo(jo)),Q){const{cellWidth:Ft}=Q;Ft&&(oe["--vxe-ui-gantt-view-default-cell-width"]=Lo(Ft))}if(U){const{width:Ft}=U;Ft&&(oe["--vxe-ui-gantt-view-table-default-width"]=Lo(Ft))}return oe}),Io=(0,n.computed)(()=>{const e={},t=o;return wn.forEach(a=>{t[a]!==void 0&&(e[a]=t[a])}),e}),sa=(0,n.computed)(()=>{const{showFooter:e,seqConfig:t,pagerConfig:a,editConfig:p,proxyConfig:m}=o,{isZMax:E,tablePage:H,footerData:_}=y,j=nt.value,{tableStyle:Q}=j,U=Io.value,K=M.value,pe=re.value,Lt=Jt.value,Ve=Object.assign({},U,{showOverflow:!0,showHeaderOverflow:!0,showFooterOverflow:!0});if(Q){const{border:wt}=Q;B.default.eqNull(wt)||(Ve.border=wt)}return(e&&!Ve.footerData||K.footer&&_.length)&&(Ve.footerData=_),E&&(Ve.maxHeight?Ve.maxHeight="100%":Ve.height="100%"),m&&ne(K)&&(Ve.loading=Lt,a&&K.seq&&ne(pe)&&(Ve.seqConfig=Object.assign({},t,{startIndex:(H.currentPage-1)*H.pageSize}))),p&&(Ve.editConfig=Object.assign({},p)),Ve}),Bo=(0,n.computed)(()=>{const{layouts:e}=o;let t=[];e&&e.length?t=e:t=ve().gantt.layouts||xn;let a=[],p=[],m=[];return t.length&&(B.default.isArray(t[0])?(a=t[0],p=t[1]||[],m=t[2]||[]):p=t),{headKeys:a,bodyKeys:p,footKeys:m}}),Ct=(0,n.computed)(()=>re.value.currentPage),Qo=(0,n.computed)(()=>re.value.pageSize),fo=(0,n.computed)(()=>re.value.total),Oo=(0,n.computed)(()=>{const{tablePage:e}=y;return Math.max(Math.ceil(e.total/e.pageSize),1)}),Jt=(0,n.computed)(()=>{const{loading:e,proxyConfig:t}=o,{tableLoading:a}=y,p=M.value,{showLoading:m}=p;return e||a&&m&&t&&ne(p)}),po=(0,n.computed)(()=>{let{border:e}=o;const t=nt.value,{viewStyle:a}=t;return a&&(B.default.eqNull(a.border)||(e=a.border)),e===!0?"full":e||"default"}),la={refElem:ae,refTable:Z,refForm:ie,refToolbar:at,refPager:Ee,refGanttView:Pe,refGanttContainerElem:qe,refClassifyWrapperElem:Fe,refPopupContainerElem:Re},$t={computeSize:It,computeIsVScrollbar:we,computeProxyOpts:M,computePagerOpts:re,computeFormOpts:he,computeToolbarOpts:ke,computeZoomOpts:rt,computeTaskOpts:De,computeTaskViewScaleOpts:Ke,computeTaskNowLineOpts:We,computeTaskViewOpts:nt,computeTaskBarOpts:st,computeTaskBarMoveOpts:Ie,computeTaskBarMoveTooltipOpts:Be,computeTaskBarResizeOpts:mt,computeTaskBarResizeTooltipOpts:Je,computeTaskSplitOpts:ht,computeTaskBarMilestoneOpts:bt,computeTaskCriticalPathOpts:Te,computeTaskBarSubviewOpts:xe,computeTaskBarTooltipOpts:vt,computeTaskLinkOpts:Bt,computeTaskViewScales:Ht,computeScaleUnit:co,computeDateFormat:io,computeMinScale:zt,computeScaleStep:Nt,computeWeekScale:uo,computeTitleField:At,computeStartField:To,computeEndField:Co,computeTypeField:de,computeProgressField:Xt,computeScrollbarOpts:_t,computeScrollbarXOpts:Tt,computeScrollbarYOpts:jt,computeScrollbarXToTop:Kt,computeScrollbarYToLeft:Eo};$t.computeTaskScaleConfs=Ht;const b={xID:ee,props:o,context:F,reactData:y,internalData:P,getRefMaps:()=>la,getComputeMaps:()=>$t},Vt=()=>{const e=Ht.value,t=Ke.value,a=[],p={};(e&&e.length?e:["month","date"]).forEach(E=>{const H=!E||B.default.isString(E)?{type:E}:E,_=H.type,j=yn(_);if(!_||!Ta[_]){xt("vxe.error.errProp",[`type=${_}`,B.default.keys(Ta).join(",")]);return}if(p[_]){xt("vxe.error.repeatProp",["type",_]);return}const Q=Object.assign({},_?t[_]||{}:{},H,{level:j});p[_]=!0,a.push(Q)}),y.taskScaleList=B.default.orderBy(a,{field:"level",order:"desc"})},Ue=()=>{const e=ke.value;o.toolbarConfig&&ne(e)&&(0,n.nextTick)(()=>{const t=Z.value,a=at.value;t&&a&&t.connectToolbar(a)})},$e=()=>{const e=Z.value,t=Pe.value;e&&t&&e.handleConnectGanttView(t)},ze=()=>{const{proxyConfig:e}=o,{formData:t}=y,a=M.value,p=he.value;return e&&ne(a)&&a.form?t:p.data},Et=e=>{const{tablePage:t}=y,{pagerConfig:a}=o,p=re.value;if(a&&ne(p))if(e)p[e]&&(t[e]=B.default.toNumber(p[e]));else{const{currentPage:m,pageSize:E,total:H}=p;m&&(t.currentPage=m),E&&(t.pageSize=E),H&&(t.total=H)}},eo=e=>{const t=Ze.value,a=Z.value,p=a?a.getCheckboxRecords():[];p.length?(a&&a.togglePendingRow(p),b.clearCheckboxRow()):t&&Se.VxeUI.modal&&Se.VxeUI.modal.message({id:e,content:Xo("vxe.grid.selectOneRecord"),status:"warning"})},go=(e,t)=>{const a=M.value,m=(a.response||a.props||{}).message,E=Z.value;let H;return e&&m&&(H=B.default.isFunction(m)?m({data:e,$table:E,$grid:null,$gantt:b}):B.default.get(e,m)),H||Xo(t)},zo=(e,t,a)=>{const p=Ze.value,m=b.getCheckboxRecords();if(p)if(m.length){if(Se.VxeUI.modal)return Se.VxeUI.modal.confirm({id:`cfm_${e}`,content:Xo(t),escClosable:!0}).then(E=>{if(E==="confirm")return a()})}else Se.VxeUI.modal&&Se.VxeUI.modal.message({id:`msg_${e}`,content:Xo("vxe.grid.selectOneRecord"),status:"warning"});else m.length&&a();return Promise.resolve()},ho=e=>{const{proxyConfig:t}=o,{tablePage:a}=y,{$event:p,currentPage:m,pageSize:E}=e,H=M.value;a.currentPage=m,a.pageSize=E,b.dispatchEvent("page-change",e,p),t&&ne(H)&&b.commitProxy("query").then(_=>{b.dispatchEvent("proxy-query",_,p)})},Ho=e=>{const t=Z.value,{proxyConfig:a}=o;if(!t)return;const{computeSortOpts:p}=t.getComputeMaps(),m=M.value;p.value.remote&&(y.sortData=e.sortList,a&&ne(m)&&(y.tablePage.currentPage=1,b.commitProxy("query").then(H=>{b.dispatchEvent("proxy-query",H,e.$event)})))},to=e=>{Ho(e),b.dispatchEvent("sort-change",e,e.$event)},Ro=e=>{Ho(e),b.dispatchEvent("clear-all-sort",e,e.$event)},_o=e=>{const t=Z.value,{proxyConfig:a}=o;if(!t)return;const{computeFilterOpts:p}=t.getComputeMaps(),m=M.value;p.value.remote&&(y.filterData=e.filterList,a&&ne(m)&&(y.tablePage.currentPage=1,P.uFoot=!0,b.commitProxy("query").then(H=>{b.dispatchEvent("proxy-query",H,e.$event)}),P.uFoot=!1,u()))},oo=e=>{_o(e),b.dispatchEvent("filter-change",e,e.$event)},Zo=e=>{_o(e),b.dispatchEvent("clear-all-filter",e,e.$event)},Ea=e=>{const{proxyConfig:t}=o,a=M.value;y.tableLoading||(t&&ne(a)&&(P.uFoot=!0,b.commitProxy("reload").then(p=>{b.dispatchEvent("proxy-query",{...p,isReload:!0},e.$event)}),P.uFoot=!1,u()),b.dispatchEvent("form-submit",e,e.$event))},$o=e=>{const t=Z.value,{proxyConfig:a}=o,{$event:p}=e,m=M.value;a&&ne(m)&&(t&&t.clearScroll(),P.uFoot=!0,b.commitProxy("reload").then(E=>{b.dispatchEvent("proxy-query",{...E,isReload:!0},p)}),P.uFoot=!1,u()),b.dispatchEvent("form-reset",e,p)},Dt=e=>{b.dispatchEvent("form-submit-invalid",e,e.$event)},r=e=>{const{$event:t}=e;b.dispatchEvent("form-toggle-collapse",e,t),b.dispatchEvent("form-collapse",e,t)},l=e=>{const{isZMax:t}=y;return(e?!t:t)&&(y.isZMax=!t,y.tZindex<jr()&&(y.tZindex=_r())),(0,n.nextTick)().then(()=>b.recalculate(!0)).then(()=>(setTimeout(()=>b.recalculate(!0),15),y.isZMax))},s=(e,t)=>{const a=e[t];if(a)if(B.default.isString(a)){if(W[a])return W[a];xt("vxe.error.notSlot",[a])}else return a;return null},v=e=>{const t={};return B.default.objectMap(e,(a,p)=>{a&&(B.default.isString(a)?W[a]?t[p]=W[a]:xt("vxe.error.notSlot",[a]):t[p]=a)}),t},S=e=>{const t=ae.value;if(!t)return;const a=qe.value;if(!a)return;const p=Xe.value;if(!p)return;const m=Qe.value;if(!m)return;const E=nt.value,H=a.getBoundingClientRect(),_=m.children[0],j=e.clientX,Q=a.clientWidth,U=p.clientWidth,K=E.tableStyle&&B.default.toNumber(E.tableStyle.minWidth)||80;let pe=U,Lt=-1;Wa(t,"is--split-drag");const Ve=wt=>{const vo=_.children[0],Gt=_.children[1];let mo=0;vo&&(Lt<0?vo.style.display="none":(vo.textContent=`${pe}px`,vo.style.display="block",mo=vo.offsetHeight)),Gt&&(Lt<0?(Gt.textContent=`${Math.floor(H.width-pe)}px`,Gt.style.display="block",mo=Gt.offsetHeight):Gt.style.display="none");const jo=wt.clientY-H.top-mo/2;m.style.left=`${pe}px`,_.style.top=`${Math.min(H.height-mo-1,Math.max(1,jo))}px`};document.onmousemove=wt=>{wt.preventDefault(),Lt=wt.clientX-j,pe=Math.min(Q-80,Math.max(K,U+Lt)),Ve(wt)},document.onmouseup=()=>{document.onmousemove=null,document.onmouseup=null,m.style.display="",p.style.width=`${pe}px`,va(t,"is--split-drag");const wt=Z.value;wt&&wt.recalculate(!0)},m.style.display="block",Ve(e)},h=()=>{const e=ht.value,{animation:t}=e;if(t){const{_taTime:a}=P;a&&clearTimeout(a),y.showSplitAnimat=!0,P._taTime=setTimeout(()=>{y.showSplitAnimat=!1,P._taTime=null},350)}},d=()=>{h(),y.showLeftView=!y.showLeftView},k=()=>{h(),y.showRightView=!y.showRightView},C={};ar.forEach(e=>{const t=B.default.camelCase(`on-${e}`);C[t]=(...a)=>me(e,...a)});const f=()=>{const e=he.value;if(e.items){const t={};return e.items.forEach(a=>{const{field:p,itemRender:m}=a;if(p){let E=null;if(m){const{startField:H,endField:_,defaultValue:j}=m;B.default.isFunction(j)?E=j({item:a}):B.default.isUndefined(j)||(E=j),H&&_&&(B.default.set(t,H,null),B.default.set(t,_,null))}t[p]=E}}),t}return{}},w=()=>{const{proxyConfig:e,formConfig:t}=o,{proxyInited:a}=y,p=M.value,m=he.value;e&&ne(p)&&(t&&ne(m)&&p.form&&m.items&&(y.formData=f()),a||(y.proxyInited=!0,p.autoLoad!==!1&&(0,n.nextTick)().then(()=>{P.uFoot=!0;const E=b.commitProxy("initial");return P.uFoot=!1,u(),E}).then(E=>{c("proxy-query",{...E,isInited:!0},new Event("initial"))})))},u=()=>{const e=M.value,{ajax:t}=e;if(t&&t.queryFooter)return b.commitProxy("queryFooter")},g=e=>{const t=rt.value;Na.hasKey(e,bn.ESCAPE)&&y.isZMax&&t.escRestore!==!1&&b.triggerZoomEvent(e)},c=(e,t,a)=>{me(e,mn(a,{$grid:null,$gantt:b},t))},D=e=>{const t=be.value;clearTimeout(P.barTipTimeout),e?b.closeTaskBarTooltip():t&&t.setActived&&t.setActived(!0)},$={dispatchEvent:c,getEl(){return ae.value},commitProxy(e,...t){const{showFooter:a,proxyConfig:p,toolbarConfig:m,pagerConfig:E,editRules:H,validConfig:_}=o,{tablePage:j}=y,Q=Ze.value,U=V.value,K=M.value,pe=re.value,Lt=ke.value,{beforeQuery:Ve,afterQuery:wt,beforeQueryFooter:vo,afterQueryFooter:Gt,beforeDelete:mo,afterDelete:jo,beforeSave:ia,afterSave:Ko,ajax:oe={}}=K,Ft=K.response||K.props||{},G=Z.value;if(!G)return(0,n.nextTick)();let bo=ze(),ao=null,et=null;if(B.default.isString(e)){const{buttons:Me}=Lt,He=m&&ne(Lt)&&Me?B.default.findTree(Me,_e=>_e.code===e,{children:"dropdowns"}):null;ao=He?He.item:null,et=e}else ao=e,et=ao.code;const Da=ao?ao.params:null;switch(et){case"insert":return G.insert({});case"insert_edit":return G.insert({}).then(({row:Me})=>G.setEditRow(Me,!0));case"insert_actived":return G.insert({}).then(({row:Me})=>G.setEditRow(Me,!0));case"mark_cancel":eo(et);break;case"remove":return zo(et,"vxe.grid.removeSelectRecord",()=>G.removeCheckboxRow());case"import":G.importData(Da);break;case"open_import":G.openImport(Da);break;case"export":G.exportData(Da);break;case"open_export":G.openExport(Da);break;case"reset_custom":return G.resetCustom(!0);case"initial":case"reload":case"query":{const Me=oe.beforeQuery,He=oe.query,_e=oe.afterQuery,qt=oe.querySuccess,Qt=oe.queryError;if(He){const tt=et==="initial",Rt=et==="reload";if(!tt&&y.tableLoading)return(0,n.nextTick)();let Pt=null,Ge=[],Ce=[],je={};if(E&&((tt||Rt)&&(j.currentPage=1),ne(pe)&&(je={...j})),tt){if(p&&ne(K)&&K.form&&(bo=f(),y.formData=bo),G){const Ye=G.internalData,{tableFullColumn:it,fullColumnFieldData:wo}=Ye,{computeSortOpts:kt}=G.getComputeMaps();let xo=kt.value.defaultSort;it.forEach(ea=>{ea.order=null}),xo&&(B.default.isArray(xo)||(xo=[xo]),Ge=xo.map(ea=>{const{field:Xa,order:Er}=ea,Dr=wo[Xa];if(Dr){const Or=Dr.column;Or&&(Or.order=Er)}return{field:Xa,property:Xa,order:Er}})),Ce=G.getCheckedFilters()}}else G&&(Rt?Pt=G.clearAll():(Ge=G.getSortColumns(),Ce=G.getCheckedFilters()));const ro={$table:G,$grid:null,$gantt:b,code:et,button:ao,isInited:tt,isReload:Rt,page:je,sort:Ge.length?Ge[0]:{},sorts:Ge,filters:Ce,form:bo,options:He},Vo=()=>(y.sortData=Ge,y.filterData=Ce,y.tableLoading=!0,Promise.all([Promise.resolve((Ve||He)(ro,...t)),Pt]).then(([Ye])=>{if(y.tableLoading=!1,_e)_e({...ro,response:Ye,status:"success"},...t);else{let it=[];if(Ye){const wo={data:Ye,$table:G,$grid:null,$gantt:b};if(E&&ne(pe)){const kt=Ft.total,Jo=(B.default.isFunction(kt)?kt(wo):B.default.get(Ye,kt||"page.total"))||0;j.total=B.default.toNumber(Jo);const xo=Ft.result;it=(B.default.isFunction(xo)?xo(wo):B.default.get(Ye,xo||"result"))||[];const ea=Math.max(Math.ceil(Jo/j.pageSize),1);j.currentPage>ea&&(j.currentPage=ea)}else{const kt=Ft.list;B.default.isArray(Ye)?it=Ye:kt&&(it=(B.default.isFunction(kt)?kt(wo):B.default.get(Ye,kt))||[])}if(a){const kt=Ft.footerData,Jo=kt?B.default.isFunction(kt)?kt(wo):B.default.get(Ye,kt):[];B.default.isArray(Jo)&&(y.footerData=Jo)}}G?G.loadData(it):(0,n.nextTick)(()=>{const wo=Z.value;wo&&wo.loadData(it)}),wt&&wt({...ro,response:Ye},...t)}return qt&&qt({...ro,response:Ye}),{status:!0}}).catch(Ye=>(y.tableLoading=!1,_e&&_e({...ro,response:Ye,status:"error"},...t),Qt&&Qt({...ro,response:Ye}),{status:!1})));return Me?Promise.resolve(Me(ro,...t)).then(Ye=>{if(Ye!==!1)return Vo()}):Vo()}else xt("vxe.error.notFunc",["proxy-config.ajax.query"]);break}case"queryFooter":{const Me=oe.beforeQueryFooter,He=oe.queryFooter,_e=oe.afterQueryFooter,qt=oe.queryFooterSuccess,Qt=oe.queryFooterError;if(He){let tt=[];G&&(tt=G.getCheckedFilters());let Rt={};E&&ne(pe)&&(Rt={...j});const Pt={$table:G,$grid:null,$gantt:b,code:et,button:ao,page:Rt,filters:tt,form:bo,options:He},Ge=()=>Promise.resolve((vo||He)(Pt,...t)).then(Ce=>(_e?_e({...Pt,response:Ce,status:"success"},...t):(y.footerData=B.default.isArray(Ce)?Ce:[],Gt&&Gt({...Pt,response:Ce},...t)),qt&&qt({...Pt,response:Ce}),{status:!0})).catch(Ce=>(_e&&_e({...Pt,response:Ce,status:"error"},...t),Qt&&Qt({...Pt,response:Ce}),{status:!1}));return Me?Promise.resolve(Me(Pt,...t)).then(Ce=>{if(Ce!==!1)return Ge()}):Ge()}else xt("vxe.error.notFunc",["proxy-config.ajax.queryFooter"]);break}case"delete":{const Me=oe.beforeDelete,He=oe.delete,_e=oe.afterDelete,qt=oe.deleteSuccess,Qt=oe.deleteError;if(He){const tt=b.getCheckboxRecords(),Rt=tt.filter(Ce=>!G.isInsertByRow(Ce)),Ge={$table:G,$grid:null,$gantt:b,code:et,button:ao,body:{removeRecords:Rt},form:bo,options:He};if(tt.length)return zo(et,"vxe.grid.deleteSelectRecord",()=>{if(!Rt.length)return G.remove(tt);const Ce=()=>(y.tableLoading=!0,Promise.resolve((mo||He)(Ge,...t)).then(je=>(y.tableLoading=!1,_e?_e({...Ge,response:je,status:"success"},...t):(G.setPendingRow(Rt,!1),U&&Se.VxeUI.modal&&Se.VxeUI.modal.message({content:go(je,"vxe.grid.delSuccess"),status:"success"}),jo?jo({...Ge,response:je},...t):(P.uFoot=!0,b.commitProxy("query"),P.uFoot=!1,u())),qt&&qt({...Ge,response:je}),{status:!0})).catch(je=>(y.tableLoading=!1,_e?_e({...Ge,response:je,status:"error"},...t):U&&Se.VxeUI.modal&&Se.VxeUI.modal.message({id:et,content:go(je,"vxe.grid.operError"),status:"error"}),Qt&&Qt({...Ge,response:je}),{status:!1})));return Me?Promise.resolve(Me(Ge,...t)).then(je=>{if(je!==!1)return Ce()}):Ce()});Q&&Se.VxeUI.modal&&Se.VxeUI.modal.message({id:et,content:Xo("vxe.grid.selectOneRecord"),status:"warning"})}else xt("vxe.error.notFunc",["proxy-config.ajax.delete"]);break}case"save":{const Me=oe.beforeSave,He=oe.save,_e=oe.afterSave,qt=oe.saveSuccess,Qt=oe.saveError;if(He){const tt=G.getRecordset(),{insertRecords:Rt,removeRecords:Pt,updateRecords:Ge,pendingRecords:Ce}=tt,je={$table:G,$grid:null,$gantt:b,code:et,button:ao,body:tt,form:bo,options:He};Rt.length&&(tt.pendingRecords=Ce.filter(Vo=>G.findRowIndexOf(Rt,Vo)===-1)),Ce.length&&(tt.insertRecords=Rt.filter(Vo=>G.findRowIndexOf(Ce,Vo)===-1));let ro=Promise.resolve();return H&&(ro=G[_&&_.msgMode==="full"?"fullValidate":"validate"](tt.insertRecords.concat(Ge))),ro.then(Vo=>{if(!Vo)if(tt.insertRecords.length||Pt.length||Ge.length||tt.pendingRecords.length){const Ye=()=>(y.tableLoading=!0,Promise.resolve((ia||He)(je,...t)).then(it=>(y.tableLoading=!1,_e?_e({...je,response:it,status:"success"},...t):(G.clearPendingRow(),U&&Se.VxeUI.modal&&Se.VxeUI.modal.message({content:go(it,"vxe.grid.saveSuccess"),status:"success"}),Ko?Ko({...je,response:it},...t):(P.uFoot=!0,b.commitProxy("query"),P.uFoot=!1,u())),qt&&qt({...je,response:it}),{status:!0})).catch(it=>(y.tableLoading=!1,_e?_e({...je,response:it,status:"error"},...t):U&&Se.VxeUI.modal&&Se.VxeUI.modal.message({id:et,content:go(it,"vxe.grid.operError"),status:"error"}),Qt&&Qt({...je,response:it}),{status:!1})));return Me?Promise.resolve(Me(je,...t)).then(it=>{if(it!==!1)return Ye()}):Ye()}else Q&&Se.VxeUI.modal&&Se.VxeUI.modal.message({id:et,content:Xo("vxe.grid.dataUnchanged"),status:"info"})})}else xt("vxe.error.notFunc",["proxy-config.ajax.save"]);break}default:{const Me=hn.get(et);if(Me){const He=Me.tableCommandMethod||Me.commandMethod;He?He({code:et,button:ao,$table:G,$grid:null,$gantt:b},...t):xt("vxe.error.notCommands",[et])}}}return(0,n.nextTick)()},getParams(){return o.params},zoom(){return y.isZMax?b.revert():b.maximize()},isMaximized(){return y.isZMax},maximize(){return l(!0)},revert(){return l()},getFormData:ze,getFormItems(e){const t=he.value,{formConfig:a}=o,{items:p}=t,m=[];return B.default.eachTree(a&&ne(t)&&p?p:[],E=>{m.push(E)},{children:"children"}),B.default.isUndefined(e)?m:m[e]},getFormFlatItems(){const e=ie.value;return e?e.getFlatItems():[]},getFormNestedItems(){const e=ie.value;return e?e.getNestedItems():[]},getFormItemByField(e){const t=ie.value;return t?t.getItemByField(e):null},resetForm(){const e=ie.value;return e?e.reset():(0,n.nextTick)()},validateForm(){const e=ie.value;return e?e.validate():(0,n.nextTick)()},validateFormField(e){const t=ie.value;return t?t.validateField(e):(0,n.nextTick)()},clearFormValidate(e){const t=ie.value;return t?t.clearValidate(e):(0,n.nextTick)()},homePage(){const{tablePage:e}=y;return e.currentPage=1,(0,n.nextTick)()},homePageByEvent(e){const t=Ee.value;t&&t.homePageByEvent(e)},endPage(){const{tablePage:e}=y,t=Oo.value;return e.currentPage=t,(0,n.nextTick)()},endPageByEvent(e){const t=Ee.value;t&&t.endPageByEvent(e)},getCurrentPage(){const{tablePage:e}=y;return e.currentPage},setCurrentPage(e){const{tablePage:t}=y,a=Oo.value;return t.currentPage=Math.min(a,Math.max(1,B.default.toNumber(e))),(0,n.nextTick)()},setCurrentPageByEvent(e,t){const a=Ee.value;a&&a.setCurrentPageByEvent(e,t)},getPageSize(){const{tablePage:e}=y;return e.pageSize},setPageSize(e){const{tablePage:t}=y;return t.pageSize=Math.max(1,B.default.toNumber(e)),(0,n.nextTick)()},setPageSizeByEvent(e,t){const a=Ee.value;a&&a.setPageSizeByEvent(e,t)},getProxyInfo(){const e=Z.value;if(o.proxyConfig){const{sortData:t}=y;return{data:e?e.getFullData():[],filter:y.filterData,form:ze(),sort:t.length?t[0]:{},sorts:t,pager:y.tablePage,pendingRecords:e?e.getPendingRecords():[]}}return null},getCustomPagerData(){const{pagerConfig:e}=o,{tablePage:t}=y,a=re.value;return e&&ne(a)?{pSize:t.pageSize}:{}},refreshTaskView(){const e=Pe.value;return e?e.refreshData():(0,n.nextTick)()},hasTableViewVisible(){return y.showLeftView},showTableView(){return y.showLeftView=!0,(0,n.nextTick)()},hideTableView(){return y.showLeftView=!1,y.showRightView||(y.showRightView=!0),(0,n.nextTick)()},hasTaskViewVisible(){return y.showRightView},showTaskView(){return y.showRightView=!0,(0,n.nextTick)()},hideTaskView(){return y.showRightView=!1,y.showLeftView||(y.showLeftView=!0),(0,n.nextTick)()},closeTaskBarTooltip(){const{barTipStore:e}=y,t=be.value;return e.visible&&(Object.assign(e,{row:null,content:null,visible:!1,params:{}}),t&&t.close&&t.close()),(0,n.nextTick)()},scrollToDateView(e){const t=Pe.value;if(t){const a=t.reactData,p=t.internalData,{viewCellWidth:m}=a,{visibleColumn:E,elemStore:H}=p,j=B.default.toStringDate(e).getTime(),Q=B.default.findIndexOf(E,K=>j===K.dateObj.date.getTime()),U=le(H["main-body-scroll"]);Q>-1&&U&&(U.scrollLeft=B.default.floor(Q*m))}return(0,n.nextTick)()},scrollToTaskView(e){const t=Z.value;if(t){const a=B.default.isString(e)||B.default.isNumber(e)?e:t.getRowid(e);return t.scrollToRow(e).then(()=>{const p=Pe.value;if(p){const m=p.reactData,E=p.internalData,{viewCellWidth:H}=m,{chartMaps:_,elemStore:j}=E,Q=a?_[a]:null;if(Q){const U=le(j["main-body-scroll"]);U&&(U.scrollLeft=B.default.floor(Q.oLeftSize*H))}}})}return(0,n.nextTick)()},getCriticalPath(){const{criticalRowIds:e,criticalLinks:t}=y,{criticalRowMaps:a}=P;return{rowIds:e.slice(0),rows:Array.from(a.values()),links:t.slice(0)}}},R={extendTableMethods:pt,callSlot(e,t){return e&&(B.default.isString(e)&&(e=W[e]||null),B.default.isFunction(e))?Xr(e(t)):[]},getExcludeHeight(){const{height:e}=o,{isZMax:t}=y,a=ae.value;if(a){const p=dt.value,m=A.value,E=te.value,H=se.value,_=Ae.value,j=a.parentElement;let Q=0;return j&&(e==="100%"||e==="auto")&&(Q=t?0:tr(j)),Q+tr(a)+aa(p)+aa(m)+aa(E)+aa(H)+aa(_)}return 0},getParentElem(){const e=ae.value;if(!e)return null;let t=e.parentElement;return t&&So(t,"vxe-scrollbar--view-inner")&&(t=t.parentElement),t},getParentHeight(){if(ae.value){const t=b.getParentElem();return(y.isZMax?Nr().visibleHeight:t?B.default.toNumber(getComputedStyle(t).height):0)-R.getExcludeHeight()}return 0},triggerToolbarCommitEvent(e,t){const{code:a}=e;if(a){const p=["reload","delete","save"].includes(a);p&&(P.uFoot=!0);const m=b.commitProxy(e,t).then(E=>{E&&E.status&&["query","reload","delete","save"].includes(a)&&b.dispatchEvent(a==="delete"||a==="save"?`proxy-${a}`:"proxy-query",{...E,isReload:a==="reload"},t)});return P.uFoot=!1,p&&u(),m}return(0,n.nextTick)()},triggerToolbarBtnEvent(e,t){b.triggerToolbarCommitEvent(e,t),b.dispatchEvent("toolbar-button-click",{code:e.code,button:e},t)},triggerToolbarTolEvent(e,t){b.triggerToolbarCommitEvent(e,t),b.dispatchEvent("toolbar-tool-click",{code:e.code,tool:e},t)},triggerZoomEvent(e){b.zoom(),b.dispatchEvent("zoom",{type:y.isZMax?"max":"revert"},e)},handleTaskCellClickEvent(e,t){const a=Z.value;if(a){const p=a.props,{highlightCurrentRow:m}=p,E=a.reactData,{radioColumn:H,checkboxColumn:_}=E,{computeRadioOpts:j,computeCheckboxOpts:Q,computeRowOpts:U}=a.getComputeMaps(),K=j.value,pe=Q.value,Lt=U.value,{row:Ve}=t;(Lt.isCurrent||m)&&a.triggerCurrentRowEvent(e,Object.assign({$table:a,rowIndex:a.getRowIndex(Ve),$rowIndex:a.getVMRowIndex(Ve)},t)),H&&K.trigger==="row"&&a.triggerRadioRowEvent(e,t),_&&pe.trigger==="row"&&a.handleToggleCheckRowEvent(e,t)}y.isActiveCeLe=!1,y.activeBarRowid=null,y.activeLink=null,b.dispatchEvent("task-cell-click",t,e)},handleTaskCellDblclickEvent(e,t){b.dispatchEvent("task-cell-dblclick",t,e)},handleTaskBarClickEvent(e,t){const a=Z.value,p=st.value,{linkCreatable:m}=p,{row:E}=t;y.isActiveCeLe=!!m,y.activeBarRowid=a?a.getRowid(E):E,y.activeLink=null,b.dispatchEvent("task-bar-click",t,e)},handleTaskBarDblclickEvent(e,t){b.dispatchEvent("task-bar-dblclick",t,e)},triggerTaskBarTooltipEvent(e,t){const{barTipStore:a,activeLink:p}=y,{dragBarRow:m,dragLineRow:E}=P;if(m||E||p)return;const H=vt.value,_=At.value,{contentMethod:j}=H,{row:Q}=t;let U=Ka(B.default.get(Q,_));if(j){const pe=j(t);B.default.eqNull(pe)||(U=`${pe}`)}D(a.row!==Q);const K=Ka(U);Object.assign(a,{row:Q,visible:!0,content:K,params:t}),(0,n.nextTick)(()=>{const pe=be.value;pe&&(pe.openByEvent?pe.openByEvent(e,e.currentTarget,K):pe.open&&pe.open(e.currentTarget,K))})},handleTaskBarTooltipLeaveEvent(){const e=vt.value;let t=be.value;t&&t.setActived&&t.setActived(!1),e.enterable?P.barTipTimeout=setTimeout(()=>{t=be.value,t&&t.isActived&&!t.isActived()&&b.closeTaskBarTooltip()},e.leaveDelay):b.closeTaskBarTooltip()},handleTaskHeaderContextmenuEvent(e,t){const a=Z.value;if(a){const p=a.props,{menuConfig:m}=p;ne(m)&&(e.stopPropagation(),a.handleOpenMenuEvent(e,"header",t),a.dispatchEvent("header-cell-menu",t,e))}},handleTaskBodyContextmenuEvent(e,t){const a=Z.value;if(a){const p=a.props,{menuConfig:m}=p;ne(m)&&(e.stopPropagation(),a.handleOpenMenuEvent(e,"body",t),a.dispatchEvent("cell-menu",t,e))}},handleTaskFooterContextmenuEvent(e,t){const a=Z.value;if(a){const p=a.props,{menuConfig:m}=p;ne(m)&&(e.stopPropagation(),a.handleOpenMenuEvent(e,"footer",t),a.dispatchEvent("footer-cell-menu",t,e))}},handleTaskBarContextmenuEvent(e,t){const a=Z.value;if(a){const p=a.props,{menuConfig:m}=p;ne(m)&&(e.stopPropagation(),a.handleOpenMenuEvent(e,"body",t),a.dispatchEvent("cell-menu",t,e))}}};Object.assign(b,gt,$,R,{loadColumn(e){const t=Z.value;return B.default.eachTree(e,a=>{const{type:p}=a;a.slots&&B.default.each(a.slots,m=>{B.default.isFunction(m)||W[m]||xt("vxe.error.notSlot",[m])}),p==="expand"&&xt("vxe.error.errProp",["type=expand","type=seq,radio,checkbox,html"])}),y.currLeftSpacing=0,y.currRightSpacing=0,t?t.loadColumn(e):(0,n.nextTick)()},reloadColumn(e){return b.clearAll(),b.loadColumn(e)}});const x=()=>{const{formConfig:e,proxyConfig:t}=o,{formData:a}=y,p=M.value,m=he.value;if(e&&ne(m)||W.form){let E=[];if(W.form)E=W.form({$grid:null,$gantt:b});else if(m.items){const H={};if(!m.inited){m.inited=!0;const _=p.beforeItem;p&&_&&m.items.forEach(j=>{_({$grid:null,$gantt:b,item:j})})}m.items.forEach(_=>{B.default.each(_.slots,j=>{j&&!B.default.isFunction(j)&&W[j]&&(H[j]=W[j])})}),Ne&&E.push((0,n.h)(Ne,{ref:ie,...Object.assign({},m,{data:t&&ne(p)&&p.form?a:m.data}),onSubmit:Ea,onReset:$o,onSubmitInvalid:Dt,onCollapse:r},H))}return(0,n.h)("div",{ref:dt,key:"form",class:"vxe-gantt--form-wrapper"},E)}return yt(b)},T=()=>{const{toolbarConfig:e}=o,t=ke.value,a=W.toolbar;if(e&&ne(t)||a){let p=[];if(W.toolbar)p=W.toolbar({$grid:null,$gantt:b});else{const m=t.slots,E={};if(m){const H=s(m,"buttons"),_=s(m,"buttonPrefix"),j=s(m,"buttonSuffix"),Q=s(m,"tools"),U=s(m,"toolPrefix"),K=s(m,"toolSuffix");H&&(E.buttons=H),_&&(E.buttonPrefix=_),j&&(E.buttonSuffix=j),Q&&(E.tools=Q),U&&(E.toolPrefix=U),K&&(E.toolSuffix=K)}p.push((0,n.h)(Wt,{ref:at,...t,slots:void 0},E))}return(0,n.h)("div",{ref:A,key:"toolbar",class:"vxe-gantt--toolbar-wrapper"},p)}return yt(b)},L=()=>{const e=W.top;return e?(0,n.h)("div",{ref:te,key:"top",class:"vxe-gantt--top-wrapper"},e({$grid:null,$gantt:b})):yt(b)},I=()=>{const e=W.left;return e?(0,n.h)("div",{class:"vxe-gantt--left-wrapper"},e({$grid:null,$gantt:b})):yt(b)},z=()=>{const e=W.right;return e?(0,n.h)("div",{class:"vxe-gantt--right-wrapper"},e({$grid:null,$gantt:b})):yt(b)},Y=()=>{const{proxyConfig:e}=o,t=sa.value,a=M.value,p=Object.assign({},C),m=W.empty,E=W.loading,H=W.rowDragIcon||W["row-drag-icon"],_=W.columnDragIcon||W["column-drag-icon"],j=W.headerTooltip||W["header-tooltip"],Q=W.tooltip,U=W.footerTooltip||W["footer-tooltip"];e&&ne(a)&&(a.sort&&(p.onSortChange=to,p.onClearAllSort=Ro),a.filter&&(p.onFilterChange=oo,p.onClearAllFilter=Zo));const K={};return m&&(K.empty=m),E&&(K.loading=E),H&&(K.rowDragIcon=H),_&&(K.columnDragIcon=_),j&&(K.headerTooltip=j),Q&&(K.tooltip=Q),U&&(K.footerTooltip=U),(0,n.h)("div",{ref:Xe,class:"vxe-gantt--table-wrapper"},[(0,n.h)(Oe,{ref:Z,...t,...p},K)])},fe=()=>W.bottom?(0,n.h)("div",{ref:se,key:"bottom",class:"vxe-gantt--bottom-wrapper"},W.bottom({$grid:null,$gantt:b})):yt(b),ce=()=>{const{proxyConfig:e,pagerConfig:t}=o,a=M.value,p=re.value,m=W.pager;return t&&ne(p)||W.pager?(0,n.h)("div",{ref:Ae,key:"pager",class:"vxe-gantt--pager-wrapper"},m?m({$grid:null,$gantt:b}):[N?(0,n.h)(N,{ref:Ee,...p,...e&&ne(a)?y.tablePage:{},onPageChange:ho},v(p.slots)):yt(b)]):yt(b)},ue=()=>(0,n.h)("div",{ref:ft,class:"vxe-gantt--view-wrapper"},[(0,n.h)(pn,{ref:Pe})]),X=()=>{const{showLeftView:e,showRightView:t}=y,a=ht.value,{enabled:p,resize:m,showCollapseTableButton:E,showCollapseTaskButton:H}=a;if(!p)return yt(b);const _=m&&e&&t,j={};return _&&(j.onMousedown=S),(0,n.h)("div",{class:["vxe-gantt--view-split-bar",{"is--resize":_}]},[(0,n.h)("div",{class:"vxe-gantt--view-split-bar-handle",...j}),E||H?(0,n.h)("div",{class:"vxe-gantt--view-split-bar-btn-wrapper"},[E&&t?(0,n.h)("div",{class:["vxe-gantt--view-split-bar-action-btn",e?"is--prev":"is--next"],onClick:d},[(0,n.h)("i",{class:e?ka().GANTT_VIEW_LEFT_OPEN:ka().GANTT_VIEW_LEFT_CLOSE})]):yt(b),H&&e?(0,n.h)("div",{class:["vxe-gantt--view-split-bar-action-btn",t?"is--next":"is--prev"],onClick:k},[(0,n.h)("i",{class:t?ka().GANTT_VIEW_RIGHT_OPEN:ka().GANTT_VIEW_RIGHT_CLOSE})]):yt(b)]):yt(b)])},q=e=>{const{showLeftView:t,showRightView:a}=y,p=we.value,m=ht.value,E=Kt.value,H=Eo.value,_=Go.value,j=Wo.value,{autoHideCollapseButton:Q}=m,U=[];return e.forEach(K=>{switch(K){case"Form":U.push(x());break;case"Toolbar":U.push(T());break;case"Top":U.push(L());break;case"Gantt":U.push((0,n.h)("div",{ref:qe,key:"tv",class:["vxe-gantt--gantt-container",`sx-pos--${E?"top":"bottom"}`,`sy-pos--${H?"left":"right"}`,{"is--virtual-scrollbar":p,"ov-x--auto-hide":p&&_,"ov-y--auto-hide":p&&j,"show--left":t,"hide--left":!t,"show--right":a,"hide--right":!a,"is--ah-split-btn":Q}]},[I(),Y(),X(),ue(),z(),(0,n.h)("div",{ref:Fe}),(0,n.h)("div",{ref:Qe,class:"vxe-gantt--resizable-split-tip"},[(0,n.h)("div",{class:"vxe-gantt--resizable-split-tip-number"},[(0,n.h)("div",{class:"vxe-gantt--resizable-split-number-left"}),(0,n.h)("div",{class:"vxe-gantt--resizable-split-number-right"})])]),(0,n.h)("div",{class:"vxe-gantt--border-line"})]));break;case"Bottom":U.push(fe());break;case"Pager":U.push(ce());break;default:xt("vxe.error.notProp",[`layouts -> ${K}`]);break}}),U},ye=()=>{const{barTipStore:e}=y,t=Bo.value,{headKeys:a,bodyKeys:p,footKeys:m}=t,E=vt.value,H=W.asideLeft||W["aside-left"],_=W.asideRight||W["aside-right"],j=W.taskBarTooltip||W["task-bar-tooltip"];return[(0,n.h)("div",{class:"vxe-gantt--layout-header-wrapper"},q(a)),(0,n.h)("div",{class:"vxe-gantt--layout-body-wrapper"},[H?(0,n.h)("div",{class:"vxe-gantt--layout-aside-left-wrapper"},H({})):yt(b),(0,n.h)("div",{class:"vxe-gantt--layout-body-content-wrapper"},q(p)),_?(0,n.h)("div",{class:"vxe-gantt--layout-aside-right-wrapper"},_({})):yt(b)]),(0,n.h)("div",{class:"vxe-gantt--layout-footer-wrapper"},q(m)),(0,n.h)("div",{ref:Re}),(0,n.h)("div",{},[(0,n.h)(Yt,{key:"gtp",ref:be,theme:E.theme,enterable:E.enterable,enterDelay:E.enterDelay,leaveDelay:E.leaveDelay,useHtml:B.default.isBoolean(E.useHtml)?E.useHtml:E.useHTML,width:E.width,height:E.height,minWidth:E.minWidth,minHeight:E.minHeight,maxWidth:E.maxWidth,maxHeight:E.maxHeight,isArrow:!1},j?{content:()=>{const{row:Q,content:U}=e;return Q?(0,n.h)("div",{},j(Object.assign({tooltipContent:U,$gantt:b},e.params))):yt(b)}}:{})])]},Mt=()=>{const{showLeftView:e,showRightView:t,overflowY:a,overflowX:p,showSplitAnimat:m}=y,E=It.value,H=we.value,_=Do.value,j=Jt.value,Q=ht.value,U=po.value,K=Kt.value,pe=Eo.value;return(0,n.h)("div",{ref:ae,class:["vxe-gantt",`border--${U}`,`sx-pos--${K?"top":"bottom"}`,`sy-pos--${pe?"left":"right"}`,{[`size--${E}`]:E,"is--virtual-scrollbar":H,"is--round":o.round,"show--animat":Q.animation,"is--maximize":y.isZMax,"is--loading":j,"is--animat":m,"show--left":e,"hide--left":!e,"show--right":t,"hide--right":!t,"is--scroll-y":a,"is--scroll-x":p}],style:_},ye())},lt=(0,n.ref)(0);(0,n.watch)(()=>o.columns?o.columns.length:-1,()=>{lt.value++}),(0,n.watch)(()=>o.columns,()=>{lt.value++}),(0,n.watch)(lt,()=>{(0,n.nextTick)(()=>b.loadColumn(o.columns||[]))}),(0,n.watch)(()=>o.toolbarConfig,()=>{Ue()}),(0,n.watch)(Ct,()=>{Et("currentPage")}),(0,n.watch)(Qo,()=>{Et("pageSize")}),(0,n.watch)(fo,()=>{Et("total")}),(0,n.watch)(()=>o.proxyConfig,()=>{w()});const Ot=(0,n.ref)(0);return(0,n.watch)(Ht,()=>{Vt(),Ot.value++}),(0,n.watch)(qo,()=>{Ot.value++}),(0,n.watch)(Ot,()=>{b.refreshTaskView()}),(0,n.watch)(Fo,()=>{b.handleUpTaskLinkData&&b.handleUpTaskLinkData()}),vn.forEach(e=>{const{setupGantt:t}=e;if(t){const a=t(b);a&&B.default.isObject(a)&&Object.assign(b,a)}}),b.handleTaskLoadLinks&&o.links&&b.handleTaskLoadLinks(o.links),Vt(),Et(),(0,n.onMounted)(()=>{const e=xe.value,{barStyle:t}=e;t&&(t.top&&Ao("vxe.error.delProp",["task-bar-subview-config.barStyle.top","task-bar-subview-config.barStyle.style.top"]),t.backgroundColor&&Ao("vxe.error.delProp",["task-bar-subview-config.barStyle.backgroundColor","task-bar-subview-config.barStyle.style.backgroundColor"])),b.handleUpTaskLinkData||(o.links&&Ao("vxe.error.notProp",["links"]),o.taskLinkConfig&&Ao("vxe.error.notProp",["task-link-config"])),(0,n.nextTick)(()=>{const{columns:a}=o,p=M.value;if(o.formConfig&&(Ne||xt("vxe.error.reqComp",["vxe-form"])),o.pagerConfig&&(N||xt("vxe.error.reqComp",["vxe-pager"])),o.treeConfig&&o.links){const m=Z.value;if(m){const{computeTreeOpts:E}=m.getComputeMaps();E.value.transform||xt("vxe.error.notSupportProp",["links","tree-config.transform=false","tree-config.transform=true"])}}p.props&&Ao("vxe.error.delProp",["proxy-config.props","proxy-config.response"]),o.expandConfig&&Ao("vxe.error.notProp",["expand-config"]),a&&a.length&&b.loadColumn(a),Ue(),w()}),$e(),Na.on(b,"keydown",g)}),(0,n.onBeforeUnmount)(()=>{B.default.assign(y,Sr()),B.default.assign(P,yr())}),(0,n.onUnmounted)(()=>{Na.off(b,"keydown")}),b.renderVN=Mt,(0,n.provide)("$xeGrid",null),(0,n.provide)("$xeGantt",b),b},render(){return this.renderVN()}}),ra=Object.assign({},Ca,{install(o){Br(),o.component(Ca.name,Ca)}});Va.VxeUI.dynamicApp&&Va.VxeUI.dynamicApp.use(ra),Va.VxeUI.component(Ca);var kr=ra,Sn=ra,Tr=ge("@vxe-ui/core"),{setConfig:kn,setIcon:Tn}=Tr.VxeUI;Tr.VxeUI.ganttVersion="4.9.8";var Uo="yyyy-MM-dd",Aa="yyyy-MM-dd HH:mm:ss";kn({gantt:{formConfig:{enabled:!0},pagerConfig:{enabled:!0},toolbarConfig:{enabled:!0},proxyConfig:{enabled:!0,autoLoad:!0,showLoading:!0,showResponseMsg:!0,showActionMsg:!0,response:{list:null,result:"result",total:"page.total",message:"message"}},taskBarTooltipConfig:{enterable:!0},taskLinkConfig:{enabled:!0,isHover:!0,showArrow:!0},taskViewScaleConfig:{year:{valueFormat:Uo},quarter:{valueFormat:Uo},month:{valueFormat:Uo},week:{startDay:1,valueFormat:Uo},day:{valueFormat:Uo},date:{valueFormat:Uo},hour:{valueFormat:Aa},minute:{valueFormat:Aa},second:{valueFormat:Aa}},taskViewConfig:{showNowLine:!0,gridding:{leftSpacing:1,rightSpacing:1}},taskSplitConfig:{enabled:!0,resize:!0,autoHideCollapseButton:!0,showCollapseTableButton:!0,showCollapseTaskButton:!0},taskBarSubviewConfig:{},taskBarMoveConfig:{isLimitByLink:!0},taskBarResizeConfig:{minWidthSize:.5,isLimitByLink:!0},taskBarMoveTooltipConfig:{enterable:!0,enterDelay:0},taskBarResizeTooltipConfig:{enterable:!0,enterDelay:0}}});var na="vxe-icon-";Tn({GANTT_VIEW_LEFT_OPEN:na+"arrow-left",GANTT_VIEW_LEFT_CLOSE:na+"arrow-right",GANTT_VIEW_RIGHT_OPEN:na+"arrow-right",GANTT_VIEW_RIGHT_CLOSE:na+"arrow-left",GANTT_VIEW_TASK_MILESTONE:na+"square-fill rotate45"}),Ga(fa,ge("@vxe-ui/core"));var{setConfig:Cn}=$a.VxeUI,En=[Sn];function Cr(o,F){Cn(F),En.forEach(W=>o.use(W))}Ga(Ra,fa,ca.exports);var Dn=fa;return ca.exports});
|
package/lib/ui/index.js
CHANGED
|
@@ -23,7 +23,7 @@ __export(ui_exports, {
|
|
|
23
23
|
module.exports = __toCommonJS(ui_exports);
|
|
24
24
|
var import_core = require("@vxe-ui/core");
|
|
25
25
|
const { setConfig, setIcon } = import_core.VxeUI;
|
|
26
|
-
import_core.VxeUI.ganttVersion = "4.9.
|
|
26
|
+
import_core.VxeUI.ganttVersion = "4.9.8";
|
|
27
27
|
const ymdFormat = "yyyy-MM-dd";
|
|
28
28
|
const ymdhmsFormat = "yyyy-MM-dd HH:mm:ss";
|
|
29
29
|
setConfig({
|
package/lib/ui/src/log.js
CHANGED
|
@@ -25,7 +25,7 @@ __export(log_exports, {
|
|
|
25
25
|
module.exports = __toCommonJS(log_exports);
|
|
26
26
|
var import_core = require("@vxe-ui/core");
|
|
27
27
|
const { log } = import_core.VxeUI;
|
|
28
|
-
const ganttVersion = `gantt v${"4.9.
|
|
28
|
+
const ganttVersion = `gantt v${"4.9.8"}`;
|
|
29
29
|
function createComponentLog(name) {
|
|
30
30
|
const uiVersion = import_core.VxeUI.uiVersion ? `ui v${import_core.VxeUI.uiVersion}` : "";
|
|
31
31
|
const tableVersion = import_core.VxeUI.tableVersion ? `table v${import_core.VxeUI.tableVersion}` : "";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vxe-gantt",
|
|
3
|
-
"version": "4.9.
|
|
3
|
+
"version": "4.9.8",
|
|
4
4
|
"description": "A vue based gantt component",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"update": "npm install --legacy-peer-deps",
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"typescript": "~5.9.3",
|
|
73
73
|
"vue": "3.4.27",
|
|
74
74
|
"vue-router": "~4.5.1",
|
|
75
|
-
"vxe-pc-ui": "4.20.
|
|
75
|
+
"vxe-pc-ui": "4.20.30",
|
|
76
76
|
"vxe-table": "4.23.8"
|
|
77
77
|
},
|
|
78
78
|
"vetur": {
|
package/packages/components.ts
CHANGED
|
@@ -15,6 +15,10 @@ export function install(app: App, options?: VxeGlobalConfig) {
|
|
|
15
15
|
components.forEach((component) => app.use(component))
|
|
16
16
|
}
|
|
17
17
|
|
|
18
|
+
// eslint-disable-next-line import/export
|
|
19
|
+
export { VxeUI }
|
|
20
|
+
|
|
21
|
+
// eslint-disable-next-line import/export
|
|
18
22
|
export * from '@vxe-ui/core'
|
|
19
23
|
|
|
20
24
|
// Components
|