Files
sibedas/public/build/assets/table-gridjs-SkKjBh19.js
2025-02-06 08:40:19 +07:00

5 lines
66 KiB
JavaScript

import{c as sn,a as an}from"./_commonjsHelpers-C4iS2aBk.js";var Dt={exports:{}};(function(Ft,B){(function(w,mt){mt(B)})(sn,function(w){function mt(r,e){for(var n=0;n<e.length;n++){var t=e[n];t.enumerable=t.enumerable||!1,t.configurable=!0,"value"in t&&(t.writable=!0),Object.defineProperty(r,t.key,t)}}function k(r,e,n){return e&&mt(r.prototype,e),r}function C(){return C=Object.assign||function(r){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var t in n)Object.prototype.hasOwnProperty.call(n,t)&&(r[t]=n[t])}return r},C.apply(this,arguments)}function m(r,e){r.prototype=Object.create(e.prototype),r.prototype.constructor=r,gt(r,e)}function gt(r,e){return gt=Object.setPrototypeOf||function(n,t){return n.__proto__=t,n},gt(r,e)}function V(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function At(r,e){(e==null||e>r.length)&&(e=r.length);for(var n=0,t=new Array(e);n<e;n++)t[n]=r[n];return t}function F(r,e){var n=typeof Symbol<"u"&&r[Symbol.iterator]||r["@@iterator"];if(n)return(n=n.call(r)).next.bind(n);if(Array.isArray(r)||(n=function(i,o){if(i){if(typeof i=="string")return At(i,o);var s=Object.prototype.toString.call(i).slice(8,-1);return s==="Object"&&i.constructor&&(s=i.constructor.name),s==="Map"||s==="Set"?Array.from(i):s==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(s)?At(i,o):void 0}}(r))||e){n&&(r=n);var t=0;return function(){return t>=r.length?{done:!0}:{done:!1,value:r[t++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var nt,_,Rt,Tt,Q,Ut,Lt,rt={},Bt=[],we=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i;function G(r,e){for(var n in e)r[n]=e[n];return r}function Mt(r){var e=r.parentNode;e&&e.removeChild(r)}function p(r,e,n){var t,i,o,s={};for(o in e)o=="key"?t=e[o]:o=="ref"?i=e[o]:s[o]=e[o];if(arguments.length>2&&(s.children=arguments.length>3?nt.call(arguments,2):n),typeof r=="function"&&r.defaultProps!=null)for(o in r.defaultProps)s[o]===void 0&&(s[o]=r.defaultProps[o]);return it(r,s,t,i,null)}function it(r,e,n,t,i){var o={type:r,props:e,key:n,ref:t,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:i??++Rt};return i==null&&_.vnode!=null&&_.vnode(o),o}function M(r){return r.children}function Y(r,e){this.props=r,this.context=e}function J(r,e){if(e==null)return r.__?J(r.__,r.__.__k.indexOf(r)+1):null;for(var n;e<r.__k.length;e++)if((n=r.__k[e])!=null&&n.__e!=null)return n.__e;return typeof r.type=="function"?J(r):null}function Ht(r){var e,n;if((r=r.__)!=null&&r.__c!=null){for(r.__e=r.__c.base=null,e=0;e<r.__k.length;e++)if((n=r.__k[e])!=null&&n.__e!=null){r.__e=r.__c.base=n.__e;break}return Ht(r)}}function _t(r){(!r.__d&&(r.__d=!0)&&Q.push(r)&&!ot.__r++||Ut!==_.debounceRendering)&&((Ut=_.debounceRendering)||setTimeout)(ot)}function ot(){for(var r;ot.__r=Q.length;)r=Q.sort(function(e,n){return e.__v.__b-n.__v.__b}),Q=[],r.some(function(e){var n,t,i,o,s,l;e.__d&&(s=(o=(n=e).__v).__e,(l=n.__P)&&(t=[],(i=G({},o)).__v=o.__v+1,vt(l,o,i,n.__n,l.ownerSVGElement!==void 0,o.__h!=null?[s]:null,t,s??J(o),o.__h),$t(t,o),o.__e!=s&&Ht(o)))})}function Ot(r,e,n,t,i,o,s,l,u,d){var a,g,h,c,f,P,v,b=t&&t.__k||Bt,N=b.length;for(n.__k=[],a=0;a<e.length;a++)if((c=n.__k[a]=(c=e[a])==null||typeof c=="boolean"?null:typeof c=="string"||typeof c=="number"||typeof c=="bigint"?it(null,c,null,null,c):Array.isArray(c)?it(M,{children:c},null,null,null):c.__b>0?it(c.type,c.props,c.key,null,c.__v):c)!=null){if(c.__=n,c.__b=n.__b+1,(h=b[a])===null||h&&c.key==h.key&&c.type===h.type)b[a]=void 0;else for(g=0;g<N;g++){if((h=b[g])&&c.key==h.key&&c.type===h.type){b[g]=void 0;break}h=null}vt(r,c,h=h||rt,i,o,s,l,u,d),f=c.__e,(g=c.ref)&&h.ref!=g&&(v||(v=[]),h.ref&&v.push(h.ref,null,c),v.push(g,c.__c||f,c)),f!=null?(P==null&&(P=f),typeof c.type=="function"&&c.__k===h.__k?c.__d=u=jt(c,u,r):u=Gt(r,c,h,b,f,u),typeof n.type=="function"&&(n.__d=u)):u&&h.__e==u&&u.parentNode!=r&&(u=J(h))}for(n.__e=P,a=N;a--;)b[a]!=null&&(typeof n.type=="function"&&b[a].__e!=null&&b[a].__e==n.__d&&(n.__d=J(t,a+1)),Jt(b[a],b[a]));if(v)for(a=0;a<v.length;a++)Yt(v[a],v[++a],v[++a])}function jt(r,e,n){for(var t,i=r.__k,o=0;i&&o<i.length;o++)(t=i[o])&&(t.__=r,e=typeof t.type=="function"?jt(t,e,n):Gt(n,t,t,i,t.__e,e));return e}function Gt(r,e,n,t,i,o){var s,l,u;if(e.__d!==void 0)s=e.__d,e.__d=void 0;else if(n==null||i!=o||i.parentNode==null)t:if(o==null||o.parentNode!==r)r.appendChild(i),s=null;else{for(l=o,u=0;(l=l.nextSibling)&&u<t.length;u+=2)if(l==i)break t;r.insertBefore(i,o),s=o}return s!==void 0?s:i.nextSibling}function Wt(r,e,n){e[0]==="-"?r.setProperty(e,n):r[e]=n==null?"":typeof n!="number"||we.test(e)?n:n+"px"}function st(r,e,n,t,i){var o;t:if(e==="style")if(typeof n=="string")r.style.cssText=n;else{if(typeof t=="string"&&(r.style.cssText=t=""),t)for(e in t)n&&e in n||Wt(r.style,e,"");if(n)for(e in n)t&&n[e]===t[e]||Wt(r.style,e,n[e])}else if(e[0]==="o"&&e[1]==="n")o=e!==(e=e.replace(/Capture$/,"")),e=e.toLowerCase()in r?e.toLowerCase().slice(2):e.slice(2),r.l||(r.l={}),r.l[e+o]=n,n?t||r.addEventListener(e,o?zt:Xt,o):r.removeEventListener(e,o?zt:Xt,o);else if(e!=="dangerouslySetInnerHTML"){if(i)e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(e!=="href"&&e!=="list"&&e!=="form"&&e!=="tabIndex"&&e!=="download"&&e in r)try{r[e]=n??"";break t}catch{}typeof n=="function"||(n!=null&&(n!==!1||e[0]==="a"&&e[1]==="r")?r.setAttribute(e,n):r.removeAttribute(e))}}function Xt(r){this.l[r.type+!1](_.event?_.event(r):r)}function zt(r){this.l[r.type+!0](_.event?_.event(r):r)}function vt(r,e,n,t,i,o,s,l,u){var d,a,g,h,c,f,P,v,b,N,H,S,W,D=e.type;if(e.constructor!==void 0)return null;n.__h!=null&&(u=n.__h,l=e.__e=n.__e,e.__h=null,o=[l]),(d=_.__b)&&d(e);try{t:if(typeof D=="function"){if(v=e.props,b=(d=D.contextType)&&t[d.__c],N=d?b?b.props.value:d.__:t,n.__c?P=(a=e.__c=n.__c).__=a.__E:("prototype"in D&&D.prototype.render?e.__c=a=new D(v,N):(e.__c=a=new Y(v,N),a.constructor=D,a.render=xe),b&&b.sub(a),a.props=v,a.state||(a.state={}),a.context=N,a.__n=t,g=a.__d=!0,a.__h=[]),a.__s==null&&(a.__s=a.state),D.getDerivedStateFromProps!=null&&(a.__s==a.state&&(a.__s=G({},a.__s)),G(a.__s,D.getDerivedStateFromProps(v,a.__s))),h=a.props,c=a.state,g)D.getDerivedStateFromProps==null&&a.componentWillMount!=null&&a.componentWillMount(),a.componentDidMount!=null&&a.__h.push(a.componentDidMount);else{if(D.getDerivedStateFromProps==null&&v!==h&&a.componentWillReceiveProps!=null&&a.componentWillReceiveProps(v,N),!a.__e&&a.shouldComponentUpdate!=null&&a.shouldComponentUpdate(v,a.__s,N)===!1||e.__v===n.__v){a.props=v,a.state=a.__s,e.__v!==n.__v&&(a.__d=!1),a.__v=e,e.__e=n.__e,e.__k=n.__k,e.__k.forEach(function(U){U&&(U.__=e)}),a.__h.length&&s.push(a);break t}a.componentWillUpdate!=null&&a.componentWillUpdate(v,a.__s,N),a.componentDidUpdate!=null&&a.__h.push(function(){a.componentDidUpdate(h,c,f)})}if(a.context=N,a.props=v,a.__v=e,a.__P=r,H=_.__r,S=0,"prototype"in D&&D.prototype.render)a.state=a.__s,a.__d=!1,H&&H(e),d=a.render(a.props,a.state,a.context);else do a.__d=!1,H&&H(e),d=a.render(a.props,a.state,a.context),a.state=a.__s;while(a.__d&&++S<25);a.state=a.__s,a.getChildContext!=null&&(t=G(G({},t),a.getChildContext())),g||a.getSnapshotBeforeUpdate==null||(f=a.getSnapshotBeforeUpdate(h,c)),W=d!=null&&d.type===M&&d.key==null?d.props.children:d,Ot(r,Array.isArray(W)?W:[W],e,n,t,i,o,s,l,u),a.base=e.__e,e.__h=null,a.__h.length&&s.push(a),P&&(a.__E=a.__=null),a.__e=!1}else o==null&&e.__v===n.__v?(e.__k=n.__k,e.__e=n.__e):e.__e=Ce(n.__e,e,n,t,i,o,s,u);(d=_.diffed)&&d(e)}catch(U){e.__v=null,(u||o!=null)&&(e.__e=l,e.__h=!!u,o[o.indexOf(l)]=null),_.__e(U,e,n)}}function $t(r,e){_.__c&&_.__c(e,r),r.some(function(n){try{r=n.__h,n.__h=[],r.some(function(t){t.call(n)})}catch(t){_.__e(t,n.__v)}})}function Ce(r,e,n,t,i,o,s,l){var u,d,a,g=n.props,h=e.props,c=e.type,f=0;if(c==="svg"&&(i=!0),o!=null){for(;f<o.length;f++)if((u=o[f])&&"setAttribute"in u==!!c&&(c?u.localName===c:u.nodeType===3)){r=u,o[f]=null;break}}if(r==null){if(c===null)return document.createTextNode(h);r=i?document.createElementNS("http://www.w3.org/2000/svg",c):document.createElement(c,h.is&&h),o=null,l=!1}if(c===null)g===h||l&&r.data===h||(r.data=h);else{if(o=o&&nt.call(r.childNodes),d=(g=n.props||rt).dangerouslySetInnerHTML,a=h.dangerouslySetInnerHTML,!l){if(o!=null)for(g={},f=0;f<r.attributes.length;f++)g[r.attributes[f].name]=r.attributes[f].value;(a||d)&&(a&&(d&&a.__html==d.__html||a.__html===r.innerHTML)||(r.innerHTML=a&&a.__html||""))}if(function(P,v,b,N,H){var S;for(S in b)S==="children"||S==="key"||S in v||st(P,S,null,b[S],N);for(S in v)H&&typeof v[S]!="function"||S==="children"||S==="key"||S==="value"||S==="checked"||b[S]===v[S]||st(P,S,v[S],b[S],N)}(r,h,g,i,l),a)e.__k=[];else if(f=e.props.children,Ot(r,Array.isArray(f)?f:[f],e,n,t,i&&c!=="foreignObject",o,s,o?o[0]:n.__k&&J(n,0),l),o!=null)for(f=o.length;f--;)o[f]!=null&&Mt(o[f]);l||("value"in h&&(f=h.value)!==void 0&&(f!==r.value||c==="progress"&&!f||c==="option"&&f!==g.value)&&st(r,"value",f,g.value,!1),"checked"in h&&(f=h.checked)!==void 0&&f!==r.checked&&st(r,"checked",f,g.checked,!1))}return r}function Yt(r,e,n){try{typeof r=="function"?r(e):r.current=e}catch(t){_.__e(t,n)}}function Jt(r,e,n){var t,i;if(_.unmount&&_.unmount(r),(t=r.ref)&&(t.current&&t.current!==r.__e||Yt(t,null,e)),(t=r.__c)!=null){if(t.componentWillUnmount)try{t.componentWillUnmount()}catch(o){_.__e(o,e)}t.base=t.__P=null}if(t=r.__k)for(i=0;i<t.length;i++)t[i]&&Jt(t[i],e,typeof r.type!="function");n||r.__e==null||Mt(r.__e),r.__e=r.__d=void 0}function xe(r,e,n){return this.constructor(r,n)}function tt(r,e,n){var t,i,o;_.__&&_.__(r,e),i=(t=typeof n=="function")?null:e.__k,o=[],vt(e,r=(!t&&n||e).__k=p(M,null,[r]),i||rt,rt,e.ownerSVGElement!==void 0,!t&&n?[n]:i?null:e.firstChild?nt.call(e.childNodes):null,o,!t&&n?n:i?i.__e:e.firstChild,t),$t(o,r)}function Zt(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(r){var e=16*Math.random()|0;return(r=="x"?e:3&e|8).toString(16)})}nt=Bt.slice,_={__e:function(r,e,n,t){for(var i,o,s;e=e.__;)if((i=e.__c)&&!i.__)try{if((o=i.constructor)&&o.getDerivedStateFromError!=null&&(i.setState(o.getDerivedStateFromError(r)),s=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(r,t||{}),s=i.__d),s)return i.__E=i}catch(l){r=l}throw r}},Rt=0,Tt=function(r){return r!=null&&r.constructor===void 0},Y.prototype.setState=function(r,e){var n;n=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=G({},this.state),typeof r=="function"&&(r=r(G({},n),this.props)),r&&G(n,r),r!=null&&this.__v&&(e&&this.__h.push(e),_t(this))},Y.prototype.forceUpdate=function(r){this.__v&&(this.__e=!0,r&&this.__h.push(r),_t(this))},Y.prototype.render=M,Q=[],ot.__r=0,Lt=0;var at=function(){function r(e){this._id=void 0,this._id=e||Zt()}return k(r,[{key:"id",get:function(){return this._id}}]),r}(),Se={search:{placeholder:"Type a keyword..."},sort:{sortAsc:"Sort column ascending",sortDesc:"Sort column descending"},pagination:{previous:"Previous",next:"Next",navigate:function(r,e){return"Page "+r+" of "+e},page:function(r){return"Page "+r},showing:"Showing",of:"of",to:"to",results:"results"},loading:"Loading...",noRecordsFound:"No matching records found",error:"An error happened while fetching the data"},ke=function(){function r(n){this._language=void 0,this._defaultLanguage=void 0,this._language=n,this._defaultLanguage=Se}var e=r.prototype;return e.getString=function(n,t){if(!t||!n)return null;var i=n.split("."),o=i[0];if(t[o]){var s=t[o];return typeof s=="string"?function(){return s}:typeof s=="function"?s:this.getString(i.slice(1).join("."),s)}return null},e.translate=function(n){var t,i=this.getString(n,this._language);return(t=i||this.getString(n,this._defaultLanguage))?t.apply(void 0,[].slice.call(arguments,1)):n},r}(),E=function(r){function e(n,t){var i,o;return(i=r.call(this,n,t)||this).config=void 0,i._=void 0,i.config=function(s){if(!s)return null;var l=Object.keys(s);return l.length?s[l[0]].props.value:null}(t),i.config&&(i._=(o=i.config.translator,function(s){return o.translate.apply(o,[s].concat([].slice.call(arguments,1)))})),i}return m(e,r),e}(Y),qt=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype.render=function(){return p(this.props.parentElement,{dangerouslySetInnerHTML:{__html:this.props.content}})},e}(E);function yt(r,e){return p(qt,{content:r,parentElement:e})}qt.defaultProps={parentElement:"span"};var I,lt=function(r){function e(t){var i;return(i=r.call(this)||this).data=void 0,i.update(t),i}m(e,r);var n=e.prototype;return n.cast=function(t){return t instanceof HTMLElement?yt(t.outerHTML):t},n.update=function(t){return this.data=this.cast(t),this},e}(at),ut=function(r){function e(t){var i;return(i=r.call(this)||this)._cells=void 0,i.cells=t||[],i}m(e,r);var n=e.prototype;return n.cell=function(t){return this._cells[t]},n.toArray=function(){return this.cells.map(function(t){return t.data})},e.fromCells=function(t){return new e(t.map(function(i){return new lt(i.data)}))},k(e,[{key:"cells",get:function(){return this._cells},set:function(t){this._cells=t}},{key:"length",get:function(){return this.cells.length}}]),e}(at),ct=function(r){function e(n){var t;return(t=r.call(this)||this)._rows=void 0,t._length=void 0,t.rows=n instanceof Array?n:n instanceof ut?[n]:[],t}return m(e,r),e.prototype.toArray=function(){return this.rows.map(function(n){return n.toArray()})},e.fromRows=function(n){return new e(n.map(function(t){return ut.fromCells(t.cells)}))},e.fromArray=function(n){return new e((n=function(t){return!t[0]||t[0]instanceof Array?t:[t]}(n)).map(function(t){return new ut(t.map(function(i){return new lt(i)}))}))},k(e,[{key:"rows",get:function(){return this._rows},set:function(n){this._rows=n}},{key:"length",get:function(){return this._length||this.rows.length},set:function(n){this._length=n}}]),e}(at),pt=function(){function r(){this.callbacks=void 0}var e=r.prototype;return e.init=function(n){this.callbacks||(this.callbacks={}),n&&!this.callbacks[n]&&(this.callbacks[n]=[])},e.on=function(n,t){return this.init(n),this.callbacks[n].push(t),this},e.off=function(n,t){var i=n;return this.init(),this.callbacks[i]&&this.callbacks[i].length!==0?(this.callbacks[i]=this.callbacks[i].filter(function(o){return o!=t}),this):this},e.emit=function(n){var t=arguments,i=n;return this.init(i),this.callbacks[i].length>0&&(this.callbacks[i].forEach(function(o){return o.apply(void 0,[].slice.call(t,1))}),!0)},r}();(function(r){r[r.Initiator=0]="Initiator",r[r.ServerFilter=1]="ServerFilter",r[r.ServerSort=2]="ServerSort",r[r.ServerLimit=3]="ServerLimit",r[r.Extractor=4]="Extractor",r[r.Transformer=5]="Transformer",r[r.Filter=6]="Filter",r[r.Sort=7]="Sort",r[r.Limit=8]="Limit"})(I||(I={}));var j=function(r){function e(t){var i;return(i=r.call(this)||this).id=void 0,i._props=void 0,i._props={},i.id=Zt(),t&&i.setProps(t),i}m(e,r);var n=e.prototype;return n.process=function(){var t=[].slice.call(arguments);this.validateProps instanceof Function&&this.validateProps.apply(this,t),this.emit.apply(this,["beforeProcess"].concat(t));var i=this._process.apply(this,t);return this.emit.apply(this,["afterProcess"].concat(t)),i},n.setProps=function(t){return Object.assign(this._props,t),this.emit("propsUpdated",this),this},k(e,[{key:"props",get:function(){return this._props}}]),e}(pt),Pe=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype._process=function(n){return this.props.keyword?(t=String(this.props.keyword).trim(),i=this.props.columns,o=this.props.ignoreHiddenColumns,s=n,l=this.props.selector,t=t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),new ct(s.rows.filter(function(u,d){return u.cells.some(function(a,g){if(!a||o&&i&&i[g]&&typeof i[g]=="object"&&i[g].hidden)return!1;var h="";if(typeof l=="function")h=l(a.data,d,g);else if(typeof a.data=="object"){var c=a.data;c&&c.props&&c.props.content&&(h=c.props.content)}else h=String(a.data);return new RegExp(t,"gi").test(h)})}))):n;var t,i,o,s,l},k(e,[{key:"type",get:function(){return I.Filter}}]),e}(j);function y(){var r="gridjs";return""+r+[].slice.call(arguments).reduce(function(e,n){return e+"-"+n},"")}function x(){return[].slice.call(arguments).filter(function(r){return r}).reduce(function(r,e){return(r||"")+" "+e},"").trim()||null}var Z,bt=function(r){function e(t){var i;return(i=r.call(this)||this)._state=void 0,i.dispatcher=void 0,i.dispatcher=t,i._state=i.getInitialState(),t.register(i._handle.bind(V(i))),i}m(e,r);var n=e.prototype;return n._handle=function(t){this.handle(t.type,t.payload)},n.setState=function(t){var i=this._state;this._state=t,this.emit("updated",t,i)},k(e,[{key:"state",get:function(){return this._state}}]),e}(pt),Ee=function(r){function e(){return r.apply(this,arguments)||this}m(e,r);var n=e.prototype;return n.getInitialState=function(){return{keyword:null}},n.handle=function(t,i){t==="SEARCH_KEYWORD"&&this.search(i.keyword)},n.search=function(t){this.setState({keyword:t})},e}(bt),wt=function(){function r(e){this.dispatcher=void 0,this.dispatcher=e}return r.prototype.dispatch=function(e,n){this.dispatcher.dispatch({type:e,payload:n})},r}(),Ne=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype.search=function(n){this.dispatch("SEARCH_KEYWORD",{keyword:n})},e}(wt),Kt=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype._process=function(n){if(!this.props.keyword)return n;var t={};return this.props.url&&(t.url=this.props.url(n.url,this.props.keyword)),this.props.body&&(t.body=this.props.body(n.body,this.props.keyword)),C({},n,t)},k(e,[{key:"type",get:function(){return I.ServerFilter}}]),e}(j),L=new(function(){function r(){}var e=r.prototype;return e.format=function(n,t){return"[Grid.js] ["+t.toUpperCase()+"]: "+n},e.error=function(n,t){t===void 0&&(t=!1);var i=this.format(n,"error");if(t)throw Error(i);console.error(i)},e.warn=function(n){console.warn(this.format(n,"warn"))},e.info=function(n){console.info(this.format(n,"info"))},r}()),Ct=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e}(E);w.PluginPosition=void 0,(Z=w.PluginPosition||(w.PluginPosition={}))[Z.Header=0]="Header",Z[Z.Footer=1]="Footer",Z[Z.Cell=2]="Cell";var Ie=function(){function r(){this.plugins=void 0,this.plugins=[]}var e=r.prototype;return e.get=function(n){var t=this.plugins.filter(function(i){return i.id===n});return t.length>0?t[0]:null},e.add=function(n){return n.id?this.get(n.id)!==null?(L.error("Duplicate plugin ID: "+n.id),this):(this.plugins.push(n),this):(L.error("Plugin ID cannot be empty"),this)},e.remove=function(n){return this.plugins.splice(this.plugins.indexOf(this.get(n)),1),this},e.list=function(n){var t;return t=n!=null||n!=null?this.plugins.filter(function(i){return i.position===n}):this.plugins,t.sort(function(i,o){return i.order-o.order})},r}(),ht=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype.render=function(){var n=this;if(this.props.pluginId){var t=this.config.plugin.get(this.props.pluginId);return t?p(M,{},p(t.component,C({plugin:t},t.props,this.props.props))):null}return this.props.position!==void 0?p(M,{},this.config.plugin.list(this.props.position).map(function(i){return p(i.component,C({plugin:i},i.props,n.props.props))})):null},e}(E),Vt=function(r){function e(t,i){var o;(o=r.call(this,t,i)||this).searchProcessor=void 0,o.actions=void 0,o.store=void 0,o.storeUpdatedFn=void 0,o.actions=new Ne(o.config.dispatcher),o.store=new Ee(o.config.dispatcher);var s,l=t.keyword;return t.enabled&&(l&&o.actions.search(l),o.storeUpdatedFn=o.storeUpdated.bind(V(o)),o.store.on("updated",o.storeUpdatedFn),s=t.server?new Kt({keyword:t.keyword,url:t.server.url,body:t.server.body}):new Pe({keyword:t.keyword,columns:o.config.header&&o.config.header.columns,ignoreHiddenColumns:t.ignoreHiddenColumns||t.ignoreHiddenColumns===void 0,selector:t.selector}),o.searchProcessor=s,o.config.pipeline.register(s)),o}m(e,r);var n=e.prototype;return n.componentWillUnmount=function(){this.config.pipeline.unregister(this.searchProcessor),this.store.off("updated",this.storeUpdatedFn)},n.storeUpdated=function(t){this.searchProcessor.setProps({keyword:t.keyword})},n.onChange=function(t){this.actions.search(t.target.value)},n.render=function(){if(!this.props.enabled)return null;var t,i,o,s=this.onChange.bind(this);return this.searchProcessor instanceof Kt&&(t=s,i=this.props.debounceTimeout,s=function(){var l=arguments;return new Promise(function(u){o&&clearTimeout(o),o=setTimeout(function(){return u(t.apply(void 0,[].slice.call(l)))},i)})}),p("div",{className:y(x("search",this.config.className.search))},p("input",{type:"search",placeholder:this._("search.placeholder"),"aria-label":this._("search.placeholder"),onInput:s,className:x(y("input"),y("search","input")),value:this.store.state.keyword}))},e}(Ct);Vt.defaultProps={debounceTimeout:250};var De=function(r){function e(){return r.apply(this,arguments)||this}m(e,r);var n=e.prototype;return n.validateProps=function(){if(isNaN(Number(this.props.limit))||isNaN(Number(this.props.page)))throw Error("Invalid parameters passed")},n._process=function(t){var i=this.props.page;return new ct(t.rows.slice(i*this.props.limit,(i+1)*this.props.limit))},k(e,[{key:"type",get:function(){return I.Limit}}]),e}(j),Fe=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype._process=function(n){var t={};return this.props.url&&(t.url=this.props.url(n.url,this.props.page,this.props.limit)),this.props.body&&(t.body=this.props.body(n.body,this.props.page,this.props.limit)),C({},n,t)},k(e,[{key:"type",get:function(){return I.ServerLimit}}]),e}(j),Qt=function(r){function e(t,i){var o;return(o=r.call(this,t,i)||this).processor=void 0,o.onUpdateFn=void 0,o.setTotalFromTabularFn=void 0,o.state={limit:t.limit,page:t.page||0,total:0},o}m(e,r);var n=e.prototype;return n.componentWillMount=function(){var t,i=this;this.props.enabled&&(this.setTotalFromTabularFn=this.setTotalFromTabular.bind(this),this.props.server?(t=new Fe({limit:this.state.limit,page:this.state.page,url:this.props.server.url,body:this.props.server.body}),this.config.pipeline.on("afterProcess",this.setTotalFromTabularFn)):(t=new De({limit:this.state.limit,page:this.state.page})).on("beforeProcess",this.setTotalFromTabularFn),this.processor=t,this.config.pipeline.register(t),this.config.pipeline.on("error",function(){i.setState({total:0,page:0})}))},n.setTotalFromTabular=function(t){this.setTotal(t.length)},n.onUpdate=function(t){this.props.resetPageOnUpdate&&t!==this.processor&&this.setPage(0)},n.componentDidMount=function(){this.onUpdateFn=this.onUpdate.bind(this),this.config.pipeline.on("updated",this.onUpdateFn)},n.componentWillUnmount=function(){this.config.pipeline.unregister(this.processor),this.config.pipeline.off("updated",this.onUpdateFn)},n.setPage=function(t){if(t>=this.pages||t<0||t===this.state.page)return null;this.setState({page:t}),this.processor.setProps({page:t})},n.setTotal=function(t){this.setState({total:t})},n.renderPages=function(){var t=this;if(this.props.buttonsCount<=0)return null;var i=Math.min(this.pages,this.props.buttonsCount),o=Math.min(this.state.page,Math.floor(i/2));return this.state.page+Math.floor(i/2)>=this.pages&&(o=i-(this.pages-this.state.page)),p(M,null,this.pages>i&&this.state.page-o>0&&p(M,null,p("button",{tabIndex:0,role:"button",onClick:this.setPage.bind(this,0),title:this._("pagination.firstPage"),"aria-label":this._("pagination.firstPage"),className:this.config.className.paginationButton},this._("1")),p("button",{tabIndex:-1,className:x(y("spread"),this.config.className.paginationButton)},"...")),Array.from(Array(i).keys()).map(function(s){return t.state.page+(s-o)}).map(function(s){return p("button",{tabIndex:0,role:"button",onClick:t.setPage.bind(t,s),className:x(t.state.page===s?x(y("currentPage"),t.config.className.paginationButtonCurrent):null,t.config.className.paginationButton),title:t._("pagination.page",s+1),"aria-label":t._("pagination.page",s+1)},t._(""+(s+1)))}),this.pages>i&&this.pages>this.state.page+o+1&&p(M,null,p("button",{tabIndex:-1,className:x(y("spread"),this.config.className.paginationButton)},"..."),p("button",{tabIndex:0,role:"button",onClick:this.setPage.bind(this,this.pages-1),title:this._("pagination.page",this.pages),"aria-label":this._("pagination.page",this.pages),className:this.config.className.paginationButton},this._(""+this.pages))))},n.renderSummary=function(){return p(M,null,this.props.summary&&this.state.total>0&&p("div",{role:"status","aria-live":"polite",className:x(y("summary"),this.config.className.paginationSummary),title:this._("pagination.navigate",this.state.page+1,this.pages)},this._("pagination.showing")," ",p("b",null,this._(""+(this.state.page*this.state.limit+1)))," ",this._("pagination.to")," ",p("b",null,this._(""+Math.min((this.state.page+1)*this.state.limit,this.state.total)))," ",this._("pagination.of")," ",p("b",null,this._(""+this.state.total))," ",this._("pagination.results")))},n.render=function(){return this.props.enabled?p("div",{className:x(y("pagination"),this.config.className.pagination)},this.renderSummary(),p("div",{className:y("pages")},this.props.prevButton&&p("button",{tabIndex:0,role:"button",disabled:this.state.page===0,onClick:this.setPage.bind(this,this.state.page-1),title:this._("pagination.previous"),"aria-label":this._("pagination.previous"),className:x(this.config.className.paginationButton,this.config.className.paginationButtonPrev)},this._("pagination.previous")),this.renderPages(),this.props.nextButton&&p("button",{tabIndex:0,role:"button",disabled:this.pages===this.state.page+1||this.pages===0,onClick:this.setPage.bind(this,this.state.page+1),title:this._("pagination.next"),"aria-label":this._("pagination.next"),className:x(this.config.className.paginationButton,this.config.className.paginationButtonNext)},this._("pagination.next")))):null},k(e,[{key:"pages",get:function(){return Math.ceil(this.state.total/this.state.limit)}}]),e}(Ct);function Ae(r,e){return typeof r=="string"?r.indexOf("%")>-1?e/100*parseInt(r,10):parseInt(r,10):r}function xt(r){return r?Math.floor(r)+"px":""}Qt.defaultProps={summary:!0,nextButton:!0,prevButton:!0,buttonsCount:3,limit:10,resetPageOnUpdate:!0};var Re=function(r){function e(t,i){var o;return(o=r.call(this,t,i)||this).tableElement=void 0,o.tableClassName=void 0,o.tableStyle=void 0,o.tableElement=o.props.tableRef.current.base.cloneNode(!0),o.tableElement.style.position="absolute",o.tableElement.style.width="100%",o.tableElement.style.zIndex="-2147483640",o.tableElement.style.visibility="hidden",o.tableClassName=o.tableElement.className,o.tableStyle=o.tableElement.style.cssText,o}m(e,r);var n=e.prototype;return n.widths=function(){this.tableElement.className=this.tableClassName+" "+y("shadowTable"),this.tableElement.style.tableLayout="auto",this.tableElement.style.width="auto",this.tableElement.style.padding="0",this.tableElement.style.margin="0",this.tableElement.style.border="none",this.tableElement.style.outline="none";var t=Array.from(this.base.parentNode.querySelectorAll("thead th")).reduce(function(i,o){var s;return o.style.width=o.clientWidth+"px",C(((s={})[o.getAttribute("data-column-id")]={minWidth:o.clientWidth},s),i)},{});return this.tableElement.className=this.tableClassName,this.tableElement.style.cssText=this.tableStyle,this.tableElement.style.tableLayout="auto",Array.from(this.base.parentNode.querySelectorAll("thead th")).reduce(function(i,o){return i[o.getAttribute("data-column-id")].width=o.clientWidth,i},t)},n.render=function(){var t=this;return this.props.tableRef.current?p("div",{ref:function(i){i&&i.appendChild(t.tableElement)}}):null},e}(E);function Te(r){if(!r)return"";var e=r.split(" ");return e.length===1&&/([a-z][A-Z])+/g.test(r)?r:e.map(function(n,t){return t==0?n.toLowerCase():n.charAt(0).toUpperCase()+n.slice(1).toLowerCase()}).join("")}var q=function(r){function e(){var t;return(t=r.call(this)||this)._columns=void 0,t._columns=[],t}m(e,r);var n=e.prototype;return n.adjustWidth=function(t){var i=t.container,o=t.tableRef,s=t.tempRef,l=t.tempRef||!0;if(!i)return this;var u=i.clientWidth,d={current:null},a={};if(o.current&&l){var g=p(Re,{tableRef:o});g.ref=d,tt(g,s.current),a=d.current.widths()}for(var h,c=F(e.tabularFormat(this.columns).reduce(function(P,v){return P.concat(v)},[]));!(h=c()).done;){var f=h.value;f.columns&&f.columns.length>0||(!f.width&&l?f.id in a&&(f.width=xt(a[f.id].width),f.minWidth=xt(a[f.id].minWidth)):f.width=xt(Ae(f.width,u)))}return o.current&&l&&tt(null,s.current),this},n.setSort=function(t,i){for(var o,s=F(i||this.columns||[]);!(o=s()).done;){var l=o.value;l.columns&&l.columns.length>0&&(l.sort={enabled:!1}),l.sort===void 0&&t.sort&&(l.sort={enabled:!0}),l.sort?typeof l.sort=="object"&&(l.sort=C({enabled:!0},l.sort)):l.sort={enabled:!1},l.columns&&this.setSort(t,l.columns)}},n.setFixedHeader=function(t,i){for(var o,s=F(i||this.columns||[]);!(o=s()).done;){var l=o.value;l.fixedHeader===void 0&&(l.fixedHeader=t.fixedHeader),l.columns&&this.setFixedHeader(t,l.columns)}},n.setResizable=function(t,i){for(var o,s=F(i||this.columns||[]);!(o=s()).done;){var l=o.value;l.resizable===void 0&&(l.resizable=t.resizable),l.columns&&this.setResizable(t,l.columns)}},n.setID=function(t){for(var i,o=F(t||this.columns||[]);!(i=o()).done;){var s=i.value;s.id||typeof s.name!="string"||(s.id=Te(s.name)),s.id||L.error('Could not find a valid ID for one of the columns. Make sure a valid "id" is set for all columns.'),s.columns&&this.setID(s.columns)}},n.populatePlugins=function(t,i){for(var o,s=F(i);!(o=s()).done;){var l=o.value;l.plugin!==void 0&&t.plugin.add(C({id:l.id,props:{}},l.plugin,{position:w.PluginPosition.Cell}))}},e.fromColumns=function(t){for(var i,o=new e,s=F(t);!(i=s()).done;){var l=i.value;if(typeof l=="string"||Tt(l))o.columns.push({name:l});else if(typeof l=="object"){var u=l;u.columns&&(u.columns=e.fromColumns(u.columns).columns),typeof u.plugin=="object"&&u.data===void 0&&(u.data=null),o.columns.push(l)}}return o},e.fromUserConfig=function(t){var i=new e;return t.from?i.columns=e.fromHTMLTable(t.from).columns:t.columns?i.columns=e.fromColumns(t.columns).columns:!t.data||typeof t.data[0]!="object"||t.data[0]instanceof Array||(i.columns=Object.keys(t.data[0]).map(function(o){return{name:o}})),i.columns.length?(i.setID(),i.setSort(t),i.setFixedHeader(t),i.setResizable(t),i.populatePlugins(t,i.columns),i):null},e.fromHTMLTable=function(t){for(var i,o=new e,s=F(t.querySelector("thead").querySelectorAll("th"));!(i=s()).done;){var l=i.value;o.columns.push({name:l.innerHTML,width:l.width})}return o},e.tabularFormat=function(t){var i=[],o=t||[],s=[];if(o&&o.length){i.push(o);for(var l,u=F(o);!(l=u()).done;){var d=l.value;d.columns&&d.columns.length&&(s=s.concat(d.columns))}s.length&&(i=i.concat(this.tabularFormat(s)))}return i},e.leafColumns=function(t){var i=[],o=t||[];if(o&&o.length)for(var s,l=F(o);!(s=l()).done;){var u=s.value;u.columns&&u.columns.length!==0||i.push(u),u.columns&&(i=i.concat(this.leafColumns(u.columns)))}return i},e.maximumDepth=function(t){return this.tabularFormat([t]).length-1},k(e,[{key:"columns",get:function(){return this._columns},set:function(t){this._columns=t}},{key:"visibleColumns",get:function(){return this._columns.filter(function(t){return!t.hidden})}}]),e}(at),te=function(){function r(){this._callbacks=void 0,this._isDispatching=void 0,this._isHandled=void 0,this._isPending=void 0,this._lastID=void 0,this._pendingPayload=void 0,this._callbacks={},this._isDispatching=!1,this._isHandled={},this._isPending={},this._lastID=1}var e=r.prototype;return e.register=function(n){var t="ID_"+this._lastID++;return this._callbacks[t]=n,t},e.unregister=function(n){if(!this._callbacks[n])throw Error("Dispatcher.unregister(...): "+n+" does not map to a registered callback.");delete this._callbacks[n]},e.waitFor=function(n){if(!this._isDispatching)throw Error("Dispatcher.waitFor(...): Must be invoked while dispatching.");for(var t=0;t<n.length;t++){var i=n[t];if(this._isPending[i]){if(!this._isHandled[i])throw Error(`Dispatcher.waitFor(...): Circular dependency detected while ' +
'waiting for `+i+".")}else{if(!this._callbacks[i])throw Error("Dispatcher.waitFor(...): "+i+" does not map to a registered callback.");this._invokeCallback(i)}}},e.dispatch=function(n){if(this._isDispatching)throw Error("Dispatch.dispatch(...): Cannot dispatch in the middle of a dispatch.");this._startDispatching(n);try{for(var t in this._callbacks)this._isPending[t]||this._invokeCallback(t)}finally{this._stopDispatching()}},e.isDispatching=function(){return this._isDispatching},e._invokeCallback=function(n){this._isPending[n]=!0,this._callbacks[n](this._pendingPayload),this._isHandled[n]=!0},e._startDispatching=function(n){for(var t in this._callbacks)this._isPending[t]=!1,this._isHandled[t]=!1;this._pendingPayload=n,this._isDispatching=!0},e._stopDispatching=function(){delete this._pendingPayload,this._isDispatching=!1},r}(),ee=function(){},ne=function(r){function e(t){var i;return(i=r.call(this)||this).data=void 0,i.set(t),i}m(e,r);var n=e.prototype;return n.get=function(){try{return Promise.resolve(this.data()).then(function(t){return{data:t,total:t.length}})}catch(t){return Promise.reject(t)}},n.set=function(t){return t instanceof Array?this.data=function(){return t}:t instanceof Function&&(this.data=t),this},e}(ee),re=function(r){function e(t){var i;return(i=r.call(this)||this).options=void 0,i.options=t,i}m(e,r);var n=e.prototype;return n.handler=function(t){return typeof this.options.handle=="function"?this.options.handle(t):t.ok?t.json():(L.error("Could not fetch data: "+t.status+" - "+t.statusText,!0),null)},n.get=function(t){var i=C({},this.options,t);return typeof i.data=="function"?i.data(i):fetch(i.url,i).then(this.handler.bind(this)).then(function(o){return{data:i.then(o),total:typeof i.total=="function"?i.total(o):void 0}})},e}(ee),Ue=function(){function r(){}return r.createFromUserConfig=function(e){var n=null;return e.data&&(n=new ne(e.data)),e.from&&(n=new ne(this.tableElementToArray(e.from)),e.from.style.display="none"),e.server&&(n=new re(e.server)),n||L.error("Could not determine the storage type",!0),n},r.tableElementToArray=function(e){for(var n,t,i=[],o=F(e.querySelector("tbody").querySelectorAll("tr"));!(n=o()).done;){for(var s,l=[],u=F(n.value.querySelectorAll("td"));!(s=u()).done;){var d=s.value;d.childNodes.length===1&&d.childNodes[0].nodeType===Node.TEXT_NODE?l.push((t=d.innerHTML,new DOMParser().parseFromString(t,"text/html").documentElement.textContent)):l.push(yt(d.innerHTML))}i.push(l)}return i},r}(),ie=typeof Symbol<"u"?Symbol.iterator||(Symbol.iterator=Symbol("Symbol.iterator")):"@@iterator";function A(r,e,n){if(!r.s){if(n instanceof K){if(!n.s)return void(n.o=A.bind(null,r,e));1&e&&(e=n.s),n=n.v}if(n&&n.then)return void n.then(A.bind(null,r,e),A.bind(null,r,2));r.s=e,r.v=n;var t=r.o;t&&t(r)}}var K=function(){function r(){}return r.prototype.then=function(e,n){var t=new r,i=this.s;if(i){var o=1&i?e:n;if(o){try{A(t,1,o(this.v))}catch(s){A(t,2,s)}return t}return this}return this.o=function(s){try{var l=s.v;1&s.s?A(t,1,e?e(l):l):n?A(t,1,n(l)):A(t,2,l)}catch(u){A(t,2,u)}},t},r}();function oe(r){return r instanceof K&&1&r.s}var R,Le=function(r){function e(t){var i;return(i=r.call(this)||this)._steps=new Map,i.cache=new Map,i.lastProcessorIndexUpdated=-1,t&&t.forEach(function(o){return i.register(o)}),i}m(e,r);var n=e.prototype;return n.clearCache=function(){this.cache=new Map,this.lastProcessorIndexUpdated=-1},n.register=function(t,i){if(i===void 0&&(i=null),t.type===null)throw Error("Processor type is not defined");t.on("propsUpdated",this.processorPropsUpdated.bind(this)),this.addProcessorByPriority(t,i),this.afterRegistered(t)},n.unregister=function(t){if(t){var i=this._steps.get(t.type);i&&i.length&&(this._steps.set(t.type,i.filter(function(o){return o!=t})),this.emit("updated",t))}},n.addProcessorByPriority=function(t,i){var o=this._steps.get(t.type);if(!o){var s=[];this._steps.set(t.type,s),o=s}if(i===null||i<0)o.push(t);else if(o[i]){var l=o.slice(0,i-1),u=o.slice(i+1);this._steps.set(t.type,l.concat(t).concat(u))}else o[i]=t},n.getStepsByType=function(t){return this.steps.filter(function(i){return i.type===t})},n.getSortedProcessorTypes=function(){return Object.keys(I).filter(function(t){return!isNaN(Number(t))}).map(function(t){return Number(t)})},n.process=function(t){try{var i=this,o=function(a){return i.lastProcessorIndexUpdated=l.length,i.emit("afterProcess",u),u},s=i.lastProcessorIndexUpdated,l=i.steps,u=t,d=function(a,g){try{var h=function(c,f,P){if(typeof c[ie]=="function"){var v,b,N,H=c[ie]();if(function U(O){try{for(;!(v=H.next()).done;)if((O=f(v.value))&&O.then){if(!oe(O))return void O.then(U,N||(N=A.bind(null,b=new K,2)));O=O.v}b?A(b,1,O):b=O}catch(ve){A(b||(b=new K),2,ve)}}(),H.return){var S=function(U){try{v.done||H.return()}catch{}return U};if(b&&b.then)return b.then(S,function(U){throw S(U)});S()}return b}if(!("length"in c))throw new TypeError("Object is not iterable");for(var W=[],D=0;D<c.length;D++)W.push(c[D]);return function(U,O,ve){var $,ye,be=-1;return function rn(X){try{for(;++be<U.length;)if((X=O(be))&&X.then){if(!oe(X))return void X.then(rn,ye||(ye=A.bind(null,$=new K,2)));X=X.v}$?A($,1,X):$=X}catch(on){A($||($=new K),2,on)}}(),$}(W,function(U){return f(W[U])})}(l,function(c){var f=i.findProcessorIndexByID(c.id),P=function(){if(f>=s)return Promise.resolve(c.process(u)).then(function(v){i.cache.set(c.id,u=v)});u=i.cache.get(c.id)}();if(P&&P.then)return P.then(function(){})})}catch(c){return g(c)}return h&&h.then?h.then(void 0,g):h}(0,function(a){throw L.error(a),i.emit("error",u),a});return Promise.resolve(d&&d.then?d.then(o):o())}catch(a){return Promise.reject(a)}},n.findProcessorIndexByID=function(t){return this.steps.findIndex(function(i){return i.id==t})},n.setLastProcessorIndex=function(t){var i=this.findProcessorIndexByID(t.id);this.lastProcessorIndexUpdated>i&&(this.lastProcessorIndexUpdated=i)},n.processorPropsUpdated=function(t){this.setLastProcessorIndex(t),this.emit("propsUpdated"),this.emit("updated",t)},n.afterRegistered=function(t){this.setLastProcessorIndex(t),this.emit("afterRegister"),this.emit("updated",t)},k(e,[{key:"steps",get:function(){for(var t,i=[],o=F(this.getSortedProcessorTypes());!(t=o()).done;){var s=this._steps.get(t.value);s&&s.length&&(i=i.concat(s))}return i.filter(function(l){return l})}}]),e}(pt),Be=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype._process=function(n){try{return Promise.resolve(this.props.storage.get(n))}catch(t){return Promise.reject(t)}},k(e,[{key:"type",get:function(){return I.Extractor}}]),e}(j),Me=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype._process=function(n){var t=ct.fromArray(n.data);return t.length=n.total,t},k(e,[{key:"type",get:function(){return I.Transformer}}]),e}(j),He=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype._process=function(){return Object.entries(this.props.serverStorageOptions).filter(function(n){return typeof n[1]!="function"}).reduce(function(n,t){var i;return C({},n,((i={})[t[0]]=t[1],i))},{})},k(e,[{key:"type",get:function(){return I.Initiator}}]),e}(j),Oe=function(r){function e(){return r.apply(this,arguments)||this}m(e,r);var n=e.prototype;return n.castData=function(t){if(!t||!t.length)return[];if(!this.props.header||!this.props.header.columns)return t;var i=q.leafColumns(this.props.header.columns);return t[0]instanceof Array?t.map(function(o){var s=0;return i.map(function(l,u){return l.data!==void 0?(s++,typeof l.data=="function"?l.data(o):l.data):o[u-s]})}):typeof t[0]!="object"||t[0]instanceof Array?[]:t.map(function(o){return i.map(function(s,l){return s.data!==void 0?typeof s.data=="function"?s.data(o):s.data:s.id?o[s.id]:(L.error("Could not find the correct cell for column at position "+l+`.
Make sure either 'id' or 'selector' is defined for all columns.`),null)})})},n._process=function(t){return{data:this.castData(t.data),total:t.total}},k(e,[{key:"type",get:function(){return I.Transformer}}]),e}(j),je=function(){function r(){}return r.createFromConfig=function(e){var n=new Le;return e.storage instanceof re&&n.register(new He({serverStorageOptions:e.server})),n.register(new Be({storage:e.storage})),n.register(new Oe({header:e.header})),n.register(new Me),n},r}(),se=function(){function r(n){this._userConfig=void 0,Object.assign(this,C({},r.defaultConfig(),n)),this._userConfig={}}var e=r.prototype;return e.assign=function(n){for(var t=0,i=Object.keys(n);t<i.length;t++){var o=i[t];o!=="_userConfig"&&(this[o]=n[o])}return this},e.update=function(n){return n?(this._userConfig=C({},this._userConfig,n),this.assign(r.fromUserConfig(this._userConfig)),this):this},r.defaultConfig=function(){return{plugin:new Ie,dispatcher:new te,tableRef:{current:null},tempRef:{current:null},width:"100%",height:"auto",autoWidth:!0,style:{},className:{}}},r.fromUserConfig=function(n){var t=new r(n);return t._userConfig=n,typeof n.sort=="boolean"&&n.sort&&t.assign({sort:{multiColumn:!0}}),t.assign({header:q.fromUserConfig(t)}),t.assign({storage:Ue.createFromUserConfig(n)}),t.assign({pipeline:je.createFromConfig(t)}),t.assign({translator:new ke(n.language)}),t.plugin.add({id:"search",position:w.PluginPosition.Header,component:Vt,props:C({enabled:n.search===!0||n.search instanceof Object},n.search)}),t.plugin.add({id:"pagination",position:w.PluginPosition.Footer,component:Qt,props:C({enabled:n.pagination===!0||n.pagination instanceof Object},n.pagination)}),n.plugins&&n.plugins.forEach(function(i){return t.plugin.add(i)}),t},r}();(function(r){r[r.Init=0]="Init",r[r.Loading=1]="Loading",r[r.Loaded=2]="Loaded",r[r.Rendered=3]="Rendered",r[r.Error=4]="Error"})(R||(R={}));var St,T,kt,ae,le=function(r){function e(){return r.apply(this,arguments)||this}m(e,r);var n=e.prototype;return n.content=function(){return this.props.column&&typeof this.props.column.formatter=="function"?this.props.column.formatter(this.props.cell.data,this.props.row,this.props.column):this.props.column&&this.props.column.plugin?p(ht,{pluginId:this.props.column.id,props:{column:this.props.column,cell:this.props.cell,row:this.props.row}}):this.props.cell.data},n.handleClick=function(t){this.props.messageCell||this.config.eventEmitter.emit("cellClick",t,this.props.cell,this.props.column,this.props.row)},n.getCustomAttributes=function(t){return t?typeof t.attributes=="function"?t.attributes(this.props.cell.data,this.props.row,this.props.column):t.attributes:{}},n.render=function(){return p("td",C({role:this.props.role,colSpan:this.props.colSpan,"data-column-id":this.props.column&&this.props.column.id,className:x(y("td"),this.props.className,this.config.className.td),style:C({},this.props.style,this.config.style.td),onClick:this.handleClick.bind(this)},this.getCustomAttributes(this.props.column)),this.content())},e}(E),Pt=function(r){function e(){return r.apply(this,arguments)||this}m(e,r);var n=e.prototype;return n.getColumn=function(t){if(this.props.header){var i=q.leafColumns(this.props.header.columns);if(i)return i[t]}return null},n.handleClick=function(t){this.props.messageRow||this.config.eventEmitter.emit("rowClick",t,this.props.row)},n.getChildren=function(){var t=this;return this.props.children?this.props.children:p(M,null,this.props.row.cells.map(function(i,o){var s=t.getColumn(o);return s&&s.hidden?null:p(le,{key:i.id,cell:i,row:t.props.row,column:s})}))},n.render=function(){return p("tr",{className:x(y("tr"),this.config.className.tr),onClick:this.handleClick.bind(this)},this.getChildren())},e}(E),Et=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype.render=function(){return p(Pt,{messageRow:!0},p(le,{role:"alert",colSpan:this.props.colSpan,messageCell:!0,cell:new lt(this.props.message),className:x(y("message"),this.props.className?this.props.className:null)}))},e}(E),Ge=function(r){function e(){return r.apply(this,arguments)||this}m(e,r);var n=e.prototype;return n.headerLength=function(){return this.props.header?this.props.header.visibleColumns.length:0},n.render=function(){var t=this;return p("tbody",{className:x(y("tbody"),this.config.className.tbody)},this.props.data&&this.props.data.rows.map(function(i){return p(Pt,{key:i.id,row:i,header:t.props.header})}),this.props.status===R.Loading&&(!this.props.data||this.props.data.length===0)&&p(Et,{message:this._("loading"),colSpan:this.headerLength(),className:x(y("loading"),this.config.className.loading)}),this.props.status===R.Rendered&&this.props.data&&this.props.data.length===0&&p(Et,{message:this._("noRecordsFound"),colSpan:this.headerLength(),className:x(y("notfound"),this.config.className.notfound)}),this.props.status===R.Error&&p(Et,{message:this._("error"),colSpan:this.headerLength(),className:x(y("error"),this.config.className.error)}))},e}(E),We=function(r){function e(){return r.apply(this,arguments)||this}m(e,r);var n=e.prototype;return n.validateProps=function(){for(var t,i=F(this.props.columns);!(t=i()).done;){var o=t.value;o.direction===void 0&&(o.direction=1),o.direction!==1&&o.direction!==-1&&L.error("Invalid sort direction "+o.direction)}},n.compare=function(t,i){return t>i?1:t<i?-1:0},n.compareWrapper=function(t,i){for(var o,s=0,l=F(this.props.columns);!(o=l()).done;){var u=o.value;if(s!==0)break;var d=t.cells[u.index].data,a=i.cells[u.index].data;s|=typeof u.compare=="function"?u.compare(d,a)*u.direction:this.compare(d,a)*u.direction}return s},n._process=function(t){var i=[].concat(t.rows);i.sort(this.compareWrapper.bind(this));var o=new ct(i);return o.length=t.length,o},k(e,[{key:"type",get:function(){return I.Sort}}]),e}(j),Xe=function(r){function e(){return r.apply(this,arguments)||this}m(e,r);var n=e.prototype;return n.getInitialState=function(){return[]},n.handle=function(t,i){t==="SORT_COLUMN"?this.sortColumn(i.index,i.direction,i.multi,i.compare):t==="SORT_COLUMN_TOGGLE"&&this.sortToggle(i.index,i.multi,i.compare)},n.sortToggle=function(t,i,o){var s=[].concat(this.state).find(function(l){return l.index===t});this.sortColumn(t,s&&s.direction===1?-1:1,i,o)},n.sortColumn=function(t,i,o,s){var l=[].concat(this.state),u=l.length,d=l.find(function(v){return v.index===t}),a=!1,g=!1,h=!1,c=!1;if(d!==void 0?o?d.direction===-1?h=!0:c=!0:u===1?c=!0:u>1&&(g=!0,a=!0):u===0?a=!0:u>0&&!o?(a=!0,g=!0):u>0&&o&&(a=!0),g&&(l=[]),a)l.push({index:t,direction:i,compare:s});else if(c){var f=l.indexOf(d);l[f].direction=i}else if(h){var P=l.indexOf(d);l.splice(P,1)}this.setState(l)},e}(bt),ze=function(r){function e(){return r.apply(this,arguments)||this}m(e,r);var n=e.prototype;return n.sortColumn=function(t,i,o,s){this.dispatch("SORT_COLUMN",{index:t,direction:i,multi:o,compare:s})},n.sortToggle=function(t,i,o){this.dispatch("SORT_COLUMN_TOGGLE",{index:t,multi:i,compare:o})},e}(wt),$e=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype._process=function(n){var t={};return this.props.url&&(t.url=this.props.url(n.url,this.props.columns)),this.props.body&&(t.body=this.props.body(n.body,this.props.columns)),C({},n,t)},k(e,[{key:"type",get:function(){return I.ServerSort}}]),e}(j),Ye=function(r){function e(t,i){var o;return(o=r.call(this,t,i)||this).sortProcessor=void 0,o.actions=void 0,o.store=void 0,o.updateStateFn=void 0,o.updateSortProcessorFn=void 0,o.actions=new ze(o.config.dispatcher),o.store=new Xe(o.config.dispatcher),t.enabled&&(o.sortProcessor=o.getOrCreateSortProcessor(),o.updateStateFn=o.updateState.bind(V(o)),o.store.on("updated",o.updateStateFn),o.state={direction:0}),o}m(e,r);var n=e.prototype;return n.componentWillUnmount=function(){this.config.pipeline.unregister(this.sortProcessor),this.store.off("updated",this.updateStateFn),this.updateSortProcessorFn&&this.store.off("updated",this.updateSortProcessorFn)},n.updateState=function(){var t=this,i=this.store.state.find(function(o){return o.index===t.props.index});this.setState(i?{direction:i.direction}:{direction:0})},n.updateSortProcessor=function(t){this.sortProcessor.setProps({columns:t})},n.getOrCreateSortProcessor=function(){var t=I.Sort;this.config.sort&&typeof this.config.sort.server=="object"&&(t=I.ServerSort);var i,o=this.config.pipeline.getStepsByType(t);return o.length>0?i=o[0]:(this.updateSortProcessorFn=this.updateSortProcessor.bind(this),this.store.on("updated",this.updateSortProcessorFn),i=t===I.ServerSort?new $e(C({columns:this.store.state},this.config.sort.server)):new We({columns:this.store.state}),this.config.pipeline.register(i)),i},n.changeDirection=function(t){t.preventDefault(),t.stopPropagation(),this.actions.sortToggle(this.props.index,t.shiftKey===!0&&this.config.sort.multiColumn,this.props.compare)},n.render=function(){if(!this.props.enabled)return null;var t=this.state.direction,i="neutral";return t===1?i="asc":t===-1&&(i="desc"),p("button",{tabIndex:-1,"aria-label":this._("sort.sort"+(t===1?"Desc":"Asc")),title:this._("sort.sort"+(t===1?"Desc":"Asc")),className:x(y("sort"),y("sort",i),this.config.className.sort),onClick:this.changeDirection.bind(this)})},e}(E),Je=function(r){function e(){for(var t,i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return(t=r.call.apply(r,[this].concat(o))||this).moveFn=void 0,t.upFn=void 0,t}m(e,r);var n=e.prototype;return n.getPageX=function(t){return t instanceof MouseEvent?Math.floor(t.pageX):Math.floor(t.changedTouches[0].pageX)},n.start=function(t){var i,o,s,l,u;t.stopPropagation(),this.setState({offsetStart:parseInt(this.props.thRef.current.style.width,10)-this.getPageX(t)}),this.upFn=this.end.bind(this),this.moveFn=(i=this.move.bind(this),(o=10)===void 0&&(o=100),function(){var d=[].slice.call(arguments);s?(clearTimeout(l),l=setTimeout(function(){Date.now()-u>=o&&(i.apply(void 0,d),u=Date.now())},Math.max(o-(Date.now()-u),0))):(i.apply(void 0,d),u=Date.now(),s=!0)}),document.addEventListener("mouseup",this.upFn),document.addEventListener("touchend",this.upFn),document.addEventListener("mousemove",this.moveFn),document.addEventListener("touchmove",this.moveFn)},n.move=function(t){t.stopPropagation();var i=this.props.thRef.current;this.state.offsetStart+this.getPageX(t)>=parseInt(i.style.minWidth,10)&&(i.style.width=this.state.offsetStart+this.getPageX(t)+"px")},n.end=function(t){t.stopPropagation(),document.removeEventListener("mouseup",this.upFn),document.removeEventListener("mousemove",this.moveFn),document.removeEventListener("touchmove",this.moveFn),document.removeEventListener("touchend",this.upFn)},n.render=function(){return p("div",{className:x(y("th"),y("resizable")),onMouseDown:this.start.bind(this),onTouchStart:this.start.bind(this),onClick:function(t){return t.stopPropagation()}})},e}(E),Ze=function(r){function e(t,i){var o;return(o=r.call(this,t,i)||this).sortRef={current:null},o.thRef={current:null},o.state={style:{}},o}m(e,r);var n=e.prototype;return n.isSortable=function(){return this.props.column.sort.enabled},n.isResizable=function(){return this.props.column.resizable},n.onClick=function(t){t.stopPropagation(),this.isSortable()&&this.sortRef.current.changeDirection(t)},n.keyDown=function(t){this.isSortable()&&t.which===13&&this.onClick(t)},n.componentDidMount=function(){var t=this;setTimeout(function(){if(t.props.column.fixedHeader&&t.thRef.current){var i=t.thRef.current.offsetTop;typeof i=="number"&&t.setState({style:{top:i}})}},0)},n.content=function(){return this.props.column.name!==void 0?this.props.column.name:this.props.column.plugin!==void 0?p(ht,{pluginId:this.props.column.plugin.id,props:{column:this.props.column}}):null},n.getCustomAttributes=function(){var t=this.props.column;return t?typeof t.attributes=="function"?t.attributes(null,null,this.props.column):t.attributes:{}},n.render=function(){var t={};return this.isSortable()&&(t.tabIndex=0),p("th",C({ref:this.thRef,"data-column-id":this.props.column&&this.props.column.id,className:x(y("th"),this.isSortable()?y("th","sort"):null,this.props.column.fixedHeader?y("th","fixed"):null,this.config.className.th),onClick:this.onClick.bind(this),style:C({},this.config.style.th,{minWidth:this.props.column.minWidth,width:this.props.column.width},this.state.style,this.props.style),onKeyDown:this.keyDown.bind(this),rowSpan:this.props.rowSpan>1?this.props.rowSpan:void 0,colSpan:this.props.colSpan>1?this.props.colSpan:void 0},this.getCustomAttributes(),t),p("div",{className:y("th","content")},this.content()),this.isSortable()&&p(Ye,C({ref:this.sortRef,index:this.props.index},this.props.column.sort)),this.isResizable()&&this.props.index<this.config.header.visibleColumns.length-1&&p(Je,{column:this.props.column,thRef:this.thRef}))},e}(E),qe=function(r){function e(){return r.apply(this,arguments)||this}m(e,r);var n=e.prototype;return n.renderColumn=function(t,i,o,s){var l=function(u,d,a){var g=q.maximumDepth(u),h=a-d;return{rowSpan:Math.floor(h-g-g/h),colSpan:u.columns&&u.columns.length||1}}(t,i,s);return p(Ze,{column:t,index:o,colSpan:l.colSpan,rowSpan:l.rowSpan})},n.renderRow=function(t,i,o){var s=this,l=q.leafColumns(this.props.header.columns);return p(Pt,null,t.map(function(u){return u.hidden?null:s.renderColumn(u,i,l.indexOf(u),o)}))},n.renderRows=function(){var t=this,i=q.tabularFormat(this.props.header.columns);return i.map(function(o,s){return t.renderRow(o,s,i.length)})},n.render=function(){return this.props.header?p("thead",{key:this.props.header.id,className:x(y("thead"),this.config.className.thead)},this.renderRows()):null},e}(E),Ke=function(r){function e(){return r.apply(this,arguments)||this}return m(e,r),e.prototype.render=function(){return p("table",{role:"grid",className:x(y("table"),this.config.className.table),style:C({},this.config.style.table,{height:this.props.height})},p(qe,{header:this.props.header}),p(Ge,{data:this.props.data,status:this.props.status,header:this.props.header}))},e}(E),Ve=function(r){function e(t,i){var o;return(o=r.call(this,t,i)||this).headerRef={current:null},o.state={isActive:!0},o}m(e,r);var n=e.prototype;return n.componentDidMount=function(){this.headerRef.current.children.length===0&&this.setState({isActive:!1})},n.render=function(){return this.state.isActive?p("div",{ref:this.headerRef,className:x(y("head"),this.config.className.header),style:C({},this.config.style.header)},p(ht,{position:w.PluginPosition.Header})):null},e}(E),Qe=function(r){function e(t,i){var o;return(o=r.call(this,t,i)||this).footerRef={current:null},o.state={isActive:!0},o}m(e,r);var n=e.prototype;return n.componentDidMount=function(){this.footerRef.current.children.length===0&&this.setState({isActive:!1})},n.render=function(){return this.state.isActive?p("div",{ref:this.footerRef,className:x(y("footer"),this.config.className.footer),style:C({},this.config.style.footer)},p(ht,{position:w.PluginPosition.Footer})):null},e}(E),tn=function(r){function e(t,i){var o;return(o=r.call(this,t,i)||this).configContext=void 0,o.processPipelineFn=void 0,o.configContext=function(s,l){var u={__c:l="__cC"+Lt++,__:null,Consumer:function(d,a){return d.children(a)},Provider:function(d){var a,g;return this.getChildContext||(a=[],(g={})[l]=this,this.getChildContext=function(){return g},this.shouldComponentUpdate=function(h){this.props.value!==h.value&&a.some(_t)},this.sub=function(h){a.push(h);var c=h.componentWillUnmount;h.componentWillUnmount=function(){a.splice(a.indexOf(h),1),c&&c.call(h)}}),d.children}};return u.Provider.__=u.Consumer.contextType=u}(),o.state={status:R.Loading,header:t.header,data:null},o}m(e,r);var n=e.prototype;return n.processPipeline=function(){try{var t=this;t.props.config.eventEmitter.emit("beforeLoad"),t.setState({status:R.Loading});var i=function(o,s){try{var l=Promise.resolve(t.props.pipeline.process()).then(function(u){t.setState({data:u,status:R.Loaded}),t.props.config.eventEmitter.emit("load",u)})}catch(u){return s(u)}return l&&l.then?l.then(void 0,s):l}(0,function(o){L.error(o),t.setState({status:R.Error,data:null})});return Promise.resolve(i&&i.then?i.then(function(){}):void 0)}catch(o){return Promise.reject(o)}},n.componentDidMount=function(){try{var t=this,i=t.props.config;return Promise.resolve(t.processPipeline()).then(function(){i.header&&t.state.data&&t.state.data.length&&t.setState({header:i.header.adjustWidth(i)}),t.processPipelineFn=t.processPipeline.bind(t),t.props.pipeline.on("updated",t.processPipelineFn)})}catch(o){return Promise.reject(o)}},n.componentWillUnmount=function(){this.props.pipeline.off("updated",this.processPipelineFn)},n.componentDidUpdate=function(t,i){i.status!=R.Rendered&&this.state.status==R.Loaded&&(this.setState({status:R.Rendered}),this.props.config.eventEmitter.emit("ready"))},n.render=function(){return p(this.configContext.Provider,{value:this.props.config},p("div",{role:"complementary",className:x("gridjs",y("container"),this.state.status===R.Loading?y("loading"):null,this.props.config.className.container),style:C({},this.props.config.style.container,{width:this.props.width})},this.state.status===R.Loading&&p("div",{className:y("loading-bar")}),p(Ve,null),p("div",{className:y("wrapper"),style:{height:this.props.height}},p(Ke,{ref:this.props.config.tableRef,data:this.state.data,header:this.state.header,width:this.props.width,height:this.props.height,status:this.state.status})),p(Qe,null),p("div",{ref:this.props.config.tempRef,id:"gridjs-temp",className:y("temp")})))},e}(E),en=function(r){function e(t){var i;return(i=r.call(this)||this).config=void 0,i.plugin=void 0,i.config=new se({instance:V(i),eventEmitter:V(i)}).update(t),i.plugin=i.config.plugin,i}m(e,r);var n=e.prototype;return n.updateConfig=function(t){return this.config.update(t),this},n.createElement=function(){return p(tn,{config:this.config,pipeline:this.config.pipeline,header:this.config.header,width:this.config.width,height:this.config.height})},n.forceRender=function(){return this.config&&this.config.container||L.error("Container is empty. Make sure you call render() before forceRender()",!0),this.config.pipeline.clearCache(),tt(null,this.config.container),tt(this.createElement(),this.config.container),this},n.render=function(t){return t||L.error("Container element cannot be null",!0),t.childNodes.length>0?(L.error("The container element "+t+" is not empty. Make sure the container is empty and call render() again"),this):(this.config.container=t,tt(this.createElement(),t),this)},e}(pt),Nt=0,ue=[],dt=[],ce=_.__b,pe=_.__r,he=_.diffed,de=_.__c,fe=_.unmount;function me(r,e){_.__h&&_.__h(T,r,Nt||e),Nt=0;var n=T.__H||(T.__H={__:[],__h:[]});return r>=n.__.length&&n.__.push({__V:dt}),n.__[r]}function nn(){for(var r;r=ue.shift();)if(r.__P&&r.__H)try{r.__H.__h.forEach(ft),r.__H.__h.forEach(It),r.__H.__h=[]}catch(e){r.__H.__h=[],_.__e(e,r.__v)}}_.__b=function(r){T=null,ce&&ce(r)},_.__r=function(r){pe&&pe(r),St=0;var e=(T=r.__c).__H;e&&(kt===T?(e.__h=[],T.__h=[],e.__.forEach(function(n){n.__N&&(n.__=n.__N),n.__V=dt,n.__N=n.i=void 0})):(e.__h.forEach(ft),e.__h.forEach(It),e.__h=[])),kt=T},_.diffed=function(r){he&&he(r);var e=r.__c;e&&e.__H&&(e.__H.__h.length&&(ue.push(e)!==1&&ae===_.requestAnimationFrame||((ae=_.requestAnimationFrame)||function(n){var t,i=function(){clearTimeout(o),ge&&cancelAnimationFrame(t),setTimeout(n)},o=setTimeout(i,100);ge&&(t=requestAnimationFrame(i))})(nn)),e.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.__V!==dt&&(n.__=n.__V),n.i=void 0,n.__V=dt})),kt=T=null},_.__c=function(r,e){e.some(function(n){try{n.__h.forEach(ft),n.__h=n.__h.filter(function(t){return!t.__||It(t)})}catch(t){e.some(function(i){i.__h&&(i.__h=[])}),e=[],_.__e(t,n.__v)}}),de&&de(r,e)},_.unmount=function(r){fe&&fe(r);var e,n=r.__c;n&&n.__H&&(n.__H.__.forEach(function(t){try{ft(t)}catch(i){e=i}}),e&&_.__e(e,n.__v))};var ge=typeof requestAnimationFrame=="function";function ft(r){var e=T,n=r.__c;typeof n=="function"&&(r.__c=void 0,n()),T=e}function It(r){var e=T;r.__c=r.__(),T=e}function _e(r,e){return!r||r.length!==e.length||e.some(function(n,t){return n!==r[t]})}w.BaseActions=wt,w.BaseComponent=E,w.BaseStore=bt,w.Cell=lt,w.Component=Y,w.Config=se,w.Dispatcher=te,w.Grid=en,w.PluginBaseComponent=Ct,w.Row=ut,w.className=y,w.createElement=p,w.createRef=function(){return{current:null}},w.h=p,w.html=yt,w.useEffect=function(r,e){var n=me(St++,3);!_.__s&&_e(n.__H,e)&&(n.__=r,n.i=e,T.__H.__h.push(n))},w.useRef=function(r){return Nt=5,function(e,n){var t=me(St++,7);return _e(t.__H,n)?(t.__V=e(),t.i=n,t.__h=e,t.__V):t.__}(function(){return{current:r}},[])}})})(Dt,Dt.exports);var z=Dt.exports;const et=an(z);class ln{init(){this.GridjsTableInit()}GridjsTableInit(){document.getElementById("table-gridjs")&&new z.Grid({columns:[{name:"ID",formatter:function(B){return et.html('<span class="fw-semibold">'+B+"</span>")}},"Name",{name:"Email",formatter:function(B){return et.html('<a href="">'+B+"</a>")}},"Position","Company","Country",{name:"Actions",width:"120px",formatter:function(B){return et.html("<a href='#' class='text-reset text-decoration-underline'>Details</a>")}}],pagination:{limit:5},sort:!0,search:!0,data:[["11","Alice","alice@example.com","Software Engineer","ABC Company","United States"],["12","Bob","bob@example.com","Product Manager","XYZ Inc","Canada"],["13","Charlie","charlie@example.com","Data Analyst","123 Corp","Australia"],["14","David","david@example.com","UI/UX Designer","456 Ltd","United Kingdom"],["15","Eve","eve@example.com","Marketing Specialist","789 Enterprises","France"],["16","Frank","frank@example.com","HR Manager","ABC Company","Germany"],["17","Grace","grace@example.com","Financial Analyst","XYZ Inc","Japan"],["18","Hannah","hannah@example.com","Sales Representative","123 Corp","Brazil"],["19","Ian","ian@example.com","Software Developer","456 Ltd","India"],["20","Jane","jane@example.com","Operations Manager","789 Enterprises","China"]]}).render(document.getElementById("table-gridjs")),document.getElementById("table-pagination")&&new z.Grid({columns:[{name:"ID",width:"120px",formatter:function(B){return et.html('<a href="" class="fw-medium">'+B+"</a>")}},"Name","Date","Total",{name:"Actions",width:"100px",formatter:function(B){return et.html("<button type='button' class='btn btn-sm btn-light'>Details</button>")}}],pagination:{limit:5},data:[["#RB2320","Alice","07 Oct, 2024","$24.05"],["#RB8652","Bob","07 Oct, 2024","$26.15"],["#RB8520","Charlie","06 Oct, 2024","$21.25"],["#RB9512","David","05 Oct, 2024","$25.03"],["#RB7532","Eve","05 Oct, 2024","$22.61"],["#RB9632","Frank","04 Oct, 2024","$24.05"],["#RB7456","Grace","04 Oct, 2024","$26.15"],["#RB3002","Hannah","04 Oct, 2024","$21.25"],["#RB9857","Ian","03 Oct, 2024","$22.61"],["#RB2589","Jane","03 Oct, 2024","$25.03"]]}).render(document.getElementById("table-pagination")),document.getElementById("table-search")&&new z.Grid({columns:["Name","Email","Position","Company","Country"],pagination:{limit:5},search:!0,data:[["Alice","alice@example.com","Software Engineer","ABC Company","United States"],["Bob","bob@example.com","Product Manager","XYZ Inc","Canada"],["Charlie","charlie@example.com","Data Analyst","123 Corp","Australia"],["David","david@example.com","UI/UX Designer","456 Ltd","United Kingdom"],["Eve","eve@example.com","Marketing Specialist","789 Enterprises","France"],["Frank","frank@example.com","HR Manager","ABC Company","Germany"],["Grace","grace@example.com","Financial Analyst","XYZ Inc","Japan"],["Hannah","hannah@example.com","Sales Representative","123 Corp","Brazil"],["Ian","ian@example.com","Software Developer","456 Ltd","India"],["Jane","jane@example.com","Operations Manager","789 Enterprises","China"]]}).render(document.getElementById("table-search")),document.getElementById("table-sorting")&&new z.Grid({columns:["Name","Email","Position","Company","Country"],pagination:{limit:5},sort:!0,data:[["Alice","alice@example.com","Software Engineer","ABC Company","United States"],["Bob","bob@example.com","Product Manager","XYZ Inc","Canada"],["Charlie","charlie@example.com","Data Analyst","123 Corp","Australia"],["David","david@example.com","UI/UX Designer","456 Ltd","United Kingdom"],["Eve","eve@example.com","Marketing Specialist","789 Enterprises","France"],["Frank","frank@example.com","HR Manager","ABC Company","Germany"],["Grace","grace@example.com","Financial Analyst","XYZ Inc","Japan"],["Hannah","hannah@example.com","Sales Representative","123 Corp","Brazil"],["Ian","ian@example.com","Software Developer","456 Ltd","India"],["Jane","jane@example.com","Operations Manager","789 Enterprises","China"]]}).render(document.getElementById("table-sorting")),document.getElementById("table-loading-state")&&new z.Grid({columns:["Name","Email","Position","Company","Country"],pagination:{limit:5},sort:!0,data:function(){return new Promise(function(B){setTimeout(function(){B([["Alice","alice@example.com","Software Engineer","ABC Company","United States"],["Bob","bob@example.com","Product Manager","XYZ Inc","Canada"],["Charlie","charlie@example.com","Data Analyst","123 Corp","Australia"],["David","david@example.com","UI/UX Designer","456 Ltd","United Kingdom"],["Eve","eve@example.com","Marketing Specialist","789 Enterprises","France"],["Frank","frank@example.com","HR Manager","ABC Company","Germany"],["Grace","grace@example.com","Financial Analyst","XYZ Inc","Japan"],["Hannah","hannah@example.com","Sales Representative","123 Corp","Brazil"],["Ian","ian@example.com","Software Developer","456 Ltd","India"],["Jane","jane@example.com","Operations Manager","789 Enterprises","China"]])},2e3)})}}).render(document.getElementById("table-loading-state")),document.getElementById("table-fixed-header")&&new z.Grid({columns:["Name","Email","Position","Company","Country"],sort:!0,pagination:!0,fixedHeader:!0,height:"400px",data:[["Alice","alice@example.com","Software Engineer","ABC Company","United States"],["Bob","bob@example.com","Product Manager","XYZ Inc","Canada"],["Charlie","charlie@example.com","Data Analyst","123 Corp","Australia"],["David","david@example.com","UI/UX Designer","456 Ltd","United Kingdom"],["Eve","eve@example.com","Marketing Specialist","789 Enterprises","France"],["Frank","frank@example.com","HR Manager","ABC Company","Germany"],["Grace","grace@example.com","Financial Analyst","XYZ Inc","Japan"],["Hannah","hannah@example.com","Sales Representative","123 Corp","Brazil"],["Ian","ian@example.com","Software Developer","456 Ltd","India"],["Jane","jane@example.com","Operations Manager","789 Enterprises","China"]]}).render(document.getElementById("table-fixed-header")),document.getElementById("table-hidden-column")&&new z.Grid({columns:["Name","Email","Position","Company",{name:"Country",hidden:!0}],pagination:{limit:5},sort:!0,data:[["Alice","alice@example.com","Software Engineer","ABC Company","United States"],["Bob","bob@example.com","Product Manager","XYZ Inc","Canada"],["Charlie","charlie@example.com","Data Analyst","123 Corp","Australia"],["David","david@example.com","UI/UX Designer","456 Ltd","United Kingdom"],["Eve","eve@example.com","Marketing Specialist","789 Enterprises","France"],["Frank","frank@example.com","HR Manager","ABC Company","Germany"],["Grace","grace@example.com","Financial Analyst","XYZ Inc","Japan"],["Hannah","hannah@example.com","Sales Representative","123 Corp","Brazil"],["Ian","ian@example.com","Software Developer","456 Ltd","India"],["Jane","jane@example.com","Operations Manager","789 Enterprises","China"]]}).render(document.getElementById("table-hidden-column"))}}document.addEventListener("DOMContentLoaded",function(Ft){new ln().init()});