@stonecrop/atable 0.8.1 → 0.8.2

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.
@@ -1,3 +1,47 @@
1
- (function(F,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("pinia")):typeof define=="function"&&define.amd?define(["exports","vue","pinia"],e):(F=typeof globalThis<"u"?globalThis:F||self,e(F["@stonecrop/atable"]={},F.Vue,F.pinia))})(this,(function(F,e,st){"use strict";var He=document.createElement("style");He.textContent=`@import"https://fonts.googleapis.com/css2?family=Arimo:ital,wght@0,400..700;1,400..700&display=swap";.atable-cell{border-radius:0;box-sizing:border-box;outline:none;box-shadow:none;color:var(--sc-cell-text-color);padding-left:.5ch!important;padding-right:.5ch;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding);border-spacing:0px;border-collapse:collapse;overflow:hidden;text-overflow:ellipsis;order:1;white-space:nowrap;max-width:40ch;border-top:1px solid var(--sc-row-border-color);margin:0 0 0 1px}.atable-cell a{color:var(--sc-cell-text-color);text-decoration:none}.atable-cell:focus,.atable-cell:focus-within{background-color:var(--sc-focus-cell-background);outline-width:var(--sc-atable-cell-border-width);outline-style:solid;outline-offset:calc(var(--sc-atable-cell-border-width) * -1);outline-color:var(--sc-focus-cell-outline);box-shadow:none;overflow:hidden;text-wrap:nowrap;box-sizing:border-box}.cell-modified{font-weight:700;font-style:italic}.cell-modified-highlight{background-color:var(--sc-cell-changed-color)}.row-index{color:var(--sc-header-text-color);font-weight:700;text-align:center;-webkit-user-select:none;user-select:none;width:2ch;display:flex;align-items:center;justify-content:center}.expandable-row{border-top:1px solid var(--sc-row-border-color);height:var(--sc-atable-row-height)}.expandable-row>td:first-child{border-left:4px solid var(--sc-row-border-color)}.expanded-row{border-left:2px solid var(--sc-row-border-color)}.expandable-row:last-child{border-bottom:1px solid var(--sc-row-border-color)}.expanded-row-content{border-top:1px solid var(--sc-row-border-color);padding:1.5rem}.expandable-row.changed-row-gradient[data-v-a42297c7]:has(td.cell-modified){--cell-color-start: color-mix(in srgb, var(--sc-cell-changed-color), #fff 20%);--cell-color-end: color-mix(in srgb, var(--sc-cell-changed-color), #fff 60%);background:linear-gradient(90deg,var(--cell-color-start),var(--cell-color-end))}.aganttcell[data-v-8917a8a3]{background-color:#f9f9f9;width:100%;padding:0;height:100%}.gantt-container[data-v-8917a8a3]{position:relative;height:100%;background-color:#f0f0f0;border-radius:4px;overflow:visible}.gantt-bar[data-v-8917a8a3]{position:absolute;border-radius:4px;display:flex;align-items:center;justify-content:space-between;cursor:grab;box-sizing:border-box;border:1px solid rgba(0,0,0,.5);transition:left .1s ease-out,width .1s ease-out;height:80%;top:50%;z-index:2;transform:translateY(-50%)}.gantt-bar[data-v-8917a8a3]:active{cursor:grabbing}.gantt-bar.is-dragging[data-v-8917a8a3]{z-index:10}.gantt-label[data-v-8917a8a3]{flex:1;text-align:center;font-size:12px;color:#aaa;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;padding:0 8px;-webkit-user-select:none;user-select:none}.resize-handle[data-v-8917a8a3]{position:relative;width:12px;height:100%;cursor:ew-resize;display:flex;align-items:center;justify-content:center;z-index:0;background:#00000040}.left-resize-handle[data-v-8917a8a3]{border-right:1px solid rgba(0,0,0,.5)}.right-resize-handle[data-v-8917a8a3]{border-left:1px solid rgba(0,0,0,.5)}.handle-grip[data-v-8917a8a3]{width:4px;height:12px;border-radius:2px;background:#000c}.resize-handle[data-v-8917a8a3]:hover{background-color:#ffffff80}.vertical-indicator[data-v-8917a8a3]{position:absolute;width:2px;opacity:0;pointer-events:none;transition:opacity .2s ease;top:-100vh;height:100vh;z-index:5;background-color:var(--v6d722296)}.left-indicator[data-v-8917a8a3]{left:50%;transform:translate(-50%)}.right-indicator[data-v-8917a8a3]{right:50%;transform:translate(50%)}.resize-handle.is-dragging .vertical-indicator[data-v-8917a8a3]{opacity:.7}.gantt-container[data-v-8917a8a3]:after{content:"";position:absolute;inset:0;background-size:calc(100% / var(--v260b36f8)) 100%;background-image:linear-gradient(to right,rgba(0,0,0,.1) 1px,transparent 1px);pointer-events:none;z-index:1}.connection-handle[data-v-8917a8a3]{position:absolute;top:50%;transform:translateY(-50%);width:16px;height:16px;opacity:0;transition:opacity .2s ease;cursor:crosshair;z-index:15;display:flex;align-items:center;justify-content:center}.connection-handle.visible[data-v-8917a8a3]{opacity:1}.left-connection-handle[data-v-8917a8a3]{left:-16px}.right-connection-handle[data-v-8917a8a3]{right:-16px}.connection-dot[data-v-8917a8a3]{width:8px;height:8px;border-radius:50%;background-color:#2196f3;border:2px solid white;box-shadow:0 1px 3px #0000004d}.connection-handle:hover .connection-dot[data-v-8917a8a3]{background-color:#1976d2;transform:scale(1.2)}.connection-handle.is-dragging[data-v-8917a8a3]{opacity:1!important}.connection-handle.is-dragging .connection-dot[data-v-8917a8a3]{background-color:#1976d2;transform:scale(1.3);box-shadow:0 2px 8px #2196f366}.atable-row{background-color:#fff}.atable-row>td:first-child{border-left:4px solid var(--sc-row-border-color)}.list-index{color:var(--sc-header-text-color);font-weight:700;padding-left:var(--sc-atable-row-padding);padding-right:.5em;text-align:left;-webkit-user-select:none;user-select:none;width:7ch;text-overflow:ellipsis;overflow:hidden;box-sizing:border-box;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding)}.tree-index{color:var(--sc-header-text-color);font-weight:700;text-align:center;-webkit-user-select:none;user-select:none;width:2ch;box-sizing:border-box;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding)}.atable-row:has(td.cell-modified)>td.sticky-column,.atable-row:has(td.cell-modified)>th.sticky-column,.atable-row:has(td.cell-modified)>td.sticky-index,.atable-row:has(td.cell-modified)>th.sticky-index{background:var(--sc-cell-changed-color)}.atable-row.changed-row-gradient[data-v-0fa91f83]:has(td.cell-modified){--cell-color-start: color-mix(in srgb, var(--sc-cell-changed-color), #fff 20%);--cell-color-end: color-mix(in srgb, var(--sc-cell-changed-color), #fff 60%);background:linear-gradient(90deg,var(--cell-color-start),var(--cell-color-end))}.gantt-connection-overlay[data-v-71911260]{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none;z-index:1}.connection-path[data-v-71911260]{transition:stroke-width .2s ease;pointer-events:auto;cursor:pointer;stroke-dasharray:5px;stroke:var(--sc-cell-text-color)}#arrowhead-marker polygon[data-v-71911260]{fill:var(--sc-cell-text-color)}.animated-path[data-v-71911260]{animation:animated-dash-71911260 infinite 1.5s linear}.connection-path[data-v-71911260]:hover{stroke-width:3px}.connection-hitbox[data-v-71911260]{pointer-events:auto;cursor:pointer}@keyframes animated-dash-71911260{0%{stroke-dashoffset:0px}to{stroke-dashoffset:-10px}}.column-filter[data-v-8487462d]{display:flex;align-items:center;gap:.25rem;width:100%}.filter-input[data-v-8487462d],.filter-select[data-v-8487462d]{background-color:var(--sc-form-background)!important;padding:.15rem .2rem;border:1px solid var(--sc-form-border);border-radius:3px;font-size:.875rem;color:var(--sc-text-color);width:100%;box-sizing:border-box}.filter-input[data-v-8487462d]:focus,.filter-select[data-v-8487462d]:focus{outline:none;border-color:var(--sc-input-active-border-color)}.checkbox-filter[data-v-8487462d]{display:flex;align-items:center;gap:.25rem;font-size:.875rem;color:var(--sc-text-color);cursor:pointer}.filter-checkbox[data-v-8487462d]{margin:0}.date-range-filter[data-v-8487462d]{display:flex;gap:.25rem;align-items:center;width:100%}.date-range-filter .filter-input[data-v-8487462d]{flex:1;min-width:0}.date-separator[data-v-8487462d]{color:var(--sc-gray-50);font-weight:500;padding:0 .25rem;flex-shrink:0}.clear-btn[data-v-8487462d]{background:var(--sc-gray-10, #f0f0f0);border:1px solid var(--sc-form-border);border-radius:3px;color:var(--sc-gray-70);cursor:pointer;font-size:1rem;padding:.15rem .4rem;line-height:1;flex-shrink:0}.atable-header-row th{padding-left:.5ch!important;font-weight:700;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding);box-sizing:border-box;color:var(--sc-header-text-color);position:relative}#header-index{padding-left:var(--sc-atable-row-padding);box-sizing:border-box}.tree-index{padding-right:0}th{order:1}.list-expansion-index{width:2ch;margin-left:5px}.cursor-pointer{cursor:pointer}.atable-filters-row th{padding:.25rem .5ch;vertical-align:top}:root{--sc-primary-color: #0098c9;--sc-primary-text-color: #ffffff;--sc-brand-color: #202a44;--sc-gray-5: #f2f2f2;--sc-gray-10: #e6e6e6;--sc-gray-20: #cccccc;--sc-gray-50: #808080;--sc-gray-60: #666666;--sc-gray-80: #333333;--sc-brand-danger: #e63c28;--sc-brand-success: #155724;--sc-brand-warning: #b99d3e;--sc-active-cell-background: #ffffff;--sc-active-cell-outline: #e6a92d;--sc-cell-border-color: #ffffff;--sc-cell-text-color: #3a3c41;--sc-focus-cell-background: #ffffff;--sc-focus-cell-outline: #000000;--sc-header-border-color: #ffffff;--sc-header-text-color: var(--sc-gray-20);--sc-row-border-color: var(--sc-gray-20);--sc-row-color-zebra-dark: #dddddd;--sc-row-color-zebra-light: #eeeeee;--sc-row-number-background-color: #ffffff;--sc-input-active-border-color: #000000;--sc-input-active-label-color: #000000;--sc-input-border-color: var(--sc-gray-20);--sc-input-label-color: var(--sc-gray-60);--sc-required-border: #e63c28;--sc-cell-changed-color: #d8edff;--sc-form-border: var(--sc-gray-5);--sc-form-background: #ffffff;--sc-input-field-background: #ffffff;--sc-input-field-disabled-background: var(--sc-gray-5);--sc-font-size: 10px;--sc-font-family: Arimo, Arial, sans-serif;--sc-table-font-size: 16px;--sc-atable-font-family: "Arimo", sans-serif;--sc-atable-row-padding: .125rem;--sc-atable-row-height: 1.5em;--sc-atable-cell-border-width: 2px;--sc-table-loading-color: 204, 204, 204;--sc-btn-border: #cccccc;--sc-btn-color: white;--sc-btn-hover: #f2f2f2;--sc-btn-label-color: black}.amodal{position:absolute;background-color:var(--sc-row-color-zebra-dark);z-index:5}.atable-container{position:relative}.sticky-index{position:sticky;left:0;z-index:10;order:0}.sticky-column,th.sticky-column,td.sticky-column,th.sticky-index,td.sticky-index{position:sticky;z-index:10;order:0;background:#fff}.sticky-column-edge,.atable th.sticky-column-edge{border-right:1px solid var(--sc-row-border-color)}[data-v-c0a0032f]:root{--sc-primary-color: #0098c9;--sc-primary-text-color: #ffffff;--sc-brand-color: #202a44;--sc-gray-5: #f2f2f2;--sc-gray-10: #e6e6e6;--sc-gray-20: #cccccc;--sc-gray-50: #808080;--sc-gray-60: #666666;--sc-gray-80: #333333;--sc-brand-danger: #e63c28;--sc-brand-success: #155724;--sc-brand-warning: #b99d3e;--sc-active-cell-background: #ffffff;--sc-active-cell-outline: #e6a92d;--sc-cell-border-color: #ffffff;--sc-cell-text-color: #3a3c41;--sc-focus-cell-background: #ffffff;--sc-focus-cell-outline: #000000;--sc-header-border-color: #ffffff;--sc-header-text-color: var(--sc-gray-20);--sc-row-border-color: var(--sc-gray-20);--sc-row-color-zebra-dark: #dddddd;--sc-row-color-zebra-light: #eeeeee;--sc-row-number-background-color: #ffffff;--sc-input-active-border-color: #000000;--sc-input-active-label-color: #000000;--sc-input-border-color: var(--sc-gray-20);--sc-input-label-color: var(--sc-gray-60);--sc-required-border: #e63c28;--sc-cell-changed-color: #d8edff;--sc-form-border: var(--sc-gray-5);--sc-form-background: #ffffff;--sc-input-field-background: #ffffff;--sc-input-field-disabled-background: var(--sc-gray-5);--sc-font-size: 10px;--sc-font-family: Arimo, Arial, sans-serif;--sc-table-font-size: 16px;--sc-atable-font-family: "Arimo", sans-serif;--sc-atable-row-padding: .125rem;--sc-atable-row-height: 1.5em;--sc-atable-cell-border-width: 2px;--sc-table-loading-color: 204, 204, 204;--sc-btn-border: #cccccc;--sc-btn-color: white;--sc-btn-hover: #f2f2f2;--sc-btn-label-color: black}.atable[data-v-c0a0032f]{position:relative;font-family:var(--sc-atable-font-family);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:var(--sc-table-font-size);border-collapse:collapse;box-sizing:border-box;table-layout:auto;width:auto;overflow:clip;height:1px}.atable th[data-v-c0a0032f]{border-width:0px;border-style:solid;border-radius:0;padding-left:.5ch;padding-right:.5ch;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding);color:var(--sc-gray-60);height:var(--sc-atable-row-height);font-weight:300;letter-spacing:.05rem;order:1;box-sizing:border-box}.atable th[data-v-c0a0032f]:focus{outline:none}.atable[data-v-c0a0032f]:tbody{overflow:hidden;position:relative}.atable[data-v-c0a0032f]:tbody:before{content:"";position:absolute;top:0;left:0;right:0;height:1px;background-color:transparent;z-index:100}.aloading[data-v-a930a25b]{width:100%;border-top:1px solid var(--sc-row-border-color);border-bottom:1px solid var(--sc-row-border-color);display:flex;background-color:#fff;border-left:4px solid var(--sc-row-border-color);padding-left:.5ch!important;padding-right:.5ch;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding);align-items:center;box-sizing:border-box;background:var(--sc-focus-cell-background);overflow:hidden;position:relative}.aloading-bar[data-v-a930a25b]{width:100%;height:100%;position:absolute;left:-100%;top:0;background:linear-gradient(90deg,rgba(var(--sc-table-loading-color),0),rgba(var(--sc-table-loading-color),1),rgba(var(--sc-table-loading-color),0));animation:gradient-a930a25b infinite 2s;z-index:0}.aloading-header[data-v-a930a25b]{color:var(--sc-cell-text-color);font-family:var(--sc-atable-font-family);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:var(--sc-table-font-size);padding:0;margin:0;font-weight:400;z-index:1}.aloading-header[data-v-a930a25b]:after{content:"...";animation:ellipse-a930a25b 2s;animation-iteration-count:infinite}@keyframes gradient-a930a25b{0%{left:-100%}to{left:100%}}@keyframes ellipse-a930a25b{0%{content:""}20%{content:""}40%{content:"."}60%{content:".."}80%{content:"..."}}.aloading[data-v-e1165876]{width:100%;border-top:1px solid var(--sc-row-border-color);border-bottom:1px solid var(--sc-row-border-color);display:flex;background-color:#fff;border-left:4px solid var(--sc-row-border-color);padding-left:.5ch!important;padding-right:.5ch;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding);align-items:center;box-sizing:border-box;background:var(--sc-focus-cell-background);overflow:hidden;position:relative}.aloading-bar[data-v-e1165876]{width:50%;height:3px;position:absolute;left:-100%;bottom:0;background:var(--sc-row-border-color);animation:bar-left-e1165876 infinite 2s;z-index:0}.aloading-header[data-v-e1165876]{color:var(--sc-cell-text-color);font-family:var(--sc-atable-font-family);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:var(--sc-table-font-size);padding:0;margin:0;font-weight:400;z-index:1}.aloading-header[data-v-e1165876]:after{content:"...";animation:ellipse-e1165876 2s;animation-iteration-count:infinite}@keyframes bar-left-e1165876{0%{left:-50%}to{left:100%}}@keyframes ellipse-e1165876{0%{content:""}20%{content:""}40%{content:"."}60%{content:".."}80%{content:"..."}}
2
- /*$vite$:1*/`,document.head.appendChild(He);function Fe(t,n){return e.getCurrentScope()?(e.onScopeDispose(t,n),!0):!1}const ct=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const dt=t=>t!=null,ft=Object.prototype.toString,ut=t=>ft.call(t)==="[object Object]",mt=()=>{};function ie(t){return Array.isArray(t)?t:[t]}function gt(t,n,l){return e.watch(t,n,{...l,immediate:!0})}const ne=ct?window:void 0;function oe(t){var n;const l=e.toValue(t);return(n=l?.$el)!==null&&n!==void 0?n:l}function ae(...t){const n=(i,s,r,o)=>(i.addEventListener(s,r,o),()=>i.removeEventListener(s,r,o)),l=e.computed(()=>{const i=ie(e.toValue(t[0])).filter(s=>s!=null);return i.every(s=>typeof s!="string")?i:void 0});return gt(()=>{var i,s;return[(i=(s=l.value)===null||s===void 0?void 0:s.map(r=>oe(r)))!==null&&i!==void 0?i:[ne].filter(r=>r!=null),ie(e.toValue(l.value?t[1]:t[0])),ie(e.unref(l.value?t[2]:t[1])),e.toValue(l.value?t[3]:t[2])]},([i,s,r,o],a,d)=>{if(!i?.length||!s?.length||!r?.length)return;const f=ut(o)?{...o}:o,m=i.flatMap(b=>s.flatMap(I=>r.map(p=>n(b,I,p,f))));d(()=>{m.forEach(b=>b())})},{flush:"post"})}function ht(){const t=e.shallowRef(!1),n=e.getCurrentInstance();return n&&e.onMounted(()=>{t.value=!0},n),t}function pt(t){const n=ht();return e.computed(()=>(n.value,!!t()))}function bt(t,n,l={}){const{window:i=ne,...s}=l;let r;const o=pt(()=>i&&"MutationObserver"in i),a=()=>{r&&(r.disconnect(),r=void 0)},d=e.watch(e.computed(()=>{const b=ie(e.toValue(t)).map(oe).filter(dt);return new Set(b)}),b=>{a(),o.value&&b.size&&(r=new MutationObserver(n),b.forEach(I=>r.observe(I,s)))},{immediate:!0,flush:"post"}),f=()=>r?.takeRecords(),m=()=>{d(),a()};return Fe(m),{isSupported:o,stop:m,takeRecords:f}}function wt(t,n,l={}){const{window:i=ne,document:s=i?.document,flush:r="sync"}=l;if(!i||!s)return mt;let o;const a=m=>{o?.(),o=m},d=e.watchEffect(()=>{const m=oe(t);if(m){const{stop:b}=bt(s,I=>{I.map(p=>[...p.removedNodes]).flat().some(p=>p===m||p.contains(m))&&n(I)},{window:i,childList:!0,subtree:!0});a(b)}},{flush:r}),f=()=>{d(),a()};return Fe(f),f}function xt(t={}){var n;const{window:l=ne,deep:i=!0,triggerOnRemoval:s=!1}=t,r=(n=t.document)!==null&&n!==void 0?n:l?.document,o=()=>{let f=r?.activeElement;if(i)for(var m;f?.shadowRoot;)f=f==null||(m=f.shadowRoot)===null||m===void 0?void 0:m.activeElement;return f},a=e.shallowRef(),d=()=>{a.value=o()};if(l){const f={capture:!0,passive:!0};ae(l,"blur",m=>{m.relatedTarget===null&&d()},f),ae(l,"focus",d,f)}return s&&wt(a,d,{document:r}),d(),a}const yt="focusin",vt="focusout",kt=":focus-within";function Ct(t,n={}){const{window:l=ne}=n,i=e.computed(()=>oe(t)),s=e.shallowRef(!1),r=e.computed(()=>s.value);if(!l||!xt(n).value)return{focused:r};const o={passive:!0};return ae(i,yt,()=>s.value=!0,o),ae(i,vt,()=>{var a,d,f;return s.value=(a=(d=i.value)===null||d===void 0||(f=d.matches)===null||f===void 0?void 0:f.call(d,kt))!==null&&a!==void 0?a:!1},o),{focused:r}}function Et(t,{window:n=ne,scrollTarget:l}={}){const i=e.ref(!1),s=()=>{if(!n)return;const r=n.document,o=oe(t);if(!o)i.value=!1;else{const a=o.getBoundingClientRect();i.value=a.top<=(n.innerHeight||r.documentElement.clientHeight)&&a.left<=(n.innerWidth||r.documentElement.clientWidth)&&a.bottom>=0&&a.right>=0}};return e.watch(()=>oe(t),()=>s(),{immediate:!0,flush:"post"}),n&&ae(l||n,"scroll",s,{capture:!1,passive:!0}),i}const J=t=>{let n=Et(t).value;return n=n&&t.offsetHeight>0,n},Z=t=>t.tabIndex>=0,We=t=>{const n=t.target;return xe(n)},xe=t=>{let n;if(t instanceof HTMLTableCellElement){const l=t.parentElement?.previousElementSibling;if(l){const i=Array.from(l.children)[t.cellIndex];i&&(n=i)}}else if(t instanceof HTMLTableRowElement){const l=t.previousElementSibling;l&&(n=l)}return n&&(!Z(n)||!J(n))?xe(n):n},It=t=>{const n=t.target;let l;if(n instanceof HTMLTableCellElement){const i=n.parentElement?.parentElement;if(i){const s=i.firstElementChild?.children[n.cellIndex];s&&(l=s)}}else if(n instanceof HTMLTableRowElement){const i=n.parentElement;if(i){const s=i.firstElementChild;s&&(l=s)}}return l&&(!Z(l)||!J(l))?ye(l):l},Xe=t=>{const n=t.target;return ye(n)},ye=t=>{let n;if(t instanceof HTMLTableCellElement){const l=t.parentElement?.nextElementSibling;if(l){const i=Array.from(l.children)[t.cellIndex];i&&(n=i)}}else if(t instanceof HTMLTableRowElement){const l=t.nextElementSibling;l&&(n=l)}return n&&(!Z(n)||!J(n))?ye(n):n},Bt=t=>{const n=t.target;let l;if(n instanceof HTMLTableCellElement){const i=n.parentElement?.parentElement;if(i){const s=i.lastElementChild?.children[n.cellIndex];s&&(l=s)}}else if(n instanceof HTMLTableRowElement){const i=n.parentElement;if(i){const s=i.lastElementChild;s&&(l=s)}}return l&&(!Z(l)||!J(l))?xe(l):l},Ge=t=>{const n=t.target;return ve(n)},ve=t=>{let n;return t.previousElementSibling?n=t.previousElementSibling:n=t.parentElement?.previousElementSibling?.lastElementChild,n&&(!Z(n)||!J(n))?ve(n):n},Ye=t=>{const n=t.target;return ke(n)},ke=t=>{let n;return t.nextElementSibling?n=t.nextElementSibling:n=t.parentElement?.nextElementSibling?.firstElementChild,n&&(!Z(n)||!J(n))?ke(n):n},je=t=>{const n=t.target.parentElement?.firstElementChild;return n&&(!Z(n)||!J(n))?ke(n):n},Ue=t=>{const n=t.target.parentElement?.lastElementChild;return n&&(!Z(n)||!J(n))?ve(n):n},se=["alt","control","shift","meta"],St={ArrowUp:"up",ArrowDown:"down",ArrowLeft:"left",ArrowRight:"right"},ce={"keydown.up":t=>{const n=We(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.down":t=>{const n=Xe(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.left":t=>{const n=Ge(t);t.preventDefault(),t.stopPropagation(),n&&n.focus()},"keydown.right":t=>{const n=Ye(t);t.preventDefault(),t.stopPropagation(),n&&n.focus()},"keydown.control.up":t=>{const n=It(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.control.down":t=>{const n=Bt(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.control.left":t=>{const n=je(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.control.right":t=>{const n=Ue(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.end":t=>{const n=Ue(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.enter":t=>{if(t.target instanceof HTMLTableCellElement){t.preventDefault(),t.stopPropagation();const n=Xe(t);n&&n.focus()}},"keydown.shift.enter":t=>{if(t.target instanceof HTMLTableCellElement){t.preventDefault(),t.stopPropagation();const n=We(t);n&&n.focus()}},"keydown.home":t=>{const n=je(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.tab":t=>{const n=Ye(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.shift.tab":t=>{const n=Ge(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())}};function Ce(t){const n=o=>{let a=null;return o.parent&&(typeof o.parent=="string"?a=document.querySelector(o.parent):o.parent instanceof HTMLElement?a=o.parent:a=o.parent.value),a},l=o=>{const a=n(o);let d=[];if(typeof o.selectors=="string")d=Array.from(a?a.querySelectorAll(o.selectors):document.querySelectorAll(o.selectors));else if(Array.isArray(o.selectors))for(const f of o.selectors)f instanceof HTMLElement?d.push(f):d.push(f.$el);else if(o.selectors instanceof HTMLElement)d.push(o.selectors);else if(o.selectors?.value)if(Array.isArray(o.selectors.value))for(const f of o.selectors.value)f instanceof HTMLElement?d.push(f):d.push(f.$el);else d.push(o.selectors.value);return d},i=o=>{const a=n(o);let d=[];return o.selectors?d=l(o):a&&(d=Array.from(a.children).filter(f=>Z(f)&&J(f))),d},s=o=>a=>{const d=St[a.key]||a.key.toLowerCase();if(se.includes(d))return;const f=o.handlers||ce;for(const m of Object.keys(f)){const[b,...I]=m.split(".");if(b==="keydown"&&I.includes(d)){const p=f[m],C=I.filter(g=>se.includes(g)),w=se.some(g=>{const h=g.charAt(0).toUpperCase()+g.slice(1);return a.getModifierState(h)});if(C.length>0){if(w){for(const g of se)if(I.includes(g)){const h=g.charAt(0).toUpperCase()+g.slice(1);a.getModifierState(h)&&p(a)}}}else w||p(a)}}},r=[];e.onMounted(()=>{for(const o of t){const a=n(o),d=i(o),f=s(o),m=a?[a]:d;for(const b of m){const{focused:I}=Ct(e.ref(b)),p=e.watch(I,C=>{C?b.addEventListener("keydown",f):b.removeEventListener("keydown",f)});r.push(p)}}}),e.onBeforeUnmount(()=>{for(const o of r)o()})}function Ee(t,n){return e.getCurrentScope()?(e.onScopeDispose(t,n),!0):!1}const qe=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const $t=t=>t!=null,Vt=Object.prototype.toString,Rt=t=>Vt.call(t)==="[object Object]",ee=()=>{};function zt(...t){if(t.length!==1)return e.toRef(...t);const n=t[0];return typeof n=="function"?e.readonly(e.customRef(()=>({get:n,set:ee}))):e.ref(n)}function Dt(t,n){function l(...i){return new Promise((s,r)=>{Promise.resolve(t(()=>n.apply(this,i),{fn:n,thisArg:this,args:i})).then(s).catch(r)})}return l}function Tt(t,n={}){let l,i,s=ee;const r=d=>{clearTimeout(d),s(),s=ee};let o;return d=>{const f=e.toValue(t),m=e.toValue(n.maxWait);return l&&r(l),f<=0||m!==void 0&&m<=0?(i&&(r(i),i=void 0),Promise.resolve(d())):new Promise((b,I)=>{s=n.rejectOnCancel?I:b,o=d,m&&!i&&(i=setTimeout(()=>{l&&r(l),i=void 0,b(o())},m)),l=setTimeout(()=>{i&&r(i),i=void 0,b(d())},f)})}}function de(t){return Array.isArray(t)?t:[t]}function Mt(t){return e.getCurrentInstance()}function Nt(t,n=200,l={}){return Dt(Tt(n,l),t)}function At(t,n={}){if(!e.isRef(t))return e.toRefs(t);const l=Array.isArray(t.value)?Array.from({length:t.value.length}):{};for(const i in t.value)l[i]=e.customRef(()=>({get(){return t.value[i]},set(s){var r;if(!((r=e.toValue(n.replaceRef))!==null&&r!==void 0)||r)if(Array.isArray(t.value)){const o=[...t.value];o[i]=s,t.value=o}else{const o={...t.value,[i]:s};Object.setPrototypeOf(o,Object.getPrototypeOf(t.value)),t.value=o}else t.value[i]=s}}));return l}function Ot(t,n=!0,l){Mt()?e.onMounted(t,l):n?t():e.nextTick(t)}function Pt(t,n,l){return e.watch(t,n,{...l,immediate:!0})}const le=qe?window:void 0;function U(t){var n;const l=e.toValue(t);return(n=l?.$el)!==null&&n!==void 0?n:l}function Q(...t){const n=(i,s,r,o)=>(i.addEventListener(s,r,o),()=>i.removeEventListener(s,r,o)),l=e.computed(()=>{const i=de(e.toValue(t[0])).filter(s=>s!=null);return i.every(s=>typeof s!="string")?i:void 0});return Pt(()=>{var i,s;return[(i=(s=l.value)===null||s===void 0?void 0:s.map(r=>U(r)))!==null&&i!==void 0?i:[le].filter(r=>r!=null),de(e.toValue(l.value?t[1]:t[0])),de(e.unref(l.value?t[2]:t[1])),e.toValue(l.value?t[3]:t[2])]},([i,s,r,o],a,d)=>{if(!i?.length||!s?.length||!r?.length)return;const f=Rt(o)?{...o}:o,m=i.flatMap(b=>s.flatMap(I=>r.map(p=>n(b,I,p,f))));d(()=>{m.forEach(b=>b())})},{flush:"post"})}function Je(t,n,l={}){const{window:i=le,ignore:s=[],capture:r=!0,detectIframe:o=!1,controls:a=!1}=l;if(!i)return a?{stop:ee,cancel:ee,trigger:ee}:ee;let d=!0;const f=g=>e.toValue(s).some(h=>{if(typeof h=="string")return Array.from(i.document.querySelectorAll(h)).some(v=>v===g.target||g.composedPath().includes(v));{const v=U(h);return v&&(g.target===v||g.composedPath().includes(v))}});function m(g){const h=e.toValue(g);return h&&h.$.subTree.shapeFlag===16}function b(g,h){const v=e.toValue(g),T=v.$.subTree&&v.$.subTree.children;return T==null||!Array.isArray(T)?!1:T.some(D=>D.el===h.target||h.composedPath().includes(D.el))}const I=g=>{const h=U(t);if(g.target!=null&&!(!(h instanceof Element)&&m(t)&&b(t,g))&&!(!h||h===g.target||g.composedPath().includes(h))){if("detail"in g&&g.detail===0&&(d=!f(g)),!d){d=!0;return}n(g)}};let p=!1;const C=[Q(i,"click",g=>{p||(p=!0,setTimeout(()=>{p=!1},0),I(g))},{passive:!0,capture:r}),Q(i,"pointerdown",g=>{const h=U(t);d=!f(g)&&!!(h&&!g.composedPath().includes(h))},{passive:!0}),o&&Q(i,"blur",g=>{setTimeout(()=>{var h;const v=U(t);((h=i.document.activeElement)===null||h===void 0?void 0:h.tagName)==="IFRAME"&&!v?.contains(i.document.activeElement)&&n(g)},0)},{passive:!0})].filter(Boolean),w=()=>C.forEach(g=>g());return a?{stop:w,cancel:()=>{d=!1},trigger:g=>{d=!0,I(g),d=!1}}:w}function Lt(){const t=e.shallowRef(!1),n=e.getCurrentInstance();return n&&e.onMounted(()=>{t.value=!0},n),t}function Ze(t){const n=Lt();return e.computed(()=>(n.value,!!t()))}function Qe(t,n,l={}){const{window:i=le,...s}=l;let r;const o=Ze(()=>i&&"MutationObserver"in i),a=()=>{r&&(r.disconnect(),r=void 0)},d=e.watch(e.computed(()=>{const b=de(e.toValue(t)).map(U).filter($t);return new Set(b)}),b=>{a(),o.value&&b.size&&(r=new MutationObserver(n),b.forEach(I=>r.observe(I,s)))},{immediate:!0,flush:"post"}),f=()=>r?.takeRecords(),m=()=>{d(),a()};return Ee(m),{isSupported:o,stop:m,takeRecords:f}}function Ie(t,n={}){var l;const{pointerTypes:i,preventDefault:s,stopPropagation:r,exact:o,onMove:a,onEnd:d,onStart:f,initialValue:m,axis:b="both",draggingElement:I=le,containerElement:p,handle:C=t,buttons:w=[0]}=n,g=e.ref((l=e.toValue(m))!==null&&l!==void 0?l:{x:0,y:0}),h=e.ref(),v=y=>i?i.includes(y.pointerType):!0,T=y=>{e.toValue(s)&&y.preventDefault(),e.toValue(r)&&y.stopPropagation()},D=y=>{var S;if(!e.toValue(w).includes(y.button)||e.toValue(n.disabled)||!v(y)||e.toValue(o)&&y.target!==e.toValue(t))return;const P=e.toValue(p),A=P==null||(S=P.getBoundingClientRect)===null||S===void 0?void 0:S.call(P),z=e.toValue(t).getBoundingClientRect(),j={x:y.clientX-(P?z.left-A.left+P.scrollLeft:z.left),y:y.clientY-(P?z.top-A.top+P.scrollTop:z.top)};f?.(j,y)!==!1&&(h.value=j,T(y))},X=y=>{if(e.toValue(n.disabled)||!v(y)||!h.value)return;const S=e.toValue(p),P=e.toValue(t).getBoundingClientRect();let{x:A,y:z}=g.value;(b==="x"||b==="both")&&(A=y.clientX-h.value.x,S&&(A=Math.min(Math.max(0,A),S.scrollWidth-P.width))),(b==="y"||b==="both")&&(z=y.clientY-h.value.y,S&&(z=Math.min(Math.max(0,z),S.scrollHeight-P.height))),g.value={x:A,y:z},a?.(g.value,y),T(y)},R=y=>{e.toValue(n.disabled)||!v(y)||h.value&&(h.value=void 0,d?.(g.value,y),T(y))};if(qe){const y=()=>{var S;return{capture:(S=n.capture)!==null&&S!==void 0?S:!0,passive:!e.toValue(s)}};Q(C,"pointerdown",D,y),Q(I,"pointermove",X,y),Q(I,"pointerup",R,y)}return{...At(g),position:g,isDragging:e.computed(()=>!!h.value),style:e.computed(()=>`left:${g.value.x}px;top:${g.value.y}px;`)}}function Be(t,n,l={}){const{window:i=le,...s}=l;let r;const o=Ze(()=>i&&"ResizeObserver"in i),a=()=>{r&&(r.disconnect(),r=void 0)},d=e.watch(e.computed(()=>{const m=e.toValue(t);return Array.isArray(m)?m.map(b=>U(b)):[U(m)]}),m=>{if(a(),o.value&&i){r=new ResizeObserver(n);for(const b of m)b&&r.observe(b,s)}},{immediate:!0,flush:"post"}),f=()=>{a(),d()};return Ee(f),{isSupported:o,stop:f}}function te(t,n={}){const{reset:l=!0,windowResize:i=!0,windowScroll:s=!0,immediate:r=!0,updateTiming:o="sync"}=n,a=e.shallowRef(0),d=e.shallowRef(0),f=e.shallowRef(0),m=e.shallowRef(0),b=e.shallowRef(0),I=e.shallowRef(0),p=e.shallowRef(0),C=e.shallowRef(0);function w(){const h=U(t);if(!h){l&&(a.value=0,d.value=0,f.value=0,m.value=0,b.value=0,I.value=0,p.value=0,C.value=0);return}const v=h.getBoundingClientRect();a.value=v.height,d.value=v.bottom,f.value=v.left,m.value=v.right,b.value=v.top,I.value=v.width,p.value=v.x,C.value=v.y}function g(){o==="sync"?w():o==="next-frame"&&requestAnimationFrame(()=>w())}return Be(t,g),e.watch(()=>U(t),h=>!h&&g()),Qe(t,g,{attributeFilter:["style","class"]}),s&&Q("scroll",g,{capture:!0,passive:!0}),i&&Q("resize",g,{passive:!0}),Ot(()=>{r&&g()}),{height:a,bottom:d,left:f,right:m,top:b,width:I,x:p,y:C,update:g}}function Se(t){return typeof Window<"u"&&t instanceof Window?t.document.documentElement:typeof Document<"u"&&t instanceof Document?t.documentElement:t}const $e=new WeakMap;function Ht(t,n=!1){const l=e.shallowRef(n);let i="";e.watch(zt(t),o=>{const a=Se(e.toValue(o));if(a){const d=a;if($e.get(d)||$e.set(d,d.style.overflow),d.style.overflow!=="hidden"&&(i=d.style.overflow),d.style.overflow==="hidden")return l.value=!0;if(l.value)return d.style.overflow="hidden"}},{immediate:!0});const s=()=>{const o=Se(e.toValue(t));!o||l.value||(o.style.overflow="hidden",l.value=!0)},r=()=>{const o=Se(e.toValue(t));!o||!l.value||(o.style.overflow=i,$e.delete(o),l.value=!1)};return Ee(r),e.computed({get(){return l.value},set(o){o?s():r()}})}const Ft=t=>{const n=new DOMParser().parseFromString(t,"text/html");return Array.from(n.body.childNodes).some(l=>l.nodeType===1)},Wt=(t=8)=>Array.from({length:t},()=>Math.floor(Math.random()*16).toString(16)).join(""),Xt=["data-colindex","data-rowindex","data-editable","contenteditable","tabindex"],Gt=["innerHTML"],Yt={key:2},Ke=e.defineComponent({__name:"ACell",props:{colIndex:{},rowIndex:{},store:{},addNavigation:{type:[Boolean,Object],default:!0},tabIndex:{default:0},pinned:{type:Boolean,default:!1},debounce:{default:300}},setup(t,{expose:n}){const l=e.useTemplateRef("cell"),i=t.store.getCellData(t.colIndex,t.rowIndex),s=e.ref(""),r=e.ref(!1),o=t.store.columns[t.colIndex],a=t.store.rows[t.rowIndex],d=o.align||"center",f=o.width||"40ch",m=e.computed(()=>t.store.getCellDisplayValue(t.colIndex,t.rowIndex)),b=e.computed(()=>typeof m.value=="string"?Ft(m.value):!1),I=e.computed(()=>({textAlign:d,width:f,fontWeight:r.value?"bold":"inherit",paddingLeft:t.store.getIndent(t.colIndex,t.store.display[t.rowIndex]?.indent)})),p=e.computed(()=>({"sticky-column":t.pinned,"cell-modified":r.value})),C=()=>{g(),w()},w=()=>{const{left:R,bottom:y,width:S,height:P}=te(l);o.mask,o.modalComponent&&t.store.$patch(A=>{A.modal.visible=!0,A.modal.colIndex=t.colIndex,A.modal.rowIndex=t.rowIndex,A.modal.left=R,A.modal.bottom=y,A.modal.width=S,A.modal.height=P,A.modal.cell=l.value,typeof o.modalComponent=="function"?A.modal.component=o.modalComponent({table:A.table,row:a,column:o}):A.modal.component=o.modalComponent,A.modal.componentProps=o.modalComponentExtraProps})};if(t.addNavigation){let R={...ce,"keydown.f2":w,"keydown.alt.up":w,"keydown.alt.down":w,"keydown.alt.left":w,"keydown.alt.right":w};typeof t.addNavigation=="object"&&(R={...R,...t.addNavigation}),Ce([{selectors:l,handlers:R}])}const g=()=>{if(l.value&&o.edit){const R=window.getSelection();if(R)try{const y=document.createRange();y.selectNodeContents&&(y.selectNodeContents(l.value),R.removeAllRanges(),R.addRange(y))}catch{}}},h=()=>{l.value&&(s.value=l.value.textContent,g())},v=()=>{try{const R=window.getSelection();if(R&&R.rangeCount>0&&l.value){const y=R.getRangeAt(0),S=y.cloneRange();if(S.selectNodeContents&&S.setEnd)return S.selectNodeContents(l.value),S.setEnd(y.endContainer,y.endOffset),S.toString().length}}catch{}return 0},T=R=>{if(l.value)try{const y=window.getSelection();if(!y)return;let S=0;const P=document.createTreeWalker?document.createTreeWalker(l.value,NodeFilter.SHOW_TEXT,null):null;if(!P)return;let A,z=null;for(;A=P.nextNode();){const j=A,_=S+j.textContent.length;if(R<=_&&(z=document.createRange(),z.setStart&&z.setEnd)){z.setStart(j,R-S),z.setEnd(j,R-S);break}S=_}z&&y.removeAllRanges&&y.addRange&&(y.removeAllRanges(),y.addRange(z))}catch{}},D=R=>{if(!o.edit)return;const y=R.target;if(y.textContent===s.value)return;const S=v();s.value=y.textContent,o.format?(r.value=y.textContent!==t.store.getFormattedValue(t.colIndex,t.rowIndex,i),t.store.setCellText(t.colIndex,t.rowIndex,y.textContent)):(r.value=y.textContent!==i,t.store.setCellData(t.colIndex,t.rowIndex,y.textContent)),e.nextTick().then(()=>{T(S)})},X=Nt(D,t.debounce);return n({currentData:s}),(R,y)=>(e.openBlock(),e.createElementBlock("td",{ref:"cell","data-colindex":t.colIndex,"data-rowindex":t.rowIndex,"data-editable":e.unref(o).edit,contenteditable:e.unref(o).edit,tabindex:t.tabIndex,spellcheck:!1,style:e.normalizeStyle(I.value),class:e.normalizeClass(["atable-cell",p.value]),onFocus:h,onPaste:D,onInput:y[0]||(y[0]=(...S)=>e.unref(X)&&e.unref(X)(...S)),onClick:C},[e.unref(o).cellComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(o).cellComponent),e.mergeProps({key:0,value:m.value},e.unref(o).cellComponentProps),null,16,["value"])):b.value?(e.openBlock(),e.createElementBlock("span",{key:1,innerHTML:m.value},null,8,Gt)):(e.openBlock(),e.createElementBlock("span",Yt,e.toDisplayString(m.value),1))],46,Xt))}}),jt=["tabindex"],Ut=["tabindex"],qt=["colspan"],Jt=e.defineComponent({__name:"AExpansionRow",props:{rowIndex:{},store:{},tabIndex:{default:()=>-1},addNavigation:{type:[Boolean,Object],default:()=>ce}},setup(t){const n=e.useTemplateRef("rowEl"),l=e.computed(()=>t.store.display[t.rowIndex].expanded?"▼":"►");if(t.addNavigation){const i={"keydown.control.g":s=>{s.stopPropagation(),s.preventDefault(),t.store.toggleRowExpand(t.rowIndex)}};typeof t.addNavigation=="object"&&Object.assign(i,t.addNavigation),Ce([{selectors:n,handlers:i}])}return(i,s)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("tr",e.mergeProps(i.$attrs,{ref:"rowEl",tabindex:t.tabIndex,class:"expandable-row"}),[e.createElementVNode("td",{tabIndex:-1,class:"row-index",onClick:s[0]||(s[0]=r=>t.store.toggleRowExpand(t.rowIndex))},e.toDisplayString(l.value),1),e.renderSlot(i.$slots,"row",{},void 0,!0)],16,jt),t.store.display[t.rowIndex].expanded?(e.openBlock(),e.createElementBlock("tr",{key:0,ref:"rowExpanded",tabindex:t.tabIndex,class:"expanded-row"},[e.createElementVNode("td",{tabIndex:-1,colspan:t.store.columns.length+1,class:"expanded-row-content"},[e.renderSlot(i.$slots,"content",{},void 0,!0)],8,qt)],8,Ut)):e.createCommentVNode("",!0)],64))}}),K=(t,n)=>{const l=t.__vccOpts||t;for(const[i,s]of n)l[i]=s;return l},_e=K(Jt,[["__scopeId","data-v-a42297c7"]]),Zt=["colspan"],Qt={ref:"container",class:"gantt-container"},Kt=["data-rowindex","data-colindex"],_t={key:2,class:"gantt-label"},en=["x1","y1","x2","y2"],et=K(e.defineComponent({__name:"AGanttCell",props:{store:{},columnsCount:{},rowIndex:{},colIndex:{},start:{default:0},end:{default:0},colspan:{default:1},label:{default:""},color:{default:"#cccccc"}},emits:["connection:create"],setup(t,{expose:n,emit:l}){e.useCssVars(E=>({v6d722296:s.value,v260b36f8:E.colspan}));const i=l,s=e.ref(t.color.length>=6?t.color:"#cccccc"),r=`gantt-bar-row-${t.rowIndex}-col-${t.colIndex}`,o=e.useTemplateRef("container"),a=e.useTemplateRef("bar"),d=e.useTemplateRef("leftResizeHandle"),f=e.useTemplateRef("rightResizeHandle"),m=e.useTemplateRef("leftConnectionHandle"),b=e.useTemplateRef("rightConnectionHandle"),{width:I}=te(o),{left:p,right:C}=te(a),w=e.ref(t.start),g=e.ref(t.end||w.value+t.colspan),h=e.ref(!1),v=e.ref(!1),T=e.ref(!1),D=e.ref(!1),X=e.ref(!1),R=e.ref({startX:0,startY:0,endX:0,endY:0}),y=e.computed(()=>ue.value||j.value||_.value),S=e.computed(()=>t.colspan>0?I.value/t.colspan:0),P=e.computed(()=>{const E=w.value/t.colspan*100,$=g.value/t.colspan*100;return{left:`${E}%`,width:`${$-E}%`,backgroundColor:s.value}}),A=e.computed(()=>({position:"fixed",top:0,left:0,width:"100vw",height:"100vh",pointerEvents:"none",zIndex:1e3})),z=e.ref({startX:0,startPos:0}),{isDragging:j}=Ie(d,{axis:"x",onStart:()=>re(p.value,w.value),onMove:({x:E})=>Te(E),onEnd:({x:E})=>Me(E)}),{isDragging:_}=Ie(f,{axis:"x",onStart:()=>re(C.value,g.value),onMove:({x:E})=>Ne(E),onEnd:({x:E})=>me(E)}),{isDragging:ue}=Ie(a,{exact:!0,axis:"x",onStart:()=>re(p.value,w.value),onMove:({x:E})=>Ae(E),onEnd:({x:E})=>ge(E)});e.onMounted(()=>{Oe()}),e.onUnmounted(()=>{Pe()});function re(E,$){a.value&&(a.value.style.transition="none"),z.value={startX:E,startPos:$}}function Te(E){if(!j.value||!a.value)return;const O=(E-z.value.startX)/S.value,N=Math.max(0,Math.min(g.value-1,z.value.startPos+O));a.value.style.left=`${N/t.colspan*100}%`,a.value.style.width=`${(g.value-N)/t.colspan*100}%`}function Me(E){if(!a.value)return;const $=E-z.value.startX,O=Math.round($/S.value),N=w.value,L=Math.max(0,Math.min(g.value-1,z.value.startPos+O));w.value=L,t.store.updateGanttBar({rowIndex:t.rowIndex,colIndex:t.colIndex,type:"resize",edge:"start",oldStart:N,newStart:L,end:g.value,delta:O,oldColspan:g.value-N,newColspan:g.value-L})}function Ne(E){if(!_.value||!a.value)return;const O=(E-z.value.startX)/S.value,N=Math.max(w.value+1,Math.min(t.columnsCount,z.value.startPos+O));a.value.style.width=`${(N-w.value)/t.colspan*100}%`}function me(E){if(!a.value)return;const $=E-z.value.startX,O=Math.round($/S.value),N=g.value,L=Math.max(w.value+1,Math.min(t.columnsCount,z.value.startPos+O));g.value=L,t.store.updateGanttBar({rowIndex:t.rowIndex,colIndex:t.colIndex,type:"resize",edge:"end",oldEnd:N,newEnd:L,start:w.value,delta:O,oldColspan:N-w.value,newColspan:L-w.value})}function Ae(E){if(!ue.value||!a.value)return;const O=(E-z.value.startX)/S.value,N=g.value-w.value,L=Math.max(0,Math.min(z.value.startPos+O,t.columnsCount-N));a.value.style.left=`${L/t.colspan*100}%`}function ge(E){if(!a.value)return;const $=E-z.value.startX,O=Math.round($/S.value),N=g.value-w.value,L=w.value,W=g.value;let G=z.value.startPos+O,Y=G+N;G<0?(G=0,Y=N):Y>t.columnsCount&&(Y=t.columnsCount,G=Y-N),w.value=G,g.value=Y,t.store.updateGanttBar({rowIndex:t.rowIndex,colIndex:t.colIndex,type:"bar",oldStart:L,oldEnd:W,newStart:G,newEnd:Y,delta:O,colspan:Y-G})}function Oe(){const{x:E,y:$}=te(a),{x:O,y:N}=te(m),{x:L,y:W}=te(b);t.store.registerGanttBar({id:r,rowIndex:t.rowIndex,colIndex:t.colIndex,startIndex:w,endIndex:g,color:s,label:t.label,position:{x:E,y:$}}),t.store.isDependencyGraphEnabled&&(t.store.registerConnectionHandle({id:`${r}-connection-left`,rowIndex:t.rowIndex,colIndex:t.colIndex,side:"left",position:{x:O,y:N},visible:h,barId:r}),t.store.registerConnectionHandle({id:`${r}-connection-right`,rowIndex:t.rowIndex,colIndex:t.colIndex,side:"right",position:{x:L,y:W},visible:v,barId:r}))}function Pe(){t.store.unregisterGanttBar(r),t.store.isDependencyGraphEnabled&&(t.store.unregisterConnectionHandle(`${r}-connection-left`),t.store.unregisterConnectionHandle(`${r}-connection-right`))}function Le(){t.store.isDependencyGraphEnabled&&(h.value=!0,v.value=!0)}function he(){!T.value&&!D.value&&(h.value=!1,v.value=!1)}function pe(E,$){$.preventDefault(),$.stopPropagation(),X.value=!0,E==="left"?T.value=!0:D.value=!0;const O=E==="left"?m.value:b.value;if(O){const W=O.getBoundingClientRect(),G=W.left+W.width/2,Y=W.top+W.height/2;R.value={startX:G,startY:Y,endX:G,endY:Y}}const N=W=>{R.value.endX=W.clientX,R.value.endY=W.clientY},L=W=>{be(W,E),we(N,L)};document.addEventListener("mousemove",N),document.addEventListener("mouseup",L)}function be(E,$){const N=document.elementFromPoint(E.clientX,E.clientY)?.closest(".connection-handle");if(N&&N!==($==="left"?m.value:b.value)){const L=N.closest(".gantt-bar");if(L){const W=parseInt(L.getAttribute("data-rowindex")||"0"),G=parseInt(L.getAttribute("data-colindex")||"0"),Y=N.classList.contains("left-connection-handle")?"left":"right",c=`gantt-bar-row-${W}-col-${G}`,u=t.store.createConnection(`${r}-connection-${$}`,`${c}-connection-${Y}`);u&&i("connection:create",u)}}}function we(E,$){X.value=!1,T.value=!1,D.value=!1,document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",$),a.value?.matches(":hover")||he()}return n({barStyle:P,cleanupConnectionDrag:we,currentEnd:g,handleConnectionDrop:be,isLeftConnectionDragging:T,isLeftConnectionVisible:h,isRightConnectionDragging:D,isRightConnectionVisible:v,showDragPreview:X}),(E,$)=>(e.openBlock(),e.createElementBlock("td",{class:"aganttcell",colspan:t.colspan},[e.createElementVNode("div",Qt,[e.createElementVNode("div",{ref:"bar","data-rowindex":t.rowIndex,"data-colindex":t.colIndex,class:e.normalizeClass(["gantt-bar",{"is-dragging":y.value}]),style:e.normalizeStyle(P.value),onMouseenter:Le,onMouseleave:he},[t.store.isDependencyGraphEnabled?(e.openBlock(),e.createElementBlock("div",{key:0,ref:"leftConnectionHandle",class:e.normalizeClass(["connection-handle left-connection-handle",{visible:h.value,"is-dragging":T.value}]),onMousedown:$[0]||($[0]=e.withModifiers(O=>pe("left",O),["stop"]))},[...$[2]||($[2]=[e.createElementVNode("div",{class:"connection-dot"},null,-1)])],34)):e.createCommentVNode("",!0),t.store.isDependencyGraphEnabled?(e.openBlock(),e.createElementBlock("div",{key:1,ref:"rightConnectionHandle",class:e.normalizeClass(["connection-handle right-connection-handle",{visible:v.value,"is-dragging":D.value}]),onMousedown:$[1]||($[1]=e.withModifiers(O=>pe("right",O),["stop"]))},[...$[3]||($[3]=[e.createElementVNode("div",{class:"connection-dot"},null,-1)])],34)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref:"leftResizeHandle",class:e.normalizeClass(["resize-handle left-resize-handle",{"is-dragging":e.unref(j)}])},[...$[4]||($[4]=[e.createElementVNode("div",{class:"handle-grip"},null,-1),e.createElementVNode("div",{class:"vertical-indicator left-indicator"},null,-1)])],2),t.label?(e.openBlock(),e.createElementBlock("label",_t,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref:"rightResizeHandle",class:e.normalizeClass(["resize-handle right-resize-handle",{"is-dragging":e.unref(_)}])},[...$[5]||($[5]=[e.createElementVNode("div",{class:"handle-grip"},null,-1),e.createElementVNode("div",{class:"vertical-indicator right-indicator"},null,-1)])],2)],46,Kt)],512),t.store.isDependencyGraphEnabled&&X.value?(e.openBlock(),e.createElementBlock("svg",{key:0,style:e.normalizeStyle(A.value)},[e.createElementVNode("line",{x1:R.value.startX,y1:R.value.startY,x2:R.value.endX,y2:R.value.endY,stroke:"#2196f3","stroke-width":"2","stroke-dasharray":"5,5"},null,8,en)],4)):e.createCommentVNode("",!0)],8,Zt))}}),[["__scopeId","data-v-8917a8a3"]]),tn=["tabindex"],Ve=K(e.defineComponent({__name:"ARow",props:{rowIndex:{},store:{},tabIndex:{default:()=>-1},addNavigation:{type:[Boolean,Object],default:!1}},setup(t){const n=e.useTemplateRef("rowEl"),l=e.computed(()=>t.store.isRowVisible(t.rowIndex)),i=e.computed(()=>t.store.getRowExpandSymbol(t.rowIndex));if(t.addNavigation){let s=ce;typeof t.addNavigation=="object"&&(s={...s,...t.addNavigation}),Ce([{selectors:n,handlers:s}])}return(s,r)=>e.withDirectives((e.openBlock(),e.createElementBlock("tr",{ref:"rowEl",tabindex:t.tabIndex,class:"atable-row"},[t.store.config.view!=="uncounted"?e.renderSlot(s.$slots,"index",{key:0},()=>[t.store.config.view==="list"?(e.openBlock(),e.createElementBlock("td",{key:0,tabIndex:-1,class:e.normalizeClass(["list-index",t.store.hasPinnedColumns?"sticky-index":""])},e.toDisplayString(t.rowIndex+1),3)):t.store.isTreeView?(e.openBlock(),e.createElementBlock("td",{key:1,tabIndex:-1,class:e.normalizeClass(["tree-index",t.store.hasPinnedColumns?"sticky-index":""]),onClick:r[0]||(r[0]=o=>t.store.toggleRowExpand(t.rowIndex))},e.toDisplayString(i.value),3)):e.createCommentVNode("",!0)],!0):e.createCommentVNode("",!0),e.renderSlot(s.$slots,"default",{},void 0,!0)],8,tn)),[[e.vShow,l.value]])}}),[["__scopeId","data-v-0fa91f83"]]),Re=new WeakMap,nn={mounted(t,n){const l=!n.modifiers.bubble;let i;if(typeof n.value=="function")i=Je(t,n.value,{capture:l});else{const[s,r]=n.value;i=Je(t,s,Object.assign({capture:l},r))}Re.set(t,i)},unmounted(t){const n=Re.get(t);n&&typeof n=="function"?n():n?.stop(),Re.delete(t)}},on={mounted(t,n){typeof n.value=="function"?Be(t,n.value):Be(t,...n.value)}};function an(){let t=!1;const n=e.shallowRef(!1);return(l,i)=>{if(n.value=i.value,t)return;t=!0;const s=Ht(l,i.value);e.watch(n,r=>s.value=r)}}an();const ln={class:"gantt-connection-overlay"},rn={class:"connection-svg",style:{position:"absolute",top:0,left:0,width:"100%",height:"100%",pointerEvents:"none",zIndex:1}},sn=["d","stroke-width","onDblclick"],cn=["id","d","stroke","stroke-width","onDblclick"],dn=.25,fe=16,fn=K(e.defineComponent({__name:"AGanttConnection",props:{store:{}},emits:["connection:delete"],setup(t,{emit:n}){const l=n,i=e.computed(()=>t.store.connectionPaths.filter(o=>{const a=t.store.ganttBars.find(f=>f.id===o.from.barId),d=t.store.ganttBars.find(f=>f.id===o.to.barId);return a&&d})),s=o=>{const a=t.store.connectionHandles.find(y=>y.barId===o.from.barId&&y.side===o.from.side),d=t.store.connectionHandles.find(y=>y.barId===o.to.barId&&y.side===o.to.side);if(!a||!d)return"";const f=a.position.x+fe/2,m=a.position.y+fe/2,b=d.position.x+fe/2,I=d.position.y+fe/2,p=Math.abs(b-f),C=Math.max(p*dn,50),w=f+(o.from.side==="left"?-C:C),g=b+(o.to.side==="left"?-C:C),h={x:.5*f+.5*w,y:.5*m+.5*m},v={x:.5*w+.5*g,y:.5*m+.5*I},T={x:.5*g+.5*b,y:.5*I+.5*I},D={x:.5*h.x+.5*v.x,y:.5*h.y+.5*v.y},X={x:.5*v.x+.5*T.x,y:.5*v.y+.5*T.y},R={x:.5*D.x+.5*X.x,y:.5*D.y+.5*X.y};return`M ${f} ${m} Q ${w} ${m}, ${R.x} ${R.y} Q ${g} ${I}, ${b} ${I}`},r=o=>{t.store.deleteConnection(o.id)&&l("connection:delete",o)};return(o,a)=>(e.openBlock(),e.createElementBlock("div",ln,[(e.openBlock(),e.createElementBlock("svg",rn,[a[0]||(a[0]=e.createElementVNode("defs",null,[e.createElementVNode("path",{id:"arrowhead",d:"M 0 -7 L 20 0 L 0 7Z",stroke:"black","stroke-width":"1",fill:"currentColor"}),e.createElementVNode("marker",{id:"arrowhead-marker",markerWidth:"10",markerHeight:"7",refX:"5",refY:"3.5",orient:"auto",markerUnits:"strokeWidth"},[e.createElementVNode("polygon",{points:"0 0, 10 3.5, 0 7",fill:"currentColor"})])],-1)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,d=>(e.openBlock(),e.createElementBlock("path",{key:`${d.id}-hitbox`,d:s(d),stroke:"transparent","stroke-width":(d.style?.width||2)+10,fill:"none",class:"connection-hitbox",onDblclick:f=>r(d)},null,40,sn))),128)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,d=>(e.openBlock(),e.createElementBlock("path",{id:d.id,key:d.id,d:s(d),stroke:d.style?.color||"#666","stroke-width":d.style?.width||2,fill:"none","marker-mid":"url(#arrowhead-marker)",class:"connection-path animated-path",onDblclick:f=>r(d)},null,40,cn))),128))]))]))}}),[["__scopeId","data-v-71911260"]]),un={class:"column-filter"},mn={key:2,class:"checkbox-filter"},gn=["value"],hn={key:5,class:"date-range-filter"},pn=K(e.defineComponent({__name:"ATableColumnFilter",props:{column:{},colIndex:{},store:{}},setup(t){const n=e.ref(""),l=e.reactive({startValue:"",endValue:""}),i=d=>{if(d.filterOptions)return d.filterOptions;const f=new Set;return t.store.rows.forEach(m=>{const b=m[d.name];b!=null&&b!==""&&f.add(b)}),Array.from(f).map(m=>({value:m,label:String(m)}))},s=e.computed(()=>!!(n.value||l.startValue||l.endValue)),r=d=>{!d&&t.column.filterType!=="checkbox"?(t.store.clearFilter(t.colIndex),n.value=""):(n.value=d,t.store.setFilter(t.colIndex,{value:d}))},o=(d,f)=>{d==="start"?l.startValue=f:l.endValue=f,!l.startValue&&!l.endValue?t.store.clearFilter(t.colIndex):t.store.setFilter(t.colIndex,{value:null,startValue:l.startValue,endValue:l.endValue})},a=()=>{n.value="",l.startValue="",l.endValue="",t.store.clearFilter(t.colIndex)};return(d,f)=>(e.openBlock(),e.createElementBlock("div",un,[(t.column.filterType||"text")==="text"?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:0,"onUpdate:modelValue":f[0]||(f[0]=m=>n.value=m),type:"text",class:"filter-input",onInput:f[1]||(f[1]=m=>r(n.value))},null,544)),[[e.vModelText,n.value]]):t.column.filterType==="number"?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:1,"onUpdate:modelValue":f[2]||(f[2]=m=>n.value=m),type:"number",class:"filter-input",onInput:f[3]||(f[3]=m=>r(n.value))},null,544)),[[e.vModelText,n.value]]):t.column.filterType==="checkbox"?(e.openBlock(),e.createElementBlock("label",mn,[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":f[4]||(f[4]=m=>n.value=m),type:"checkbox",class:"filter-checkbox",onChange:f[5]||(f[5]=m=>r(n.value))},null,544),[[e.vModelCheckbox,n.value]]),e.createElementVNode("span",null,e.toDisplayString(t.column.label),1)])):t.column.filterType==="select"?e.withDirectives((e.openBlock(),e.createElementBlock("select",{key:3,"onUpdate:modelValue":f[6]||(f[6]=m=>n.value=m),class:"filter-select",onChange:f[7]||(f[7]=m=>r(n.value))},[f[15]||(f[15]=e.createElementVNode("option",{value:""},"All",-1)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i(t.column),m=>(e.openBlock(),e.createElementBlock("option",{key:m.value||m,value:m.value||m},e.toDisplayString(m.label||m),9,gn))),128))],544)),[[e.vModelSelect,n.value]]):t.column.filterType==="date"?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:4,"onUpdate:modelValue":f[8]||(f[8]=m=>n.value=m),type:"date",class:"filter-input",onChange:f[9]||(f[9]=m=>r(n.value))},null,544)),[[e.vModelText,n.value]]):t.column.filterType==="dateRange"?(e.openBlock(),e.createElementBlock("div",hn,[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":f[10]||(f[10]=m=>l.startValue=m),type:"date",class:"filter-input",onChange:f[11]||(f[11]=m=>o("start",l.startValue))},null,544),[[e.vModelText,l.startValue]]),f[16]||(f[16]=e.createElementVNode("span",{class:"date-separator"},"-",-1)),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":f[12]||(f[12]=m=>l.endValue=m),type:"date",class:"filter-input",onChange:f[13]||(f[13]=m=>o("end",l.endValue))},null,544),[[e.vModelText,l.endValue]])])):t.column.filterType==="component"&&t.column.filterComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.column.filterComponent),{key:6,value:n.value,column:t.column,colIndex:t.colIndex,store:t.store,"onUpdate:value":f[14]||(f[14]=m=>r(m))},null,40,["value","column","colIndex","store"])):e.createCommentVNode("",!0),s.value?(e.openBlock(),e.createElementBlock("button",{key:7,onClick:a,class:"clear-btn",title:"Clear"},"×")):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-8487462d"]]),bn={key:0},wn={class:"atable-header-row",tabindex:"-1"},xn=["data-colindex","onClick"],yn={key:0,class:"atable-filters-row"},ze=e.defineComponent({__name:"ATableHeader",props:{columns:{},store:{}},setup(t){const n=e.computed(()=>t.columns.filter(s=>s.filterable)),l=s=>t.store.sortByColumn(s),i=s=>{for(const r of s){if(r.borderBoxSize.length===0)continue;const a=r.borderBoxSize[0].inlineSize,d=Number(r.target.dataset.colindex),f=t.store.columns[d]?.width;typeof f=="number"&&f!==a&&t.store.resizeColumn(d,a)}};return(s,r)=>t.columns.length?(e.openBlock(),e.createElementBlock("thead",bn,[e.createElementVNode("tr",wn,[t.store.zeroColumn?(e.openBlock(),e.createElementBlock("th",{key:0,id:"header-index",class:e.normalizeClass([[t.store.hasPinnedColumns?"sticky-index":"",t.store.isTreeView?"tree-index":"",t.store.config.view==="list-expansion"?"list-expansion-index":""],"list-index"])},null,2)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,(o,a)=>e.withDirectives((e.openBlock(),e.createElementBlock("th",{key:o.name,"data-colindex":a,tabindex:"-1",style:e.normalizeStyle(t.store.getHeaderCellStyle(o)),class:e.normalizeClass(`${o.pinned?"sticky-column":""} ${o.sortable===!1?"":"cursor-pointer"}`),onClick:d=>o.sortable!==!1?l(a):void 0},[e.renderSlot(s.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(o.label||String.fromCharCode(a+97).toUpperCase()),1)])],14,xn)),[[e.unref(on),i]])),128))]),n.value.length>0?(e.openBlock(),e.createElementBlock("tr",yn,[t.store.zeroColumn?(e.openBlock(),e.createElementBlock("th",{key:0,class:e.normalizeClass([[t.store.hasPinnedColumns?"sticky-index":"",t.store.isTreeView?"tree-index":"",t.store.config.view==="list-expansion"?"list-expansion-index":""],"list-index"])},null,2)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,(o,a)=>(e.openBlock(),e.createElementBlock("th",{key:`filter-${o.name}`,class:e.normalizeClass(`${o.pinned?"sticky-column":""}`),style:e.normalizeStyle(t.store.getHeaderCellStyle(o))},[o.filterable?(e.openBlock(),e.createBlock(pn,{key:0,column:o,"col-index":a,store:t.store},null,8,["column","col-index","store"])):e.createCommentVNode("",!0)],6))),128))])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)}}),De=e.defineComponent({__name:"ATableModal",props:{store:{}},setup(t){const n=e.useTemplateRef("amodal"),{width:l,height:i}=te(n),s=e.computed(()=>{if(!(t.store.modal.height&&t.store.modal.width&&t.store.modal.left&&t.store.modal.bottom))return;const r=t.store.modal.cell?.closest("table");if(!r)return{};const o=r.offsetHeight||0,a=r.offsetWidth||0;let d=t.store.modal.cell?.offsetTop||0;const f=r.querySelector("thead")?.offsetHeight||0;d+=f,d=d+i.value<o?d:d-(i.value+t.store.modal.height);let m=t.store.modal.cell?.offsetLeft||0;return m=m+l.value<=a?m:m-(l.value-t.store.modal.width),{left:`${m}px`,top:`${d}px`}});return(r,o)=>(e.openBlock(),e.createElementBlock("div",{ref:"amodal",class:"amodal",tabindex:"-1",style:e.normalizeStyle(s.value),onClick:o[0]||(o[0]=e.withModifiers(()=>{},["stop"])),onInput:o[1]||(o[1]=e.withModifiers(()=>{},["stop"]))},[e.renderSlot(r.$slots,"default")],36))}}),tt=t=>{const n=t.id||Wt();return st.defineStore(`table-${n}`,()=>{const i=()=>{const c=[Object.assign({},{rowModified:!1})],u=new Set;for(let k=0;k<r.value.length;k++){const B=r.value[k];B.parent!==null&&B.parent!==void 0&&u.add(B.parent)}const x=k=>r.value[k]?.gantt!==void 0,V=k=>{for(let B=0;B<r.value.length;B++)if(r.value[B].parent===k&&(x(B)||V(B)))return!0;return!1},M=k=>{const B=o.value,H=B.view==="tree"||B.view==="tree-gantt"?B.defaultTreeExpansion:void 0;if(!H)return!0;switch(H){case"root":return!1;case"branch":return V(k);case"leaf":return!0;default:return!0}};for(let k=0;k<r.value.length;k++){const B=r.value[k],H=B.parent===null||B.parent===void 0,q=u.has(k);c[k]={childrenOpen:M(k),expanded:!1,indent:B.indent||0,isParent:q,isRoot:H,rowModified:!1,open:H,parent:B.parent}}return c},s=e.ref(t.columns),r=e.ref(t.rows),o=e.ref(t.config||{}),a=e.ref({}),d=e.ref({}),f=e.computed(()=>{const c={};for(const[u,x]of s.value.entries())for(const[V,M]of r.value.entries())c[`${u}:${V}`]=M[x.name];return c}),m=e.computed({get:()=>{const c=i();for(let u=0;u<c.length;u++)a.value[u]&&(c[u].rowModified=a.value[u]),d.value[u]&&(d.value[u].childrenOpen!==void 0&&(c[u].childrenOpen=d.value[u].childrenOpen),d.value[u].expanded!==void 0&&(c[u].expanded=d.value[u].expanded));if(D.value){const u=(x,V)=>{const M=V[x];if(M.isRoot||M.parent===null||M.parent===void 0)return!0;const k=M.parent;return k<0||k>=V.length?!1:(V[k].childrenOpen||!1)&&u(k,V)};for(let x=0;x<c.length;x++)c[x].isRoot||(c[x].open=u(x,c))}return c},set:c=>{JSON.stringify(c)!==JSON.stringify(m.value)&&(m.value=c)}}),b=e.ref(t.modal||{visible:!1}),I=e.ref({}),p=e.ref([]),C=e.ref([]),w=e.ref([]),g=e.ref({column:null,direction:null}),h=e.ref({}),v=e.computed(()=>s.value.some(c=>c.pinned)),T=e.computed(()=>o.value.view==="gantt"||o.value.view==="tree-gantt"),D=e.computed(()=>o.value.view==="tree"||o.value.view==="tree-gantt"),X=e.computed(()=>{const c=o.value;return c.view==="gantt"||c.view==="tree-gantt"?c.dependencyGraph!==!1:!0}),R=e.computed(()=>`${Math.ceil(r.value.length/100+1)}ch`),y=e.computed(()=>o.value.view?["list","tree","tree-gantt","list-expansion"].includes(o.value.view):!1),S=e.computed(()=>{let c=r.value.map((u,x)=>({...u,originalIndex:x}));if(Object.entries(h.value).forEach(([u,x])=>{const V=parseInt(u),M=s.value[V];!M||!(x.value||x.startValue||x.endValue||M.filterType==="checkbox"&&x.value!==void 0)||(c=c.filter(B=>{const H=B[M.name];return W(H,x,M)}))}),g.value.column!==null&&g.value.direction){const u=s.value[g.value.column],x=g.value.direction;c.sort((V,M)=>{let k=V[u.name],B=M[u.name];k==null&&(k=""),B==null&&(B="");const H=Number(k),q=Number(B);if(!isNaN(H)&&!isNaN(q)&&k!==""&&B!=="")return x==="asc"?H-q:q-H;{const rt=String(k).toLowerCase(),it=String(B).toLowerCase();return x==="asc"?rt.localeCompare(it):it.localeCompare(rt)}})}return c}),P=(c,u)=>f.value[`${c}:${u}`],A=(c,u,x)=>{const V=`${c}:${u}`,M=s.value[c];f.value[V]!==x&&(a.value[u]=!0),f.value[V]=x,r.value[u]={...r.value[u],[M.name]:x}},z=c=>{r.value=c},j=(c,u,x)=>{const V=`${c}:${u}`;f.value[V]!==x&&(a.value[u]=!0,I.value[V]=x)},_=c=>{const u=s.value.indexOf(c)===s.value.length-1,x=o.value.fullWidth?c.resizable&&!u:c.resizable;return{width:c.width||"40ch",textAlign:c.align||"center",...x&&{resize:"horizontal",overflow:"hidden",whiteSpace:"nowrap"}}},ue=(c,u)=>{if(c<0||c>=s.value.length)return;const V=Math.max(u,40);s.value[c]={...s.value[c],width:`${V}px`}},re=c=>{const u=r.value[c];return T.value&&u.gantt!==void 0},Te=c=>!D.value||m.value[c].isRoot||m.value[c].open,Me=c=>!D.value&&o.value.view!=="list-expansion"?"":D.value&&(m.value[c].isRoot||m.value[c].isParent)?m.value[c].childrenOpen?"▼":"►":o.value.view==="list-expansion"?m.value[c].expanded?"▼":"►":"",Ne=c=>{if(D.value){const u=d.value[c]||{},V=!(u.childrenOpen??m.value[c].childrenOpen);d.value[c]={...u,childrenOpen:V},V||me(c)}else if(o.value.view==="list-expansion"){const u=d.value[c]||{},x=u.expanded??m.value[c].expanded;d.value[c]={...u,expanded:!x}}},me=c=>{for(let u=0;u<r.value.length;u++)if(m.value[u].parent===c){const x=d.value[u]||{};d.value[u]={...x,childrenOpen:!1},me(u)}},Ae=(c,u)=>{const x=P(c,u);return ge(c,u,x)},ge=(c,u,x)=>{const V=s.value[c],M=r.value[u],k=V.format;return k?typeof k=="function"?k(x,{table:f.value,row:M,column:V}):typeof k=="string"?Function(`"use strict";return (${k})`)()(x,{table:f.value,row:M,column:V}):x:x},Oe=c=>{c.target instanceof Node&&b.value.parent?.contains(c.target)||b.value.visible&&(b.value.visible=!1)},Pe=(c,u)=>u&&c===0&&u>0?`${u}ch`:"inherit",Le=c=>{const u=r.value[c.rowIndex]?.gantt;u&&(c.type==="resize"?c.edge==="start"?(u.startIndex=c.newStart,u.endIndex=c.end,u.colspan=u.endIndex-u.startIndex):c.edge==="end"&&(u.startIndex=c.start,u.endIndex=c.newEnd,u.colspan=u.endIndex-u.startIndex):c.type==="bar"&&(u.startIndex=c.newStart,u.endIndex=c.newEnd,u.colspan=u.endIndex-u.startIndex))},he=c=>{const u=p.value.findIndex(x=>x.id===c.id);u>=0?p.value[u]=c:p.value.push(c)},pe=c=>{const u=p.value.findIndex(x=>x.id===c);u>=0&&p.value.splice(u,1)},be=c=>{const u=C.value.findIndex(x=>x.id===c.id);u>=0?C.value[u]=c:C.value.push(c)},we=c=>{const u=C.value.findIndex(x=>x.id===c);u>=0&&C.value.splice(u,1)},E=(c,u,x)=>{const V=C.value.find(B=>B.id===c),M=C.value.find(B=>B.id===u);if(!V||!M)return console.warn("Cannot create connection: handle not found"),null;const k={id:`connection-${c}-${u}`,from:{barId:V.barId,side:V.side},to:{barId:M.barId,side:M.side},style:x?.style,label:x?.label};return w.value.push(k),k},$=c=>{const u=w.value.findIndex(x=>x.id===c);return u>=0?(w.value.splice(u,1),!0):!1},O=c=>w.value.filter(u=>u.from.barId===c||u.to.barId===c),N=c=>C.value.filter(u=>u.barId===c),L=c=>{if(s.value[c].sortable===!1)return;let x;g.value.column===c&&g.value.direction==="asc"?x="desc":x="asc",g.value.column=c,g.value.direction=x},W=(c,u,x)=>{const V=x.filterType||"text",M=u.value;if(!M&&V!=="dateRange"&&V!=="checkbox")return!0;switch(V){case"text":{let k="";return typeof c=="object"&&c!==null?k=Object.values(c).join(" "):k=String(c||""),k.toLowerCase().includes(String(M).toLowerCase())}case"number":{const k=Number(c),B=Number(M);return!isNaN(k)&&!isNaN(B)&&k===B}case"select":return c===M;case"checkbox":return M===!0?!!c:!0;case"date":{let k;if(typeof c=="number"){const H=new Date(c),q=new Date().getFullYear();k=new Date(q,H.getMonth(),H.getDate())}else k=new Date(String(c));const B=new Date(String(M));return k.toDateString()===B.toDateString()}case"dateRange":{const k=u.startValue,B=u.endValue;if(!k&&!B)return!0;let H;if(typeof c=="number"){const q=new Date(c),lt=new Date().getFullYear();H=new Date(lt,q.getMonth(),q.getDate())}else H=new Date(String(c));return!(k&&H<new Date(String(k))||B&&H>new Date(String(B)))}default:return!0}};return{columns:s,config:o,connectionHandles:C,connectionPaths:w,display:m,filterState:h,ganttBars:p,modal:b,rows:r,sortState:g,table:f,updates:I,filteredRows:S,hasPinnedColumns:v,isGanttView:T,isTreeView:D,isDependencyGraphEnabled:X,numberedRowWidth:R,zeroColumn:y,clearFilter:c=>{delete h.value[c]},closeModal:Oe,createConnection:E,deleteConnection:$,getCellData:P,getCellDisplayValue:Ae,getConnectionsForBar:O,getFormattedValue:ge,getHandlesForBar:N,getHeaderCellStyle:_,getIndent:Pe,getRowExpandSymbol:Me,isRowGantt:re,isRowVisible:Te,registerConnectionHandle:be,registerGanttBar:he,resizeColumn:ue,setCellData:A,setCellText:j,setFilter:(c,u)=>{!u.value&&!u.startValue&&!u.endValue?delete h.value[c]:h.value[c]=u},sortByColumn:L,toggleRowExpand:Ne,unregisterConnectionHandle:we,unregisterGanttBar:pe,updateGanttBar:Le,updateRows:z}})()},vn={class:"atable-container",style:{position:"relative"}},nt=K(e.defineComponent({__name:"ATable",props:e.mergeModels({id:{default:""},config:{default:()=>new Object}},{rows:{required:!0},rowsModifiers:{},columns:{required:!0},columnsModifiers:{}}),emits:e.mergeModels(["cellUpdate","gantt:drag","connection:event","columns:update"],["update:rows","update:columns"]),setup(t,{expose:n,emit:l}){const i=e.useModel(t,"rows"),s=e.useModel(t,"columns"),r=l,o=e.useTemplateRef("table"),a=tt({columns:s.value,rows:i.value,id:t.id,config:t.config});a.$onAction(({name:p,store:C,args:w,after:g})=>{if(p==="setCellData"||p==="setCellText"){const[h,v,T]=w,D=C.getCellData(h,v);g(()=>{i.value=[...C.rows],r("cellUpdate",{colIndex:h,rowIndex:v,newValue:T,oldValue:D})})}else if(p==="updateGanttBar"){const[h]=w;let v=!1;h.type==="resize"?v=h.oldColspan!==h.newColspan:h.type==="bar"&&(v=h.oldStart!==h.newStart||h.oldEnd!==h.newEnd),v&&g(()=>{r("gantt:drag",h)})}else p==="resizeColumn"&&g(()=>{s.value=[...C.columns],r("columns:update",[...C.columns])})}),e.watch(()=>i.value,p=>{JSON.stringify(p)!==JSON.stringify(a.rows)&&(a.rows=[...p])},{deep:!0}),e.watch(s,p=>{JSON.stringify(p)!==JSON.stringify(a.columns)&&(a.columns=[...p],r("columns:update",[...p]))},{deep:!0}),e.onMounted(()=>{s.value.some(p=>p.pinned)&&(f(),a.isTreeView&&Qe(o,f,{childList:!0,subtree:!0}))});const d=e.computed(()=>a.columns.filter(p=>p.pinned).length),f=()=>{const p=o.value,C=p?.rows[0],w=p?.rows[1],g=C?Array.from(C.cells):[];for(const[h,v]of g.entries()){const T=w?.cells[h];T&&(v.style.width=`${T.offsetWidth}px`)}for(const h of p?.rows||[]){let v=0;const T=[];for(const D of h.cells)(D.classList.contains("sticky-column")||D.classList.contains("sticky-index"))&&(D.style.left=`${v}px`,v+=D.offsetWidth,T.push(D));T.length>0&&T[T.length-1].classList.add("sticky-column-edge")}};window.addEventListener("keydown",p=>{if(p.key==="Escape"&&a.modal.visible){a.modal.visible=!1;const C=a.modal.parent;C&&e.nextTick().then(()=>{C.focus()})}});const m=p=>{if(!p.gantt||d.value===0)return a.columns;const C=[];for(let w=0;w<d.value;w++){const g={...a.columns[w]};g.originalIndex=w,C.push(g)}return C.push({...a.columns[d.value],isGantt:!0,colspan:p.gantt?.colspan||a.columns.length-d.value,originalIndex:d.value,width:"auto"}),C},b=p=>{r("connection:event",{type:"create",connection:p})},I=p=>{r("connection:event",{type:"delete",connection:p})};return n({store:a,createConnection:a.createConnection,deleteConnection:a.deleteConnection,getConnectionsForBar:a.getConnectionsForBar,getHandlesForBar:a.getHandlesForBar}),(p,C)=>(e.openBlock(),e.createElementBlock("div",vn,[e.withDirectives((e.openBlock(),e.createElementBlock("table",{ref:"table",class:"atable",style:e.normalizeStyle({width:e.unref(a).config.fullWidth?"100%":"auto"})},[e.renderSlot(p.$slots,"header",{data:e.unref(a)},()=>[e.createVNode(ze,{columns:e.unref(a).columns,store:e.unref(a)},null,8,["columns","store"])],!0),e.createElementVNode("tbody",null,[e.renderSlot(p.$slots,"body",{data:e.unref(a)},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(a).filteredRows,(w,g)=>(e.openBlock(),e.createBlock(Ve,{key:`${w.originalIndex}-${g}`,row:w,rowIndex:w.originalIndex,store:e.unref(a)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m(w),(h,v)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:h.name},[h.isGantt?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.ganttComponent||"AGanttCell"),{key:0,store:e.unref(a),"columns-count":e.unref(a).columns.length-d.value,color:w.gantt?.color,start:w.gantt?.startIndex,end:w.gantt?.endIndex,colspan:h.colspan,pinned:h.pinned,rowIndex:w.originalIndex,colIndex:h.originalIndex??v,style:e.normalizeStyle({textAlign:h?.align||"center",minWidth:h?.width||"40ch",width:e.unref(a).config.fullWidth?"auto":null}),"onConnection:create":b},null,40,["store","columns-count","color","start","end","colspan","pinned","rowIndex","colIndex","style"])):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.cellComponent||"ACell"),{key:1,store:e.unref(a),pinned:h.pinned,rowIndex:w.originalIndex,colIndex:v,style:e.normalizeStyle({textAlign:h?.align||"center",width:e.unref(a).config.fullWidth?"auto":null}),spellcheck:"false"},null,8,["store","pinned","rowIndex","colIndex","style"]))],64))),128))]),_:2},1032,["row","rowIndex","store"]))),128))],!0)]),e.renderSlot(p.$slots,"footer",{data:e.unref(a)},void 0,!0),e.renderSlot(p.$slots,"modal",{data:e.unref(a)},()=>[e.withDirectives(e.createVNode(De,{store:e.unref(a)},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(a).modal.component),e.mergeProps({key:`${e.unref(a).modal.rowIndex}:${e.unref(a).modal.colIndex}`,"col-index":e.unref(a).modal.colIndex,"row-index":e.unref(a).modal.rowIndex,store:e.unref(a)},e.unref(a).modal.componentProps),null,16,["col-index","row-index","store"]))]),_:1},8,["store"]),[[e.vShow,e.unref(a).modal.visible]])],!0)],4)),[[e.unref(nn),e.unref(a).closeModal]]),e.unref(a).isGanttView&&e.unref(a).isDependencyGraphEnabled?(e.openBlock(),e.createBlock(fn,{key:0,store:e.unref(a),"onConnection:delete":I},null,8,["store"])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-c0a0032f"]]),kn={},Cn={class:"aloading"},En={class:"aloading-header"};function In(t,n){return e.openBlock(),e.createElementBlock("div",Cn,[e.createElementVNode("h2",En,[e.renderSlot(t.$slots,"default",{},void 0,!0)]),n[0]||(n[0]=e.createElementVNode("div",{class:"aloading-bar"},null,-1))])}const ot=K(kn,[["render",In],["__scopeId","data-v-a930a25b"]]),Bn={},Sn={class:"aloading"},$n={class:"aloading-header"};function Vn(t,n){return e.openBlock(),e.createElementBlock("div",Sn,[e.createElementVNode("h2",$n,[e.renderSlot(t.$slots,"default",{},void 0,!0)]),n[0]||(n[0]=e.createElementVNode("div",{class:"aloading-bar"},null,-1))])}const at=K(Bn,[["render",Vn],["__scopeId","data-v-e1165876"]]);function Rn(t){t.component("ACell",Ke),t.component("AExpansionRow",_e),t.component("AGanttCell",et),t.component("ARow",Ve),t.component("ATable",nt),t.component("ATableHeader",ze),t.component("ATableLoading",ot),t.component("ATableLoadingBar",at),t.component("ATableModal",De)}F.ACell=Ke,F.AExpansionRow=_e,F.AGanttCell=et,F.ARow=Ve,F.ATable=nt,F.ATableHeader=ze,F.ATableLoading=ot,F.ATableLoadingBar=at,F.ATableModal=De,F.createTableStore=tt,F.install=Rn,Object.defineProperty(F,Symbol.toStringTag,{value:"Module"})}));
1
+ (function(O,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("pinia")):typeof define=="function"&&define.amd?define(["exports","vue","pinia"],e):(O=typeof globalThis<"u"?globalThis:O||self,e(O["@stonecrop/atable"]={},O.Vue,O.pinia))})(this,(function(O,e,bt){"use strict";var Xe=document.createElement("style");Xe.textContent=`@import"https://fonts.googleapis.com/css2?family=Arimo:ital,wght@0,400..700;1,400..700&display=swap";.atable-cell{border-radius:0;box-sizing:border-box;outline:none;box-shadow:none;color:var(--sc-cell-text-color);padding-left:.5ch!important;padding-right:.5ch;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding);border-spacing:0px;border-collapse:collapse;overflow:hidden;text-overflow:ellipsis;order:1;white-space:nowrap;max-width:40ch;border-top:1px solid var(--sc-row-border-color);margin:0 0 0 1px}.atable-cell a{color:var(--sc-cell-text-color);text-decoration:none}.atable-cell:focus,.atable-cell:focus-within{background-color:var(--sc-focus-cell-background);outline-width:var(--sc-atable-cell-border-width);outline-style:solid;outline-offset:calc(var(--sc-atable-cell-border-width) * -1);outline-color:var(--sc-focus-cell-outline);box-shadow:none;overflow:hidden;text-wrap:nowrap;box-sizing:border-box}.cell-modified{font-weight:700;font-style:italic}.cell-modified-highlight{background-color:var(--sc-cell-changed-color)}.row-index{color:var(--sc-header-text-color);font-weight:700;text-align:center;-webkit-user-select:none;user-select:none;width:2ch;display:flex;align-items:center;justify-content:center}.expandable-row{border-top:1px solid var(--sc-row-border-color);height:var(--sc-atable-row-height)}.expandable-row>td:first-child{border-left:4px solid var(--sc-row-border-color)}.expanded-row{border-left:2px solid var(--sc-row-border-color)}.expandable-row:last-child{border-bottom:1px solid var(--sc-row-border-color)}.expanded-row-content{border-top:1px solid var(--sc-row-border-color);padding:1.5rem}.expandable-row.changed-row-gradient[data-v-a42297c7]:has(td.cell-modified){--cell-color-start: color-mix(in srgb, var(--sc-cell-changed-color), #fff 20%);--cell-color-end: color-mix(in srgb, var(--sc-cell-changed-color), #fff 60%);background:linear-gradient(90deg,var(--cell-color-start),var(--cell-color-end))}.aganttcell[data-v-8917a8a3]{background-color:#f9f9f9;width:100%;padding:0;height:100%}.gantt-container[data-v-8917a8a3]{position:relative;height:100%;background-color:#f0f0f0;border-radius:4px;overflow:visible}.gantt-bar[data-v-8917a8a3]{position:absolute;border-radius:4px;display:flex;align-items:center;justify-content:space-between;cursor:grab;box-sizing:border-box;border:1px solid rgba(0,0,0,.5);transition:left .1s ease-out,width .1s ease-out;height:80%;top:50%;z-index:2;transform:translateY(-50%)}.gantt-bar[data-v-8917a8a3]:active{cursor:grabbing}.gantt-bar.is-dragging[data-v-8917a8a3]{z-index:10}.gantt-label[data-v-8917a8a3]{flex:1;text-align:center;font-size:12px;color:#aaa;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;padding:0 8px;-webkit-user-select:none;user-select:none}.resize-handle[data-v-8917a8a3]{position:relative;width:12px;height:100%;cursor:ew-resize;display:flex;align-items:center;justify-content:center;z-index:0;background:#00000040}.left-resize-handle[data-v-8917a8a3]{border-right:1px solid rgba(0,0,0,.5)}.right-resize-handle[data-v-8917a8a3]{border-left:1px solid rgba(0,0,0,.5)}.handle-grip[data-v-8917a8a3]{width:4px;height:12px;border-radius:2px;background:#000c}.resize-handle[data-v-8917a8a3]:hover{background-color:#ffffff80}.vertical-indicator[data-v-8917a8a3]{position:absolute;width:2px;opacity:0;pointer-events:none;transition:opacity .2s ease;top:-100vh;height:100vh;z-index:5;background-color:var(--v6d722296)}.left-indicator[data-v-8917a8a3]{left:50%;transform:translate(-50%)}.right-indicator[data-v-8917a8a3]{right:50%;transform:translate(50%)}.resize-handle.is-dragging .vertical-indicator[data-v-8917a8a3]{opacity:.7}.gantt-container[data-v-8917a8a3]:after{content:"";position:absolute;inset:0;background-size:calc(100% / var(--v260b36f8)) 100%;background-image:linear-gradient(to right,rgba(0,0,0,.1) 1px,transparent 1px);pointer-events:none;z-index:1}.connection-handle[data-v-8917a8a3]{position:absolute;top:50%;transform:translateY(-50%);width:16px;height:16px;opacity:0;transition:opacity .2s ease;cursor:crosshair;z-index:15;display:flex;align-items:center;justify-content:center}.connection-handle.visible[data-v-8917a8a3]{opacity:1}.left-connection-handle[data-v-8917a8a3]{left:-16px}.right-connection-handle[data-v-8917a8a3]{right:-16px}.connection-dot[data-v-8917a8a3]{width:8px;height:8px;border-radius:50%;background-color:#2196f3;border:2px solid white;box-shadow:0 1px 3px #0000004d}.connection-handle:hover .connection-dot[data-v-8917a8a3]{background-color:#1976d2;transform:scale(1.2)}.connection-handle.is-dragging[data-v-8917a8a3]{opacity:1!important}.connection-handle.is-dragging .connection-dot[data-v-8917a8a3]{background-color:#1976d2;transform:scale(1.3);box-shadow:0 2px 8px #2196f366}.atable-row-actions{width:2rem;min-width:2rem;padding:0 .25rem;vertical-align:middle;white-space:nowrap;border-top:1px solid var(--sc-row-border-color);background:#fff;-webkit-user-select:none;user-select:none;position:relative}.atable-row-actions.dropdown-active{z-index:500}.row-actions-icons{display:flex;gap:.25rem;align-items:center;justify-content:center}.row-action-btn{display:inline-flex;align-items:center;justify-content:center;width:1.5rem;height:1.5rem;padding:.125rem;border:none;background:transparent;cursor:pointer;border-radius:.25rem;transition:background-color .15s ease}.row-action-btn:hover{background-color:var(--sc-gray-10, #e5e5e5)}.row-action-btn:focus{outline:2px solid var(--sc-focus-cell-outline, #3b82f6);outline-offset:1px}.row-action-btn .action-icon{display:flex;align-items:center;justify-content:center;width:1rem;height:1rem}.row-action-btn .action-icon :deep(svg){width:100%;height:100%}.row-actions-dropdown{position:relative;display:inline-block}.row-actions-dropdown:has(button:focus){outline:2px solid var(--sc-focus-cell-outline);outline-offset:-2px}.row-actions-toggle{display:inline-flex;align-items:center;justify-content:center;width:1.5rem;height:1.5rem;padding:0;border:none;background:transparent;cursor:pointer;border-radius:.25rem;font-size:1rem;font-weight:700;transition:background-color .15s ease}.row-actions-toggle:hover{background-color:var(--sc-gray-10, #e5e5e5)}.dropdown-icon{line-height:1}.row-actions-menu{position:fixed;z-index:9999;min-width:10rem;padding:.25rem 0;background:#fff;border:1px solid var(--sc-row-border-color);border-left:4px solid var(--sc-row-border-color);border-radius:0}.row-actions-menu.menu-flipped{box-shadow:0 -4px 6px -1px #0000001a,0 -2px 4px -2px #0000001a}.row-action-menu-item{display:flex;align-items:center;gap:.5rem;width:100%;padding:.5rem .75rem;border:none;background:transparent;cursor:pointer;text-align:left;font-size:.875rem;transition:background-color .15s ease}.row-action-menu-item:hover{background-color:var(--sc-gray-10, #f5f5f5)}.row-action-menu-item:focus{outline:none;background-color:var(--sc-gray-10, #f5f5f5)}.row-action-menu-item .action-icon{display:flex;align-items:center;justify-content:center;width:1rem;height:1rem;flex-shrink:0}.row-action-menu-item .action-icon :deep(svg){width:100%;height:100%}.row-action-menu-item .action-label{flex:1}.atable-row{background-color:#fff}.atable-row>td:first-child{border-left:4px solid var(--sc-row-border-color)}.list-index{color:var(--sc-header-text-color);font-weight:700;padding-left:var(--sc-atable-row-padding);padding-right:.5em;text-align:left;-webkit-user-select:none;user-select:none;border-top:1px solid var(--sc-row-border-color);text-overflow:ellipsis;overflow:hidden;box-sizing:border-box;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding)}.tree-index{color:var(--sc-header-text-color);font-weight:700;text-align:center;-webkit-user-select:none;user-select:none;width:2ch;box-sizing:border-box;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding)}.atable-row:has(td.cell-modified)>td.sticky-column,.atable-row:has(td.cell-modified)>th.sticky-column,.atable-row:has(td.cell-modified)>td.sticky-index,.atable-row:has(td.cell-modified)>th.sticky-index{background:var(--sc-cell-changed-color)}.atable-row.changed-row-gradient[data-v-c35a3748]:has(td.cell-modified){--cell-color-start: color-mix(in srgb, var(--sc-cell-changed-color), #fff 20%);--cell-color-end: color-mix(in srgb, var(--sc-cell-changed-color), #fff 60%);background:linear-gradient(90deg,var(--cell-color-start),var(--cell-color-end))}.gantt-connection-overlay[data-v-71911260]{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none;z-index:1}.connection-path[data-v-71911260]{transition:stroke-width .2s ease;pointer-events:auto;cursor:pointer;stroke-dasharray:5px;stroke:var(--sc-cell-text-color)}#arrowhead-marker polygon[data-v-71911260]{fill:var(--sc-cell-text-color)}.animated-path[data-v-71911260]{animation:animated-dash-71911260 infinite 1.5s linear}.connection-path[data-v-71911260]:hover{stroke-width:3px}.connection-hitbox[data-v-71911260]{pointer-events:auto;cursor:pointer}@keyframes animated-dash-71911260{0%{stroke-dashoffset:0px}to{stroke-dashoffset:-10px}}.column-filter[data-v-8487462d]{display:flex;align-items:center;gap:.25rem;width:100%}.filter-input[data-v-8487462d],.filter-select[data-v-8487462d]{background-color:var(--sc-form-background)!important;padding:.15rem .2rem;border:1px solid var(--sc-form-border);border-radius:3px;font-size:.875rem;color:var(--sc-text-color);width:100%;box-sizing:border-box}.filter-input[data-v-8487462d]:focus,.filter-select[data-v-8487462d]:focus{outline:none;border-color:var(--sc-input-active-border-color)}.checkbox-filter[data-v-8487462d]{display:flex;align-items:center;gap:.25rem;font-size:.875rem;color:var(--sc-text-color);cursor:pointer}.filter-checkbox[data-v-8487462d]{margin:0}.date-range-filter[data-v-8487462d]{display:flex;gap:.25rem;align-items:center;width:100%}.date-range-filter .filter-input[data-v-8487462d]{flex:1;min-width:0}.date-separator[data-v-8487462d]{color:var(--sc-gray-50);font-weight:500;padding:0 .25rem;flex-shrink:0}.clear-btn[data-v-8487462d]{background:var(--sc-gray-10, #f0f0f0);border:1px solid var(--sc-form-border);border-radius:3px;color:var(--sc-gray-70);cursor:pointer;font-size:1rem;padding:.15rem .4rem;line-height:1;flex-shrink:0}.atable-header-row th{padding-left:.5ch!important;font-weight:700;min-width:3ch;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding);box-sizing:border-box;color:var(--sc-header-text-color);position:relative}#header-index{padding-left:var(--sc-atable-row-padding);box-sizing:border-box;border-top:none}.tree-index{padding-right:0}th{order:1}.list-expansion-index{width:2ch;margin-left:5px}.cursor-pointer{cursor:pointer}.atable-filters-row th{padding:.25rem .5ch;vertical-align:top}.row-actions-header{width:2rem;min-width:2rem;padding:0 .25rem}:root{--sc-primary-color: #0098c9;--sc-primary-text-color: #ffffff;--sc-brand-color: #202a44;--sc-gray-5: #f2f2f2;--sc-gray-10: #e6e6e6;--sc-gray-20: #cccccc;--sc-gray-50: #808080;--sc-gray-60: #666666;--sc-gray-80: #333333;--sc-brand-danger: #e63c28;--sc-brand-success: #155724;--sc-brand-warning: #b99d3e;--sc-active-cell-background: #ffffff;--sc-active-cell-outline: #e6a92d;--sc-cell-border-color: #ffffff;--sc-cell-text-color: #3a3c41;--sc-focus-cell-background: #ffffff;--sc-focus-cell-outline: #000000;--sc-header-border-color: #ffffff;--sc-header-text-color: var(--sc-gray-20);--sc-row-border-color: var(--sc-gray-20);--sc-row-color-zebra-dark: #dddddd;--sc-row-color-zebra-light: #eeeeee;--sc-row-number-background-color: #ffffff;--sc-input-active-border-color: #000000;--sc-input-active-label-color: #000000;--sc-input-border-color: var(--sc-gray-20);--sc-input-label-color: var(--sc-gray-60);--sc-required-border: #e63c28;--sc-cell-changed-color: #d8edff;--sc-form-border: var(--sc-gray-5);--sc-form-background: #ffffff;--sc-input-field-background: #ffffff;--sc-input-field-disabled-background: var(--sc-gray-5);--sc-font-size: 10px;--sc-font-family: Arimo, Arial, sans-serif;--sc-table-font-size: 16px;--sc-atable-font-family: "Arimo", sans-serif;--sc-atable-row-padding: .125rem;--sc-atable-row-height: 1.5em;--sc-atable-cell-border-width: 2px;--sc-table-loading-color: 204, 204, 204;--sc-btn-border: #cccccc;--sc-btn-color: white;--sc-btn-hover: #f2f2f2;--sc-btn-label-color: black}.amodal{position:absolute;background-color:var(--sc-row-color-zebra-dark);z-index:5}.atable-container{position:relative}.sticky-index{position:sticky;left:0;z-index:10;order:0}.sticky-column,th.sticky-column,td.sticky-column,th.sticky-index,td.sticky-index{position:sticky;z-index:10;order:0;background:#fff}.sticky-column-edge,.atable th.sticky-column-edge{border-right:1px solid var(--sc-row-border-color)}[data-v-3d00d51b]:root{--sc-primary-color: #0098c9;--sc-primary-text-color: #ffffff;--sc-brand-color: #202a44;--sc-gray-5: #f2f2f2;--sc-gray-10: #e6e6e6;--sc-gray-20: #cccccc;--sc-gray-50: #808080;--sc-gray-60: #666666;--sc-gray-80: #333333;--sc-brand-danger: #e63c28;--sc-brand-success: #155724;--sc-brand-warning: #b99d3e;--sc-active-cell-background: #ffffff;--sc-active-cell-outline: #e6a92d;--sc-cell-border-color: #ffffff;--sc-cell-text-color: #3a3c41;--sc-focus-cell-background: #ffffff;--sc-focus-cell-outline: #000000;--sc-header-border-color: #ffffff;--sc-header-text-color: var(--sc-gray-20);--sc-row-border-color: var(--sc-gray-20);--sc-row-color-zebra-dark: #dddddd;--sc-row-color-zebra-light: #eeeeee;--sc-row-number-background-color: #ffffff;--sc-input-active-border-color: #000000;--sc-input-active-label-color: #000000;--sc-input-border-color: var(--sc-gray-20);--sc-input-label-color: var(--sc-gray-60);--sc-required-border: #e63c28;--sc-cell-changed-color: #d8edff;--sc-form-border: var(--sc-gray-5);--sc-form-background: #ffffff;--sc-input-field-background: #ffffff;--sc-input-field-disabled-background: var(--sc-gray-5);--sc-font-size: 10px;--sc-font-family: Arimo, Arial, sans-serif;--sc-table-font-size: 16px;--sc-atable-font-family: "Arimo", sans-serif;--sc-atable-row-padding: .125rem;--sc-atable-row-height: 1.5em;--sc-atable-cell-border-width: 2px;--sc-table-loading-color: 204, 204, 204;--sc-btn-border: #cccccc;--sc-btn-color: white;--sc-btn-hover: #f2f2f2;--sc-btn-label-color: black}.atable[data-v-3d00d51b]{position:relative;font-family:var(--sc-atable-font-family);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:var(--sc-table-font-size);border-collapse:collapse;box-sizing:border-box;table-layout:auto;width:auto;overflow:clip;height:1px}.atable th[data-v-3d00d51b]{border-width:0px;border-style:solid;border-radius:0;padding-left:.5ch;padding-right:.5ch;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding);color:var(--sc-gray-60);height:var(--sc-atable-row-height);font-weight:300;letter-spacing:.05rem;order:1;box-sizing:border-box}.atable th[data-v-3d00d51b]:focus{outline:none}.atable[data-v-3d00d51b]:tbody{overflow:hidden;position:relative}.atable[data-v-3d00d51b]:tbody:before{content:"";position:absolute;top:0;left:0;right:0;height:1px;background-color:transparent;z-index:100}.aloading[data-v-a930a25b]{width:100%;border-top:1px solid var(--sc-row-border-color);border-bottom:1px solid var(--sc-row-border-color);display:flex;background-color:#fff;border-left:4px solid var(--sc-row-border-color);padding-left:.5ch!important;padding-right:.5ch;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding);align-items:center;box-sizing:border-box;background:var(--sc-focus-cell-background);overflow:hidden;position:relative}.aloading-bar[data-v-a930a25b]{width:100%;height:100%;position:absolute;left:-100%;top:0;background:linear-gradient(90deg,rgba(var(--sc-table-loading-color),0),rgba(var(--sc-table-loading-color),1),rgba(var(--sc-table-loading-color),0));animation:gradient-a930a25b infinite 2s;z-index:0}.aloading-header[data-v-a930a25b]{color:var(--sc-cell-text-color);font-family:var(--sc-atable-font-family);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:var(--sc-table-font-size);padding:0;margin:0;font-weight:400;z-index:1}.aloading-header[data-v-a930a25b]:after{content:"...";animation:ellipse-a930a25b 2s;animation-iteration-count:infinite}@keyframes gradient-a930a25b{0%{left:-100%}to{left:100%}}@keyframes ellipse-a930a25b{0%{content:""}20%{content:""}40%{content:"."}60%{content:".."}80%{content:"..."}}.aloading[data-v-e1165876]{width:100%;border-top:1px solid var(--sc-row-border-color);border-bottom:1px solid var(--sc-row-border-color);display:flex;background-color:#fff;border-left:4px solid var(--sc-row-border-color);padding-left:.5ch!important;padding-right:.5ch;padding-top:var(--sc-atable-row-padding);padding-bottom:var(--sc-atable-row-padding);align-items:center;box-sizing:border-box;background:var(--sc-focus-cell-background);overflow:hidden;position:relative}.aloading-bar[data-v-e1165876]{width:50%;height:3px;position:absolute;left:-100%;bottom:0;background:var(--sc-row-border-color);animation:bar-left-e1165876 infinite 2s;z-index:0}.aloading-header[data-v-e1165876]{color:var(--sc-cell-text-color);font-family:var(--sc-atable-font-family);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:var(--sc-table-font-size);padding:0;margin:0;font-weight:400;z-index:1}.aloading-header[data-v-e1165876]:after{content:"...";animation:ellipse-e1165876 2s;animation-iteration-count:infinite}@keyframes bar-left-e1165876{0%{left:-50%}to{left:100%}}@keyframes ellipse-e1165876{0%{content:""}20%{content:""}40%{content:"."}60%{content:".."}80%{content:"..."}}
2
+ /*$vite$:1*/`,document.head.appendChild(Xe);function Ge(t,n){return e.getCurrentScope()?(e.onScopeDispose(t,n),!0):!1}const vt=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const xt=t=>t!=null,yt=Object.prototype.toString,kt=t=>yt.call(t)==="[object Object]",Ct=()=>{};function ce(t){return Array.isArray(t)?t:[t]}function Et(t,n,i){return e.watch(t,n,{...i,immediate:!0})}const ne=vt?window:void 0;function oe(t){var n;const i=e.toValue(t);return(n=i?.$el)!==null&&n!==void 0?n:i}function ae(...t){const n=(s,f,l,r)=>(s.addEventListener(f,l,r),()=>s.removeEventListener(f,l,r)),i=e.computed(()=>{const s=ce(e.toValue(t[0])).filter(f=>f!=null);return s.every(f=>typeof f!="string")?s:void 0});return Et(()=>{var s,f;return[(s=(f=i.value)===null||f===void 0?void 0:f.map(l=>oe(l)))!==null&&s!==void 0?s:[ne].filter(l=>l!=null),ce(e.toValue(i.value?t[1]:t[0])),ce(e.unref(i.value?t[2]:t[1])),e.toValue(i.value?t[3]:t[2])]},([s,f,l,r],o,d)=>{if(!s?.length||!f?.length||!l?.length)return;const c=kt(r)?{...r}:r,m=s.flatMap(w=>f.flatMap(M=>l.map(V=>n(w,M,V,c))));d(()=>{m.forEach(w=>w())})},{flush:"post"})}function Bt(){const t=e.shallowRef(!1),n=e.getCurrentInstance();return n&&e.onMounted(()=>{t.value=!0},n),t}function Mt(t){const n=Bt();return e.computed(()=>(n.value,!!t()))}function Rt(t,n,i={}){const{window:s=ne,...f}=i;let l;const r=Mt(()=>s&&"MutationObserver"in s),o=()=>{l&&(l.disconnect(),l=void 0)},d=e.watch(e.computed(()=>{const w=ce(e.toValue(t)).map(oe).filter(xt);return new Set(w)}),w=>{o(),r.value&&w.size&&(l=new MutationObserver(n),w.forEach(M=>l.observe(M,f)))},{immediate:!0,flush:"post"}),c=()=>l?.takeRecords(),m=()=>{d(),o()};return Ge(m),{isSupported:r,stop:m,takeRecords:c}}function Vt(t,n,i={}){const{window:s=ne,document:f=s?.document,flush:l="sync"}=i;if(!s||!f)return Ct;let r;const o=m=>{r?.(),r=m},d=e.watchEffect(()=>{const m=oe(t);if(m){const{stop:w}=Rt(f,M=>{M.map(V=>[...V.removedNodes]).flat().some(V=>V===m||V.contains(m))&&n(M)},{window:s,childList:!0,subtree:!0});o(w)}},{flush:l}),c=()=>{d(),o()};return Ge(c),c}function It(t={}){var n;const{window:i=ne,deep:s=!0,triggerOnRemoval:f=!1}=t,l=(n=t.document)!==null&&n!==void 0?n:i?.document,r=()=>{let c=l?.activeElement;if(s)for(var m;c?.shadowRoot;)c=c==null||(m=c.shadowRoot)===null||m===void 0?void 0:m.activeElement;return c},o=e.shallowRef(),d=()=>{o.value=r()};if(i){const c={capture:!0,passive:!0};ae(i,"blur",m=>{m.relatedTarget===null&&d()},c),ae(i,"focus",d,c)}return f&&Vt(o,d,{document:l}),d(),o}const St="focusin",$t="focusout",At=":focus-within";function Dt(t,n={}){const{window:i=ne}=n,s=e.computed(()=>oe(t)),f=e.shallowRef(!1),l=e.computed(()=>f.value);if(!i||!It(n).value)return{focused:l};const r={passive:!0};return ae(s,St,()=>f.value=!0,r),ae(s,$t,()=>{var o,d,c;return f.value=(o=(d=s.value)===null||d===void 0||(c=d.matches)===null||c===void 0?void 0:c.call(d,At))!==null&&o!==void 0?o:!1},r),{focused:l}}function Tt(t,{window:n=ne,scrollTarget:i}={}){const s=e.ref(!1),f=()=>{if(!n)return;const l=n.document,r=oe(t);if(!r)s.value=!1;else{const o=r.getBoundingClientRect();s.value=o.top<=(n.innerHeight||l.documentElement.clientHeight)&&o.left<=(n.innerWidth||l.documentElement.clientWidth)&&o.bottom>=0&&o.right>=0}};return e.watch(()=>oe(t),()=>f(),{immediate:!0,flush:"post"}),n&&ae(i||n,"scroll",f,{capture:!1,passive:!0}),s}const q=t=>{let n=Tt(t).value;return n=n&&t.offsetHeight>0,n},J=t=>t.tabIndex>=0,je=t=>{const n=t.target;return ke(n)},ke=t=>{let n;if(t instanceof HTMLTableCellElement){const i=t.parentElement?.previousElementSibling;if(i){const s=Array.from(i.children)[t.cellIndex];s&&(n=s)}}else if(t instanceof HTMLTableRowElement){const i=t.previousElementSibling;i&&(n=i)}return n&&(!J(n)||!q(n))?ke(n):n},zt=t=>{const n=t.target;let i;if(n instanceof HTMLTableCellElement){const s=n.parentElement?.parentElement;if(s){const f=s.firstElementChild?.children[n.cellIndex];f&&(i=f)}}else if(n instanceof HTMLTableRowElement){const s=n.parentElement;if(s){const f=s.firstElementChild;f&&(i=f)}}return i&&(!J(i)||!q(i))?Ce(i):i},Ue=t=>{const n=t.target;return Ce(n)},Ce=t=>{let n;if(t instanceof HTMLTableCellElement){const i=t.parentElement?.nextElementSibling;if(i){const s=Array.from(i.children)[t.cellIndex];s&&(n=s)}}else if(t instanceof HTMLTableRowElement){const i=t.nextElementSibling;i&&(n=i)}return n&&(!J(n)||!q(n))?Ce(n):n},Nt=t=>{const n=t.target;let i;if(n instanceof HTMLTableCellElement){const s=n.parentElement?.parentElement;if(s){const f=s.lastElementChild?.children[n.cellIndex];f&&(i=f)}}else if(n instanceof HTMLTableRowElement){const s=n.parentElement;if(s){const f=s.lastElementChild;f&&(i=f)}}return i&&(!J(i)||!q(i))?ke(i):i},Ye=t=>{const n=t.target;return Ee(n)},Ee=t=>{let n;return t.previousElementSibling?n=t.previousElementSibling:n=t.parentElement?.previousElementSibling?.lastElementChild,n&&(!J(n)||!q(n))?Ee(n):n},qe=t=>{const n=t.target;return Be(n)},Be=t=>{let n;return t.nextElementSibling?n=t.nextElementSibling:n=t.parentElement?.nextElementSibling?.firstElementChild,n&&(!J(n)||!q(n))?Be(n):n},Je=t=>{const n=t.target.parentElement?.firstElementChild;return n&&(!J(n)||!q(n))?Be(n):n},Qe=t=>{const n=t.target.parentElement?.lastElementChild;return n&&(!J(n)||!q(n))?Ee(n):n},de=["alt","control","shift","meta"],Ht={ArrowUp:"up",ArrowDown:"down",ArrowLeft:"left",ArrowRight:"right"},fe={"keydown.up":t=>{const n=je(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.down":t=>{const n=Ue(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.left":t=>{const n=Ye(t);t.preventDefault(),t.stopPropagation(),n&&n.focus()},"keydown.right":t=>{const n=qe(t);t.preventDefault(),t.stopPropagation(),n&&n.focus()},"keydown.control.up":t=>{const n=zt(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.control.down":t=>{const n=Nt(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.control.left":t=>{const n=Je(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.control.right":t=>{const n=Qe(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.end":t=>{const n=Qe(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.enter":t=>{if(t.target instanceof HTMLTableCellElement){t.preventDefault(),t.stopPropagation();const n=Ue(t);n&&n.focus()}},"keydown.shift.enter":t=>{if(t.target instanceof HTMLTableCellElement){t.preventDefault(),t.stopPropagation();const n=je(t);n&&n.focus()}},"keydown.home":t=>{const n=Je(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.tab":t=>{const n=qe(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())},"keydown.shift.tab":t=>{const n=Ye(t);n&&(t.preventDefault(),t.stopPropagation(),n.focus())}};function Me(t){const n=r=>{let o=null;return r.parent&&(typeof r.parent=="string"?o=document.querySelector(r.parent):r.parent instanceof HTMLElement?o=r.parent:o=r.parent.value),o},i=r=>{const o=n(r);let d=[];if(typeof r.selectors=="string")d=Array.from(o?o.querySelectorAll(r.selectors):document.querySelectorAll(r.selectors));else if(Array.isArray(r.selectors))for(const c of r.selectors)c instanceof HTMLElement?d.push(c):d.push(c.$el);else if(r.selectors instanceof HTMLElement)d.push(r.selectors);else if(r.selectors?.value)if(Array.isArray(r.selectors.value))for(const c of r.selectors.value)c instanceof HTMLElement?d.push(c):d.push(c.$el);else d.push(r.selectors.value);return d},s=r=>{const o=n(r);let d=[];return r.selectors?d=i(r):o&&(d=Array.from(o.children).filter(c=>J(c)&&q(c))),d},f=r=>o=>{const d=Ht[o.key]||o.key.toLowerCase();if(de.includes(d))return;const c=r.handlers||fe;for(const m of Object.keys(c)){const[w,...M]=m.split(".");if(w==="keydown"&&M.includes(d)){const V=c[m],x=M.filter(g=>de.includes(g)),v=de.some(g=>{const h=g.charAt(0).toUpperCase()+g.slice(1);return o.getModifierState(h)});if(x.length>0){if(v){for(const g of de)if(M.includes(g)){const h=g.charAt(0).toUpperCase()+g.slice(1);o.getModifierState(h)&&V(o)}}}else v||V(o)}}},l=[];e.onMounted(()=>{for(const r of t){const o=n(r),d=s(r),c=f(r),m=o?[o]:d;for(const w of m){const{focused:M}=Dt(e.ref(w)),V=e.watch(M,x=>{x?w.addEventListener("keydown",c):w.removeEventListener("keydown",c)});l.push(V)}}}),e.onBeforeUnmount(()=>{for(const r of l)r()})}function Re(t,n){return e.getCurrentScope()?(e.onScopeDispose(t,n),!0):!1}const Ke=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const Lt=t=>t!=null,Ot=Object.prototype.toString,Pt=t=>Ot.call(t)==="[object Object]",ee=()=>{};function Zt(...t){if(t.length!==1)return e.toRef(...t);const n=t[0];return typeof n=="function"?e.readonly(e.customRef(()=>({get:n,set:ee}))):e.ref(n)}function Ft(t,n){function i(...s){return new Promise((f,l)=>{Promise.resolve(t(()=>n.apply(this,s),{fn:n,thisArg:this,args:s})).then(f).catch(l)})}return i}function Wt(t,n={}){let i,s,f=ee;const l=d=>{clearTimeout(d),f(),f=ee};let r;return d=>{const c=e.toValue(t),m=e.toValue(n.maxWait);return i&&l(i),c<=0||m!==void 0&&m<=0?(s&&(l(s),s=void 0),Promise.resolve(d())):new Promise((w,M)=>{f=n.rejectOnCancel?M:w,r=d,m&&!s&&(s=setTimeout(()=>{i&&l(i),s=void 0,w(r())},m)),i=setTimeout(()=>{s&&l(s),s=void 0,w(d())},c)})}}function ue(t){return Array.isArray(t)?t:[t]}function Xt(t){return e.getCurrentInstance()}function Gt(t,n=200,i={}){return Ft(Wt(n,i),t)}function jt(t,n={}){if(!e.isRef(t))return e.toRefs(t);const i=Array.isArray(t.value)?Array.from({length:t.value.length}):{};for(const s in t.value)i[s]=e.customRef(()=>({get(){return t.value[s]},set(f){var l;if(!((l=e.toValue(n.replaceRef))!==null&&l!==void 0)||l)if(Array.isArray(t.value)){const r=[...t.value];r[s]=f,t.value=r}else{const r={...t.value,[s]:f};Object.setPrototypeOf(r,Object.getPrototypeOf(t.value)),t.value=r}else t.value[s]=f}}));return i}function Ut(t,n=!0,i){Xt()?e.onMounted(t,i):n?t():e.nextTick(t)}function Yt(t,n,i){return e.watch(t,n,{...i,immediate:!0})}const le=Ke?window:void 0;function Y(t){var n;const i=e.toValue(t);return(n=i?.$el)!==null&&n!==void 0?n:i}function Q(...t){const n=(s,f,l,r)=>(s.addEventListener(f,l,r),()=>s.removeEventListener(f,l,r)),i=e.computed(()=>{const s=ue(e.toValue(t[0])).filter(f=>f!=null);return s.every(f=>typeof f!="string")?s:void 0});return Yt(()=>{var s,f;return[(s=(f=i.value)===null||f===void 0?void 0:f.map(l=>Y(l)))!==null&&s!==void 0?s:[le].filter(l=>l!=null),ue(e.toValue(i.value?t[1]:t[0])),ue(e.unref(i.value?t[2]:t[1])),e.toValue(i.value?t[3]:t[2])]},([s,f,l,r],o,d)=>{if(!s?.length||!f?.length||!l?.length)return;const c=Pt(r)?{...r}:r,m=s.flatMap(w=>f.flatMap(M=>l.map(V=>n(w,M,V,c))));d(()=>{m.forEach(w=>w())})},{flush:"post"})}function Ve(t,n,i={}){const{window:s=le,ignore:f=[],capture:l=!0,detectIframe:r=!1,controls:o=!1}=i;if(!s)return o?{stop:ee,cancel:ee,trigger:ee}:ee;let d=!0;const c=g=>e.toValue(f).some(h=>{if(typeof h=="string")return Array.from(s.document.querySelectorAll(h)).some(p=>p===g.target||g.composedPath().includes(p));{const p=Y(h);return p&&(g.target===p||g.composedPath().includes(p))}});function m(g){const h=e.toValue(g);return h&&h.$.subTree.shapeFlag===16}function w(g,h){const p=e.toValue(g),E=p.$.subTree&&p.$.subTree.children;return E==null||!Array.isArray(E)?!1:E.some(I=>I.el===h.target||h.composedPath().includes(I.el))}const M=g=>{const h=Y(t);if(g.target!=null&&!(!(h instanceof Element)&&m(t)&&w(t,g))&&!(!h||h===g.target||g.composedPath().includes(h))){if("detail"in g&&g.detail===0&&(d=!c(g)),!d){d=!0;return}n(g)}};let V=!1;const x=[Q(s,"click",g=>{V||(V=!0,setTimeout(()=>{V=!1},0),M(g))},{passive:!0,capture:l}),Q(s,"pointerdown",g=>{const h=Y(t);d=!c(g)&&!!(h&&!g.composedPath().includes(h))},{passive:!0}),r&&Q(s,"blur",g=>{setTimeout(()=>{var h;const p=Y(t);((h=s.document.activeElement)===null||h===void 0?void 0:h.tagName)==="IFRAME"&&!p?.contains(s.document.activeElement)&&n(g)},0)},{passive:!0})].filter(Boolean),v=()=>x.forEach(g=>g());return o?{stop:v,cancel:()=>{d=!1},trigger:g=>{d=!0,M(g),d=!1}}:v}function qt(){const t=e.shallowRef(!1),n=e.getCurrentInstance();return n&&e.onMounted(()=>{t.value=!0},n),t}function _e(t){const n=qt();return e.computed(()=>(n.value,!!t()))}function et(t,n,i={}){const{window:s=le,...f}=i;let l;const r=_e(()=>s&&"MutationObserver"in s),o=()=>{l&&(l.disconnect(),l=void 0)},d=e.watch(e.computed(()=>{const w=ue(e.toValue(t)).map(Y).filter(Lt);return new Set(w)}),w=>{o(),r.value&&w.size&&(l=new MutationObserver(n),w.forEach(M=>l.observe(M,f)))},{immediate:!0,flush:"post"}),c=()=>l?.takeRecords(),m=()=>{d(),o()};return Re(m),{isSupported:r,stop:m,takeRecords:c}}function Ie(t,n={}){var i;const{pointerTypes:s,preventDefault:f,stopPropagation:l,exact:r,onMove:o,onEnd:d,onStart:c,initialValue:m,axis:w="both",draggingElement:M=le,containerElement:V,handle:x=t,buttons:v=[0]}=n,g=e.ref((i=e.toValue(m))!==null&&i!==void 0?i:{x:0,y:0}),h=e.ref(),p=y=>s?s.includes(y.pointerType):!0,E=y=>{e.toValue(f)&&y.preventDefault(),e.toValue(l)&&y.stopPropagation()},I=y=>{var S;if(!e.toValue(v).includes(y.button)||e.toValue(n.disabled)||!p(y)||e.toValue(r)&&y.target!==e.toValue(t))return;const Z=e.toValue(V),L=Z==null||(S=Z.getBoundingClientRect)===null||S===void 0?void 0:S.call(Z),z=e.toValue(t).getBoundingClientRect(),U={x:y.clientX-(Z?z.left-L.left+Z.scrollLeft:z.left),y:y.clientY-(Z?z.top-L.top+Z.scrollTop:z.top)};c?.(U,y)!==!1&&(h.value=U,E(y))},N=y=>{if(e.toValue(n.disabled)||!p(y)||!h.value)return;const S=e.toValue(V),Z=e.toValue(t).getBoundingClientRect();let{x:L,y:z}=g.value;(w==="x"||w==="both")&&(L=y.clientX-h.value.x,S&&(L=Math.min(Math.max(0,L),S.scrollWidth-Z.width))),(w==="y"||w==="both")&&(z=y.clientY-h.value.y,S&&(z=Math.min(Math.max(0,z),S.scrollHeight-Z.height))),g.value={x:L,y:z},o?.(g.value,y),E(y)},A=y=>{e.toValue(n.disabled)||!p(y)||h.value&&(h.value=void 0,d?.(g.value,y),E(y))};if(Ke){const y=()=>{var S;return{capture:(S=n.capture)!==null&&S!==void 0?S:!0,passive:!e.toValue(f)}};Q(x,"pointerdown",I,y),Q(M,"pointermove",N,y),Q(M,"pointerup",A,y)}return{...jt(g),position:g,isDragging:e.computed(()=>!!h.value),style:e.computed(()=>`left:${g.value.x}px;top:${g.value.y}px;`)}}function me(t,n,i={}){const{window:s=le,...f}=i;let l;const r=_e(()=>s&&"ResizeObserver"in s),o=()=>{l&&(l.disconnect(),l=void 0)},d=e.watch(e.computed(()=>{const m=e.toValue(t);return Array.isArray(m)?m.map(w=>Y(w)):[Y(m)]}),m=>{if(o(),r.value&&s){l=new ResizeObserver(n);for(const w of m)w&&l.observe(w,f)}},{immediate:!0,flush:"post"}),c=()=>{o(),d()};return Re(c),{isSupported:r,stop:c}}function te(t,n={}){const{reset:i=!0,windowResize:s=!0,windowScroll:f=!0,immediate:l=!0,updateTiming:r="sync"}=n,o=e.shallowRef(0),d=e.shallowRef(0),c=e.shallowRef(0),m=e.shallowRef(0),w=e.shallowRef(0),M=e.shallowRef(0),V=e.shallowRef(0),x=e.shallowRef(0);function v(){const h=Y(t);if(!h){i&&(o.value=0,d.value=0,c.value=0,m.value=0,w.value=0,M.value=0,V.value=0,x.value=0);return}const p=h.getBoundingClientRect();o.value=p.height,d.value=p.bottom,c.value=p.left,m.value=p.right,w.value=p.top,M.value=p.width,V.value=p.x,x.value=p.y}function g(){r==="sync"?v():r==="next-frame"&&requestAnimationFrame(()=>v())}return me(t,g),e.watch(()=>Y(t),h=>!h&&g()),et(t,g,{attributeFilter:["style","class"]}),f&&Q("scroll",g,{capture:!0,passive:!0}),s&&Q("resize",g,{passive:!0}),Ut(()=>{l&&g()}),{height:o,bottom:d,left:c,right:m,top:w,width:M,x:V,y:x,update:g}}function Se(t){return typeof Window<"u"&&t instanceof Window?t.document.documentElement:typeof Document<"u"&&t instanceof Document?t.documentElement:t}const $e=new WeakMap;function Jt(t,n=!1){const i=e.shallowRef(n);let s="";e.watch(Zt(t),r=>{const o=Se(e.toValue(r));if(o){const d=o;if($e.get(d)||$e.set(d,d.style.overflow),d.style.overflow!=="hidden"&&(s=d.style.overflow),d.style.overflow==="hidden")return i.value=!0;if(i.value)return d.style.overflow="hidden"}},{immediate:!0});const f=()=>{const r=Se(e.toValue(t));!r||i.value||(r.style.overflow="hidden",i.value=!0)},l=()=>{const r=Se(e.toValue(t));!r||!i.value||(r.style.overflow=s,$e.delete(r),i.value=!1)};return Re(l),e.computed({get(){return i.value},set(r){r?f():l()}})}const Qt=t=>{const n=new DOMParser().parseFromString(t,"text/html");return Array.from(n.body.childNodes).some(i=>i.nodeType===1)},Kt=(t=8)=>Array.from({length:t},()=>Math.floor(Math.random()*16).toString(16)).join(""),_t=["data-colindex","data-rowindex","data-editable","contenteditable","tabindex"],en=["innerHTML"],tn={key:2},tt=e.defineComponent({__name:"ACell",props:{colIndex:{},rowIndex:{},store:{},addNavigation:{type:[Boolean,Object],default:!0},tabIndex:{default:0},pinned:{type:Boolean,default:!1},debounce:{default:300}},setup(t,{expose:n}){const i=e.useTemplateRef("cell"),s=t.store.getCellData(t.colIndex,t.rowIndex),f=e.ref(""),l=e.ref(!1),r=t.store.columns[t.colIndex],o=t.store.rows[t.rowIndex],d=r.align||"center",c=r.width||"40ch",m=e.computed(()=>t.store.getCellDisplayValue(t.colIndex,t.rowIndex)),w=e.computed(()=>typeof m.value=="string"?Qt(m.value):!1),M=e.computed(()=>({textAlign:d,width:c,fontWeight:l.value?"bold":"inherit",paddingLeft:t.store.getIndent(t.colIndex,t.store.display[t.rowIndex]?.indent)})),V=e.computed(()=>({"sticky-column":t.pinned,"cell-modified":l.value})),x=()=>{g(),v()},v=()=>{const{left:A,bottom:y,width:S,height:Z}=te(i);r.mask,r.modalComponent&&t.store.$patch(L=>{L.modal.visible=!0,L.modal.colIndex=t.colIndex,L.modal.rowIndex=t.rowIndex,L.modal.left=A,L.modal.bottom=y,L.modal.width=S,L.modal.height=Z,L.modal.cell=i.value,typeof r.modalComponent=="function"?L.modal.component=r.modalComponent({table:L.table,row:o,column:r}):L.modal.component=r.modalComponent,L.modal.componentProps=r.modalComponentExtraProps})};if(t.addNavigation){let A={...fe,"keydown.f2":v,"keydown.alt.up":v,"keydown.alt.down":v,"keydown.alt.left":v,"keydown.alt.right":v};typeof t.addNavigation=="object"&&(A={...A,...t.addNavigation}),Me([{selectors:i,handlers:A}])}const g=()=>{if(i.value&&r.edit){const A=window.getSelection();if(A)try{const y=document.createRange();y.selectNodeContents&&(y.selectNodeContents(i.value),A.removeAllRanges(),A.addRange(y))}catch{}}},h=()=>{i.value&&(f.value=i.value.textContent,g())},p=()=>{try{const A=window.getSelection();if(A&&A.rangeCount>0&&i.value){const y=A.getRangeAt(0),S=y.cloneRange();if(S.selectNodeContents&&S.setEnd)return S.selectNodeContents(i.value),S.setEnd(y.endContainer,y.endOffset),S.toString().length}}catch{}return 0},E=A=>{if(i.value)try{const y=window.getSelection();if(!y)return;let S=0;const Z=document.createTreeWalker?document.createTreeWalker(i.value,NodeFilter.SHOW_TEXT,null):null;if(!Z)return;let L,z=null;for(;L=Z.nextNode();){const U=L,_=S+U.textContent.length;if(A<=_&&(z=document.createRange(),z.setStart&&z.setEnd)){z.setStart(U,A-S),z.setEnd(U,A-S);break}S=_}z&&y.removeAllRanges&&y.addRange&&(y.removeAllRanges(),y.addRange(z))}catch{}},I=A=>{if(!r.edit)return;const y=A.target;if(y.textContent===f.value)return;const S=p();f.value=y.textContent,r.format?(l.value=y.textContent!==t.store.getFormattedValue(t.colIndex,t.rowIndex,s),t.store.setCellText(t.colIndex,t.rowIndex,y.textContent)):(l.value=y.textContent!==s,t.store.setCellData(t.colIndex,t.rowIndex,y.textContent)),e.nextTick().then(()=>{E(S)})},N=Gt(I,t.debounce);return n({currentData:f}),(A,y)=>(e.openBlock(),e.createElementBlock("td",{ref:"cell","data-colindex":t.colIndex,"data-rowindex":t.rowIndex,"data-editable":e.unref(r).edit,contenteditable:e.unref(r).edit,tabindex:t.tabIndex,spellcheck:!1,style:e.normalizeStyle(M.value),class:e.normalizeClass(["atable-cell",V.value]),onFocus:h,onPaste:I,onInput:y[0]||(y[0]=(...S)=>e.unref(N)&&e.unref(N)(...S)),onClick:x},[e.unref(r).cellComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(r).cellComponent),e.mergeProps({key:0,value:m.value},e.unref(r).cellComponentProps),null,16,["value"])):w.value?(e.openBlock(),e.createElementBlock("span",{key:1,innerHTML:m.value},null,8,en)):(e.openBlock(),e.createElementBlock("span",tn,e.toDisplayString(m.value),1))],46,_t))}}),nn=["tabindex"],on=["tabindex"],an=["colspan"],ln=e.defineComponent({__name:"AExpansionRow",props:{rowIndex:{},store:{},tabIndex:{default:()=>-1},addNavigation:{type:[Boolean,Object],default:()=>fe}},setup(t){const n=e.useTemplateRef("rowEl"),i=e.computed(()=>t.store.display[t.rowIndex].expanded?"▼":"►");if(t.addNavigation){const s={"keydown.control.g":f=>{f.stopPropagation(),f.preventDefault(),t.store.toggleRowExpand(t.rowIndex)}};typeof t.addNavigation=="object"&&Object.assign(s,t.addNavigation),Me([{selectors:n,handlers:s}])}return(s,f)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("tr",e.mergeProps(s.$attrs,{ref:"rowEl",tabindex:t.tabIndex,class:"expandable-row"}),[e.createElementVNode("td",{tabIndex:-1,class:"row-index",onClick:f[0]||(f[0]=l=>t.store.toggleRowExpand(t.rowIndex))},e.toDisplayString(i.value),1),e.renderSlot(s.$slots,"row",{},void 0,!0)],16,nn),t.store.display[t.rowIndex].expanded?(e.openBlock(),e.createElementBlock("tr",{key:0,ref:"rowExpanded",tabindex:t.tabIndex,class:"expanded-row"},[e.createElementVNode("td",{tabIndex:-1,colspan:t.store.columns.length+1,class:"expanded-row-content"},[e.renderSlot(s.$slots,"content",{},void 0,!0)],8,an)],8,on)):e.createCommentVNode("",!0)],64))}}),K=(t,n)=>{const i=t.__vccOpts||t;for(const[s,f]of n)i[s]=f;return i},nt=K(ln,[["__scopeId","data-v-a42297c7"]]),rn=["colspan"],sn={ref:"container",class:"gantt-container"},cn=["data-rowindex","data-colindex"],dn={key:2,class:"gantt-label"},fn=["x1","y1","x2","y2"],ot=K(e.defineComponent({__name:"AGanttCell",props:{store:{},columnsCount:{},rowIndex:{},colIndex:{},start:{default:0},end:{default:0},colspan:{default:1},label:{default:""},color:{default:"#cccccc"}},emits:["connection:create"],setup(t,{expose:n,emit:i}){e.useCssVars(R=>({v6d722296:f.value,v260b36f8:R.colspan}));const s=i,f=e.ref(t.color.length>=6?t.color:"#cccccc"),l=`gantt-bar-row-${t.rowIndex}-col-${t.colIndex}`,r=e.useTemplateRef("container"),o=e.useTemplateRef("bar"),d=e.useTemplateRef("leftResizeHandle"),c=e.useTemplateRef("rightResizeHandle"),m=e.useTemplateRef("leftConnectionHandle"),w=e.useTemplateRef("rightConnectionHandle"),{width:M}=te(r),{left:V,right:x}=te(o),v=e.ref(t.start),g=e.ref(t.end||v.value+t.colspan),h=e.ref(!1),p=e.ref(!1),E=e.ref(!1),I=e.ref(!1),N=e.ref(!1),A=e.ref({startX:0,startY:0,endX:0,endY:0}),y=e.computed(()=>he.value||U.value||_.value),S=e.computed(()=>t.colspan>0?M.value/t.colspan:0),Z=e.computed(()=>{const R=v.value/t.colspan*100,D=g.value/t.colspan*100;return{left:`${R}%`,width:`${D-R}%`,backgroundColor:f.value}}),L=e.computed(()=>({position:"fixed",top:0,left:0,width:"100vw",height:"100vh",pointerEvents:"none",zIndex:1e3})),z=e.ref({startX:0,startPos:0}),{isDragging:U}=Ie(d,{axis:"x",onStart:()=>ie(V.value,v.value),onMove:({x:R})=>Ne(R),onEnd:({x:R})=>He(R)}),{isDragging:_}=Ie(c,{axis:"x",onStart:()=>ie(x.value,g.value),onMove:({x:R})=>Le(R),onEnd:({x:R})=>pe(R)}),{isDragging:he}=Ie(o,{exact:!0,axis:"x",onStart:()=>ie(V.value,v.value),onMove:({x:R})=>Oe(R),onEnd:({x:R})=>we(R)});e.onMounted(()=>{Pe()}),e.onUnmounted(()=>{Ze()});function ie(R,D){o.value&&(o.value.style.transition="none"),z.value={startX:R,startPos:D}}function Ne(R){if(!U.value||!o.value)return;const P=(R-z.value.startX)/S.value,H=Math.max(0,Math.min(g.value-1,z.value.startPos+P));o.value.style.left=`${H/t.colspan*100}%`,o.value.style.width=`${(g.value-H)/t.colspan*100}%`}function He(R){if(!o.value)return;const D=R-z.value.startX,P=Math.round(D/S.value),H=v.value,F=Math.max(0,Math.min(g.value-1,z.value.startPos+P));v.value=F,t.store.updateGanttBar({rowIndex:t.rowIndex,colIndex:t.colIndex,type:"resize",edge:"start",oldStart:H,newStart:F,end:g.value,delta:P,oldColspan:g.value-H,newColspan:g.value-F})}function Le(R){if(!_.value||!o.value)return;const P=(R-z.value.startX)/S.value,H=Math.max(v.value+1,Math.min(t.columnsCount,z.value.startPos+P));o.value.style.width=`${(H-v.value)/t.colspan*100}%`}function pe(R){if(!o.value)return;const D=R-z.value.startX,P=Math.round(D/S.value),H=g.value,F=Math.max(v.value+1,Math.min(t.columnsCount,z.value.startPos+P));g.value=F,t.store.updateGanttBar({rowIndex:t.rowIndex,colIndex:t.colIndex,type:"resize",edge:"end",oldEnd:H,newEnd:F,start:v.value,delta:P,oldColspan:H-v.value,newColspan:F-v.value})}function Oe(R){if(!he.value||!o.value)return;const P=(R-z.value.startX)/S.value,H=g.value-v.value,F=Math.max(0,Math.min(z.value.startPos+P,t.columnsCount-H));o.value.style.left=`${F/t.colspan*100}%`}function we(R){if(!o.value)return;const D=R-z.value.startX,P=Math.round(D/S.value),H=g.value-v.value,F=v.value,X=g.value;let G=z.value.startPos+P,j=G+H;G<0?(G=0,j=H):j>t.columnsCount&&(j=t.columnsCount,G=j-H),v.value=G,g.value=j,t.store.updateGanttBar({rowIndex:t.rowIndex,colIndex:t.colIndex,type:"bar",oldStart:F,oldEnd:X,newStart:G,newEnd:j,delta:P,colspan:j-G})}function Pe(){const{x:R,y:D}=te(o),{x:P,y:H}=te(m),{x:F,y:X}=te(w);t.store.registerGanttBar({id:l,rowIndex:t.rowIndex,colIndex:t.colIndex,startIndex:v,endIndex:g,color:f,label:t.label,position:{x:R,y:D}}),t.store.isDependencyGraphEnabled&&(t.store.registerConnectionHandle({id:`${l}-connection-left`,rowIndex:t.rowIndex,colIndex:t.colIndex,side:"left",position:{x:P,y:H},visible:h,barId:l}),t.store.registerConnectionHandle({id:`${l}-connection-right`,rowIndex:t.rowIndex,colIndex:t.colIndex,side:"right",position:{x:F,y:X},visible:p,barId:l}))}function Ze(){t.store.unregisterGanttBar(l),t.store.isDependencyGraphEnabled&&(t.store.unregisterConnectionHandle(`${l}-connection-left`),t.store.unregisterConnectionHandle(`${l}-connection-right`))}function Fe(){t.store.isDependencyGraphEnabled&&(h.value=!0,p.value=!0)}function be(){!E.value&&!I.value&&(h.value=!1,p.value=!1)}function ve(R,D){D.preventDefault(),D.stopPropagation(),N.value=!0,R==="left"?E.value=!0:I.value=!0;const P=R==="left"?m.value:w.value;if(P){const X=P.getBoundingClientRect(),G=X.left+X.width/2,j=X.top+X.height/2;A.value={startX:G,startY:j,endX:G,endY:j}}const H=X=>{A.value.endX=X.clientX,A.value.endY=X.clientY},F=X=>{xe(X,R),ye(H,F)};document.addEventListener("mousemove",H),document.addEventListener("mouseup",F)}function xe(R,D){const H=document.elementFromPoint(R.clientX,R.clientY)?.closest(".connection-handle");if(H&&H!==(D==="left"?m.value:w.value)){const F=H.closest(".gantt-bar");if(F){const X=parseInt(F.getAttribute("data-rowindex")||"0"),G=parseInt(F.getAttribute("data-colindex")||"0"),j=H.classList.contains("left-connection-handle")?"left":"right",se=`gantt-bar-row-${X}-col-${G}`,We=t.store.createConnection(`${l}-connection-${D}`,`${se}-connection-${j}`);We&&s("connection:create",We)}}}function ye(R,D){N.value=!1,E.value=!1,I.value=!1,document.removeEventListener("mousemove",R),document.removeEventListener("mouseup",D),o.value?.matches(":hover")||be()}return n({barStyle:Z,cleanupConnectionDrag:ye,currentEnd:g,handleConnectionDrop:xe,isLeftConnectionDragging:E,isLeftConnectionVisible:h,isRightConnectionDragging:I,isRightConnectionVisible:p,showDragPreview:N}),(R,D)=>(e.openBlock(),e.createElementBlock("td",{class:"aganttcell",colspan:t.colspan},[e.createElementVNode("div",sn,[e.createElementVNode("div",{ref:"bar","data-rowindex":t.rowIndex,"data-colindex":t.colIndex,class:e.normalizeClass(["gantt-bar",{"is-dragging":y.value}]),style:e.normalizeStyle(Z.value),onMouseenter:Fe,onMouseleave:be},[t.store.isDependencyGraphEnabled?(e.openBlock(),e.createElementBlock("div",{key:0,ref:"leftConnectionHandle",class:e.normalizeClass(["connection-handle left-connection-handle",{visible:h.value,"is-dragging":E.value}]),onMousedown:D[0]||(D[0]=e.withModifiers(P=>ve("left",P),["stop"]))},[...D[2]||(D[2]=[e.createElementVNode("div",{class:"connection-dot"},null,-1)])],34)):e.createCommentVNode("",!0),t.store.isDependencyGraphEnabled?(e.openBlock(),e.createElementBlock("div",{key:1,ref:"rightConnectionHandle",class:e.normalizeClass(["connection-handle right-connection-handle",{visible:p.value,"is-dragging":I.value}]),onMousedown:D[1]||(D[1]=e.withModifiers(P=>ve("right",P),["stop"]))},[...D[3]||(D[3]=[e.createElementVNode("div",{class:"connection-dot"},null,-1)])],34)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref:"leftResizeHandle",class:e.normalizeClass(["resize-handle left-resize-handle",{"is-dragging":e.unref(U)}])},[...D[4]||(D[4]=[e.createElementVNode("div",{class:"handle-grip"},null,-1),e.createElementVNode("div",{class:"vertical-indicator left-indicator"},null,-1)])],2),t.label?(e.openBlock(),e.createElementBlock("label",dn,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref:"rightResizeHandle",class:e.normalizeClass(["resize-handle right-resize-handle",{"is-dragging":e.unref(_)}])},[...D[5]||(D[5]=[e.createElementVNode("div",{class:"handle-grip"},null,-1),e.createElementVNode("div",{class:"vertical-indicator right-indicator"},null,-1)])],2)],46,cn)],512),t.store.isDependencyGraphEnabled&&N.value?(e.openBlock(),e.createElementBlock("svg",{key:0,style:e.normalizeStyle(L.value)},[e.createElementVNode("line",{x1:A.value.startX,y1:A.value.startY,x2:A.value.endX,y2:A.value.endY,stroke:"#2196f3","stroke-width":"2","stroke-dasharray":"5,5"},null,8,fn)],4)):e.createCommentVNode("",!0)],8,rn))}}),[["__scopeId","data-v-8917a8a3"]]),at=`<?xml version="1.0" encoding="UTF-8"?>
3
+ <svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64">
4
+ <path d="M32,64C14.35,64,0,49.65,0,32S14.35,0,32,0s32,14.35,32,32-14.35,32-32,32ZM32,4c-15.44,0-28,12.56-28,28s12.56,28,28,28,28-12.56,28-28S47.44,4,32,4Z" style="fill: #000; stroke-width: 0px;"/>
5
+ <polygon points="34 18 30 18 30 30 18 30 18 34 30 34 30 46 34 46 34 34 46 34 46 30 34 30 34 18" style="fill: #000; stroke-width: 0px;"/>
6
+ </svg>
7
+ `,lt=`<?xml version="1.0" encoding="UTF-8"?>
8
+ <svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64">
9
+ <path d="M32,64C14.35,64,0,49.65,0,32S14.35,0,32,0s32,14.35,32,32-14.35,32-32,32ZM32,4c-15.44,0-28,12.56-28,28s12.56,28,28,28,28-12.56,28-28S47.44,4,32,4Z" style="fill: #000; stroke-width: 0px;"/>
10
+ <polygon points="46.84 19.99 44.01 17.16 32 29.17 19.99 17.16 17.16 19.99 29.17 32 17.16 44.01 19.99 46.84 32 34.83 44.01 46.84 46.84 44.01 34.83 32 46.84 19.99" style="fill: #000; stroke-width: 0px;"/>
11
+ </svg>`,rt=`<?xml version="1.0" encoding="UTF-8"?>
12
+ <svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 70.67 70.67">
13
+ <path d="M68.67,16.67h-14.67V2c0-1.1-.9-2-2-2H2C.9,0,0,.9,0,2v50c0,1.1.9,2,2,2h14.67v14.67c0,1.1.9,2,2,2h50c1.1,0,2-.9,2-2V18.67c0-1.1-.9-2-2-2ZM4,4h46v46H4V4ZM66.67,66.67H20.67v-12.67h31.33c1.1,0,2-.9,2-2v-31.33h12.67v46Z" style="fill: #000; stroke-width: 0px;"/>
14
+ <polygon points="41 25 29 25 29 13 25 13 25 25 13 25 13 29 25 29 25 41 29 41 29 29 41 29 41 25" style="fill: #000; stroke-width: 0px;"/>
15
+ </svg>`,it=`<?xml version="1.0" encoding="UTF-8"?>
16
+ <svg id="Layer_1" xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 70.6 61.5">
17
+ <path d="M68.6,45.8v13.7H2v-13.7h66.6M70.6,43.8H0v17.7h70.6v-17.7h0Z"/>
18
+ <path d="M68.6,24.2v13.7H2v-13.7h66.6M70.6,22.2H0v17.7h70.6v-17.7h0Z"/>
19
+ <g>
20
+ <polygon points="70.6 2.5 68.6 2.5 68.6 2 68.1 2 68.1 0 70.6 0 70.6 2.5"/>
21
+ <path d="M65.3,2h-2.9V0h2.9v2ZM59.6,2h-2.9V0h2.9v2ZM53.9,2h-2.9V0h2.9v2ZM48.2,2h-2.9V0h2.9v2ZM42.4,2h-2.9V0h2.9v2ZM36.7,2h-2.9V0h2.9v2ZM31,2h-2.9V0h2.9v2ZM25.3,2h-2.9V0h2.9v2ZM19.6,2h-2.9V0h2.9v2ZM13.9,2h-2.9V0h2.9v2ZM8.2,2h-2.9V0h2.9v2Z"/>
22
+ <polygon points="2 2.5 0 2.5 0 0 2.5 0 2.5 2 2 2 2 2.5"/>
23
+ <path d="M2,13.4H0v-2.7h2v2.7ZM2,8H0v-2.7h2v2.7Z"/>
24
+ <polygon points="2.5 18.7 0 18.7 0 16.2 2 16.2 2 16.7 2.5 16.7 2.5 18.7"/>
25
+ <path d="M65.3,18.7h-2.9v-2h2.9v2ZM59.6,18.7h-2.9v-2h2.9v2ZM53.9,18.7h-2.9v-2h2.9v2ZM48.2,18.7h-2.9v-2h2.9v2ZM42.4,18.7h-2.9v-2h2.9v2ZM36.7,18.7h-2.9v-2h2.9v2ZM31,18.7h-2.9v-2h2.9v2ZM25.3,18.7h-2.9v-2h2.9v2ZM19.6,18.7h-2.9v-2h2.9v2ZM13.9,18.7h-2.9v-2h2.9v2ZM8.2,18.7h-2.9v-2h2.9v2Z"/>
26
+ <polygon points="70.6 18.7 68.1 18.7 68.1 16.7 68.6 16.7 68.6 16.2 70.6 16.2 70.6 18.7"/>
27
+ <path d="M70.6,13.4h-2v-2.7h2v2.7ZM70.6,8h-2v-2.7h2v2.7Z"/>
28
+ </g>
29
+ </svg>`,st=`<?xml version="1.0" encoding="UTF-8"?>
30
+ <svg id="Layer_1" xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 70.6 61.5">
31
+ <g>
32
+ <polygon points="70.6 45.3 68.6 45.3 68.6 44.8 68.1 44.8 68.1 42.8 70.6 42.8 70.6 45.3"/>
33
+ <path d="M65.3,44.8h-2.9v-2h2.9v2ZM59.6,44.8h-2.9v-2h2.9v2ZM53.9,44.8h-2.9v-2h2.9v2ZM48.2,44.8h-2.9v-2h2.9v2ZM42.4,44.8h-2.9v-2h2.9v2ZM36.7,44.8h-2.9v-2h2.9v2ZM31,44.8h-2.9v-2h2.9v2ZM25.3,44.8h-2.9v-2h2.9v2ZM19.6,44.8h-2.9v-2h2.9v2ZM13.9,44.8h-2.9v-2h2.9v2ZM8.2,44.8h-2.9v-2h2.9v2Z"/>
34
+ <polygon points="2 45.3 0 45.3 0 42.8 2.5 42.8 2.5 44.8 2 44.8 2 45.3"/>
35
+ <path d="M2,56.3H0v-2.7h2v2.7ZM2,50.8H0v-2.7h2v2.7Z"/>
36
+ <polygon points="2.5 61.5 0 61.5 0 59 2 59 2 59.5 2.5 59.5 2.5 61.5"/>
37
+ <path d="M65.3,61.5h-2.9v-2h2.9v2ZM59.6,61.5h-2.9v-2h2.9v2ZM53.9,61.5h-2.9v-2h2.9v2ZM48.2,61.5h-2.9v-2h2.9v2ZM42.4,61.5h-2.9v-2h2.9v2ZM36.7,61.5h-2.9v-2h2.9v2ZM31,61.5h-2.9v-2h2.9v2ZM25.3,61.5h-2.9v-2h2.9v2ZM19.6,61.5h-2.9v-2h2.9v2ZM13.9,61.5h-2.9v-2h2.9v2ZM8.2,61.5h-2.9v-2h2.9v2Z"/>
38
+ <polygon points="70.6 61.5 68.1 61.5 68.1 59.5 68.6 59.5 68.6 59 70.6 59 70.6 61.5"/>
39
+ <path d="M70.6,56.3h-2v-2.7h2v2.7ZM70.6,50.8h-2v-2.7h2v2.7Z"/>
40
+ </g>
41
+ <path d="M68.6,23.7v13.7H2v-13.7h66.6M70.6,21.7H0v17.7h70.6v-17.7h0Z"/>
42
+ <path d="M68.6,2v13.7H2V2h66.6M70.6,0H0v17.7h70.6V0h0Z"/>
43
+ </svg>`,ct=`<?xml version="1.0" encoding="UTF-8"?>
44
+ <svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 70.67 70.64">
45
+ <path d="M70.08,33.9l-9.75-9.75-2.83,2.83,6.33,6.33h-26.51V6.81l6.33,6.33,2.83-2.83L36.75.56c-.75-.75-2.08-.75-2.83,0l-9.75,9.75,2.83,2.83,6.33-6.33v26.5H6.83l6.33-6.33-2.83-2.83L.59,33.9c-.38.38-.59.88-.59,1.41s.21,1.04.59,1.41l9.75,9.75,2.83-2.83-6.33-6.33h26.5v26.51l-6.33-6.33-2.83,2.83,9.75,9.75c.38.38.88.59,1.41.59s1.04-.21,1.41-.59l9.75-9.75-2.83-2.83-6.33,6.33v-26.51h26.51l-6.33,6.33,2.83,2.83,9.75-9.75c.38-.38.59-.88.59-1.41s-.21-1.04-.59-1.41Z" style="fill: #000; stroke-width: 0px;"/>
46
+ </svg>`,dt={add:at,delete:lt,duplicate:rt,insertAbove:it,insertBelow:st,move:ct},un={key:0,class:"row-actions-dropdown"},mn=["aria-expanded"],gn=["onClick"],hn=["innerHTML"],pn={class:"action-label"},wn={key:1,class:"row-actions-icons"},bn=["title","aria-label","onClick"],vn=["innerHTML"],re=e.defineComponent({__name:"ARowActions",props:{rowIndex:{},store:{},config:{},position:{}},emits:["action"],setup(t,{emit:n}){const i=t,s=n,f=e.useTemplateRef("actionsCell"),l=e.useTemplateRef("toggleButton"),r=e.ref(0),o=e.ref(!1),d=e.ref(!1),c=e.ref({top:0,left:0}),m={add:"Add Row",delete:"Delete Row",duplicate:"Duplicate Row",insertAbove:"Insert Above",insertBelow:"Insert Below",move:"Move Row"},w=e.computed(()=>{const h=[],p=i.config.actions||{},E=["add","delete","duplicate","insertAbove","insertBelow","move"];for(const I of E){const N=p[I];if(N===!1||N===void 0)continue;let A=!0,y=m[I],S=dt[I];typeof N=="object"&&(A=N.enabled!==!1,y=N.label||y,S=N.icon||S),A&&h.push({type:I,label:y,icon:S})}return h}),M=e.computed(()=>{if(i.config.forceDropdown)return!0;const h=i.config.dropdownThreshold??150;return h===0?!1:r.value>0&&r.value<h}),V=e.computed(()=>o.value?d.value?{position:"fixed",bottom:`${window.innerHeight-c.value.top}px`,left:`${c.value.left}px`,top:"auto"}:{position:"fixed",top:`${c.value.top}px`,left:`${c.value.left}px`}:{});me(f,h=>{const p=h[0];p&&(r.value=p.contentRect.width)});const x=()=>{o.value||v(),o.value=!o.value},v=()=>{if(!l.value)return;const h=l.value.getBoundingClientRect(),p=window.innerHeight,E=w.value.length*40+16,I=p-h.bottom,N=h.top;d.value=I<E&&N>E,d.value?c.value={top:h.top,left:h.left}:c.value={top:h.bottom,left:h.left}};Ve(f,()=>{o.value=!1});const g=h=>{o.value=!1;const p=i.config.actions?.[h];typeof p=="object"&&p.handler&&p.handler(i.rowIndex,i.store)===!1||s("action",h,i.rowIndex)};return(h,p)=>(e.openBlock(),e.createElementBlock("td",{ref:"actionsCell",class:e.normalizeClass(["atable-row-actions",{"sticky-column":t.position==="before-index","dropdown-active":o.value}])},[M.value?(e.openBlock(),e.createElementBlock("div",un,[e.createElementVNode("button",{ref:"toggleButton",type:"button",class:"row-actions-toggle","aria-expanded":o.value,"aria-haspopup":"true",onClick:e.withModifiers(x,["stop"])},[...p[0]||(p[0]=[e.createElementVNode("span",{class:"dropdown-icon"},"⋮",-1)])],8,mn),e.withDirectives(e.createElementVNode("div",{class:e.normalizeClass(["row-actions-menu",{"menu-flipped":d.value}]),style:e.normalizeStyle(V.value),role:"menu"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,E=>(e.openBlock(),e.createElementBlock("button",{key:E.type,type:"button",class:"row-action-menu-item",role:"menuitem",onClick:e.withModifiers(I=>g(E.type),["stop"])},[e.createElementVNode("span",{class:"action-icon",innerHTML:E.icon},null,8,hn),e.createElementVNode("span",pn,e.toDisplayString(E.label),1)],8,gn))),128))],6),[[e.vShow,o.value]])])):(e.openBlock(),e.createElementBlock("div",wn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,E=>(e.openBlock(),e.createElementBlock("button",{key:E.type,type:"button",class:"row-action-btn",title:E.label,"aria-label":E.label,onClick:e.withModifiers(I=>g(E.type),["stop"])},[e.createElementVNode("span",{class:"action-icon",innerHTML:E.icon},null,8,vn)],8,bn))),128))]))],2))}}),xn=["tabindex"],Ae=K(e.defineComponent({__name:"ARow",props:{rowIndex:{},store:{},tabIndex:{default:()=>-1},addNavigation:{type:[Boolean,Object],default:!1}},emits:["row:action"],setup(t,{emit:n}){const i=n,s=e.useTemplateRef("rowEl"),f=e.computed(()=>t.store.isRowVisible(t.rowIndex)),l=e.computed(()=>t.store.getRowExpandSymbol(t.rowIndex)),r=e.computed(()=>t.store.config.rowActions||{enabled:!1}),o=e.computed(()=>r.value.enabled),d=e.computed(()=>r.value.position||"before-index"),c=(m,w)=>{i("row:action",m,w)};if(t.addNavigation){let m=fe;typeof t.addNavigation=="object"&&(m={...m,...t.addNavigation}),Me([{selectors:s,handlers:m}])}return(m,w)=>e.withDirectives((e.openBlock(),e.createElementBlock("tr",{ref:"rowEl",tabindex:t.tabIndex,class:"atable-row"},[o.value&&d.value==="before-index"?(e.openBlock(),e.createBlock(re,{key:0,"row-index":t.rowIndex,store:t.store,config:r.value,position:d.value,onAction:c},null,8,["row-index","store","config","position"])):e.createCommentVNode("",!0),t.store.config.view!=="uncounted"?e.renderSlot(m.$slots,"index",{key:1},()=>[t.store.config.view==="list"?(e.openBlock(),e.createElementBlock("td",{key:0,tabIndex:-1,class:e.normalizeClass(["list-index",t.store.hasPinnedColumns?"sticky-index":""])},e.toDisplayString(t.rowIndex+1),3)):t.store.isTreeView?(e.openBlock(),e.createElementBlock("td",{key:1,tabIndex:-1,class:e.normalizeClass(["tree-index",t.store.hasPinnedColumns?"sticky-index":""]),onClick:w[0]||(w[0]=M=>t.store.toggleRowExpand(t.rowIndex))},e.toDisplayString(l.value),3)):e.createCommentVNode("",!0)],!0):e.createCommentVNode("",!0),o.value&&d.value==="after-index"?(e.openBlock(),e.createBlock(re,{key:2,"row-index":t.rowIndex,store:t.store,config:r.value,position:d.value,onAction:c},null,8,["row-index","store","config","position"])):e.createCommentVNode("",!0),e.renderSlot(m.$slots,"default",{},void 0,!0),o.value&&d.value==="end"?(e.openBlock(),e.createBlock(re,{key:3,"row-index":t.rowIndex,store:t.store,config:r.value,position:d.value,onAction:c},null,8,["row-index","store","config","position"])):e.createCommentVNode("",!0)],8,xn)),[[e.vShow,f.value]])}}),[["__scopeId","data-v-c35a3748"]]),De=new WeakMap,yn={mounted(t,n){const i=!n.modifiers.bubble;let s;if(typeof n.value=="function")s=Ve(t,n.value,{capture:i});else{const[f,l]=n.value;s=Ve(t,f,Object.assign({capture:i},l))}De.set(t,s)},unmounted(t){const n=De.get(t);n&&typeof n=="function"?n():n?.stop(),De.delete(t)}},kn={mounted(t,n){typeof n.value=="function"?me(t,n.value):me(t,...n.value)}};function Cn(){let t=!1;const n=e.shallowRef(!1);return(i,s)=>{if(n.value=s.value,t)return;t=!0;const f=Jt(i,s.value);e.watch(n,l=>f.value=l)}}Cn();const En={class:"gantt-connection-overlay"},Bn={class:"connection-svg",style:{position:"absolute",top:0,left:0,width:"100%",height:"100%",pointerEvents:"none",zIndex:1}},Mn=["d","stroke-width","onDblclick"],Rn=["id","d","stroke","stroke-width","onDblclick"],Vn=.25,ge=16,In=K(e.defineComponent({__name:"AGanttConnection",props:{store:{}},emits:["connection:delete"],setup(t,{emit:n}){const i=n,s=e.computed(()=>t.store.connectionPaths.filter(r=>{const o=t.store.ganttBars.find(c=>c.id===r.from.barId),d=t.store.ganttBars.find(c=>c.id===r.to.barId);return o&&d})),f=r=>{const o=t.store.connectionHandles.find(y=>y.barId===r.from.barId&&y.side===r.from.side),d=t.store.connectionHandles.find(y=>y.barId===r.to.barId&&y.side===r.to.side);if(!o||!d)return"";const c=o.position.x+ge/2,m=o.position.y+ge/2,w=d.position.x+ge/2,M=d.position.y+ge/2,V=Math.abs(w-c),x=Math.max(V*Vn,50),v=c+(r.from.side==="left"?-x:x),g=w+(r.to.side==="left"?-x:x),h={x:.5*c+.5*v,y:.5*m+.5*m},p={x:.5*v+.5*g,y:.5*m+.5*M},E={x:.5*g+.5*w,y:.5*M+.5*M},I={x:.5*h.x+.5*p.x,y:.5*h.y+.5*p.y},N={x:.5*p.x+.5*E.x,y:.5*p.y+.5*E.y},A={x:.5*I.x+.5*N.x,y:.5*I.y+.5*N.y};return`M ${c} ${m} Q ${v} ${m}, ${A.x} ${A.y} Q ${g} ${M}, ${w} ${M}`},l=r=>{t.store.deleteConnection(r.id)&&i("connection:delete",r)};return(r,o)=>(e.openBlock(),e.createElementBlock("div",En,[(e.openBlock(),e.createElementBlock("svg",Bn,[o[0]||(o[0]=e.createElementVNode("defs",null,[e.createElementVNode("path",{id:"arrowhead",d:"M 0 -7 L 20 0 L 0 7Z",stroke:"black","stroke-width":"1",fill:"currentColor"}),e.createElementVNode("marker",{id:"arrowhead-marker",markerWidth:"10",markerHeight:"7",refX:"5",refY:"3.5",orient:"auto",markerUnits:"strokeWidth"},[e.createElementVNode("polygon",{points:"0 0, 10 3.5, 0 7",fill:"currentColor"})])],-1)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,d=>(e.openBlock(),e.createElementBlock("path",{key:`${d.id}-hitbox`,d:f(d),stroke:"transparent","stroke-width":(d.style?.width||2)+10,fill:"none",class:"connection-hitbox",onDblclick:c=>l(d)},null,40,Mn))),128)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,d=>(e.openBlock(),e.createElementBlock("path",{id:d.id,key:d.id,d:f(d),stroke:d.style?.color||"#666","stroke-width":d.style?.width||2,fill:"none","marker-mid":"url(#arrowhead-marker)",class:"connection-path animated-path",onDblclick:c=>l(d)},null,40,Rn))),128))]))]))}}),[["__scopeId","data-v-71911260"]]),Sn={class:"column-filter"},$n={key:2,class:"checkbox-filter"},An=["value"],Dn={key:5,class:"date-range-filter"},Tn=K(e.defineComponent({__name:"ATableColumnFilter",props:{column:{},colIndex:{},store:{}},setup(t){const n=e.ref(""),i=e.reactive({startValue:"",endValue:""}),s=d=>{if(d.filterOptions)return d.filterOptions;const c=new Set;return t.store.rows.forEach(m=>{const w=m[d.name];w!=null&&w!==""&&c.add(w)}),Array.from(c).map(m=>({value:m,label:String(m)}))},f=e.computed(()=>!!(n.value||i.startValue||i.endValue)),l=d=>{!d&&t.column.filterType!=="checkbox"?(t.store.clearFilter(t.colIndex),n.value=""):(n.value=d,t.store.setFilter(t.colIndex,{value:d}))},r=(d,c)=>{d==="start"?i.startValue=c:i.endValue=c,!i.startValue&&!i.endValue?t.store.clearFilter(t.colIndex):t.store.setFilter(t.colIndex,{value:null,startValue:i.startValue,endValue:i.endValue})},o=()=>{n.value="",i.startValue="",i.endValue="",t.store.clearFilter(t.colIndex)};return(d,c)=>(e.openBlock(),e.createElementBlock("div",Sn,[(t.column.filterType||"text")==="text"?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:0,"onUpdate:modelValue":c[0]||(c[0]=m=>n.value=m),type:"text",class:"filter-input",onInput:c[1]||(c[1]=m=>l(n.value))},null,544)),[[e.vModelText,n.value]]):t.column.filterType==="number"?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:1,"onUpdate:modelValue":c[2]||(c[2]=m=>n.value=m),type:"number",class:"filter-input",onInput:c[3]||(c[3]=m=>l(n.value))},null,544)),[[e.vModelText,n.value]]):t.column.filterType==="checkbox"?(e.openBlock(),e.createElementBlock("label",$n,[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":c[4]||(c[4]=m=>n.value=m),type:"checkbox",class:"filter-checkbox",onChange:c[5]||(c[5]=m=>l(n.value))},null,544),[[e.vModelCheckbox,n.value]]),e.createElementVNode("span",null,e.toDisplayString(t.column.label),1)])):t.column.filterType==="select"?e.withDirectives((e.openBlock(),e.createElementBlock("select",{key:3,"onUpdate:modelValue":c[6]||(c[6]=m=>n.value=m),class:"filter-select",onChange:c[7]||(c[7]=m=>l(n.value))},[c[15]||(c[15]=e.createElementVNode("option",{value:""},"All",-1)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s(t.column),m=>(e.openBlock(),e.createElementBlock("option",{key:m.value||m,value:m.value||m},e.toDisplayString(m.label||m),9,An))),128))],544)),[[e.vModelSelect,n.value]]):t.column.filterType==="date"?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:4,"onUpdate:modelValue":c[8]||(c[8]=m=>n.value=m),type:"date",class:"filter-input",onChange:c[9]||(c[9]=m=>l(n.value))},null,544)),[[e.vModelText,n.value]]):t.column.filterType==="dateRange"?(e.openBlock(),e.createElementBlock("div",Dn,[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":c[10]||(c[10]=m=>i.startValue=m),type:"date",class:"filter-input",onChange:c[11]||(c[11]=m=>r("start",i.startValue))},null,544),[[e.vModelText,i.startValue]]),c[16]||(c[16]=e.createElementVNode("span",{class:"date-separator"},"-",-1)),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":c[12]||(c[12]=m=>i.endValue=m),type:"date",class:"filter-input",onChange:c[13]||(c[13]=m=>r("end",i.endValue))},null,544),[[e.vModelText,i.endValue]])])):t.column.filterType==="component"&&t.column.filterComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.column.filterComponent),{key:6,value:n.value,column:t.column,colIndex:t.colIndex,store:t.store,"onUpdate:value":c[14]||(c[14]=m=>l(m))},null,40,["value","column","colIndex","store"])):e.createCommentVNode("",!0),f.value?(e.openBlock(),e.createElementBlock("button",{key:7,onClick:o,class:"clear-btn",title:"Clear"},"×")):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-8487462d"]]),zn={key:0},Nn={class:"atable-header-row",tabindex:"-1"},Hn={key:2,class:"row-actions-header"},Ln=["data-colindex","onClick"],On={key:3,class:"row-actions-header"},Pn={key:0,class:"atable-filters-row"},Zn={key:2,class:"row-actions-header"},Fn={key:3,class:"row-actions-header"},Te=e.defineComponent({__name:"ATableHeader",props:{columns:{},store:{}},setup(t){const n=t,i=e.computed(()=>n.columns.filter(o=>o.filterable)),s=e.computed(()=>n.store.config.value?.rowActions?.enabled??!1),f=e.computed(()=>n.store.config.value?.rowActions?.position??"before-index"),l=o=>n.store.sortByColumn(o),r=o=>{for(const d of o){if(d.borderBoxSize.length===0)continue;const m=d.borderBoxSize[0].inlineSize,w=Number(d.target.dataset.colindex),M=n.store.columns[w]?.width;typeof M=="number"&&M!==m&&n.store.resizeColumn(w,m)}};return(o,d)=>n.columns.length?(e.openBlock(),e.createElementBlock("thead",zn,[e.createElementVNode("tr",Nn,[s.value&&f.value==="before-index"?(e.openBlock(),e.createElementBlock("th",{key:0,class:e.normalizeClass(["row-actions-header",{"sticky-column":f.value==="before-index"}])},null,2)):e.createCommentVNode("",!0),n.store.zeroColumn?(e.openBlock(),e.createElementBlock("th",{key:1,id:"header-index",class:e.normalizeClass([[n.store.hasPinnedColumns?"sticky-index":"",n.store.isTreeView?"tree-index":"",n.store.config.view==="list-expansion"?"list-expansion-index":""],"list-index"])},null,2)):e.createCommentVNode("",!0),s.value&&f.value==="after-index"?(e.openBlock(),e.createElementBlock("th",Hn)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.columns,(c,m)=>e.withDirectives((e.openBlock(),e.createElementBlock("th",{key:c.name,"data-colindex":m,tabindex:"-1",style:e.normalizeStyle(n.store.getHeaderCellStyle(c)),class:e.normalizeClass(`${c.pinned?"sticky-column":""} ${c.sortable===!1?"":"cursor-pointer"}`),onClick:w=>c.sortable!==!1?l(m):void 0},[e.renderSlot(o.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(c.label||String.fromCharCode(m+97).toUpperCase()),1)])],14,Ln)),[[e.unref(kn),r]])),128)),s.value&&f.value==="end"?(e.openBlock(),e.createElementBlock("th",On)):e.createCommentVNode("",!0)]),i.value.length>0?(e.openBlock(),e.createElementBlock("tr",Pn,[s.value&&f.value==="before-index"?(e.openBlock(),e.createElementBlock("th",{key:0,class:e.normalizeClass(["row-actions-header",{"sticky-column":f.value==="before-index"}])},null,2)):e.createCommentVNode("",!0),n.store.zeroColumn?(e.openBlock(),e.createElementBlock("th",{key:1,class:e.normalizeClass([[n.store.hasPinnedColumns?"sticky-index":"",n.store.isTreeView?"tree-index":"",n.store.config.view==="list-expansion"?"list-expansion-index":""],"list-index"])},null,2)):e.createCommentVNode("",!0),s.value&&f.value==="after-index"?(e.openBlock(),e.createElementBlock("th",Zn)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.columns,(c,m)=>(e.openBlock(),e.createElementBlock("th",{key:`filter-${c.name}`,class:e.normalizeClass(`${c.pinned?"sticky-column":""}`),style:e.normalizeStyle(n.store.getHeaderCellStyle(c))},[c.filterable?(e.openBlock(),e.createBlock(Tn,{key:0,column:c,"col-index":m,store:n.store},null,8,["column","col-index","store"])):e.createCommentVNode("",!0)],6))),128)),s.value&&f.value==="end"?(e.openBlock(),e.createElementBlock("th",Fn)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)}}),ze=e.defineComponent({__name:"ATableModal",props:{store:{}},setup(t){const n=e.useTemplateRef("amodal"),{width:i,height:s}=te(n),f=e.computed(()=>{if(!(t.store.modal.height&&t.store.modal.width&&t.store.modal.left&&t.store.modal.bottom))return;const l=t.store.modal.cell?.closest("table");if(!l)return{};const r=l.offsetHeight||0,o=l.offsetWidth||0;let d=t.store.modal.cell?.offsetTop||0;const c=l.querySelector("thead")?.offsetHeight||0;d+=c,d=d+s.value<r?d:d-(s.value+t.store.modal.height);let m=t.store.modal.cell?.offsetLeft||0;return m=m+i.value<=o?m:m-(i.value-t.store.modal.width),{left:`${m}px`,top:`${d}px`}});return(l,r)=>(e.openBlock(),e.createElementBlock("div",{ref:"amodal",class:"amodal",tabindex:"-1",style:e.normalizeStyle(f.value),onClick:r[0]||(r[0]=e.withModifiers(()=>{},["stop"])),onInput:r[1]||(r[1]=e.withModifiers(()=>{},["stop"]))},[e.renderSlot(l.$slots,"default")],36))}}),ft=t=>{const n=t.id||Kt();return bt.defineStore(`table-${n}`,()=>{const s=()=>{const a=[Object.assign({},{rowModified:!1})],u=new Set;for(let k=0;k<l.value.length;k++){const C=l.value[k];C.parent!==null&&C.parent!==void 0&&u.add(C.parent)}const b=k=>l.value[k]?.gantt!==void 0,B=k=>{for(let C=0;C<l.value.length;C++)if(l.value[C].parent===k&&(b(C)||B(C)))return!0;return!1},$=k=>{const C=r.value,T=C.view==="tree"||C.view==="tree-gantt"?C.defaultTreeExpansion:void 0;if(!T)return!0;switch(T){case"root":return!1;case"branch":return B(k);case"leaf":return!0;default:return!0}};for(let k=0;k<l.value.length;k++){const C=l.value[k],T=C.parent===null||C.parent===void 0,W=u.has(k);a[k]={childrenOpen:$(k),expanded:!1,indent:C.indent||0,isParent:W,isRoot:T,rowModified:!1,open:T,parent:C.parent}}return a},f=e.ref(t.columns),l=e.ref(t.rows),r=e.ref(t.config||{}),o=e.ref({}),d=e.ref({}),c=e.computed(()=>{const a={};for(const[u,b]of f.value.entries())for(const[B,$]of l.value.entries())a[`${u}:${B}`]=$[b.name];return a}),m=e.computed({get:()=>{const a=s();for(let u=0;u<a.length;u++)o.value[u]&&(a[u].rowModified=o.value[u]),d.value[u]&&(d.value[u].childrenOpen!==void 0&&(a[u].childrenOpen=d.value[u].childrenOpen),d.value[u].expanded!==void 0&&(a[u].expanded=d.value[u].expanded));if(I.value){const u=(b,B)=>{const $=B[b];if($.isRoot||$.parent===null||$.parent===void 0)return!0;const k=$.parent;return k<0||k>=B.length?!1:(B[k].childrenOpen||!1)&&u(k,B)};for(let b=0;b<a.length;b++)a[b].isRoot||(a[b].open=u(b,a))}return a},set:a=>{JSON.stringify(a)!==JSON.stringify(m.value)&&(m.value=a)}}),w=e.ref(t.modal||{visible:!1}),M=e.ref({}),V=e.ref([]),x=e.ref([]),v=e.ref([]),g=e.ref({column:null,direction:null}),h=e.ref({}),p=e.computed(()=>f.value.some(a=>a.pinned)),E=e.computed(()=>r.value.view==="gantt"||r.value.view==="tree-gantt"),I=e.computed(()=>r.value.view==="tree"||r.value.view==="tree-gantt"),N=e.computed(()=>{const a=r.value;return a.view==="gantt"||a.view==="tree-gantt"?a.dependencyGraph!==!1:!0}),A=e.computed(()=>`${Math.ceil(l.value.length/100+1)}ch`),y=e.computed(()=>r.value.view?["list","tree","tree-gantt","list-expansion"].includes(r.value.view):!1),S=e.computed(()=>{let a=l.value.map((u,b)=>({...u,originalIndex:b}));if(Object.entries(h.value).forEach(([u,b])=>{const B=parseInt(u),$=f.value[B];!$||!(b.value||b.startValue||b.endValue||$.filterType==="checkbox"&&b.value!==void 0)||(a=a.filter(C=>{const T=C[$.name];return X(T,b,$)}))}),g.value.column!==null&&g.value.direction){const u=f.value[g.value.column],b=g.value.direction;a.sort((B,$)=>{let k=B[u.name],C=$[u.name];k==null&&(k=""),C==null&&(C="");const T=Number(k),W=Number(C);if(!isNaN(T)&&!isNaN(W)&&k!==""&&C!=="")return b==="asc"?T-W:W-T;{const pt=String(k).toLowerCase(),wt=String(C).toLowerCase();return b==="asc"?pt.localeCompare(wt):wt.localeCompare(pt)}})}return a}),Z=(a,u)=>c.value[`${a}:${u}`],L=(a,u,b)=>{const B=`${a}:${u}`,$=f.value[a];c.value[B]!==b&&(o.value[u]=!0),c.value[B]=b,l.value[u]={...l.value[u],[$.name]:b}},z=a=>{l.value=a},U=(a,u,b)=>{const B=`${a}:${u}`;c.value[B]!==b&&(o.value[u]=!0,M.value[B]=b)},_=a=>{const u=f.value.indexOf(a)===f.value.length-1,b=r.value.fullWidth?a.resizable&&!u:a.resizable;return{width:a.width||"40ch",textAlign:a.align||"center",...b&&{resize:"horizontal",overflow:"hidden",whiteSpace:"nowrap"}}},he=(a,u)=>{if(a<0||a>=f.value.length)return;const B=Math.max(u,40);f.value[a]={...f.value[a],width:`${B}px`}},ie=a=>{const u=l.value[a];return E.value&&u.gantt!==void 0},Ne=a=>!I.value||m.value[a].isRoot||m.value[a].open,He=a=>!I.value&&r.value.view!=="list-expansion"?"":I.value&&(m.value[a].isRoot||m.value[a].isParent)?m.value[a].childrenOpen?"▼":"►":r.value.view==="list-expansion"?m.value[a].expanded?"▼":"►":"",Le=a=>{if(I.value){const u=d.value[a]||{},B=!(u.childrenOpen??m.value[a].childrenOpen);d.value[a]={...u,childrenOpen:B},B||pe(a)}else if(r.value.view==="list-expansion"){const u=d.value[a]||{},b=u.expanded??m.value[a].expanded;d.value[a]={...u,expanded:!b}}},pe=a=>{for(let u=0;u<l.value.length;u++)if(m.value[u].parent===a){const b=d.value[u]||{};d.value[u]={...b,childrenOpen:!1},pe(u)}},Oe=(a,u)=>{const b=Z(a,u);return we(a,u,b)},we=(a,u,b)=>{const B=f.value[a],$=l.value[u],k=B.format;return k?typeof k=="function"?k(b,{table:c.value,row:$,column:B}):typeof k=="string"?Function(`"use strict";return (${k})`)()(b,{table:c.value,row:$,column:B}):b:b},Pe=a=>{a.target instanceof Node&&w.value.parent?.contains(a.target)||w.value.visible&&(w.value.visible=!1)},Ze=(a,u)=>u&&a===0&&u>0?`${u}ch`:"inherit",Fe=a=>{const u=l.value[a.rowIndex]?.gantt;u&&(a.type==="resize"?a.edge==="start"?(u.startIndex=a.newStart,u.endIndex=a.end,u.colspan=u.endIndex-u.startIndex):a.edge==="end"&&(u.startIndex=a.start,u.endIndex=a.newEnd,u.colspan=u.endIndex-u.startIndex):a.type==="bar"&&(u.startIndex=a.newStart,u.endIndex=a.newEnd,u.colspan=u.endIndex-u.startIndex))},be=a=>{const u=V.value.findIndex(b=>b.id===a.id);u>=0?V.value[u]=a:V.value.push(a)},ve=a=>{const u=V.value.findIndex(b=>b.id===a);u>=0&&V.value.splice(u,1)},xe=a=>{const u=x.value.findIndex(b=>b.id===a.id);u>=0?x.value[u]=a:x.value.push(a)},ye=a=>{const u=x.value.findIndex(b=>b.id===a);u>=0&&x.value.splice(u,1)},R=(a,u,b)=>{const B=x.value.find(C=>C.id===a),$=x.value.find(C=>C.id===u);if(!B||!$)return console.warn("Cannot create connection: handle not found"),null;const k={id:`connection-${a}-${u}`,from:{barId:B.barId,side:B.side},to:{barId:$.barId,side:$.side},style:b?.style,label:b?.label};return v.value.push(k),k},D=a=>{const u=v.value.findIndex(b=>b.id===a);return u>=0?(v.value.splice(u,1),!0):!1},P=a=>v.value.filter(u=>u.from.barId===a||u.to.barId===a),H=a=>x.value.filter(u=>u.barId===a),F=a=>{if(f.value[a].sortable===!1)return;let b;g.value.column===a&&g.value.direction==="asc"?b="desc":b="asc",g.value.column=a,g.value.direction=b},X=(a,u,b)=>{const B=b.filterType||"text",$=u.value;if(!$&&B!=="dateRange"&&B!=="checkbox")return!0;switch(B){case"text":{let k="";return typeof a=="object"&&a!==null?k=Object.values(a).join(" "):k=String(a||""),k.toLowerCase().includes(String($).toLowerCase())}case"number":{const k=Number(a),C=Number($);return!isNaN(k)&&!isNaN(C)&&k===C}case"select":return a===$;case"checkbox":return $===!0?!!a:!0;case"date":{let k;if(typeof a=="number"){const T=new Date(a),W=new Date().getFullYear();k=new Date(W,T.getMonth(),T.getDate())}else k=new Date(String(a));const C=new Date(String($));return k.toDateString()===C.toDateString()}case"dateRange":{const k=u.startValue,C=u.endValue;if(!k&&!C)return!0;let T;if(typeof a=="number"){const W=new Date(a),ht=new Date().getFullYear();T=new Date(ht,W.getMonth(),W.getDate())}else T=new Date(String(a));return!(k&&T<new Date(String(k))||C&&T>new Date(String(C)))}default:return!0}},G=(a,u)=>{!u.value&&!u.startValue&&!u.endValue?delete h.value[a]:h.value[a]=u},j=a=>{delete h.value[a]},se=(a,u="end")=>{const b={};for(const $ of f.value)b[$.name]="";a&&Object.assign(b,a);let B;return u==="start"?(B=0,l.value.unshift(b)):u==="end"?(B=l.value.length,l.value.push(b)):(B=Math.max(0,Math.min(u,l.value.length)),l.value.splice(B,0,b)),B};return{columns:f,config:r,connectionHandles:x,connectionPaths:v,display:m,filterState:h,ganttBars:V,modal:w,rows:l,sortState:g,table:c,updates:M,filteredRows:S,hasPinnedColumns:p,isGanttView:E,isTreeView:I,isDependencyGraphEnabled:N,numberedRowWidth:A,zeroColumn:y,addRow:se,clearFilter:j,closeModal:Pe,createConnection:R,deleteConnection:D,deleteRow:a=>{if(a<0||a>=l.value.length)return null;const[u]=l.value.splice(a,1);delete o.value[a],delete d.value[a];const b={},B={};for(const[$,k]of Object.entries(o.value)){const C=parseInt($);C>a?b[C-1]=k:b[C]=k}for(const[$,k]of Object.entries(d.value)){const C=parseInt($);C>a?B[C-1]=k:B[C]=k}return o.value=b,d.value=B,u},duplicateRow:a=>{if(a<0||a>=l.value.length)return-1;const u=l.value[a],b=JSON.parse(JSON.stringify(u)),B=a+1;return l.value.splice(B,0,b),B},getCellData:Z,getCellDisplayValue:Oe,getConnectionsForBar:P,getFormattedValue:we,getHandlesForBar:H,getHeaderCellStyle:_,getIndent:Ze,getRowExpandSymbol:He,insertRowAbove:(a,u)=>{const b=Math.max(0,a);return se(u,b)},insertRowBelow:(a,u)=>{const b=Math.min(a+1,l.value.length);return se(u,b)},isRowGantt:ie,isRowVisible:Ne,moveRow:(a,u)=>{if(a<0||a>=l.value.length||u<0||u>=l.value.length||a===u)return!1;const[b]=l.value.splice(a,1);l.value.splice(u,0,b);const B={},$={};for(const[k,C]of Object.entries(o.value)){const T=parseInt(k);let W=T;T===a?W=u:a<u?T>a&&T<=u&&(W=T-1):T>=u&&T<a&&(W=T+1),B[W]=C}for(const[k,C]of Object.entries(d.value)){const T=parseInt(k);let W=T;T===a?W=u:a<u?T>a&&T<=u&&(W=T-1):T>=u&&T<a&&(W=T+1),$[W]=C}return o.value=B,d.value=$,!0},registerConnectionHandle:xe,registerGanttBar:be,resizeColumn:he,setCellData:L,setCellText:U,setFilter:G,sortByColumn:F,toggleRowExpand:Le,unregisterConnectionHandle:ye,unregisterGanttBar:ve,updateGanttBar:Fe,updateRows:z}})()},Wn={class:"atable-container",style:{position:"relative"}},ut=K(e.defineComponent({__name:"ATable",props:e.mergeModels({id:{default:""},config:{default:()=>new Object}},{rows:{required:!0},rowsModifiers:{},columns:{required:!0},columnsModifiers:{}}),emits:e.mergeModels(["cellUpdate","gantt:drag","connection:event","columns:update","row:add","row:delete","row:duplicate","row:insert-above","row:insert-below","row:move"],["update:rows","update:columns"]),setup(t,{expose:n,emit:i}){const s=e.useModel(t,"rows"),f=e.useModel(t,"columns"),l=i,r=e.useTemplateRef("table"),o=ft({columns:f.value,rows:s.value,id:t.id,config:t.config});o.$onAction(({name:x,store:v,args:g,after:h})=>{if(x==="setCellData"||x==="setCellText"){const[p,E,I]=g,N=v.getCellData(p,E);h(()=>{s.value=[...v.rows],l("cellUpdate",{colIndex:p,rowIndex:E,newValue:I,oldValue:N})})}else if(x==="updateGanttBar"){const[p]=g;let E=!1;p.type==="resize"?E=p.oldColspan!==p.newColspan:p.type==="bar"&&(E=p.oldStart!==p.newStart||p.oldEnd!==p.newEnd),E&&h(()=>{l("gantt:drag",p)})}else x==="resizeColumn"&&h(()=>{f.value=[...v.columns],l("columns:update",[...v.columns])})}),e.watch(()=>s.value,x=>{JSON.stringify(x)!==JSON.stringify(o.rows)&&(o.rows=[...x])},{deep:!0}),e.watch(f,x=>{JSON.stringify(x)!==JSON.stringify(o.columns)&&(o.columns=[...x],l("columns:update",[...x]))},{deep:!0}),e.onMounted(()=>{f.value.some(x=>x.pinned)&&(c(),o.isTreeView&&et(r,c,{childList:!0,subtree:!0}))});const d=e.computed(()=>o.columns.filter(x=>x.pinned).length),c=()=>{const x=r.value,v=x?.rows[0],g=x?.rows[1],h=v?Array.from(v.cells):[];for(const[p,E]of h.entries()){const I=g?.cells[p];I&&(E.style.width=`${I.offsetWidth}px`)}for(const p of x?.rows||[]){let E=0;const I=[];for(const N of p.cells)(N.classList.contains("sticky-column")||N.classList.contains("sticky-index"))&&(N.style.left=`${E}px`,E+=N.offsetWidth,I.push(N));I.length>0&&I[I.length-1].classList.add("sticky-column-edge")}};window.addEventListener("keydown",x=>{if(x.key==="Escape"&&o.modal.visible){o.modal.visible=!1;const v=o.modal.parent;v&&e.nextTick().then(()=>{v.focus()})}});const m=x=>{if(!x.gantt||d.value===0)return o.columns;const v=[];for(let g=0;g<d.value;g++){const h={...o.columns[g]};h.originalIndex=g,v.push(h)}return v.push({...o.columns[d.value],isGantt:!0,colspan:x.gantt?.colspan||o.columns.length-d.value,originalIndex:d.value,width:"auto"}),v},w=x=>{l("connection:event",{type:"create",connection:x})},M=x=>{l("connection:event",{type:"delete",connection:x})},V=(x,v)=>{switch(x){case"add":{const g=o.addRow({},v+1),h=o.rows[g];s.value=[...o.rows],l("row:add",{rowIndex:g,row:h});break}case"delete":{const g=o.deleteRow(v);g&&(s.value=[...o.rows],l("row:delete",{rowIndex:v,row:g}));break}case"duplicate":{const g=o.duplicateRow(v);if(g>=0){const h=o.rows[g];s.value=[...o.rows],l("row:duplicate",{sourceIndex:v,newIndex:g,row:h})}break}case"insertAbove":{const g=o.insertRowAbove(v),h=o.rows[g];s.value=[...o.rows],l("row:insert-above",{targetIndex:v,newIndex:g,row:h});break}case"insertBelow":{const g=o.insertRowBelow(v),h=o.rows[g];s.value=[...o.rows],l("row:insert-below",{targetIndex:v,newIndex:g,row:h});break}case"move":{l("row:move",{fromIndex:v,toIndex:-1});break}}};return n({store:o,createConnection:o.createConnection,deleteConnection:o.deleteConnection,getConnectionsForBar:o.getConnectionsForBar,getHandlesForBar:o.getHandlesForBar,addRow:o.addRow,deleteRow:o.deleteRow,duplicateRow:o.duplicateRow,insertRowAbove:o.insertRowAbove,insertRowBelow:o.insertRowBelow,moveRow:o.moveRow}),(x,v)=>(e.openBlock(),e.createElementBlock("div",Wn,[e.withDirectives((e.openBlock(),e.createElementBlock("table",{ref:"table",class:"atable",style:e.normalizeStyle({width:e.unref(o).config.fullWidth?"100%":"auto"})},[e.renderSlot(x.$slots,"header",{data:e.unref(o)},()=>[e.createVNode(Te,{columns:e.unref(o).columns,store:e.unref(o)},null,8,["columns","store"])],!0),e.createElementVNode("tbody",null,[e.renderSlot(x.$slots,"body",{data:e.unref(o)},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(o).filteredRows,(g,h)=>(e.openBlock(),e.createBlock(Ae,{key:`${g.originalIndex}-${h}`,row:g,rowIndex:g.originalIndex,store:e.unref(o),"onRow:action":V},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m(g),(p,E)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:p.name},[p.isGantt?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(p.ganttComponent||"AGanttCell"),{key:0,store:e.unref(o),"columns-count":e.unref(o).columns.length-d.value,color:g.gantt?.color,start:g.gantt?.startIndex,end:g.gantt?.endIndex,colspan:p.colspan,pinned:p.pinned,rowIndex:g.originalIndex,colIndex:p.originalIndex??E,style:e.normalizeStyle({textAlign:p?.align||"center",minWidth:p?.width||"40ch",width:e.unref(o).config.fullWidth?"auto":null}),"onConnection:create":w},null,40,["store","columns-count","color","start","end","colspan","pinned","rowIndex","colIndex","style"])):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(p.cellComponent||"ACell"),{key:1,store:e.unref(o),pinned:p.pinned,rowIndex:g.originalIndex,colIndex:E,style:e.normalizeStyle({textAlign:p?.align||"center",width:e.unref(o).config.fullWidth?"auto":null}),spellcheck:"false"},null,8,["store","pinned","rowIndex","colIndex","style"]))],64))),128))]),_:2},1032,["row","rowIndex","store"]))),128))],!0)]),e.renderSlot(x.$slots,"footer",{data:e.unref(o)},void 0,!0),e.renderSlot(x.$slots,"modal",{data:e.unref(o)},()=>[e.withDirectives(e.createVNode(ze,{store:e.unref(o)},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(o).modal.component),e.mergeProps({key:`${e.unref(o).modal.rowIndex}:${e.unref(o).modal.colIndex}`,"col-index":e.unref(o).modal.colIndex,"row-index":e.unref(o).modal.rowIndex,store:e.unref(o)},e.unref(o).modal.componentProps),null,16,["col-index","row-index","store"]))]),_:1},8,["store"]),[[e.vShow,e.unref(o).modal.visible]])],!0)],4)),[[e.unref(yn),e.unref(o).closeModal]]),e.unref(o).isGanttView&&e.unref(o).isDependencyGraphEnabled?(e.openBlock(),e.createBlock(In,{key:0,store:e.unref(o),"onConnection:delete":M},null,8,["store"])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-3d00d51b"]]),Xn={},Gn={class:"aloading"},jn={class:"aloading-header"};function Un(t,n){return e.openBlock(),e.createElementBlock("div",Gn,[e.createElementVNode("h2",jn,[e.renderSlot(t.$slots,"default",{},void 0,!0)]),n[0]||(n[0]=e.createElementVNode("div",{class:"aloading-bar"},null,-1))])}const mt=K(Xn,[["render",Un],["__scopeId","data-v-a930a25b"]]),Yn={},qn={class:"aloading"},Jn={class:"aloading-header"};function Qn(t,n){return e.openBlock(),e.createElementBlock("div",qn,[e.createElementVNode("h2",Jn,[e.renderSlot(t.$slots,"default",{},void 0,!0)]),n[0]||(n[0]=e.createElementVNode("div",{class:"aloading-bar"},null,-1))])}const gt=K(Yn,[["render",Qn],["__scopeId","data-v-e1165876"]]);function Kn(t){t.component("ACell",tt),t.component("AExpansionRow",nt),t.component("AGanttCell",ot),t.component("ARow",Ae),t.component("ARowActions",re),t.component("ATable",ut),t.component("ATableHeader",Te),t.component("ATableLoading",mt),t.component("ATableLoadingBar",gt),t.component("ATableModal",ze)}O.ACell=tt,O.AExpansionRow=nt,O.AGanttCell=ot,O.ARow=Ae,O.ARowActions=re,O.ATable=ut,O.ATableHeader=Te,O.ATableLoading=mt,O.ATableLoadingBar=gt,O.ATableModal=ze,O.AddIcon=at,O.DeleteIcon=lt,O.DuplicateIcon=rt,O.InsertAboveIcon=it,O.InsertBelowIcon=st,O.MoveIcon=ct,O.actionIcons=dt,O.createTableStore=ft,O.install=Kn,Object.defineProperty(O,Symbol.toStringTag,{value:"Module"})}));
3
47
  //# sourceMappingURL=atable.umd.cjs.map