2 lines
21 KiB
JavaScript
2 lines
21 KiB
JavaScript
var We=Object.defineProperty;var Xe=(t,e,l)=>e in t?We(t,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):t[e]=l;var y=(t,e,l)=>(Xe(t,typeof e!="symbol"?e+"":e,l),l);(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))n(i);new MutationObserver(i=>{for(const o of i)if(o.type==="childList")for(const r of o.addedNodes)r.tagName==="LINK"&&r.rel==="modulepreload"&&n(r)}).observe(document,{childList:!0,subtree:!0});function l(i){const o={};return i.integrity&&(o.integrity=i.integrity),i.referrerpolicy&&(o.referrerPolicy=i.referrerpolicy),i.crossorigin==="use-credentials"?o.credentials="include":i.crossorigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function n(i){if(i.ep)return;i.ep=!0;const o=l(i);fetch(i.href,o)}})();function V(){}function Ye(t,e){for(const l in e)t[l]=e[l];return t}function Ze(t){return!!t&&(typeof t=="object"||typeof t=="function")&&typeof t.then=="function"}function Je(t){return t()}function we(){return Object.create(null)}function J(t){t.forEach(Je)}function Ke(t){return typeof t=="function"}function oe(t,e){return t!=t?e==e:t!==e||t&&typeof t=="object"||typeof t=="function"}function xe(t){return Object.keys(t).length===0}function et(t,e,l,n){if(t){const i=Qe(t,e,l,n);return t[0](i)}}function Qe(t,e,l,n){return t[1]&&n?Ye(l.ctx.slice(),t[1](n(e))):l.ctx}function tt(t,e,l,n){if(t[2]&&n){const i=t[2](n(l));if(e.dirty===void 0)return i;if(typeof i=="object"){const o=[],r=Math.max(e.dirty.length,i.length);for(let c=0;c<r;c+=1)o[c]=e.dirty[c]|i[c];return o}return e.dirty|i}return e.dirty}function nt(t,e,l,n,i,o){if(i){const r=Qe(e,l,n,o);t.p(r,i)}}function lt(t){if(t.ctx.length>32){const e=[],l=t.ctx.length/32;for(let n=0;n<l;n++)e[n]=-1;return e}return-1}function _(t,e){t.appendChild(e)}function E(t,e,l){t.insertBefore(e,l||null)}function O(t){t.parentNode&&t.parentNode.removeChild(t)}function Q(t,e){for(let l=0;l<t.length;l+=1)t[l]&&t[l].d(e)}function v(t){return document.createElement(t)}function S(t){return document.createTextNode(t)}function R(){return S(" ")}function Ve(){return S("")}function F(t,e,l,n){return t.addEventListener(e,l,n),()=>t.removeEventListener(e,l,n)}function A(t,e,l){l==null?t.removeAttribute(e):t.getAttribute(e)!==l&&t.setAttribute(e,l)}function it(t){return Array.from(t.childNodes)}function P(t,e){e=""+e,t.data!==e&&(t.data=e)}function Oe(t,e){t.value=e==null?"":e}function W(t,e,l){for(let n=0;n<t.options.length;n+=1){const i=t.options[n];if(i.__value===e){i.selected=!0;return}}(!l||e!==void 0)&&(t.selectedIndex=-1)}function ae(t){const e=t.querySelector(":checked");return e&&e.__value}let te;function I(t){te=t}function De(){if(!te)throw new Error("Function called outside component initialization");return te}function ot(t){De().$$.on_mount.push(t)}const Y=[],ne=[];let Z=[];const he=[],rt=Promise.resolve();let de=!1;function st(){de||(de=!0,rt.then(be))}function x(t){Z.push(t)}function ge(t){he.push(t)}const fe=new Set;let X=0;function be(){if(X!==0)return;const t=te;do{try{for(;X<Y.length;){const e=Y[X];X++,I(e),ut(e.$$)}}catch(e){throw Y.length=0,X=0,e}for(I(null),Y.length=0,X=0;ne.length;)ne.pop()();for(let e=0;e<Z.length;e+=1){const l=Z[e];fe.has(l)||(fe.add(l),l())}Z.length=0}while(Y.length);for(;he.length;)he.pop()();de=!1,fe.clear(),I(t)}function ut(t){if(t.fragment!==null){t.update(),J(t.before_update);const e=t.dirty;t.dirty=[-1],t.fragment&&t.fragment.p(t.ctx,e),t.after_update.forEach(x)}}function ct(t){const e=[],l=[];Z.forEach(n=>t.indexOf(n)===-1?e.push(n):l.push(n)),l.forEach(n=>n()),Z=e}const le=new Set;let K;function ve(){K={r:0,c:[],p:K}}function ke(){K.r||J(K.c),K=K.p}function $(t,e){t&&t.i&&(le.delete(t),t.i(e))}function T(t,e,l,n){if(t&&t.o){if(le.has(t))return;le.add(t),K.c.push(()=>{le.delete(t),n&&(l&&t.d(1),n())}),t.o(e)}else n&&n()}function ie(t,e){const l=e.token={};function n(i,o,r,c){if(e.token!==l)return;e.resolved=c;let a=e.ctx;r!==void 0&&(a=a.slice(),a[r]=c);const u=i&&(e.current=i)(a);let h=!1;e.block&&(e.blocks?e.blocks.forEach((g,p)=>{p!==o&&g&&(ve(),T(g,1,1,()=>{e.blocks[p]===g&&(e.blocks[p]=null)}),ke())}):e.block.d(1),u.c(),$(u,1),u.m(e.mount(),e.anchor),h=!0),e.block=u,e.blocks&&(e.blocks[o]=u),h&&be()}if(Ze(t)){const i=De();if(t.then(o=>{I(i),n(e.then,1,e.value,o),I(null)},o=>{if(I(i),n(e.catch,2,e.error,o),I(null),!e.hasCatch)throw o}),e.current!==e.pending)return n(e.pending,0),!0}else{if(e.current!==e.then)return n(e.then,1,e.value,t),!0;e.resolved=t}}function He(t,e,l){const n=e.slice(),{resolved:i}=t;t.current===t.then&&(n[t.value]=i),t.current===t.catch&&(n[t.error]=i),t.block.p(n,l)}function me(t,e,l){const n=t.$$.props[e];n!==void 0&&(t.$$.bound[n]=l,l(t.$$.ctx[n]))}function ye(t){t&&t.c()}function re(t,e,l,n){const{fragment:i,after_update:o}=t.$$;i&&i.m(e,l),n||x(()=>{const r=t.$$.on_mount.map(Je).filter(Ke);t.$$.on_destroy?t.$$.on_destroy.push(...r):J(r),t.$$.on_mount=[]}),o.forEach(x)}function se(t,e){const l=t.$$;l.fragment!==null&&(ct(l.after_update),J(l.on_destroy),l.fragment&&l.fragment.d(e),l.on_destroy=l.fragment=null,l.ctx=[])}function at(t,e){t.$$.dirty[0]===-1&&(Y.push(t),st(),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<<e%31}function ue(t,e,l,n,i,o,r,c=[-1]){const a=te;I(t);const u=t.$$={fragment:null,ctx:[],props:o,update:V,not_equal:i,bound:we(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(e.context||(a?a.$$.context:[])),callbacks:we(),dirty:c,skip_bound:!1,root:e.target||a.$$.root};r&&r(u.root);let h=!1;if(u.ctx=l?l(t,e.props||{},(g,p,...d)=>{const m=d.length?d[0]:p;return u.ctx&&i(u.ctx[g],u.ctx[g]=m)&&(!u.skip_bound&&u.bound[g]&&u.bound[g](m),h&&at(t,g)),p}):[],u.update(),h=!0,J(u.before_update),u.fragment=n?n(u.ctx):!1,e.target){if(e.hydrate){const g=it(e.target);u.fragment&&u.fragment.l(g),g.forEach(O)}else u.fragment&&u.fragment.c();e.intro&&$(t.$$.fragment),re(t,e.target,e.anchor,e.customElement),be()}I(a)}class ce{$destroy(){se(this,1),this.$destroy=V}$on(e,l){if(!Ke(l))return V;const n=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return n.push(l),()=>{const i=n.indexOf(l);i!==-1&&n.splice(i,1)}}$set(e){this.$$set&&!xe(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}}function ft(t,e,l){return window.runtime.EventsOnMultiple(t,e,l)}function _e(t,e){return ft(t,e,-1)}function _t(t,e,l){return window.go.main.App.AggregateByColumn(t,e,l)}function ht(t,e,l,n,i){return window.go.main.App.GetEmployees(t,e,l,n,i)}function Ce(t,e,l){const n=t.slice();return n[12]=e[l],n}function Ee(t,e,l){const n=t.slice();return n[15]=e[l],n}function Ae(t,e,l){const n=t.slice();return n[18]=e[l],n}function Ne(t,e,l){const n=t.slice();return n[18]=e[l],n}function dt(t){let e,l=t[23]+"",n;return{c(){e=v("p"),n=S(l)},m(i,o){E(i,e,o),_(e,n)},p(i,o){o&51&&l!==(l=i[23]+"")&&P(n,l)},d(i){i&&O(e)}}}function gt(t){let e,l,n,i,o,r,c,a,u,h,g,p,d=Object.keys(t[11][0]),m=[];for(let f=0;f<d.length;f+=1)m[f]=Re(Ne(t,d,f));let b=Object.keys(t[11][0]),j=[];for(let f=0;f<b.length;f+=1)j[f]=Me(Ae(t,b,f));let L=t[11],N=[];for(let f=0;f<L.length;f+=1)N[f]=Se(Ce(t,L,f));return{c(){e=v("div"),l=v("select");for(let f=0;f<m.length;f+=1)m[f].c();n=R(),i=v("input"),o=R(),r=v("button"),r.textContent="Search",c=R(),a=v("table"),u=v("tr");for(let f=0;f<j.length;f+=1)j[f].c();h=R();for(let f=0;f<N.length;f+=1)N[f].c();A(l,"name","query"),A(i,"placeholder","Query"),A(i,"type","text"),A(r,"type","button"),A(u,"class","svelte-1bs0eb4"),A(a,"class","svelte-1bs0eb4")},m(f,M){E(f,e,M),_(e,l);for(let s=0;s<m.length;s+=1)m[s]&&m[s].m(l,null);_(e,n),_(e,i),Oe(i,t[3]),_(e,o),_(e,r),E(f,c,M),E(f,a,M),_(a,u);for(let s=0;s<j.length;s+=1)j[s]&&j[s].m(u,null);_(a,h);for(let s=0;s<N.length;s+=1)N[s]&&N[s].m(a,null);g||(p=[F(l,"change",t[8]),F(i,"input",t[9]),F(r,"click",t[10])],g=!0)},p(f,M){if(M&115){d=Object.keys(f[11][0]);let s;for(s=0;s<d.length;s+=1){const C=Ne(f,d,s);m[s]?m[s].p(C,M):(m[s]=Re(C),m[s].c(),m[s].m(l,null))}for(;s<m.length;s+=1)m[s].d(1);m.length=d.length}if(M&8&&i.value!==f[3]&&Oe(i,f[3]),M&115){b=Object.keys(f[11][0]);let s;for(s=0;s<b.length;s+=1){const C=Ae(f,b,s);j[s]?j[s].p(C,M):(j[s]=Me(C),j[s].c(),j[s].m(u,null))}for(;s<j.length;s+=1)j[s].d(1);j.length=b.length}if(M&115){L=f[11];let s;for(s=0;s<L.length;s+=1){const C=Ce(f,L,s);N[s]?N[s].p(C,M):(N[s]=Se(C),N[s].c(),N[s].m(a,null))}for(;s<N.length;s+=1)N[s].d(1);N.length=L.length}},d(f){f&&O(e),Q(m,f),f&&O(c),f&&O(a),Q(j,f),Q(N,f),g=!1,J(p)}}}function Re(t){let e,l=t[18]+"",n,i;return{c(){e=v("option"),n=S(l),e.__value=i=t[18],e.value=e.__value},m(o,r){E(o,e,r),_(e,n)},p(o,r){r&51&&l!==(l=o[18]+"")&&P(n,l),r&51&&i!==(i=o[18])&&(e.__value=i,e.value=e.__value)},d(o){o&&O(e)}}}function Me(t){let e,l=t[18]+"",n;return{c(){e=v("th"),n=S(l),A(e,"class","svelte-1bs0eb4")},m(i,o){E(i,e,o),_(e,n)},p(i,o){o&51&&l!==(l=i[18]+"")&&P(n,l)},d(i){i&&O(e)}}}function Le(t){let e,l=t[15]+"",n;return{c(){e=v("td"),n=S(l),A(e,"class","svelte-1bs0eb4")},m(i,o){E(i,e,o),_(e,n)},p(i,o){o&51&&l!==(l=i[15]+"")&&P(n,l)},d(i){i&&O(e)}}}function Se(t){let e,l,n=Object.values(t[12]),i=[];for(let o=0;o<n.length;o+=1)i[o]=Le(Ee(t,n,o));return{c(){e=v("tr");for(let o=0;o<i.length;o+=1)i[o].c();l=R(),A(e,"class","svelte-1bs0eb4")},m(o,r){E(o,e,r);for(let c=0;c<i.length;c+=1)i[c]&&i[c].m(e,null);_(e,l)},p(o,r){if(r&115){n=Object.values(o[12]);let c;for(c=0;c<n.length;c+=1){const a=Ee(o,n,c);i[c]?i[c].p(a,r):(i[c]=Le(a),i[c].c(),i[c].m(e,l))}for(;c<i.length;c+=1)i[c].d(1);i.length=n.length}},d(o){o&&O(e),Q(i,o)}}}function mt(t){let e;return{c(){e=v("p"),e.textContent="Loading..."},m(l,n){E(l,e,n)},p:V,d(l){l&&O(e)}}}function pt(t){let e,l,n={ctx:t,current:null,token:null,hasCatch:!0,pending:mt,then:gt,catch:dt,value:11,error:23};return ie(l=t[6](t[1],qe,t[0],t[4],t[5]),n),{c(){e=v("section"),n.block.c()},m(i,o){E(i,e,o),n.block.m(e,n.anchor=null),n.mount=()=>e,n.anchor=null},p(i,[o]){t=i,n.ctx=t,o&51&&l!==(l=t[6](t[1],qe,t[0],t[4],t[5]))&&ie(l,n)||He(n,t,o)},i:V,o:V,d(i){i&&O(e),n.block.d(),n.token=null,n=null}}}let qe=10;function bt(t,e,l){let{path:n}=e,{page:i}=e,{limitReached:o}=e,r=null,c=null,a=null,u=null;async function h(m,b,j,L,N){try{const f=await ht(m,b,j,L,N);return l(7,o=f.length<b),f}catch(f){throw f.message}}const g=({currentTarget:m})=>l(2,r=m.value);function p(){c=this.value,l(3,c)}const d=()=>{l(0,i=0),l(4,a=r),l(5,u=c)};return t.$$set=m=>{"path"in m&&l(1,n=m.path),"page"in m&&l(0,i=m.page),"limitReached"in m&&l(7,o=m.limitReached)},[i,n,r,c,a,u,h,o,g,p,d]}class vt extends ce{constructor(e){super(),ue(this,e,bt,pt,oe,{path:1,page:0,limitReached:7})}}function ze(t){let e,l,n,i,o,r,c;const a=t[3].default,u=et(a,t,t[2],null);return{c(){e=v("dialog"),l=v("div"),u&&u.c(),n=R(),i=v("button"),i.textContent="Close",A(l,"class","dialog svelte-rr3arx"),A(e,"class","backdrop svelte-rr3arx"),e.open=t[0]},m(h,g){E(h,e,g),_(e,l),u&&u.m(l,null),_(l,n),_(l,i),o=!0,r||(c=F(i,"click",t[4]),r=!0)},p(h,g){u&&u.p&&(!o||g&4)&&nt(u,a,h,h[2],o?tt(a,h[2],g,null):lt(h[2]),null),(!o||g&1)&&(e.open=h[0])},i(h){o||($(u,h),o=!0)},o(h){T(u,h),o=!1},d(h){h&&O(e),u&&u.d(h),r=!1,c()}}}function kt(t){let e,l,n=t[0]&&ze(t);return{c(){n&&n.c(),e=Ve()},m(i,o){n&&n.m(i,o),E(i,e,o),l=!0},p(i,[o]){i[0]?n?(n.p(i,o),o&1&&$(n,1)):(n=ze(i),n.c(),$(n,1),n.m(e.parentNode,e)):n&&(ve(),T(n,1,1,()=>{n=null}),ke())},i(i){l||($(n),l=!0)},o(i){T(n),l=!1},d(i){n&&n.d(i),i&&O(e)}}}function yt(t,e,l){let{$$slots:n={},$$scope:i}=e,{isOpen:o}=e,{onClose:r}=e;const c=()=>r();return t.$$set=a=>{"isOpen"in a&&l(0,o=a.isOpen),"onClose"in a&&l(1,r=a.onClose),"$$scope"in a&&l(2,i=a.$$scope)},[o,r,i,n,c]}class jt extends ce{constructor(e){super(),ue(this,e,yt,kt,oe,{isOpen:0,onClose:1})}}var pe;(t=>{class e{constructor(n={}){y(this,"emp_id");y(this,"name_prefix");y(this,"first_name");y(this,"middle_initial");y(this,"last_name");y(this,"gender");y(this,"email");y(this,"fathers_name");y(this,"mothers_name");y(this,"mothers_maiden_name");y(this,"birthdate");y(this,"birth_time");y(this,"weight_kg");y(this,"joining_date");y(this,"joining_quarter");y(this,"joining_half");y(this,"joining_year");y(this,"joining_month");y(this,"joining_month_name");y(this,"joining_month_name_short");y(this,"joining_month_day");y(this,"joining_week_day");y(this,"joining_week_day_short");y(this,"years_of_service");y(this,"salary");y(this,"latest_hike_percentage");y(this,"ssn");y(this,"phone_number");y(this,"place_name");y(this,"county");y(this,"city");y(this,"state");y(this,"zip");y(this,"region");y(this,"username");y(this,"password");typeof n=="string"&&(n=JSON.parse(n)),this.emp_id=n.emp_id,this.name_prefix=n.name_prefix,this.first_name=n.first_name,this.middle_initial=n.middle_initial,this.last_name=n.last_name,this.gender=n.gender,this.email=n.email,this.fathers_name=n.fathers_name,this.mothers_name=n.mothers_name,this.mothers_maiden_name=n.mothers_maiden_name,this.birthdate=n.birthdate,this.birth_time=n.birth_time,this.weight_kg=n.weight_kg,this.joining_date=n.joining_date,this.joining_quarter=n.joining_quarter,this.joining_half=n.joining_half,this.joining_year=n.joining_year,this.joining_month=n.joining_month,this.joining_month_name=n.joining_month_name,this.joining_month_name_short=n.joining_month_name_short,this.joining_month_day=n.joining_month_day,this.joining_week_day=n.joining_week_day,this.joining_week_day_short=n.joining_week_day_short,this.years_of_service=n.years_of_service,this.salary=n.salary,this.latest_hike_percentage=n.latest_hike_percentage,this.ssn=n.ssn,this.phone_number=n.phone_number,this.place_name=n.place_name,this.county=n.county,this.city=n.city,this.state=n.state,this.zip=n.zip,this.region=n.region,this.username=n.username,this.password=n.password}static createFrom(n={}){return new e(n)}}t.Employee=e})(pe||(pe={}));function Be(t,e,l){const n=t.slice();return n[13]=e[l][0],n[14]=e[l][1],n}function Ge(t,e,l){const n=t.slice();return n[13]=e[l],n}function Pe(t,e,l){const n=t.slice();return n[13]=e[l],n}function $e(t){let e,l=t[13]+"",n,i;return{c(){e=v("option"),n=S(l),e.__value=i=t[13],e.value=e.__value},m(o,r){E(o,e,r),_(e,n)},p(o,r){r&2&&l!==(l=o[13]+"")&&P(n,l),r&2&&i!==(i=o[13])&&(e.__value=i,e.value=e.__value)},d(o){o&&O(e)}}}function Fe(t){let e,l=t[13]+"",n,i;return{c(){e=v("option"),n=S(l),e.__value=i=t[13],e.value=e.__value},m(o,r){E(o,e,r),_(e,n)},p(o,r){r&2&&l!==(l=o[13]+"")&&P(n,l),r&2&&i!==(i=o[13])&&(e.__value=i,e.value=e.__value)},d(o){o&&O(e)}}}function Ie(t){let e,l,n={ctx:t,current:null,token:null,hasCatch:!0,pending:Ct,then:Ot,catch:wt,value:12,error:17};return ie(l=t[5],n),{c(){e=v("section"),n.block.c()},m(i,o){E(i,e,o),n.block.m(e,n.anchor=null),n.mount=()=>e,n.anchor=null},p(i,o){t=i,n.ctx=t,o&32&&l!==(l=t[5])&&ie(l,n)||He(n,t,o)},d(i){i&&O(e),n.block.d(),n.token=null,n=null}}}function wt(t){let e,l=t[17]+"",n;return{c(){e=v("p"),n=S(l)},m(i,o){E(i,e,o),_(e,n)},p(i,o){o&32&&l!==(l=i[17]+"")&&P(n,l)},d(i){i&&O(e)}}}function Ot(t){let e,l,n,i,o,r,c,a,u,h,g=Object.entries(t[12]),p=[];for(let d=0;d<g.length;d+=1)p[d]=Te(Be(t,g,d));return{c(){e=v("table"),l=v("tr"),n=v("th"),i=S(t[2]),o=R(),r=v("th"),c=S(t[4]),a=S(" of "),u=S(t[3]),h=R();for(let d=0;d<p.length;d+=1)p[d].c();A(n,"class","svelte-xmvjp8"),A(r,"class","svelte-xmvjp8"),A(l,"class","svelte-xmvjp8"),A(e,"class","agg-table svelte-xmvjp8")},m(d,m){E(d,e,m),_(e,l),_(l,n),_(n,i),_(l,o),_(l,r),_(r,c),_(r,a),_(r,u),_(e,h);for(let b=0;b<p.length;b+=1)p[b]&&p[b].m(e,null)},p(d,m){if(m&4&&P(i,d[2]),m&16&&P(c,d[4]),m&8&&P(u,d[3]),m&32){g=Object.entries(d[12]);let b;for(b=0;b<g.length;b+=1){const j=Be(d,g,b);p[b]?p[b].p(j,m):(p[b]=Te(j),p[b].c(),p[b].m(e,null))}for(;b<p.length;b+=1)p[b].d(1);p.length=g.length}},d(d){d&&O(e),Q(p,d)}}}function Te(t){let e,l,n=t[13]+"",i,o,r,c=t[14]+"",a,u;return{c(){e=v("tr"),l=v("td"),i=S(n),o=R(),r=v("td"),a=S(c),u=R(),A(l,"class","svelte-xmvjp8"),A(r,"class","svelte-xmvjp8"),A(e,"class","svelte-xmvjp8")},m(h,g){E(h,e,g),_(e,l),_(l,i),_(e,o),_(e,r),_(r,a),_(e,u)},p(h,g){g&32&&n!==(n=h[13]+"")&&P(i,n),g&32&&c!==(c=h[14]+"")&&P(a,c)},d(h){h&&O(e)}}}function Ct(t){let e;return{c(){e=v("p"),e.textContent="Loading..."},m(l,n){E(l,e,n)},p:V,d(l){l&&O(e)}}}function Et(t){let e,l,n,i,o,r,c,a,u,h,g,p,d,m,b,j,L,N,f,M,s,C,U,je,D=t[1],q=[];for(let k=0;k<D.length;k+=1)q[k]=$e(Pe(t,D,k));let H=t[1],z=[];for(let k=0;k<H.length;k+=1)z[k]=Fe(Ge(t,H,k));let B=t[5]&&Ie(t);return{c(){e=v("section"),l=v("p"),l.textContent="Aggregation",n=R(),i=v("div"),o=v("label"),o.textContent="Group by:",r=R(),c=v("select");for(let k=0;k<q.length;k+=1)q[k].c();a=R(),u=v("div"),h=v("label"),h.textContent="On:",g=R(),p=v("select");for(let k=0;k<z.length;k+=1)z[k].c();d=R(),m=v("label"),m.textContent="Using:",b=R(),j=v("select"),L=v("option"),L.textContent="Average",N=v("option"),N.textContent="SUM",f=R(),M=v("button"),M.textContent="Aggregate",s=R(),B&&B.c(),C=Ve(),A(o,"for","group"),A(c,"name","group"),A(c,"id",""),t[2]===void 0&&x(()=>t[7].call(c)),A(h,"for","on-column"),A(p,"name","on-column"),A(p,"id",""),t[3]===void 0&&x(()=>t[8].call(p)),A(m,"for","function"),L.__value="AVG",L.value=L.__value,N.__value="SUM",N.value=N.__value,A(j,"name","function"),A(j,"id",""),t[4]===void 0&&x(()=>t[9].call(j)),A(M,"type","button")},m(k,G){E(k,e,G),_(e,l),_(e,n),_(e,i),_(i,o),_(i,r),_(i,c);for(let w=0;w<q.length;w+=1)q[w]&&q[w].m(c,null);W(c,t[2],!0),_(e,a),_(e,u),_(u,h),_(u,g),_(u,p);for(let w=0;w<z.length;w+=1)z[w]&&z[w].m(p,null);W(p,t[3],!0),_(u,d),_(u,m),_(u,b),_(u,j),_(j,L),_(j,N),W(j,t[4],!0),_(e,f),_(e,M),E(k,s,G),B&&B.m(k,G),E(k,C,G),U||(je=[F(c,"change",t[7]),F(p,"change",t[8]),F(j,"change",t[9]),F(M,"click",t[10])],U=!0)},p(k,G){if(G&2){D=k[1];let w;for(w=0;w<D.length;w+=1){const ee=Pe(k,D,w);q[w]?q[w].p(ee,G):(q[w]=$e(ee),q[w].c(),q[w].m(c,null))}for(;w<q.length;w+=1)q[w].d(1);q.length=D.length}if(G&6&&W(c,k[2]),G&2){H=k[1];let w;for(w=0;w<H.length;w+=1){const ee=Ge(k,H,w);z[w]?z[w].p(ee,G):(z[w]=Fe(ee),z[w].c(),z[w].m(p,null))}for(;w<z.length;w+=1)z[w].d(1);z.length=H.length}G&10&&W(p,k[3]),G&16&&W(j,k[4]),k[5]?B?B.p(k,G):(B=Ie(k),B.c(),B.m(C.parentNode,C)):B&&(B.d(1),B=null)},d(k){k&&O(e),Q(q,k),Q(z,k),k&&O(s),B&&B.d(k),k&&O(C),U=!1,J(je)}}}function At(t){let e,l;return e=new jt({props:{isOpen:t[0],onClose:t[11],$$slots:{default:[Et]},$$scope:{ctx:t}}}),{c(){ye(e.$$.fragment)},m(n,i){re(e,n,i),l=!0},p(n,[i]){const o={};i&1&&(o.isOpen=n[0]),i&1&&(o.onClose=n[11]),i&4194366&&(o.$$scope={dirty:i,ctx:n}),e.$set(o)},i(n){l||($(e.$$.fragment,n),l=!0)},o(n){T(e.$$.fragment,n),l=!1},d(n){se(e,n)}}}function Nt(t,e,l){let{isOpen:n}=e,{keys:i}=e,o=null,r=null,c=null,a;async function u(){if(!(!o||!r||!c))try{return await _t(o,r,c)}catch(b){throw b.message}}function h(){o=ae(this),l(2,o),l(1,i)}function g(){r=ae(this),l(3,r),l(1,i)}function p(){c=ae(this),l(4,c)}const d=()=>l(5,a=u()),m=()=>{l(0,n=!1)};return t.$$set=b=>{"isOpen"in b&&l(0,n=b.isOpen),"keys"in b&&l(1,i=b.keys)},[n,i,o,r,c,a,u,h,g,p,d,m]}class Rt extends ce{constructor(e){super(),ue(this,e,Nt,At,oe,{isOpen:0,keys:1})}}function Ue(t){let e,l,n,i,o,r,c,a,u,h=t[2]+1+"",g,p,d,m,b,j,L;function N(s){t[5](s)}function f(s){t[6](s)}let M={path:t[1]};return t[2]!==void 0&&(M.page=t[2]),t[0]!==void 0&&(M.limitReached=t[0]),e=new vt({props:M}),ne.push(()=>me(e,"page",N)),ne.push(()=>me(e,"limitReached",f)),{c(){ye(e.$$.fragment),i=R(),o=v("button"),r=S("Prev"),a=R(),u=v("span"),g=S(h),p=R(),d=v("button"),m=S("Next"),o.disabled=c=t[2]<1,d.disabled=t[0]},m(s,C){re(e,s,C),E(s,i,C),E(s,o,C),_(o,r),E(s,a,C),E(s,u,C),_(u,g),E(s,p,C),E(s,d,C),_(d,m),b=!0,j||(L=[F(o,"click",t[7]),F(d,"click",t[8])],j=!0)},p(s,C){const U={};C&2&&(U.path=s[1]),!l&&C&4&&(l=!0,U.page=s[2],ge(()=>l=!1)),!n&&C&1&&(n=!0,U.limitReached=s[0],ge(()=>n=!1)),e.$set(U),(!b||C&4&&c!==(c=s[2]<1))&&(o.disabled=c),(!b||C&4)&&h!==(h=s[2]+1+"")&&P(g,h),(!b||C&1)&&(d.disabled=s[0])},i(s){b||($(e.$$.fragment,s),b=!0)},o(s){T(e.$$.fragment,s),b=!1},d(s){se(e,s),s&&O(i),s&&O(o),s&&O(a),s&&O(u),s&&O(p),s&&O(d),j=!1,J(L)}}}function Mt(t){let e,l,n,i,o,r=t[1]&&Ue(t);function c(u){t[9](u)}let a={keys:t[4]};return t[3]!==void 0&&(a.isOpen=t[3]),n=new Rt({props:a}),ne.push(()=>me(n,"isOpen",c)),{c(){e=v("main"),r&&r.c(),l=R(),ye(n.$$.fragment)},m(u,h){E(u,e,h),r&&r.m(e,null),_(e,l),re(n,e,null),o=!0},p(u,[h]){u[1]?r?(r.p(u,h),h&2&&$(r,1)):(r=Ue(u),r.c(),$(r,1),r.m(e,l)):r&&(ve(),T(r,1,1,()=>{r=null}),ke());const g={};!i&&h&8&&(i=!0,g.isOpen=u[3],ge(()=>i=!1)),n.$set(g)},i(u){o||($(r),$(n.$$.fragment,u),o=!0)},o(u){T(r),T(n.$$.fragment,u),o=!1},d(u){u&&O(e),r&&r.d(),se(n)}}}function Lt(t,e,l){let n,i=0,o=!1,r;const c=Object.keys(new pe.Employee);ot(async()=>{_e("proto-opened",d=>{l(1,n=d)}),_e("csv-converted",d=>{console.log(d)}),_e("aggregation",()=>{l(3,o=!0)})});function a(d){i=d,l(2,i)}function u(d){r=d,l(0,r)}const h=()=>l(2,i--,i),g=()=>l(2,i++,i);function p(d){o=d,l(3,o)}return t.$$.update=()=>{t.$$.dirty&1&&console.log(r)},[r,n,i,o,c,a,u,h,g,p]}class St extends ce{constructor(e){super(),ue(this,e,Lt,Mt,oe,{})}}new St({target:document.getElementById("app")});
|