1 |
- import{d as ie,aB as De,cw as go,o as _e,c as Le,g as j,a as l,aD as Qt,az as Me,aW as yo,J as E,c0 as Ue,aC as Rt,f as S,Y as tt,at as xo,t as Ro,O as vo,aE as vt,b3 as So,b4 as bo,al as Zt,r as B,bp as ne,k as lt,bq as To,am as Ye,e8 as Co,L as el,aP as ze,bs as tl,bt as Ho,bE as Io,aN as St,K as ot,aM as Oe,av as Eo,c4 as Xe,aL as bt,c5 as Ke,cY as Mo,aw as Oo,aG as ll,aA as V,aJ as Ko,cB as Wo,ai as te,aO as ol,e9 as ko,ea as Ao,aS as al,bS as Do,cQ as _o,aU as Lo,w as at,m as zo,F as $o,_ as Vo,B as No,__tla as Go}from"./index-2eab2d23.js";import{j as We,I as rl,S as nl,F as rt,u as Fo,B as sl,d as nt,A as st,R as jo,g as il,a as Bo,b as cl,k as dl,c as ul,e as Po,C as $e,E as Tt,f as Ct,h as hl,D as ml,v as qo,l as Uo,__tla as Yo}from"./el-virtual-list-197311ca.js";import{_ as Xo,__tla as Jo}from"./ContentWrap.vue_vue_type_script_setup_true_lang-5a63038a.js";import{_ as Qo,__tla as Zo}from"./AreaForm.vue_vue_type_script_setup_true_lang-4eb6b57a.js";import{g as ea,__tla as ta}from"./index-44a34f60.js";import{__tla as la}from"./el-card-c558f0ec.js";import{__tla as oa}from"./Dialog-c2716df6.js";import"./_plugin-vue_export-helper-1b428a4d.js";import{__tla as aa}from"./useMessage-171aa63e.js";let fl,ra=Promise.all([(()=>{try{return Go}catch{}})(),(()=>{try{return Yo}catch{}})(),(()=>{try{return Jo}catch{}})(),(()=>{try{return Zo}catch{}})(),(()=>{try{return ta}catch{}})(),(()=>{try{return la}catch{}})(),(()=>{try{return oa}catch{}})(),(()=>{try{return aa}catch{}})()]).then(async()=>{const pl={viewBox:"0 0 79 86",version:"1.1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink"},wl=["id"],gl=["stop-color"],yl=["stop-color"],xl=["id"],Rl=["stop-color"],vl=["stop-color"],Sl=["id"],bl={id:"Illustrations",stroke:"none","stroke-width":"1",fill:"none","fill-rule":"evenodd"},Tl={id:"B-type",transform:"translate(-1268.000000, -535.000000)"},Cl={id:"Group-2",transform:"translate(1268.000000, 535.000000)"},Hl=["fill"],Il=["fill"],El={id:"Group-Copy",transform:"translate(34.500000, 31.500000) scale(-1, 1) rotate(-25.000000) translate(-34.500000, -31.500000) translate(7.000000, 10.000000)"},Ml=["fill"],Ol=["fill"],Kl=["fill"],Wl=["fill"],kl=["fill"],Al={id:"Rectangle-Copy-17",transform:"translate(53.000000, 45.000000)"},Dl=["fill","xlink:href"],_l=["fill","mask"],Ll=["fill"],zl=ie({name:"ImgEmpty"});var $l=Qt(ie({...zl,setup(e){const t=De("empty"),o=go();return(a,r)=>(_e(),Le("svg",pl,[j("defs",null,[j("linearGradient",{id:`linearGradient-1-${l(o)}`,x1:"38.8503086%",y1:"0%",x2:"61.1496914%",y2:"100%"},[j("stop",{"stop-color":`var(${l(t).cssVarBlockName("fill-color-1")})`,offset:"0%"},null,8,gl),j("stop",{"stop-color":`var(${l(t).cssVarBlockName("fill-color-4")})`,offset:"100%"},null,8,yl)],8,wl),j("linearGradient",{id:`linearGradient-2-${l(o)}`,x1:"0%",y1:"9.5%",x2:"100%",y2:"90.5%"},[j("stop",{"stop-color":`var(${l(t).cssVarBlockName("fill-color-1")})`,offset:"0%"},null,8,Rl),j("stop",{"stop-color":`var(${l(t).cssVarBlockName("fill-color-6")})`,offset:"100%"},null,8,vl)],8,xl),j("rect",{id:`path-3-${l(o)}`,x:"0",y:"0",width:"17",height:"36"},null,8,Sl)]),j("g",bl,[j("g",Tl,[j("g",Cl,[j("path",{id:"Oval-Copy-2",d:"M39.5,86 C61.3152476,86 79,83.9106622 79,81.3333333 C79,78.7560045 57.3152476,78 35.5,78 C13.6847524,78 0,78.7560045 0,81.3333333 C0,83.9106622 17.6847524,86 39.5,86 Z",fill:`var(${l(t).cssVarBlockName("fill-color-3")})`},null,8,Hl),j("polygon",{id:"Rectangle-Copy-14",fill:`var(${l(t).cssVarBlockName("fill-color-7")})`,transform:"translate(27.500000, 51.500000) scale(1, -1) translate(-27.500000, -51.500000) ",points:"13 58 53 58 42 45 2 45"},null,8,Il),j("g",El,[j("polygon",{id:"Rectangle-Copy-10",fill:`var(${l(t).cssVarBlockName("fill-color-7")})`,transform:"translate(11.500000, 5.000000) scale(1, -1) translate(-11.500000, -5.000000) ",points:"2.84078316e-14 3 18 3 23 7 5 7"},null,8,Ml),j("polygon",{id:"Rectangle-Copy-11",fill:`var(${l(t).cssVarBlockName("fill-color-5")})`,points:"-3.69149156e-15 7 38 7 38 43 -3.69149156e-15 43"},null,8,Ol),j("rect",{id:"Rectangle-Copy-12",fill:`url(#linearGradient-1-${l(o)})`,transform:"translate(46.500000, 25.000000) scale(-1, 1) translate(-46.500000, -25.000000) ",x:"38",y:"7",width:"17",height:"36"},null,8,Kl),j("polygon",{id:"Rectangle-Copy-13",fill:`var(${l(t).cssVarBlockName("fill-color-2")})`,transform:"translate(39.500000, 3.500000) scale(-1, 1) translate(-39.500000, -3.500000) ",points:"24 7 41 7 55 -3.63806207e-12 38 -3.63806207e-12"},null,8,Wl)]),j("rect",{id:"Rectangle-Copy-15",fill:`url(#linearGradient-2-${l(o)})`,x:"13",y:"45",width:"40",height:"36"},null,8,kl),j("g",Al,[j("use",{id:"Mask",fill:`var(${l(t).cssVarBlockName("fill-color-8")})`,transform:"translate(8.500000, 18.000000) scale(-1, 1) translate(-8.500000, -18.000000) ","xlink:href":`#path-3-${l(o)}`},null,8,Dl),j("polygon",{id:"Rectangle-Copy",fill:`var(${l(t).cssVarBlockName("fill-color-9")})`,mask:`url(#mask-4-${l(o)})`,transform:"translate(12.000000, 9.000000) scale(-1, 1) translate(-12.000000, -9.000000) ",points:"7 0 24 0 20 18 7 16.5"},null,8,_l)]),j("polygon",{id:"Rectangle-Copy-18",fill:`var(${l(t).cssVarBlockName("fill-color-2")})`,transform:"translate(66.000000, 51.500000) scale(-1, 1) translate(-66.000000, -51.500000) ",points:"62 45 79 45 70 58 53 58"},null,8,Ll)])])])]))}}),[["__file","/home/runner/work/element-plus/element-plus/packages/components/empty/src/img-empty.vue"]]);const Vl=Me({image:{type:String,default:""},imageSize:Number,description:{type:String,default:""}}),Nl=["src"],Gl={key:1},Fl=ie({name:"ElEmpty"}),jl=vt(Qt(ie({...Fl,props:Vl,setup(e){const t=e,{t:o}=yo(),a=De("empty"),r=E(()=>t.description||o("el.table.emptyText")),n=E(()=>({width:Ue(t.imageSize)}));return(s,i)=>(_e(),Le("div",{class:tt(l(a).b())},[j("div",{class:tt(l(a).e("image")),style:xo(l(n))},[s.image?(_e(),Le("img",{key:0,src:s.image,ondragstart:"return false"},null,8,Nl)):Rt(s.$slots,"image",{key:1},()=>[S($l)])],6),j("div",{class:tt(l(a).e("description"))},[s.$slots.description?Rt(s.$slots,"description",{key:0}):(_e(),Le("p",Gl,Ro(l(r)),1))],2),s.$slots.default?(_e(),Le("div",{key:0,class:tt(l(a).e("bottom"))},[Rt(s.$slots,"default")],2)):vo("v-if",!0)],2))}}),[["__file","/home/runner/work/element-plus/element-plus/packages/components/empty/src/empty.vue"]])),Ht=({name:e,clearCache:t,getColumnPosition:o,getColumnStartIndexForOffset:a,getColumnStopIndexForStartIndex:r,getEstimatedTotalHeight:n,getEstimatedTotalWidth:s,getColumnOffset:i,getRowOffset:u,getRowPosition:h,getRowStartIndexForOffset:d,getRowStopIndexForStartIndex:m,initCache:C,injectToInstance:_,validateProps:M})=>ie({name:e??"ElVirtualList",props:We,emits:[rl,nl],setup(c,{emit:G,expose:P,slots:$}){const y=De("vl");M(c);const k=Zt(),K=B(C(c,k));_==null||_(k,K);const N=B(),q=B(),U=B(),Y=B(null),W=B({isScrolling:!1,scrollLeft:ne(c.initScrollLeft)?c.initScrollLeft:0,scrollTop:ne(c.initScrollTop)?c.initScrollTop:0,updateRequested:!1,xAxisScrollDir:rt,yAxisScrollDir:rt}),O=Fo(),L=E(()=>Number.parseInt(`${c.height}`,10)),F=E(()=>Number.parseInt(`${c.width}`,10)),J=E(()=>{const{totalColumn:w,totalRow:p,columnCache:g}=c,{isScrolling:T,xAxisScrollDir:I,scrollLeft:b}=l(W);if(w===0||p===0)return[0,0,0,0];const x=a(c,b,l(K)),f=r(c,x,b,l(K)),H=T&&I!==sl?1:Math.max(1,g),A=T&&I!==rt?1:Math.max(1,g);return[Math.max(0,x-H),Math.max(0,Math.min(w-1,f+A)),x,f]}),ce=E(()=>{const{totalColumn:w,totalRow:p,rowCache:g}=c,{isScrolling:T,yAxisScrollDir:I,scrollTop:b}=l(W);if(w===0||p===0)return[0,0,0,0];const x=d(c,b,l(K)),f=m(c,x,b,l(K)),H=T&&I!==sl?1:Math.max(1,g),A=T&&I!==rt?1:Math.max(1,g);return[Math.max(0,x-H),Math.max(0,Math.min(p-1,f+A)),x,f]}),se=E(()=>n(c,l(K))),le=E(()=>s(c,l(K))),ge=E(()=>{var w;return[{position:"relative",overflow:"hidden",WebkitOverflowScrolling:"touch",willChange:"transform"},{direction:c.direction,height:ne(c.height)?`${c.height}px`:c.height,width:ne(c.width)?`${c.width}px`:c.width},(w=c.style)!=null?w:{}]}),be=E(()=>{const w=`${l(le)}px`;return{height:`${l(se)}px`,pointerEvents:l(W).isScrolling?"none":void 0,width:w}}),de=()=>{const{totalColumn:w,totalRow:p}=c;if(w>0&&p>0){const[f,H,A,R]=l(J),[v,D,Q,ee]=l(ce);G(rl,{columnCacheStart:f,columnCacheEnd:H,rowCacheStart:v,rowCacheEnd:D,columnVisibleStart:A,columnVisibleEnd:R,rowVisibleStart:Q,rowVisibleEnd:ee})}const{scrollLeft:g,scrollTop:T,updateRequested:I,xAxisScrollDir:b,yAxisScrollDir:x}=l(W);G(nl,{xAxisScrollDir:b,scrollLeft:g,yAxisScrollDir:x,scrollTop:T,updateRequested:I})},Te=w=>{const{clientHeight:p,clientWidth:g,scrollHeight:T,scrollLeft:I,scrollTop:b,scrollWidth:x}=w.currentTarget,f=l(W);if(f.scrollTop===b&&f.scrollLeft===I)return;let H=I;if(dl(c.direction))switch(il()){case cl:H=-I;break;case Po:H=x-g-I}W.value={...f,isScrolling:!0,scrollLeft:H,scrollTop:Math.max(0,Math.min(b,T-p)),updateRequested:!0,xAxisScrollDir:nt(f.scrollLeft,H),yAxisScrollDir:nt(f.scrollTop,b)},Ye(()=>fe()),He(),de()},Ce=(w,p)=>{const g=l(L),T=(se.value-g)/p*w;re({scrollTop:Math.min(se.value-g,T)})},ye=(w,p)=>{const g=l(F),T=(le.value-g)/p*w;re({scrollLeft:Math.min(le.value-g,T)})},{onWheel:me}=(({atXEndEdge:w,atXStartEdge:p,atYEndEdge:g,atYStartEdge:T},I)=>{let b=null,x=0,f=0;const H=(A,R)=>{const v=A<=0&&p.value||A>=0&&w.value,D=R<=0&&T.value||R>=0&&g.value;return v&&D};return{hasReachedEdge:H,onWheel:A=>{So(b);let R=A.deltaX,v=A.deltaY;Math.abs(R)>Math.abs(v)?v=0:R=0,A.shiftKey&&v!==0&&(R=v,v=0),H(x,f)&&H(x+R,f+v)||(x+=R,f+=v,A.preventDefault(),b=bo(()=>{I(x,f),x=0,f=0}))}}})({atXStartEdge:E(()=>W.value.scrollLeft<=0),atXEndEdge:E(()=>W.value.scrollLeft>=le.value-l(F)),atYStartEdge:E(()=>W.value.scrollTop<=0),atYEndEdge:E(()=>W.value.scrollTop>=se.value-l(L))},(w,p)=>{var g,T,I,b;(T=(g=q.value)==null?void 0:g.onMouseUp)==null||T.call(g),(b=(I=U.value)==null?void 0:I.onMouseUp)==null||b.call(I);const x=l(F),f=l(L);re({scrollLeft:Math.min(W.value.scrollLeft+w,le.value-x),scrollTop:Math.min(W.value.scrollTop+p,se.value-f)})}),re=({scrollLeft:w=W.value.scrollLeft,scrollTop:p=W.value.scrollTop})=>{w=Math.max(w,0),p=Math.max(p,0);const g=l(W);p===g.scrollTop&&w===g.scrollLeft||(W.value={...g,xAxisScrollDir:nt(g.scrollLeft,w),yAxisScrollDir:nt(g.scrollTop,p),scrollLeft:w,scrollTop:p,updateRequested:!0},Ye(()=>fe()),He(),de())},Be=(w,p)=>{const{columnWidth:g,direction:T,rowHeight:I}=c,b=O.value(t&&g,t&&I,t&&T),x=`${w},${p}`;if(Ho(b,x))return b[x];{const[,f]=o(c,p,l(K)),H=l(K),A=dl(T),[R,v]=h(c,w,H),[D]=o(c,p,H);return b[x]={position:"absolute",left:A?void 0:`${f}px`,right:A?`${f}px`:void 0,top:`${v}px`,height:`${R}px`,width:`${D}px`},b[x]}},fe=()=>{W.value.isScrolling=!1,Ye(()=>{O.value(-1,null,null)})};lt(()=>{if(!To)return;const{initScrollLeft:w,initScrollTop:p}=c,g=l(N);g&&(ne(w)&&(g.scrollLeft=w),ne(p)&&(g.scrollTop=p)),de()});const He=()=>{const{direction:w}=c,{scrollLeft:p,scrollTop:g,updateRequested:T}=l(W),I=l(N);if(T&&I){if(w===jo)switch(il()){case cl:I.scrollLeft=-p;break;case Bo:I.scrollLeft=p;break;default:{const{clientWidth:b,scrollWidth:x}=I;I.scrollLeft=x-b-p;break}}else I.scrollLeft=Math.max(0,p);I.scrollTop=Math.max(0,g)}},{resetAfterColumnIndex:Pe,resetAfterRowIndex:Ie,resetAfter:z}=k.proxy;P({windowRef:N,innerRef:Y,getItemStyleCache:O,scrollTo:re,scrollToItem:(w=0,p=0,g=st)=>{const T=l(W);p=Math.max(0,Math.min(p,c.totalColumn-1)),w=Math.max(0,Math.min(w,c.totalRow-1));const I=Co(y.namespace.value),b=l(K),x=n(c,b),f=s(c,b);re({scrollLeft:i(c,p,g,T.scrollLeft,b,f>c.width?I:0),scrollTop:u(c,w,g,T.scrollTop,b,x>c.height?I:0)})},states:W,resetAfterColumnIndex:Pe,resetAfterRowIndex:Ie,resetAfter:z});const X=()=>{const w=el(c.innerElement),p=(()=>{var g;const[T,I]=l(J),[b,x]=l(ce),{data:f,totalColumn:H,totalRow:A,useIsScrolling:R,itemKey:v}=c,D=[];if(A>0&&H>0)for(let Q=b;Q<=x;Q++)for(let ee=T;ee<=I;ee++)D.push((g=$.default)==null?void 0:g.call($,{columnIndex:ee,data:f,key:v({columnIndex:ee,data:f,rowIndex:Q}),isScrolling:R?l(W).isScrolling:void 0,style:Be(Q,ee),rowIndex:Q}));return D})();return[ze(w,{style:l(be),ref:Y},tl(w)?p:{default:()=>p})]};return()=>{const w=el(c.containerElement),{horizontalScrollbar:p,verticalScrollbar:g}=(()=>{const{scrollbarAlwaysOn:I,scrollbarStartGap:b,scrollbarEndGap:x,totalColumn:f,totalRow:H}=c,A=l(F),R=l(L),v=l(le),D=l(se),{scrollLeft:Q,scrollTop:ee}=l(W);return{horizontalScrollbar:ze(ul,{ref:q,alwaysOn:I,startGap:b,endGap:x,class:y.e("horizontal"),clientSize:A,layout:"horizontal",onScroll:ye,ratio:100*A/v,scrollFrom:Q/(v-A),total:H,visible:!0}),verticalScrollbar:ze(ul,{ref:U,alwaysOn:I,startGap:b,endGap:x,class:y.e("vertical"),clientSize:R,layout:"vertical",onScroll:Ce,ratio:100*R/D,scrollFrom:ee/(D-R),total:f,visible:!0})}})(),T=X();return ze("div",{key:0,class:y.e("wrapper"),role:c.role},[ze(w,{class:c.className,style:l(ge),onScroll:Te,onWheel:me,ref:N},tl(w)?T:{default:()=>T}),p,g])}}}),Bl=Ht({name:"ElFixedSizeGrid",getColumnPosition:({columnWidth:e},t)=>[e,t*e],getRowPosition:({rowHeight:e},t)=>[e,t*e],getEstimatedTotalHeight:({totalRow:e,rowHeight:t})=>t*e,getEstimatedTotalWidth:({totalColumn:e,columnWidth:t})=>t*e,getColumnOffset:({totalColumn:e,columnWidth:t,width:o},a,r,n,s,i)=>{o=Number(o);const u=Math.max(0,e*t-o),h=Math.min(u,a*t),d=Math.max(0,a*t-o+i+t);switch(r==="smart"&&(r=n>=d-o&&n<=h+o?st:$e),r){case Ct:return h;case Tt:return d;case $e:{const m=Math.round(d+(h-d)/2);return m<Math.ceil(o/2)?0:m>u+Math.floor(o/2)?u:m}default:return n>=d&&n<=h?n:d>h||n<d?d:h}},getRowOffset:({rowHeight:e,height:t,totalRow:o},a,r,n,s,i)=>{t=Number(t);const u=Math.max(0,o*e-t),h=Math.min(u,a*e),d=Math.max(0,a*e-t+i+e);switch(r===hl&&(r=n>=d-t&&n<=h+t?st:$e),r){case Ct:return h;case Tt:return d;case $e:{const m=Math.round(d+(h-d)/2);return m<Math.ceil(t/2)?0:m>u+Math.floor(t/2)?u:m}default:return n>=d&&n<=h?n:d>h||n<d?d:h}},getColumnStartIndexForOffset:({columnWidth:e,totalColumn:t},o)=>Math.max(0,Math.min(t-1,Math.floor(o/e))),getColumnStopIndexForStartIndex:({columnWidth:e,totalColumn:t,width:o},a,r)=>{const n=a*e,s=Math.ceil((o+r-n)/e);return Math.max(0,Math.min(t-1,a+s-1))},getRowStartIndexForOffset:({rowHeight:e,totalRow:t},o)=>Math.max(0,Math.min(t-1,Math.floor(o/e))),getRowStopIndexForStartIndex:({rowHeight:e,totalRow:t,height:o},a,r)=>{const n=a*e,s=Math.ceil((o+r-n)/e);return Math.max(0,Math.min(t-1,a+s-1))},initCache:()=>{},clearCache:!0,validateProps:({columnWidth:e,rowHeight:t})=>{}}),{max:Je,min:It,floor:Et}=Math,Pl={column:"columnWidth",row:"rowHeight"},it={column:"lastVisitedColumnIndex",row:"lastVisitedRowIndex"},he=(e,t,o,a)=>{const[r,n,s]=[o[a],e[Pl[a]],o[it[a]]];if(t>s){let i=0;if(s>=0){const u=r[s];i=u.offset+u.size}for(let u=s+1;u<=t;u++){const h=n(u);r[u]={offset:i,size:h},i+=h}o[it[a]]=t}return r[t]},Mt=(e,t,o,a,r,n)=>{for(;o<=a;){const s=o+Et((a-o)/2),i=he(e,s,t,n).offset;if(i===r)return s;i<r?o=s+1:a=s-1}return Je(0,o-1)},Ot=(e,t,o,a)=>{const[r,n]=[t[a],t[it[a]]];return(n>0?r[n].offset:0)>=o?Mt(e,t,0,n,o,a):((s,i,u,h,d)=>{const m=d==="column"?s.totalColumn:s.totalRow;let C=1;for(;u<m&&he(s,u,i,d).offset<h;)u+=C,C*=2;return Mt(s,i,Et(u/2),It(u,m-1),h,d)})(e,t,Je(0,n),o,a)},Kt=({totalRow:e},{estimatedRowHeight:t,lastVisitedRowIndex:o,row:a})=>{let r=0;if(o>=e&&(o=e-1),o>=0){const n=a[o];r=n.offset+n.size}return r+(e-o-1)*t},Wt=({totalColumn:e},{column:t,estimatedColumnWidth:o,lastVisitedColumnIndex:a})=>{let r=0;if(a>e&&(a=e-1),a>=0){const n=t[a];r=n.offset+n.size}return r+(e-a-1)*o},ql={column:Wt,row:Kt},kt=(e,t,o,a,r,n,s)=>{const[i,u]=[n==="row"?e.height:e.width,ql[n]],h=he(e,t,r,n),d=u(e,r),m=Je(0,It(d-i,h.offset)),C=Je(0,h.offset-i+s+h.size);switch(o===hl&&(o=a>=C-i&&a<=m+i?st:$e),o){case Ct:return m;case Tt:return C;case $e:return Math.round(C+(m-C)/2);default:return a>=C&&a<=m?a:C>m||a<C?C:m}},Ul=Ht({name:"ElDynamicSizeGrid",getColumnPosition:(e,t,o)=>{const a=he(e,t,o,"column");return[a.size,a.offset]},getRowPosition:(e,t,o)=>{const a=he(e,t,o,"row");return[a.size,a.offset]},getColumnOffset:(e,t,o,a,r,n)=>kt(e,t,o,a,r,"column",n),getRowOffset:(e,t,o,a,r,n)=>kt(e,t,o,a,r,"row",n),getColumnStartIndexForOffset:(e,t,o)=>Ot(e,o,t,"column"),getColumnStopIndexForStartIndex:(e,t,o,a)=>{const r=he(e,t,a,"column"),n=o+e.width;let s=r.offset+r.size,i=t;for(;i<e.totalColumn-1&&s<n;)i++,s+=he(e,t,a,"column").size;return i},getEstimatedTotalHeight:Kt,getEstimatedTotalWidth:Wt,getRowStartIndexForOffset:(e,t,o)=>Ot(e,o,t,"row"),getRowStopIndexForStartIndex:(e,t,o,a)=>{const{totalRow:r,height:n}=e,s=he(e,t,a,"row"),i=o+n;let u=s.size+s.offset,h=t;for(;h<r-1&&u<i;)h++,u+=he(e,h,a,"row").size;return h},injectToInstance:(e,t)=>{const o=({columnIndex:a,rowIndex:r},n)=>{var s,i;n=!!Io(n)||n,ne(a)&&(t.value.lastVisitedColumnIndex=Math.min(t.value.lastVisitedColumnIndex,a-1)),ne(r)&&(t.value.lastVisitedRowIndex=Math.min(t.value.lastVisitedRowIndex,r-1)),(s=e.exposed)==null||s.getItemStyleCache.value(-1,null,null),n&&((i=e.proxy)==null||i.$forceUpdate())};Object.assign(e.proxy,{resetAfterColumnIndex:(a,r)=>{o({columnIndex:a},r)},resetAfterRowIndex:(a,r)=>{o({rowIndex:a},r)},resetAfter:o})},initCache:({estimatedColumnWidth:e=ml,estimatedRowHeight:t=ml})=>({column:{},estimatedColumnWidth:e,estimatedRowHeight:t,lastVisitedColumnIndex:-1,lastVisitedRowIndex:-1,row:{}}),clearCache:!1,validateProps:({columnWidth:e,rowHeight:t})=>{}});var Ve=(e=>(e.ASC="asc",e.DESC="desc",e))(Ve||{}),Ne=(e=>(e.CENTER="center",e.RIGHT="right",e))(Ne||{}),At=(e=>(e.LEFT="left",e.RIGHT="right",e))(At||{});const ct={asc:"desc",desc:"asc"},Ge=Symbol("placeholder"),Yl=(e,t,o)=>{var a;const r={flexGrow:0,flexShrink:0,...o?{}:{flexGrow:e.flexGrow||0,flexShrink:e.flexShrink||1}};o||(r.flexShrink=1);const n={...(a=e.style)!=null?a:{},...r,flexBasis:"auto",width:e.width};return t||(e.maxWidth&&(n.maxWidth=e.maxWidth),e.minWidth&&(n.minWidth=e.minWidth)),n},Xl=(e,{mainTableRef:t,leftTableRef:o,rightTableRef:a})=>{const r=Zt(),{emit:n}=r,s=Oe(!1),i=Oe(null),u=B(e.defaultExpandedRowKeys||[]),h=B(-1),d=Oe(null),m=B({}),C=B({}),_=Oe({}),M=Oe({}),c=Oe({}),G=E(()=>ne(e.estimatedRowHeight)),P=Eo(()=>{var y,k,K,N;s.value=!0,m.value={...l(m),...l(C)},$(l(d),!1),C.value={},d.value=null,(y=t.value)==null||y.forceUpdate(),(k=o.value)==null||k.forceUpdate(),(K=a.value)==null||K.forceUpdate(),(N=r.proxy)==null||N.$forceUpdate(),s.value=!1},0);function $(y,k=!1){l(G)&&[t,o,a].forEach(K=>{const N=l(K);N&&N.resetAfterRowIndex(y,k)})}return{hoveringRowKey:i,expandedRowKeys:u,lastRenderedRowIndex:h,isDynamic:G,isResetting:s,rowHeights:m,resetAfterIndex:$,onRowExpanded:function({expanded:y,rowData:k,rowIndex:K,rowKey:N}){var q,U;const Y=[...l(u)],W=Y.indexOf(N);y?W===-1&&Y.push(N):W>-1&&Y.splice(W,1),u.value=Y,n("update:expandedRowKeys",Y),(q=e.onRowExpand)==null||q.call(e,{expanded:y,rowData:k,rowIndex:K,rowKey:N}),(U=e.onExpandedRowsChange)==null||U.call(e,Y)},onRowHovered:function({hovered:y,rowKey:k}){i.value=y?k:null},onRowsRendered:function(y){var k;(k=e.onRowsRendered)==null||k.call(e,y),y.rowCacheEnd>l(h)&&(h.value=y.rowCacheEnd)},onRowHeightChange:function({rowKey:y,height:k,rowIndex:K},N){N?N===At.RIGHT?c.value[y]=k:_.value[y]=k:M.value[y]=k;const q=Math.max(...[_,c,M].map(U=>U.value[y]||0));l(m)[y]!==q&&(function(U,Y,W){const O=l(d);(O===null||O>W)&&(d.value=W),C.value[U]=Y}(y,q,K),P())}}},Jl=(e,t)=>e+t,Qe=e=>Xe(e)?e.reduce(Jl,0):e,Re=(e,t,o={})=>bt(e)?e(t):e??o,we=e=>(["width","maxWidth","minWidth","height"].forEach(t=>{e[t]=Ue(e[t])}),e),Dt=e=>Ke(e)?t=>ze(e,t):e;function Ql(e){const t=B(),o=B(),a=B(),{columns:r,columnsStyles:n,columnsTotalWidth:s,fixedColumnsOnLeft:i,fixedColumnsOnRight:u,hasFixedColumns:h,mainColumns:d,onColumnSorted:m}=function(z,X,w){const p=E(()=>l(X).filter(R=>!R.hidden)),g=E(()=>l(p).filter(R=>R.fixed==="left"||R.fixed===!0)),T=E(()=>l(p).filter(R=>R.fixed==="right")),I=E(()=>l(p).filter(R=>!R.fixed)),b=E(()=>{const R=[];return l(g).forEach(v=>{R.push({...v,placeholderSign:Ge})}),l(I).forEach(v=>{R.push(v)}),l(T).forEach(v=>{R.push({...v,placeholderSign:Ge})}),R}),x=E(()=>l(g).length||l(T).length),f=E(()=>l(X).reduce((R,v)=>(R[v.key]=Yl(v,l(w),z.fixed),R),{})),H=E(()=>l(p).reduce((R,v)=>R+v.width,0)),A=R=>l(X).find(v=>v.key===R);return{columns:X,columnsStyles:f,columnsTotalWidth:H,fixedColumnsOnLeft:g,fixedColumnsOnRight:T,hasFixedColumns:x,mainColumns:b,normalColumns:I,visibleColumns:p,getColumn:A,getColumnStyle:R=>l(f)[R],updateColumnWidth:(R,v)=>{R.width=v},onColumnSorted:function(R){var v;const{key:D}=R.currentTarget.dataset;if(!D)return;const{sortState:Q,sortBy:ee}=z;let ke=Ve.ASC;ke=St(Q)?ct[Q[D]]:ct[ee.order],(v=z.onColumnSort)==null||v.call(z,{column:A(D),key:D,order:ke})}}}(e,ll(e,"columns"),ll(e,"fixed")),{scrollTo:C,scrollToLeft:_,scrollToTop:M,scrollToRow:c,onScroll:G,onVerticalScroll:P,scrollPos:$}=((z,{mainTableRef:X,leftTableRef:w,rightTableRef:p,onMaybeEndReached:g})=>{const T=B({scrollLeft:0,scrollTop:0});function I(f){var H,A,R;const{scrollTop:v}=f;(H=X.value)==null||H.scrollTo(f),(A=w.value)==null||A.scrollToTop(v),(R=p.value)==null||R.scrollToTop(v)}function b(f){T.value=f,I(f)}function x(f){T.value.scrollTop=f,I(l(T))}return ot(()=>l(T).scrollTop,(f,H)=>{f>H&&g()}),{scrollPos:T,scrollTo:b,scrollToLeft:function(f){var H,A;T.value.scrollLeft=f,(A=(H=X.value)==null?void 0:H.scrollTo)==null||A.call(H,l(T))},scrollToTop:x,scrollToRow:function(f,H="auto"){var A;(A=X.value)==null||A.scrollToRow(f,H)},onScroll:function(f){var H;b(f),(H=z.onScroll)==null||H.call(z,f)},onVerticalScroll:function({scrollTop:f}){const{scrollTop:H}=l(T);f!==H&&x(f)}}})(e,{mainTableRef:t,leftTableRef:o,rightTableRef:a,onMaybeEndReached:function(){const{onEndReached:z}=e;if(!z)return;const{scrollTop:X}=l($),w=l(Ce),p=l(ye),g=w-(X+p)+e.hScrollbarSize;l(K)>=0&&w===X+l(ge)-l(fe)&&z(g)}}),{expandedRowKeys:y,hoveringRowKey:k,lastRenderedRowIndex:K,isDynamic:N,isResetting:q,rowHeights:U,resetAfterIndex:Y,onRowExpanded:W,onRowHeightChange:O,onRowHovered:L,onRowsRendered:F}=Xl(e,{mainTableRef:t,leftTableRef:o,rightTableRef:a}),{data:J,depthMap:ce}=((z,{expandedRowKeys:X,lastRenderedRowIndex:w,resetAfterIndex:p})=>{const g=B({}),T=E(()=>{const b={},{data:x,rowKey:f}=z,H=l(X);if(!H||!H.length)return x;const A=[],R=new Set;H.forEach(D=>R.add(D));let v=x.slice();for(v.forEach(D=>b[D[f]]=0);v.length>0;){const D=v.shift();A.push(D),R.has(D[f])&&Array.isArray(D.children)&&D.children.length>0&&(v=[...D.children,...v],D.children.forEach(Q=>b[Q[f]]=b[D[f]]+1))}return g.value=b,A}),I=E(()=>{const{data:b,expandColumnKey:x}=z;return x?l(T):b});return ot(I,(b,x)=>{b!==x&&(w.value=-1,p(0,!0))}),{data:I,depthMap:g}})(e,{expandedRowKeys:y,lastRenderedRowIndex:K,resetAfterIndex:Y}),{bodyWidth:se,fixedTableHeight:le,mainTableHeight:ge,leftTableWidth:be,rightTableWidth:de,headerWidth:Te,rowsHeight:Ce,windowHeight:ye,footerHeight:me,emptyStyle:re,rootStyle:Be,headerHeight:fe}=((z,{columnsTotalWidth:X,data:w,fixedColumnsOnLeft:p,fixedColumnsOnRight:g})=>{const T=E(()=>{const{fixed:Z,width:ae,vScrollbarSize:oe}=z,Ae=ae-oe;return Z?Math.max(Math.round(l(X)),Ae):Ae}),I=E(()=>l(T)+(z.fixed?z.vScrollbarSize:0)),b=E(()=>{const{height:Z=0,maxHeight:ae=0,footerHeight:oe,hScrollbarSize:Ae}=z;if(ae>0){const xe=l(D),yt=l(x),et=l(v)+xe+yt+Ae;return Math.min(et,ae-oe)}return Z-oe}),x=E(()=>{const{rowHeight:Z,estimatedRowHeight:ae}=z,oe=l(w);return ne(ae)?oe.length*ae:oe.length*Z}),f=E(()=>{const{maxHeight:Z}=z,ae=l(b);if(ne(Z)&&Z>0)return ae;const oe=l(x)+l(v)+l(D);return Math.min(ae,oe)}),H=Z=>Z.width,A=E(()=>Qe(l(p).map(H))),R=E(()=>Qe(l(g).map(H))),v=E(()=>Qe(z.headerHeight)),D=E(()=>{var Z;return(((Z=z.fixedData)==null?void 0:Z.length)||0)*z.rowHeight}),Q=E(()=>l(b)-l(v)-l(D)),ee=E(()=>{const{style:Z={},height:ae,width:oe}=z;return we({...Z,height:ae,width:oe})}),ke=E(()=>we({height:z.footerHeight})),qe=E(()=>({top:Ue(l(v)),bottom:Ue(z.footerHeight),width:Ue(z.width)}));return{bodyWidth:T,fixedTableHeight:f,mainTableHeight:b,leftTableWidth:A,rightTableWidth:R,headerWidth:I,rowsHeight:x,windowHeight:Q,footerHeight:ke,emptyStyle:qe,rootStyle:ee,headerHeight:v}})(e,{columnsTotalWidth:s,data:J,fixedColumnsOnLeft:i,fixedColumnsOnRight:u}),He=Oe(!1),Pe=B(),Ie=E(()=>{const z=l(J).length===0;return Xe(e.fixedData)?e.fixedData.length===0&&z:z});return ot(()=>e.expandedRowKeys,z=>y.value=z,{deep:!0}),{columns:r,containerRef:Pe,mainTableRef:t,leftTableRef:o,rightTableRef:a,isDynamic:N,isResetting:q,isScrolling:He,hoveringRowKey:k,hasFixedColumns:h,columnsStyles:n,columnsTotalWidth:s,data:J,expandedRowKeys:y,depthMap:ce,fixedColumnsOnLeft:i,fixedColumnsOnRight:u,mainColumns:d,bodyWidth:se,emptyStyle:re,rootStyle:Be,headerWidth:Te,footerHeight:me,mainTableHeight:ge,fixedTableHeight:le,leftTableWidth:be,rightTableWidth:de,showEmpty:Ie,getRowHeight:function(z){const{estimatedRowHeight:X,rowHeight:w,rowKey:p}=e;return X?l(U)[l(J)[z][p]]||X:w},onColumnSorted:m,onRowHovered:L,onRowExpanded:W,onRowsRendered:F,onRowHeightChange:O,scrollTo:C,scrollToLeft:_,scrollToTop:M,scrollToRow:c,onScroll:G,onVerticalScroll:P}}const dt=Symbol("tableV2"),_t=String,Fe={type:V(Array),required:!0},ut={type:V(Array)},Lt={...ut,required:!0},Zl=String,zt={type:V(Array),default:()=>Ko([])},ve={type:Number,required:!0},$t={type:V([String,Number,Symbol]),default:"id"},Vt={type:V(Object)},Se=Me({class:String,columns:Fe,columnsStyles:{type:V(Object),required:!0},depth:Number,expandColumnKey:Zl,estimatedRowHeight:{...We.estimatedRowHeight,default:void 0},isScrolling:Boolean,onRowExpand:{type:V(Function)},onRowHover:{type:V(Function)},onRowHeightChange:{type:V(Function)},rowData:{type:V(Object),required:!0},rowEventHandlers:{type:V(Object)},rowIndex:{type:Number,required:!0},rowKey:$t,style:{type:V(Object)}}),ht={type:Number,required:!0},mt=Me({class:String,columns:Fe,fixedHeaderData:{type:V(Array)},headerData:{type:V(Array),required:!0},headerHeight:{type:V([Number,Array]),default:50},rowWidth:ht,rowHeight:{type:Number,default:50},height:ht,width:ht}),Ze=Me({columns:Fe,data:Lt,fixedData:ut,estimatedRowHeight:Se.estimatedRowHeight,width:ve,height:ve,headerWidth:ve,headerHeight:mt.headerHeight,bodyWidth:ve,rowHeight:ve,cache:qo.cache,useIsScrolling:Boolean,scrollbarAlwaysOn:We.scrollbarAlwaysOn,scrollbarStartGap:We.scrollbarStartGap,scrollbarEndGap:We.scrollbarEndGap,class:_t,style:Vt,containerStyle:Vt,getRowHeight:{type:V(Function),required:!0},rowKey:Se.rowKey,onRowsRendered:{type:V(Function)},onScroll:{type:V(Function)}}),eo=Me({cache:Ze.cache,estimatedRowHeight:Se.estimatedRowHeight,rowKey:$t,headerClass:{type:V([String,Function])},headerProps:{type:V([Object,Function])},headerCellProps:{type:V([Object,Function])},headerHeight:mt.headerHeight,footerHeight:{type:Number,default:0},rowClass:{type:V([String,Function])},rowProps:{type:V([Object,Function])},rowHeight:{type:Number,default:50},cellProps:{type:V([Object,Function])},columns:Fe,data:Lt,dataGetter:{type:V(Function)},fixedData:ut,expandColumnKey:Se.expandColumnKey,expandedRowKeys:zt,defaultExpandedRowKeys:zt,class:_t,fixed:Boolean,style:{type:V(Object)},width:ve,height:ve,maxHeight:Number,useIsScrolling:Boolean,indentSize:{type:Number,default:12},iconSize:{type:Number,default:12},hScrollbarSize:We.hScrollbarSize,vScrollbarSize:We.vScrollbarSize,scrollbarAlwaysOn:Uo.alwaysOn,sortBy:{type:V(Object),default:()=>({})},sortState:{type:V(Object),default:void 0},onColumnSort:{type:V(Function)},onExpandedRowsChange:{type:V(Function)},onEndReached:{type:V(Function)},onRowExpand:Se.onRowExpand,onScroll:Ze.onScroll,onRowsRendered:Ze.onRowsRendered,rowEventHandlers:Se.rowEventHandlers}),ft=(e,{slots:t})=>{var o;const{cellData:a,style:r}=e,n=((o=a==null?void 0:a.toString)==null?void 0:o.call(a))||"";return S("div",{class:e.class,title:n,style:r},[t.default?t.default(e):n])};ft.displayName="ElTableV2Cell",ft.inheritAttrs=!1;const pt=(e,{slots:t})=>{var o,a;return t.default?t.default(e):S("div",{class:e.class,title:(o=e.column)==null?void 0:o.title},[(a=e.column)==null?void 0:a.title])};pt.displayName="ElTableV2HeaderCell",pt.inheritAttrs=!1;const to=Me({class:String,columns:Fe,columnsStyles:{type:V(Object),required:!0},headerIndex:Number,style:{type:V(Object)}}),lo=ie({name:"ElTableV2HeaderRow",props:to,setup:(e,{slots:t})=>()=>{const{columns:o,columnsStyles:a,headerIndex:r,style:n}=e;let s=o.map((i,u)=>t.cell({columns:o,column:i,columnIndex:u,headerIndex:r,style:a[i.key]}));return t.header&&(s=t.header({cells:s.map(i=>Xe(i)&&i.length===1?i[0]:i),columns:o,headerIndex:r})),S("div",{class:e.class,style:n,role:"row"},[s])}}),oo=ie({name:"ElTableV2Header",props:mt,setup(e,{slots:t,expose:o}){const a=De("table-v2"),r=B(),n=E(()=>we({width:e.width,height:e.height})),s=E(()=>we({width:e.rowWidth,height:e.height})),i=E(()=>Wo(l(e.headerHeight))),u=()=>{const d=a.e("fixed-header-row"),{columns:m,fixedHeaderData:C,rowHeight:_}=e;return C==null?void 0:C.map((M,c)=>{var G;const P=we({height:_,width:"100%"});return(G=t.fixed)==null?void 0:G.call(t,{class:d,columns:m,rowData:M,rowIndex:-(c+1),style:P})})},h=()=>{const d=a.e("dynamic-header-row"),{columns:m}=e;return l(i).map((C,_)=>{var M;const c=we({width:"100%",height:C});return(M=t.dynamic)==null?void 0:M.call(t,{class:d,columns:m,headerIndex:_,style:c})})};return o({scrollToLeft:d=>{const m=l(r);Ye(()=>{m!=null&&m.scroll&&m.scroll({left:d})})}}),()=>{if(!(e.height<=0))return S("div",{ref:r,class:e.class,style:l(n),role:"rowgroup"},[S("div",{style:l(s),class:a.e("header")},[h(),u()])])}}}),ao=e=>{const{isScrolling:t}=ol(dt),o=B(!1),a=B(),r=E(()=>ne(e.estimatedRowHeight)&&e.rowIndex>=0),n=E(()=>{const{rowData:s,rowIndex:i,rowKey:u,onRowHover:h}=e,d=e.rowEventHandlers||{},m={};return Object.entries(d).forEach(([C,_])=>{bt(_)&&(m[C]=M=>{_({event:M,rowData:s,rowIndex:i,rowKey:u})})}),h&&[{name:"onMouseleave",hovered:!1},{name:"onMouseenter",hovered:!0}].forEach(({name:C,hovered:_})=>{const M=m[C];m[C]=c=>{h({event:c,hovered:_,rowData:s,rowIndex:i,rowKey:u}),M==null||M(c)}}),m});return lt(()=>{l(r)&&((s=!1)=>{const i=l(a);if(!i)return;const{columns:u,onRowHeightChange:h,rowKey:d,rowIndex:m,style:C}=e,{height:_}=i.getBoundingClientRect();o.value=!0,Ye(()=>{if(s||_!==Number.parseInt(C.height)){const M=u[0],c=(M==null?void 0:M.placeholderSign)===Ge;h==null||h({rowKey:d,height:_,rowIndex:m},M&&!c&&M.fixed)}})})(!0)}),{isScrolling:t,measurable:r,measured:o,rowRef:a,eventHandlers:n,onExpand:s=>{const{onRowExpand:i,rowData:u,rowIndex:h,rowKey:d}=e;i==null||i({expanded:s,rowData:u,rowIndex:h,rowKey:d})}}},ro=ie({name:"ElTableV2TableRow",props:Se,setup(e,{expose:t,slots:o,attrs:a}){const{eventHandlers:r,isScrolling:n,measurable:s,measured:i,rowRef:u,onExpand:h}=ao(e);return t({onExpand:h}),()=>{const{columns:d,columnsStyles:m,expandColumnKey:C,depth:_,rowData:M,rowIndex:c,style:G}=e;let P=d.map(($,y)=>{const k=Xe(M.children)&&M.children.length>0&&$.key===C;return o.cell({column:$,columns:d,columnIndex:y,depth:_,style:m[$.key],rowData:M,rowIndex:c,isScrolling:l(n),expandIconProps:k?{rowData:M,rowIndex:c,onExpand:h}:void 0})});if(o.row&&(P=o.row({cells:P.map($=>Xe($)&&$.length===1?$[0]:$),style:G,columns:d,depth:_,rowData:M,rowIndex:c,isScrolling:l(n)})),l(s)){const{height:$,...y}=G||{},k=l(i);return S("div",te({ref:u,class:e.class,style:k?G:y,role:"row"},a,l(r)),[P])}return S("div",te(a,{ref:u,class:e.class,style:G,role:"row"},l(r)),[P])}}}),no=e=>{const{sortOrder:t}=e;return S(al,{size:14,class:e.class},{default:()=>[t===Ve.ASC?S(ko,null,null):S(Ao,null,null)]})},so=e=>{const{expanded:t,expandable:o,onExpand:a,style:r,size:n}=e,s={onClick:o?()=>a(!t):void 0,class:e.class};return S(al,te(s,{size:n,style:r}),{default:()=>[S(Do,null,null)]})},wt=ie({name:"ElTableV2Grid",props:Ze,setup(e,{slots:t,expose:o}){const{ns:a}=ol(dt),{bodyRef:r,fixedRowHeight:n,gridHeight:s,hasHeader:i,headerRef:u,headerHeight:h,totalHeight:d,forceUpdate:m,itemKey:C,onItemRendered:_,resetAfterRowIndex:M,scrollTo:c,scrollToTop:G,scrollToRow:P}=(y=>{const k=B(),K=B(),N=E(()=>{const{data:O,rowHeight:L,estimatedRowHeight:F}=y;if(!F)return O.length*L}),q=E(()=>{const{fixedData:O,rowHeight:L}=y;return((O==null?void 0:O.length)||0)*L}),U=E(()=>Qe(y.headerHeight)),Y=E(()=>{const{height:O}=y;return Math.max(0,O-l(U)-l(q))}),W=E(()=>l(U)+l(q)>0);return{bodyRef:K,forceUpdate:function(){var O,L;(O=l(K))==null||O.$forceUpdate(),(L=l(k))==null||L.$forceUpdate()},fixedRowHeight:q,gridHeight:Y,hasHeader:W,headerHeight:U,headerRef:k,totalHeight:N,itemKey:({data:O,rowIndex:L})=>O[L][y.rowKey],onItemRendered:function({rowCacheStart:O,rowCacheEnd:L,rowVisibleStart:F,rowVisibleEnd:J}){var ce;(ce=y.onRowsRendered)==null||ce.call(y,{rowCacheStart:O,rowCacheEnd:L,rowVisibleStart:F,rowVisibleEnd:J})},resetAfterRowIndex:function(O,L){var F;(F=K.value)==null||F.resetAfterRowIndex(O,L)},scrollTo:function(O,L){const F=l(k),J=l(K);F&&J&&(St(O)?(F.scrollToLeft(O.scrollLeft),J.scrollTo(O)):(F.scrollToLeft(O),J.scrollTo({scrollLeft:O,scrollTop:L})))},scrollToTop:function(O){var L;(L=l(K))==null||L.scrollTo({scrollTop:O})},scrollToRow:function(O,L){var F;(F=l(K))==null||F.scrollToItem(O,1,L)}}})(e);o({forceUpdate:m,totalHeight:d,scrollTo:c,scrollToTop:G,scrollToRow:P,resetAfterRowIndex:M});const $=()=>e.bodyWidth;return()=>{const{cache:y,columns:k,data:K,fixedData:N,useIsScrolling:q,scrollbarAlwaysOn:U,scrollbarEndGap:Y,scrollbarStartGap:W,style:O,rowHeight:L,bodyWidth:F,estimatedRowHeight:J,headerWidth:ce,height:se,width:le,getRowHeight:ge,onScroll:be}=e,de=ne(J),Te=de?Ul:Bl,Ce=l(h);return S("div",{role:"table",class:[a.e("table"),e.class],style:O},[S(Te,{ref:r,data:K,useIsScrolling:q,itemKey:C,columnCache:0,columnWidth:de?$:F,totalColumn:1,totalRow:K.length,rowCache:y,rowHeight:de?ge:L,width:le,height:l(s),class:a.e("body"),role:"rowgroup",scrollbarStartGap:W,scrollbarEndGap:Y,scrollbarAlwaysOn:U,onScroll:be,onItemRendered:_,perfMode:!1},{default:ye=>{var me;const re=K[ye.rowIndex];return(me=t.row)==null?void 0:me.call(t,{...ye,columns:k,rowData:re})}}),l(i)&&S(oo,{ref:u,class:a.e("header-wrapper"),columns:k,headerData:K,headerHeight:e.headerHeight,fixedHeaderData:N,rowWidth:ce,rowHeight:L,width:le,height:Math.min(Ce+l(n),se)},{dynamic:t.header,fixed:t.row})])}}}),io=(e,{slots:t})=>{const{mainTableRef:o,...a}=e;return S(wt,te({ref:o},a),typeof(r=t)=="function"||Object.prototype.toString.call(r)==="[object Object]"&&!Ke(r)?t:{default:()=>[t]});var r},co=(e,{slots:t})=>{if(!e.columns.length)return;const{leftTableRef:o,...a}=e;return S(wt,te({ref:o},a),typeof(r=t)=="function"||Object.prototype.toString.call(r)==="[object Object]"&&!Ke(r)?t:{default:()=>[t]});var r},uo=(e,{slots:t})=>{if(!e.columns.length)return;const{rightTableRef:o,...a}=e;return S(wt,te({ref:o},a),typeof(r=t)=="function"||Object.prototype.toString.call(r)==="[object Object]"&&!Ke(r)?t:{default:()=>[t]});var r},ho=(e,{slots:t})=>{const{columns:o,columnsStyles:a,depthMap:r,expandColumnKey:n,expandedRowKeys:s,estimatedRowHeight:i,hasFixedColumns:u,hoveringRowKey:h,rowData:d,rowIndex:m,style:C,isScrolling:_,rowProps:M,rowClass:c,rowKey:G,rowEventHandlers:P,ns:$,onRowHovered:y,onRowExpanded:k}=e,K=Re(c,{columns:o,rowData:d,rowIndex:m},""),N=Re(M,{columns:o,rowData:d,rowIndex:m}),q=d[G],U=r[q]||0,Y=!!n,W=m<0,O={...N,columns:o,columnsStyles:a,class:[$.e("row"),K,{[$.e(`row-depth-${U}`)]:Y&&m>=0,[$.is("expanded")]:Y&&s.includes(q),[$.is("hovered")]:!_&&q===h,[$.is("fixed")]:!U&&W,[$.is("customized")]:!!t.row}],depth:U,expandColumnKey:n,estimatedRowHeight:W?void 0:i,isScrolling:_,rowIndex:m,rowData:d,rowKey:q,rowEventHandlers:P,style:C};return S(ro,te(O,{onRowHover:u?y:void 0,onRowExpand:k}),typeof(L=t)=="function"||Object.prototype.toString.call(L)==="[object Object]"&&!Ke(L)?t:{default:()=>[t]});var L},gt=({columns:e,column:t,columnIndex:o,depth:a,expandIconProps:r,isScrolling:n,rowData:s,rowIndex:i,style:u,expandedRowKeys:h,ns:d,cellProps:m,expandColumnKey:C,indentSize:_,iconSize:M,rowKey:c},{slots:G})=>{const P=we(u);if(t.placeholderSign===Ge)return S("div",{class:d.em("row-cell","placeholder"),style:P},null);const{cellRenderer:$,dataKey:y,dataGetter:k}=t,K=Dt($)||G.default||(J=>S(ft,J,null)),N=bt(k)?k({columns:e,column:t,columnIndex:o,rowData:s,rowIndex:i}):_o(s,y??""),q=Re(m,{cellData:N,columns:e,column:t,columnIndex:o,rowIndex:i,rowData:s}),U=K({class:d.e("cell-text"),columns:e,column:t,columnIndex:o,cellData:N,isScrolling:n,rowData:s,rowIndex:i}),Y=[d.e("row-cell"),t.class,t.align===Ne.CENTER&&d.is("align-center"),t.align===Ne.RIGHT&&d.is("align-right")],W=i>=0&&C&&t.key===C,O=i>=0&&h.includes(s[c]);let L;const F=`margin-inline-start: ${a*_}px;`;return W&&(L=St(r)?S(so,te(r,{class:[d.e("expand-icon"),d.is("expanded",O)],size:M,expanded:O,style:F,expandable:!0}),null):S("div",{style:[F,`width: ${M}px; height: ${M}px;`].join(" ")},null)),S("div",te({class:Y,style:P},q,{role:"cell"}),[L,U])};gt.inheritAttrs=!1;const mo=({columns:e,columnsStyles:t,headerIndex:o,style:a,headerClass:r,headerProps:n,ns:s},{slots:i})=>{const u={columns:e,headerIndex:o},h=[s.e("header-row"),Re(r,u,""),{[s.is("customized")]:!!i.header}],d={...Re(n,u),columnsStyles:t,class:h,columns:e,headerIndex:o,style:a};return S(lo,d,typeof(m=i)=="function"||Object.prototype.toString.call(m)==="[object Object]"&&!Ke(m)?i:{default:()=>[i]});var m},Nt=(e,{slots:t})=>{const{column:o,ns:a,style:r,onColumnSorted:n}=e,s=we(r);if(o.placeholderSign===Ge)return S("div",{class:a.em("header-row-cell","placeholder"),style:s},null);const{headerCellRenderer:i,headerClass:u,sortable:h}=o,d={...e,class:a.e("header-cell-text")},m=(Dt(i)||t.default||(y=>S(pt,y,null)))(d),{sortBy:C,sortState:_,headerCellProps:M}=e;let c,G;if(_){const y=_[o.key];c=!!ct[y],G=c?y:Ve.ASC}else c=o.key===C.key,G=c?C.order:Ve.ASC;const P=[a.e("header-cell"),Re(u,e,""),o.align===Ne.CENTER&&a.is("align-center"),o.align===Ne.RIGHT&&a.is("align-right"),h&&a.is("sortable")],$={...Re(M,e),onClick:o.sortable?n:void 0,class:P,style:s,"data-key":o.key};return S("div",te($,{role:"columnheader"}),[m,h&&S(no,{class:[a.e("sort-icon"),c&&a.is("sorting")],sortOrder:G},null)])},Gt=(e,{slots:t})=>{var o;return S("div",{class:e.class,style:e.style},[(o=t.default)==null?void 0:o.call(t)])};Gt.displayName="ElTableV2Footer";const Ft=(e,{slots:t})=>S("div",{class:e.class,style:e.style},[t.default?t.default():S(jl,null,null)]);Ft.displayName="ElTableV2Empty";const jt=(e,{slots:t})=>{var o;return S("div",{class:e.class,style:e.style},[(o=t.default)==null?void 0:o.call(t)])};function je(e){return typeof e=="function"||Object.prototype.toString.call(e)==="[object Object]"&&!Ke(e)}jt.displayName="ElTableV2Overlay";let Bt,Pt,qt,Ut,Yt,Xt;Bt=ie({name:"ElTableV2",props:eo,setup(e,{slots:t,expose:o}){const a=De("table-v2"),{columnsStyles:r,fixedColumnsOnLeft:n,fixedColumnsOnRight:s,mainColumns:i,mainTableHeight:u,fixedTableHeight:h,leftTableWidth:d,rightTableWidth:m,data:C,depthMap:_,expandedRowKeys:M,hasFixedColumns:c,hoveringRowKey:G,mainTableRef:P,leftTableRef:$,rightTableRef:y,isDynamic:k,isResetting:K,isScrolling:N,bodyWidth:q,emptyStyle:U,rootStyle:Y,headerWidth:W,footerHeight:O,showEmpty:L,scrollTo:F,scrollToLeft:J,scrollToTop:ce,scrollToRow:se,getRowHeight:le,onColumnSorted:ge,onRowHeightChange:be,onRowHovered:de,onRowExpanded:Te,onRowsRendered:Ce,onScroll:ye,onVerticalScroll:me}=Ql(e);return o({scrollTo:F,scrollToLeft:J,scrollToTop:ce,scrollToRow:se}),Lo(dt,{ns:a,isResetting:K,hoveringRowKey:G,isScrolling:N}),()=>{const{cache:re,cellProps:Be,estimatedRowHeight:fe,expandColumnKey:He,fixedData:Pe,headerHeight:Ie,headerClass:z,headerProps:X,headerCellProps:w,sortBy:p,sortState:g,rowHeight:T,rowClass:I,rowEventHandlers:b,rowKey:x,rowProps:f,scrollbarAlwaysOn:H,indentSize:A,iconSize:R,useIsScrolling:v,vScrollbarSize:D,width:Q}=e,ee=l(C),ke={cache:re,class:a.e("main"),columns:l(i),data:ee,fixedData:Pe,estimatedRowHeight:fe,bodyWidth:l(q)+D,headerHeight:Ie,headerWidth:l(W),height:l(u),mainTableRef:P,rowKey:x,rowHeight:T,scrollbarAlwaysOn:H,scrollbarStartGap:2,scrollbarEndGap:D,useIsScrolling:v,width:Q,getRowHeight:le,onRowsRendered:Ce,onScroll:ye},qe=l(d),Z=l(h),ae={cache:re,class:a.e("left"),columns:l(n),data:ee,estimatedRowHeight:fe,leftTableRef:$,rowHeight:T,bodyWidth:qe,headerWidth:qe,headerHeight:Ie,height:Z,rowKey:x,scrollbarAlwaysOn:H,scrollbarStartGap:2,scrollbarEndGap:D,useIsScrolling:v,width:qe,getRowHeight:le,onScroll:me},oe=l(m)+D,Ae={cache:re,class:a.e("right"),columns:l(s),data:ee,estimatedRowHeight:fe,rightTableRef:y,rowHeight:T,bodyWidth:oe,headerWidth:oe,headerHeight:Ie,height:Z,rowKey:x,scrollbarAlwaysOn:H,scrollbarStartGap:2,scrollbarEndGap:D,width:oe,style:`--${l(a.namespace)}-table-scrollbar-size: ${D}px`,useIsScrolling:v,getRowHeight:le,onScroll:me},xe=l(r),yt={ns:a,depthMap:l(_),columnsStyles:xe,expandColumnKey:He,expandedRowKeys:l(M),estimatedRowHeight:fe,hasFixedColumns:l(c),hoveringRowKey:l(G),rowProps:f,rowClass:I,rowKey:x,rowEventHandlers:b,onRowHovered:de,onRowExpanded:Te,onRowHeightChange:be},et={cellProps:Be,expandColumnKey:He,indentSize:A,iconSize:R,rowKey:x,expandedRowKeys:l(M),ns:a},fo={ns:a,headerClass:z,headerProps:X,columnsStyles:xe},Jt={ns:a,sortBy:p,sortState:g,headerCellProps:w,onColumnSorted:ge},pe={row:xt=>S(ho,te(xt,yt),{row:t.row,cell:ue=>{let Ee;return t.cell?S(gt,te(ue,et,{style:xe[ue.column.key]}),je(Ee=t.cell(ue))?Ee:{default:()=>[Ee]}):S(gt,te(ue,et,{style:xe[ue.column.key]}),null)}}),header:xt=>S(mo,te(xt,fo),{header:t.header,cell:ue=>{let Ee;return t["header-cell"]?S(Nt,te(ue,Jt,{style:xe[ue.column.key]}),je(Ee=t["header-cell"](ue))?Ee:{default:()=>[Ee]}):S(Nt,te(ue,Jt,{style:xe[ue.column.key]}),null)}})},po=[e.class,a.b(),a.e("root"),{[a.is("dynamic")]:l(k)}],wo={class:a.e("footer"),style:l(O)};return S("div",{class:po,style:l(Y)},[S(io,ke,je(pe)?pe:{default:()=>[pe]}),S(co,ae,je(pe)?pe:{default:()=>[pe]}),S(uo,Ae,je(pe)?pe:{default:()=>[pe]}),t.footer&&S(Gt,wo,{default:t.footer}),l(L)&&S(Ft,{class:a.e("empty"),style:l(U)},{default:t.empty}),t.overlay&&S(jt,{class:a.e("overlay")},{default:t.overlay})])}}}),Pt=Me({disableWidth:Boolean,disableHeight:Boolean,onResize:{type:V(Function)}}),qt=ie({name:"ElAutoResizer",props:Pt,setup(e,{slots:t}){const o=De("auto-resizer"),{height:a,width:r,sizer:n}=(i=>{const u=B(),h=B(0),d=B(0);let m;return lt(()=>{m=Mo(u,([C])=>{const{width:_,height:M}=C.contentRect,{paddingLeft:c,paddingRight:G,paddingTop:P,paddingBottom:$}=getComputedStyle(C.target),y=Number.parseInt(c)||0,k=Number.parseInt(G)||0,K=Number.parseInt(P)||0,N=Number.parseInt($)||0;h.value=_-y-k,d.value=M-K-N}).stop}),Oo(()=>{m==null||m()}),ot([h,d],([C,_])=>{var M;(M=i.onResize)==null||M.call(i,{width:C,height:_})}),{sizer:u,width:h,height:d}})(e),s={width:"100%",height:"100%"};return()=>{var i;return S("div",{ref:n,class:o.b(),style:s},[(i=t.default)==null?void 0:i.call(t,{height:a.value,width:r.value})])}}}),Ut=vt(Bt),Yt=vt(qt),Xt={style:{width:"100%",height:"700px"}},fl=ie({name:"SystemArea",__name:"index",setup(e){const t=[{dataKey:"id",title:"\u7F16\u53F7",width:400,fixed:!0,key:"id"},{dataKey:"name",title:"\u5730\u540D",width:200}],o=B([]),a=B();return lt(()=>{(async()=>o.value=await ea())()}),(r,n)=>{const s=Vo,i=No,u=Xo,h=Ut,d=Yt;return _e(),Le($o,null,[S(u,null,{default:at(()=>[S(i,{type:"primary",plain:"",onClick:n[0]||(n[0]=m=>{a.value.open()})},{default:at(()=>[S(s,{icon:"ep:plus",class:"mr-5px"}),zo(" IP \u67E5\u8BE2 ")]),_:1})]),_:1}),S(u,null,{default:at(()=>[j("div",Xt,[S(d,null,{default:at(({height:m,width:C})=>[S(h,{columns:t,data:l(o),width:C,height:m,"expand-column-key":"id"},null,8,["data","width","height"])]),_:1})])]),_:1}),S(Qo,{ref_key:"formRef",ref:a},null,512)],64)}}})});export{ra as __tla,fl as default};
|