jspreadsheet 8.1.15 → 8.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Jspreadsheet v8.1.14
2
+ * Jspreadsheet v8.2.2
3
3
  *
4
4
  * Website: https://jspreadsheet.com
5
5
  * Description: Create amazing web based spreadsheets.
@@ -15,442 +15,446 @@ if (! jSuites && typeof(require) === 'function') {
15
15
  var jSuites = require('jsuites');
16
16
  }
17
17
 
18
- var $jscomp=$jscomp||{};$jscomp.scope={};$jscomp.arrayIteratorImpl=function(C){var H=0;return function(){return H<C.length?{done:!1,value:C[H++]}:{done:!0}}};$jscomp.arrayIterator=function(C){return{next:$jscomp.arrayIteratorImpl(C)}};$jscomp.ASSUME_ES5=!1;$jscomp.ASSUME_NO_NATIVE_MAP=!1;$jscomp.ASSUME_NO_NATIVE_SET=!1;$jscomp.SIMPLE_FROUND_POLYFILL=!1;$jscomp.ISOLATE_POLYFILLS=!1;$jscomp.FORCE_POLYFILL_PROMISE=!1;$jscomp.FORCE_POLYFILL_PROMISE_WHEN_NO_UNHANDLED_REJECTION=!1;
19
- $jscomp.defineProperty=$jscomp.ASSUME_ES5||"function"==typeof Object.defineProperties?Object.defineProperty:function(C,H,K){if(C==Array.prototype||C==Object.prototype)return C;C[H]=K.value;return C};$jscomp.getGlobal=function(C){C=["object"==typeof globalThis&&globalThis,C,"object"==typeof window&&window,"object"==typeof self&&self,"object"==typeof global&&global];for(var H=0;H<C.length;++H){var K=C[H];if(K&&K.Math==Math)return K}throw Error("Cannot find global object");};$jscomp.global=$jscomp.getGlobal(this);
20
- $jscomp.IS_SYMBOL_NATIVE="function"===typeof Symbol&&"symbol"===typeof Symbol("x");$jscomp.TRUST_ES6_POLYFILLS=!$jscomp.ISOLATE_POLYFILLS||$jscomp.IS_SYMBOL_NATIVE;$jscomp.polyfills={};$jscomp.propertyToPolyfillSymbol={};$jscomp.POLYFILL_PREFIX="$jscp$";var $jscomp$lookupPolyfilledValue=function(C,H){var K=$jscomp.propertyToPolyfillSymbol[H];if(null==K)return C[H];K=C[K];return void 0!==K?K:C[H]};
21
- $jscomp.polyfill=function(C,H,K,S){H&&($jscomp.ISOLATE_POLYFILLS?$jscomp.polyfillIsolated(C,H,K,S):$jscomp.polyfillUnisolated(C,H,K,S))};$jscomp.polyfillUnisolated=function(C,H,K,S){K=$jscomp.global;C=C.split(".");for(S=0;S<C.length-1;S++){var P=C[S];if(!(P in K))return;K=K[P]}C=C[C.length-1];S=K[C];H=H(S);H!=S&&null!=H&&$jscomp.defineProperty(K,C,{configurable:!0,writable:!0,value:H})};
22
- $jscomp.polyfillIsolated=function(C,H,K,S){var P=C.split(".");C=1===P.length;S=P[0];S=!C&&S in $jscomp.polyfills?$jscomp.polyfills:$jscomp.global;for(var Z=0;Z<P.length-1;Z++){var N=P[Z];if(!(N in S))return;S=S[N]}P=P[P.length-1];K=$jscomp.IS_SYMBOL_NATIVE&&"es6"===K?S[P]:null;H=H(K);null!=H&&(C?$jscomp.defineProperty($jscomp.polyfills,P,{configurable:!0,writable:!0,value:H}):H!==K&&(void 0===$jscomp.propertyToPolyfillSymbol[P]&&(K=1E9*Math.random()>>>0,$jscomp.propertyToPolyfillSymbol[P]=$jscomp.IS_SYMBOL_NATIVE?
23
- $jscomp.global.Symbol(P):$jscomp.POLYFILL_PREFIX+K+"$"+P),$jscomp.defineProperty(S,$jscomp.propertyToPolyfillSymbol[P],{configurable:!0,writable:!0,value:H})))};$jscomp.initSymbol=function(){};$jscomp.iteratorPrototype=function(C){C={next:C};C[Symbol.iterator]=function(){return this};return C};
24
- $jscomp.iteratorFromArray=function(C,H){C instanceof String&&(C+="");var K=0,S=!1,P={next:function(){if(!S&&K<C.length){var Z=K++;return{value:H(Z,C[Z]),done:!1}}S=!0;return{done:!0,value:void 0}}};P[Symbol.iterator]=function(){return P};return P};$jscomp.polyfill("Array.prototype.values",function(C){return C?C:function(){return $jscomp.iteratorFromArray(this,function(H,K){return K})}},"es8","es3");
25
- var _$_f495=["use strict","{","}","","8.1.15","Base","https://jspreadsheet.com","Unlicensed","Jspreadsheet Pro\r\n"," edition ","\r\n","set","=","undefined","number","fullscreen","block","string","readonly","jss_hidden_index","div","right","10px","pointer","/v8",",","localhost",".","v8"," (Expired)","Licensed to: ","Premium","License required","A valid license is required","This version is not included on the scope of this license","Your license is expired","jspreadsheet","img","/jspreadsheet/","logo.png",
26
- "none","status","data-x","data-y","px","X","goto","jss_scroll","jss_control","hidden","jss_freezed","get","colspan","center","300px","Jspreadsheet Pro","text","autocomplete","dropdown","GET","json","Jspreadsheet Alert: secureFormulas is set to false.","setConfig","insertRow","deleteRow","insertColumn","deleteColumn","moveRow","moveColumn","setMerge","removeMerge","setStyle","resetStyle","setWidth","setHeight","setHeader","setComments","setProperty","orderBy","setValue","renameWorksheet","moveWorksheet",
27
- "onundo","onredo","object","function","contextMenu","toolbar","Jspreadsheet: cursor not in the viewport","oneditionstart","oncreateeditor","jss_focus","jss_formula","oneditionend","data-mask","data-value","inputmode","0","style","jss_input","contentEditable","onevent","setRowId","onchangerowid","setBorder","resetBorders","updateCells","setFormula","updateData","onbeforesave","POST","Authorization","Bearer ","disconected",": ","Sorry, something went wrong, refreshing your spreadsheet...","_top","onsave",
28
- "persistence","?","?worksheet=","&worksheet=","add","remove","jss_cursor","selected","main","copying","onblur","onfocus","selection","onselection"," ","'","'!","!",":","jss_border","cloning","jss_border_","15","-2000px","#ccc","transparent","0px","tr","jss_group_container","td","&nbsp;",".jss_group","jss_group","+","width","Jspreadsheet: This column is part of a merged cell.","jss_dragging","1px","jss_helper_col","Jspreadsheet: This row is part of a merged cell","Jspreadsheet: Please clear your search before perform this action",
29
- "51px","jss_helper_row","No cell selected","Invalid merged properties","onmerge","rowspan","Column name","data-title","onchangeheader","jss_filters_icon","col","setFooter","onchangefooter","setFooterValue","onchangefootervalue","resetFooter","setNestedHeaders","onchangenested","jss_nested","resetNestedHeaders","setNestedCell","onchangenestedcell","data-nested-x","data-nested-y","align","calendar","-","00:00:00",'"',"g",'""',"\t","oncopy","copy","color: initial","JSS: For better results, please allow pagination or tableOverflow.",
30
- "onbeforepaste","onpaste","Export not allowed","\ufeff","text/csv;charset=utf-8;",".csv","a","download","setDefinedNames","#1a237e","#b71c1c","#880e4f","#1b5e20","#ff6f00","/","*","^","(","[","|","<",">","data-token","jss_picker","jss_object","input","contenteditable","active","last",'<b class="','" data-token="','">',"</b>","data-single","true","b","&",")","]","var "," = {};"," = ",";\n","; return ","onbeforeformula","#LOOP","Reference loop detected","#SELF","Self Reference detected","#ERROR","Table does not exist or is not loaded yet",
31
- "#SPILL!","#REF!","$","Something went wrong","onafterchanges","checkbox","autonumber","radio","email","url","color","progressbar","rating","onbeforechange","onchange","oncreatecell","values","mergeCells",";","title","jss_unlocked","oncreaterow","jss_row","Jspreadsheet: Invalid origin or destination","onmoverow","Jspreadsheet: Insert row is not enabled in the table configuration","onbeforeinsertrow","onbeforeinsertrow returned false","oninsertrow","Jspreadsheet: Delete row is not enabled in the table configuration",
18
+ var $jscomp=$jscomp||{};$jscomp.scope={};$jscomp.arrayIteratorImpl=function(B){var I=0;return function(){return I<B.length?{done:!1,value:B[I++]}:{done:!0}}};$jscomp.arrayIterator=function(B){return{next:$jscomp.arrayIteratorImpl(B)}};$jscomp.ASSUME_ES5=!1;$jscomp.ASSUME_NO_NATIVE_MAP=!1;$jscomp.ASSUME_NO_NATIVE_SET=!1;$jscomp.SIMPLE_FROUND_POLYFILL=!1;$jscomp.ISOLATE_POLYFILLS=!1;$jscomp.FORCE_POLYFILL_PROMISE=!1;$jscomp.FORCE_POLYFILL_PROMISE_WHEN_NO_UNHANDLED_REJECTION=!1;
19
+ $jscomp.defineProperty=$jscomp.ASSUME_ES5||"function"==typeof Object.defineProperties?Object.defineProperty:function(B,I,J){if(B==Array.prototype||B==Object.prototype)return B;B[I]=J.value;return B};$jscomp.getGlobal=function(B){B=["object"==typeof globalThis&&globalThis,B,"object"==typeof window&&window,"object"==typeof self&&self,"object"==typeof global&&global];for(var I=0;I<B.length;++I){var J=B[I];if(J&&J.Math==Math)return J}throw Error("Cannot find global object");};$jscomp.global=$jscomp.getGlobal(this);
20
+ $jscomp.IS_SYMBOL_NATIVE="function"===typeof Symbol&&"symbol"===typeof Symbol("x");$jscomp.TRUST_ES6_POLYFILLS=!$jscomp.ISOLATE_POLYFILLS||$jscomp.IS_SYMBOL_NATIVE;$jscomp.polyfills={};$jscomp.propertyToPolyfillSymbol={};$jscomp.POLYFILL_PREFIX="$jscp$";var $jscomp$lookupPolyfilledValue=function(B,I){var J=$jscomp.propertyToPolyfillSymbol[I];if(null==J)return B[I];J=B[J];return void 0!==J?J:B[I]};
21
+ $jscomp.polyfill=function(B,I,J,T){I&&($jscomp.ISOLATE_POLYFILLS?$jscomp.polyfillIsolated(B,I,J,T):$jscomp.polyfillUnisolated(B,I,J,T))};$jscomp.polyfillUnisolated=function(B,I,J,T){J=$jscomp.global;B=B.split(".");for(T=0;T<B.length-1;T++){var O=B[T];if(!(O in J))return;J=J[O]}B=B[B.length-1];T=J[B];I=I(T);I!=T&&null!=I&&$jscomp.defineProperty(J,B,{configurable:!0,writable:!0,value:I})};
22
+ $jscomp.polyfillIsolated=function(B,I,J,T){var O=B.split(".");B=1===O.length;T=O[0];T=!B&&T in $jscomp.polyfills?$jscomp.polyfills:$jscomp.global;for(var Z=0;Z<O.length-1;Z++){var M=O[Z];if(!(M in T))return;T=T[M]}O=O[O.length-1];J=$jscomp.IS_SYMBOL_NATIVE&&"es6"===J?T[O]:null;I=I(J);null!=I&&(B?$jscomp.defineProperty($jscomp.polyfills,O,{configurable:!0,writable:!0,value:I}):I!==J&&(void 0===$jscomp.propertyToPolyfillSymbol[O]&&(J=1E9*Math.random()>>>0,$jscomp.propertyToPolyfillSymbol[O]=$jscomp.IS_SYMBOL_NATIVE?
23
+ $jscomp.global.Symbol(O):$jscomp.POLYFILL_PREFIX+J+"$"+O),$jscomp.defineProperty(T,$jscomp.propertyToPolyfillSymbol[O],{configurable:!0,writable:!0,value:I})))};$jscomp.initSymbol=function(){};$jscomp.iteratorPrototype=function(B){B={next:B};B[Symbol.iterator]=function(){return this};return B};
24
+ $jscomp.iteratorFromArray=function(B,I){B instanceof String&&(B+="");var J=0,T=!1,O={next:function(){if(!T&&J<B.length){var Z=J++;return{value:I(Z,B[Z]),done:!1}}T=!0;return{done:!0,value:void 0}}};O[Symbol.iterator]=function(){return O};return O};$jscomp.polyfill("Array.prototype.values",function(B){return B?B:function(){return $jscomp.iteratorFromArray(this,function(I,J){return J})}},"es8","es3");
25
+ var _$_c0e3=["use strict","{","}","","8.2.3","Base","https://jspreadsheet.com","Unlicensed","Jspreadsheet Pro\r\n"," edition ","\r\n","set","=","undefined","number","fullscreen","block","string","readonly","jss_hidden_index","div","right","10px","pointer","/v8",",","localhost",".","v8"," (Expired)","Licensed to: ","Premium","License required","A valid license is required","This version is not included on the scope of this license","Your license is expired","jspreadsheet","img","/jspreadsheet/","logo.png",
26
+ "none","status","data-x","data-y","px","X","goto","jss_scroll","jss_control","hidden","jss_freezed","get","colspan","300px","Jspreadsheet Pro","text","autocomplete","dropdown","GET","json","Jspreadsheet Alert: secureFormulas is set to false.","setConfig","insertRow","deleteRow","insertColumn","deleteColumn","moveRow","moveColumn","setMerge","removeMerge","setStyle","resetStyle","setWidth","setHeight","setHeader","setComments","orderBy","setValue","setProperty","renameWorksheet","moveWorksheet","onundo",
27
+ "onredo","object","function","contextMenu","toolbar","onevent","Jspreadsheet: cursor not in the viewport","oneditionstart","oncreateeditor","jss_focus","jss_formula","oneditionend","data-mask","data-value","inputmode","0","style","jss_input","contentEditable","setRowId","onchangerowid","setBorder","resetBorders","updateCells","setFormula","updateData","onbeforesave","POST","Authorization","Bearer ","disconected",": ","Sorry, something went wrong, refreshing your spreadsheet...","_top","onsave","persistence",
28
+ "?","?worksheet=","&worksheet=","add","remove","jss_cursor","selected","main","copying","onblur","onfocus","onselection"," ","'","'!","!",":","jss_border","cloning","jss_border_","15","-2000px","#ccc","transparent","0px","tr","jss_group_container","td","&nbsp;",".jss_group","jss_group","+","width","Jspreadsheet: This column is part of a merged cell.","jss_dragging","1px","jss_helper_col","Jspreadsheet: This row is part of a merged cell","Jspreadsheet: Please clear your search before perform this action",
29
+ "51px","jss_helper_row","No cell selected","Invalid merged properties","onmerge","rowspan","Column name","data-title","onchangeheader","jss_filters_icon","col","setFooter","onchangefooter","setFooterValue","onchangefootervalue","resetFooter","setNestedHeaders","onchangenested","jss_nested","resetNestedHeaders","setNestedCell","onchangenestedcell","center","data-nested-x","data-nested-y","align","calendar","-","00:00:00",'"',"g",'""',"\t","oncopy","copy","color: initial","JSS: For better results, please allow pagination or tableOverflow.",
30
+ "onbeforepaste","onpaste","Export not allowed","\ufeff","text/csv;charset=utf-8;",".csv","a","download","setDefinedNames","#1a237e","#b71c1c","#880e4f","#1b5e20","#ff6f00","/","*","^","(","[","|","<",">",";","data-token","jss_picker","jss_object","input","contenteditable","active","last",'<b class="','" data-token="','">',"</b>","data-single","true","b","&",")","]","var "," = {};"," = ",";\n","; return ","onbeforeformula","#LOOP","Reference loop detected","#SELF","Self Reference detected","#ERROR",
31
+ "Table does not exist or is not loaded yet","CHART(","#SPILL!","#REF!","$","Something went wrong","onafterchanges","checkbox","autonumber","radio","email","url","color","progressbar","rating","onbeforechange","onchange","oncreatecell","values","mergeCells","title","jss_unlocked","oncreaterow","jss_row","Jspreadsheet: Invalid origin or destination","onmoverow","Jspreadsheet: Insert row is not enabled in the table configuration","onbeforeinsertrow","onbeforeinsertrow returned false","oninsertrow","Jspreadsheet: Delete row is not enabled in the table configuration",
32
32
  "onbeforedeleterow","onbeforedeleterow returned false","meta","cells","comments","ondeleterow","Jspreadsheet: Invalid origin","Jspreadsheet: Invalid destination","onmovecolumn","Jspreadsheet: Insert column is not enabled in the table configuration","onbeforeinsertcolumn","onbeforeinsertcolumn returned false","col_","oninsertcolumn","Jspreadsheet: Delete column is not enabled in the table configuration","Jspreadsheet: it is not possible to delete the last column","onbeforedeletecolumn","onbeforedeletecolumn returned false",
33
- "ondeletecolumn","Jspreadsheet: Column does not exists.","; ","onchangestyle","No cell provided","onresetstyle","onbeforecomments","oncomments","setMeta","onchangemeta","resetMeta","onresetmeta","arrow-down","percent","numeric","onbeforesort","This action will destroy any existing merged cells. Are you sure?","onsort","arrow-up","jss_pagination","Jspreadsheet: No pagination defined","Jspreadsheet: pagination not defined","onbeforechangepage","onchangepage","No records found","jss_page","jss_page_selected",
34
- "Showing page {0} of {1} entries","jss_content","wheel","selectstart","table","thead","tbody","tfoot","colgroup","50","jss_selectall","jss","cellpadding","cellspacing","unselectable","yes","jss_wrap","jss_overflow","jss_locked","jss_corner","on","onselectstart","return false","Y","jss_table","jss_table_container","Freeze columns cannot be greater than the number of available columns","rows","jss_container","jss_toolbar","jss_helper","jss_loading","textarea","jss_textarea","-1","bottom","Defined names are only available on the Premium edition.",
33
+ "ondeletecolumn","; ","onchangestyle","No cell provided","onresetstyle","onbeforecomments","oncomments","setMeta","onchangemeta","resetMeta","onresetmeta","arrow-down","percent","numeric","onbeforesort","This action will destroy any existing merged cells. Are you sure?","onsort","arrow-up","jss_pagination","Jspreadsheet: No pagination defined","Jspreadsheet: pagination not defined","onbeforechangepage","onchangepage","No records found","jss_page","jss_page_selected","Showing page {0} of {1} entries",
34
+ "jss_content","wheel","selectstart","table","thead","tbody","tfoot","colgroup","50","jss_selectall","jss","cellpadding","cellspacing","unselectable","yes","jss_wrap","jss_overflow","jss_locked","jss_corner","on","onselectstart","return false","Y","jss_table","jss_table_container","Freeze columns cannot be greater than the number of available columns","rows","jss_container","jss_toolbar","jss_helper","jss_loading","textarea","jss_textarea","-1","bottom","Defined names are only available on the Premium edition.",
35
35
  "beforeinit","Sheet","Worksheet clash name: ",". It is highly recommended to define a unique worksheetName on the initialization.","jss_worksheet","init","To improve the performance, use tableOverflow or pagination.","resize","touchstart","touchmove","touchend","onresizecolumn","onresizerow","label","jss_filters_active","Jspreadsheet: the filter is not enabled.","Blanks","onbeforefilter","onfilter","gi","jss_filters_options","INPUT","Search","jss_filters_search","button","Ok","jss_filters_apply",
36
36
  "jss_filters",'<input type="checkbox"> ',"Add current selection to filter",'<input type="checkbox"> (',"Select all","select","jss_pagination_dropdown","option","Show","entries","jss_search","onbeforesearch","onsearch","jss_search_container","jss_contextmenu","Mac","&#8984;","Ctrl","tabs","Rename this worksheet","Delete this worksheet","Are you sure?","line","nested","Rename this cell","header","row","cell","Cut","content_cut"," + X","Copy","content_copy"," + C","Paste","content_paste"," + V","Insert a new column before",
37
37
  "Insert a new column after","Delete selected columns","Rename this column","Create a new row","Order ascending","Order descending","Insert a new row before","Insert a new row after","Delete selected rows","Edit comments","Add comments","notes","Comments","Clear comments","Save as","save"," + S","About","info","with-toolbar","i","undo","redo","divisor","120px","Verdana","Arial","Courier New",'<span style="font-family:',"</span>","font-family","48px","format_size","x-small","small","medium","large",
38
38
  "x-large",'<span style="font-size:',"font-size","format_align_left","format_align_center","format_align_right","format_align_justify",'<i class="material-icons">',"</i>","text-align","_","format_bold","font-weight","bold","format_color_text","format_color_fill","background-color","height","50px","Normal","Medium","Large","Extra","jss_row_medium","jss_row_large","jss_row_extra","fullscreen_exit","Toggle Fullscreen","border_all","border_outer","border_inner","border_horizontal","border_vertical","border_left",
39
39
  "border_top","border_right","border_bottom","border_clear","black","border-left: ","px solid ","border-left: ; ","border-right: ","border-right: ; ","border-top: ","border-top: ; ","border-bottom: ","border-bottom: ; ","material-icons","color_lens",'<div style="height: ','px; width: 50px; background-color: black;"></div>',"80px","1","search","search_off","Toggle Search","onbeforecreateworksheet","There is one existing worksheet with the same name.","createWorksheet","oncreateworksheet","deleteWorksheet",
40
40
  "ondeleteworksheet","It was not possible to rename worksheet due conflict name","onrenameworksheet","onmoveworksheet","onopenworksheet","jss_","TABLE","Element is not a table","colgroup > col","data-celltype","readOnly","name","id",":scope > thead > tr",":scope > tr, :scope > tbody > tr","data-formula","class","styleBold","; font-weight:bold;","font-weight:bold;","tfoot tr","\r","\n","jss_ignore","THEAD","TBODY","TFOOT","selectall","header-group","jtabs-headers","filters","footer","jtoolbar","DIV",
41
- "data-current","html","jss_nowrap","insertHTML","<br/>\n","Process","A","mailto:","_blank","onclick","jclose","col-resize","row-resize","move","TD","Cloud plugin not loaded.","jtabs","jss_dialog","#","decimal","data-locale","%","jss_percent","\\[Red\\]","red","\\(","jss_notes","145px","tag","jss_dropdown_tags","jss_dropdown","multiple","image","<div class='jss_dropdown_icon' style='background-color: ","'></div>","orange","<div class='jss_dropdown_tag' style='background-color: ","'>","</div>","&lt;",
42
- "timepicker","YYYY-MM-DD","square","100px","false","FALSE","disabled","TRUE","jss_progressbar","min","max","jss_rating"," stars","star","href","IMG","round","100%","tabindex","jss_image","jpanel","jfile",'<img src="','" alt="">',"jss_richtext","jss_tags","40px","#NOTFOUND","<img src='","' class='round small' />","Jspreadsheet: worksheet not found "];
43
- (function(C,H){typeof exports===_$_f495[84]&&typeof module!==_$_f495[13]?module.exports=H():typeof define===_$_f495[85]&&define.amd?define(H):C.jspreadsheet=C.jexcel=H()})(this,function(){_$_f495[0];var C=function(k,c){k=jSuites.translate(k);if(c&&c.length)for(var b=0;b<c.length;b++)k=k.replace(_$_f495[1]+b+_$_f495[2],c[b]);return k},H=function(k,c){Array.isArray(k)&&(k=k[0]);k=k.replace(new RegExp(/'/g),_$_f495[3]).toUpperCase();if(void 0===c)return window[k]?window[k]:null;window[k]=c},K=function(){var k=
44
- {version:_$_f495[4],edition:_$_f495[5],host:_$_f495[6],license:_$_f495[7],print:function(){return[_$_f495[8]+this.edition+_$_f495[9]+this.version+_$_f495[10]+this.host+_$_f495[10]+this.license]}};return function(){return k}}(),S=function(k){var c=parseInt(k.y);if(k.id)var b=parseInt(k.id);else k.value&&(b=parseInt(k.value));0<b&&(this.rows[c].id=b,sa[_$_f495[11]].call(this,b))},P=function(k){return(_$_f495[3]+k).substr(0,1)===_$_f495[12]},Z=function(k){var c=this.options.columns;return c[k]&&c[k].name?
45
- c[k].name:k},N=function(k,c,b){var a;if(a=this.options.data[c]){var d=0<=k?Z.call(this,k):k;typeof b===_$_f495[13]?b=typeof d===_$_f495[14]?a[k]:jSuites.path.call(a,_$_f495[3]+d):(typeof d===_$_f495[14]?a[k]=b:jSuites.path.call(a,_$_f495[3]+d,b),!P(b)&&this.records[c][k]&&(this.records[c][k].v=b))}else b=null;return b},Q=function(k){return 0==this.config.editable||k&&0==k.options.editable?!1:(k=Ia.call(this))?7<=k?!0:!1:!0},Ja=function(k){var c=_$_f495[15];if(this.parent)var b=this.parent.config,
46
- a=this.parent.element,d=this;else b=this.config,a=this.element,d=t.current?t.current:null;typeof k===_$_f495[13]&&(k=!a.classList.contains(c));k?(a.classList.add(c),b.fullscreen=!0):(a.classList.remove(c),b.fullscreen=!1);d&&(d.tbody.innerHTML=_$_f495[3],G.call(d),T.refresh.call(d),fa.update.call(d.parent,d))},Ka=function(k){var c=this.loading;null===k&&(k=c.style.display==_$_f495[16]?!0:!1);c.style.display=k?_$_f495[16]:_$_f495[3];setTimeout(function(){c.style.display=_$_f495[3]},1E3)},Fa=function(k,
47
- c){if(typeof k===_$_f495[17]){var b=E.getCoordsFromColumnName(k);b=this.records[b[1]][b[0]];if(b.element)k=b.element;else return typeof c===_$_f495[13]?b.readonly:b.readonly=c?!0:!1}b=_$_f495[18];k=k.classList;if(typeof c===_$_f495[13])return k.contains(b)?!0:!1;c?k.add(b):k.remove(b)},xa=function(k){var c=_$_f495[19],b=this.table.classList;if(typeof k==_$_f495[13])return b.contains(c)?!1:!0;k?b.remove(c):b.add(c);0<this.options.freezeColumns&&ka[_$_f495[11]].call(this,this.options.freezeColumns);
48
- this.refreshBorders()},Ia=function(k){if(void 0===k)return this.status;var c=document.createElement(_$_f495[20]);c.style.textAlign=_$_f495[21];c.style.fontSize=_$_f495[22];c.style.cursor=_$_f495[23];c.onclick=function(){window.location.href=K().host+_$_f495[24]};var b=null,a=[74,50,48,50,48,33].join(_$_f495[3]);(function(e){b=1;try{if(e){var f=window.atob(e);f=f.split(_$_f495[25]);if(f[1]){f[1]=window.atob(f[1]);var g=f[0];e=a;var h=f[1],l=jSuites.sha512,m=_$_f495[3],n=_$_f495[3];128<e.length&&(e=
49
- l(e));for(var p=0;128>p;p++){var q=e[p]?e[p].charCodeAt(0):0;m+=String.fromCharCode(54^q);n+=String.fromCharCode(92^q)}var v=l(n+l(m+h));if(g!=v)b=3;else if(f[1]=JSON.parse(f[1]),f[1].date){var u=window.location.hostname||_$_f495[26],w=u.split(_$_f495[27]);u=u.split(_$_f495[27]);2<u.length&&!jSuites.isNumeric(u[u.length-1])&&w.shift();w=w.join(_$_f495[27]);u=u.join(_$_f495[27]);if(-1==f[1].domain.indexOf(w)&&-1==f[1].domain.indexOf(u))b=4;else if(f[1].scope&&0<=f[1].scope.indexOf(_$_f495[28])){u=
50
- new Date;w=parseInt(u.getTime()/1E3);var x=K();f[1].date<w?(b=f[1].date+2592E3<w&&!f[1].plan||f[1].date+15552E3<w?6:7,x.license=f[1].name+_$_f495[29]):(b=8,x.license=_$_f495[30]+f[1].name,x.edition=3==f[1].plan||6==f[1].plan?_$_f495[31]:_$_f495[5])}else b=5}else b=4}else b=2}}catch(y){}})(k);k=_$_f495[3];if(1==b)k=_$_f495[32];else if(2==b||3==b||4==b)k=_$_f495[33];else if(5==b)k=_$_f495[34];else if(6==b||7==b)k=_$_f495[35];c.appendChild(document.createTextNode(k));if(8>b)try{if(typeof sessionStorage!==
51
- _$_f495[13]&&!sessionStorage.getItem(_$_f495[36])){sessionStorage.setItem(_$_f495[36],!0);var d=document.createElement(_$_f495[37]);d.src=K().host+_$_f495[38]+_$_f495[39];d.style.display=_$_f495[40];c.appendChild(d)}}catch(e){}Object.defineProperty(this,_$_f495[41],{value:b,writable:!1,configurable:!1,enumerable:!1,extensible:!1});K().edition===_$_f495[31]&&(this.edition=1);return c},T=function(){var k=function(){if(this.edition){var d=this.edition.getAttribute(_$_f495[42]),e=this.edition.getAttribute(_$_f495[43]);
52
- da.position.call(this,d,e)}},c=function(){this.scrollX.scrollWidth<this.scrollX.scrollLeft+this.scrollX.offsetWidth+25?(this.content.scrollLeft=this.content.scrollWidth,0<this.options.freezeColumns&&ha.refresh.call(this)):this.content.scrollLeft=0;k.call(this)},b=function(){var d=this.tbody.lastChild.getAttribute(_$_f495[43]),e=this.scrollY.scrollHeight-this.content.offsetHeight-this.scrollY.scrollTop;this.content.scrollTop=d!=(this.results?this.rows[this.results[this.results.length-1]].y:this.rows[this.rows.length-
53
- 1].y)&&e?0:this.content.scrollHeight;k.call(this)},a=function(){if(G.limited.call(this)){var d=ka.getWidth.call(this);if(1==this.parent.config.fullscreen)var e=this.content.offsetWidth,f=this.content.offsetHeight;else 1==this.options.tableOverflow&&(e=parseInt(this.options.tableWidth),f=parseInt(this.options.tableHeight));this.width=a.width.call(this)+(d?d:1);this.height=a.height.call(this);this.tfoot.offsetHeight&&(this.height+=this.tfoot.offsetHeight+26);this.scrollX.firstChild.style.width=this.width+
54
- _$_f495[44];this.scrollY.firstChild.style.height=this.height+_$_f495[44];this.scrollX.style.width=e+_$_f495[44];this.scrollY.style.height=f+_$_f495[44];this.scrollX.style.display=this.width>e?_$_f495[3]:_$_f495[40];this.scrollY.style.display=this.height>f?_$_f495[3]:_$_f495[40]}else this.scrollX.style.display=_$_f495[40],this.scrollY.style.display=_$_f495[40]};a.refresh=function(){this.scrollY.scrollTop=0;this.scrollX.scrollLeft=0;a.call(this)};a.updateX=function(){if(a.event)return!1;var d=parseInt(this.thead.lastChild.children[(this.options.freezeColumns||
55
- 0)+1].getAttribute(_$_f495[42]));a.setX.call(this,a.width.call(this,d));c.call(this)};a.updateY=function(){if(a.event)return!1;if(this.tbody.firstChild){var d=parseInt(this.tbody.firstChild.getAttribute(_$_f495[43]));a.setY.call(this,a.height.call(this,d));b.call(this)}};a.setX=function(d){a.ignore=!0;this.scrollX.scrollLeft=d};a.setY=function(d){a.ignore=!0;this.scrollY.scrollTop=d};a.update=function(d,e){e==_$_f495[45]?(d=a.width.call(this,null,d.target.scrollLeft/(d.target.scrollWidth-this.content.offsetWidth)*
56
- this.width),G.reset.call(this),G[_$_f495[46]].call(this,null,d),c.call(this)):(d=a.height.call(this,null,d.target.scrollTop/(d.target.scrollHeight-this.content.offsetHeight)*(this.height-(this.tbody.offsetHeight-5))),this.tbody.textContent=_$_f495[3],G[_$_f495[46]].call(this,d),b.call(this))};a.build=function(d){var e=this,f=document.createElement(_$_f495[20]),g=document.createElement(_$_f495[20]);f.className=_$_f495[47]+d;g.className=_$_f495[48]+d;f.appendChild(g);d==_$_f495[45]?f.style.height=_$_f495[22]:
57
- f.style.width=_$_f495[22];f.onscroll=function(h){if(a.ignore)return a.ignore=!1;a.event=!0;a.update.call(e,h,d);a.event=!1};return f};a.width=function(d,e){for(var f=this.options.columns,g=0,h=this.options.freezeColumns||0;h<this.options.columns.length;h++){if(d===h)return g;!1!==f[h].visible&&f[h].type!==_$_f495[49]&&(g+=parseInt(f[h].width));if(g>=e)return h}return e?h:g};a.height=function(d,e){var f=0,g=0;this.options.defaultRowHeight||(this.options.defaultRowHeight=26);for(var h=this.results?
58
- this.results:this.rows,l=0;l<h.length;l++){g=l;this.results&&(g=h[l]);if(d===g)return f;this.rows[g]&&!1!==this.rows[g].visible&&(f=this.rows[g].height?f+parseInt(this.rows[g].height):this.rows[g].element&&this.rows[g].element.offsetHeight?f+parseInt(this.rows[g].element.offsetHeight):f+parseInt(this.options.defaultRowHeight));if(f>=e)return g}return e?g:f};return a}(),G=function(){var k=function(b,a){var d=this.thead.clientHeight;a||(a=1);var e=!1,f=!1,g=b.getAttribute(_$_f495[42]),h=b.getAttribute(_$_f495[43]);
59
- var l=this.records[h][g];l.merged&&(g-=l.merged[0],h-=l.merged[1],b=this.records[h][g].element);h=this.content.getBoundingClientRect();l=b.getBoundingClientRect();var m=ka.getWidth.call(this),n=h.left+m,p=h.left+h.width;g=h.top+d;var q=h.top+h.height;var v=0;h=l.top;h>=g&&h<=q||(v++,e=!0);h=l.top+l.height;h>=g&&h<=q||v++;if(v>=a)return 2>a&&(a=this.content.scrollTop,0==e?q-g>l.height&&(this.content.scrollTop+=h-q+3,T.ignore=!0,this.scrollY.scrollTop+=h-q+3):(this.content.scrollTop=b.offsetTop-d,T.ignore=
60
- !0,this.scrollY.scrollTop-=a-this.content.scrollTop)),!1;if(!m||!b.classList.contains(_$_f495[50]))if(v=0,g=l.left,g>=n&&g<=p||(v++,f=!0),g=l.left+l.width,g>=n&&g<p||v++,v>=a)return 2>a&&(a=this.content.scrollLeft,0==f?p-n>l.width&&(this.content.scrollLeft+=g-p+3,T.ignore=!0,this.scrollX.scrollLeft+=g-p+3):(this.content.scrollLeft=b.offsetLeft-n-50,T.ignore=!0,this.scrollX.scrollLeft-=a-this.content.scrollLeft)),!1;return!0},c=function(){var b=0;this.results&&(b=this.results[0]);c.reset.call(this,
61
- !0);c.renderX.call(this,0);c.renderY.call(this,b);ka.headers.call(this);0<this.options.pagination&&ta.update.call(this);X.update.call(this);this.refreshBorders();T.call(this)};c.limited=function(){return 1==this.options.tableOverflow||1==this.parent.config.fullscreen};c.refresh=function(){if(!this.tbody.lastChild)return!1;var b=parseInt(this.thead.lastChild.lastChild.getAttribute(_$_f495[42]))+1,a=parseInt(this.tbody.lastChild.getAttribute(_$_f495[43]));this.results?(a=this.results.indexOf(a),a<this.results.length-
62
- 1&&a++,a=this.results[a]):a++;c.renderX.call(this,b);c.renderY.call(this,a);this.content.scrollTop=0;this.content.scrollLeft=0;c.adjustX.call(this,!1,!0);c.adjustY.call(this,!1,!0);T.call(this)};c.renderX=function(b,a,d){var e=this.options.columns,f=0,g=[],h=(this.options.freezeColumns||0)+1;1==this.parent.config.fullscreen?f=this.content.offsetWidth:1==this.options.tableOverflow&&(f=parseInt(this.options.tableWidth));var l=this.headerContainer.offsetWidth||0;for(d||(d=0);e[b]&&(!f||l<f||0<d);){!1!==
63
- e[b].visible&&e[b].type!==_$_f495[49]&&(l+=parseInt(e[b].width));0<d&&d--;var m=ba.getWidth.call(this,b,g);m>d&&(d=m);a?(c.renderColumn.call(this,b,h),b--):(c.renderColumn.call(this,b),b++)}ba.batch.call(this,g)};c.renderY=function(b,a,d){var e=0,f=[];1==this.parent.config.fullscreen?e=this.content.offsetHeight:1==this.options.tableOverflow&&(e=parseInt(this.options.tableHeight));e&&(e-=this.thead.offsetHeight+4,this.tfoot.offsetHeight&&(e-=this.tfoot.offsetHeight+14));var g=this.tbody.offsetHeight;
64
- var h=this.options.freezeColumns||0,l=parseInt(this.headerContainer.lastChild.getAttribute(_$_f495[42]));h=this.headerContainer.children[h+1]?parseInt(this.headerContainer.children[h+1].getAttribute(_$_f495[42])):l;var m=this.results?this.results.indexOf(b):b,n=parseInt(this.options.pagination)||0,p=this.tbody.children.length||0,q=!1;for(d||(d=0);this.options.data&&this.options.data[b]&&(!n||p<n||0<d)&&(!e||g<=e||0<d);){var v=c.renderRow.call(this,b,h,l);a?(this.tbody.insertBefore(v,this.tbody.firstChild),
65
- m--):(this.tbody.appendChild(v),m++);this.rows[b].height?(v.offsetHeight!==this.rows[b].height&&(this.rows[b].height=v.offsetHeight,q=!0),g+=this.rows[b].height):(g+=this.rows[b].height=v.offsetHeight,q=!0);0<d&&d--;b=ba.getHeight.call(this,b,f);b>d&&(d=b);b=this.results?this.results[m]:m;p++}ba.batch.call(this,f);q&&T.call(this)};c.renderColumn=function(b,a,d){this.headers[b]||Ba.create.call(this,b);if(this.options.nestedHeaders)for(d=0;d<this.options.nestedHeaders.length;d++){var e=pa.getColumns.call(this,
66
- d);void 0!==e[b]&&pa.renderCell.call(this,e[b],d,a)}if(this.options.footers)for(d=0;d<this.options.footers.length;d++)e=aa.create.call(this,b,d),null===a?this.tfoot.children[d].appendChild(e):this.tfoot.children[d].insertBefore(e,this.tfoot.children[d].children[a]);null===a?(this.headerContainer.appendChild(this.headers[b]),this.colgroupContainer.appendChild(this.colgroup[b])):(this.headerContainer.insertBefore(this.headers[b],this.headerContainer.children[a]),this.colgroupContainer.insertBefore(this.colgroup[b],
67
- this.colgroupContainer.children[a]));if(this.tbody.children.length)for(d=0;d<this.tbody.children.length;d++)e=parseInt(this.tbody.children[d].getAttribute(_$_f495[43])),(e=M[_$_f495[51]].call(this,b,e))&&(null===a?this.tbody.children[d].appendChild(e):this.tbody.children[d].insertBefore(e,this.tbody.children[d].children[a]))};c.renderRow=function(b,a,d,e){var f=this.options.freezeColumns||0;null==a&&(a=parseInt(this.headerContainer.children[f+1].getAttribute(_$_f495[42])));null==d&&(d=parseInt(this.headerContainer.lastChild.getAttribute(_$_f495[42])));
68
- var g=za.create.call(this,b,e);if(g.children.length)for(;g.children[f+1];)g.removeChild(g.lastChild);if(0<f){for(var h=0;h<f;h++)g.appendChild(M[_$_f495[51]].call(this,h,b));ka.update.call(this,b)}for(h=a;h<=d;h++)a=M[_$_f495[51]].call(this,h,b,e),g.appendChild(a);return g};c.resetY=function(){if(this.options.pagination){this.pageNumber||(this.pageNumber=0);var b=this.options.pagination*this.pageNumber}else b=0;var a=0;if(this.merged.rows[b]){for(a=this.options.pagination;this.merged.rows[b]&&0<=
69
- b;)b--;b++}this.tbody.textContent=_$_f495[3];this.results&&this.results.length&&(b=this.results[b]);(!this.results||0<this.results.length)&&G.renderY.call(this,b,0,a);0<this.options.pagination&&ta.update.call(this);T.call(this);this.refreshBorders()};c[_$_f495[46]]=function(b,a){if(null!==b&&0<=b)if(0<this.options.pagination)this.page(this.whichPage(b));else if(this.rows[b]||(b=this.options.data.length-1),!za.attached.call(this,b)){if(this.merged.rows[b]){for(;this.merged.rows[b]&&0<=b;)b--;b++}this.tbody.textContent=
70
- _$_f495[3];c.renderY.call(this,b);var d=this.results?this.results.indexOf(b):b;0<d&&(this.results?d=this.results[d-1]:d--,c.renderY.call(this,d,!0));T.updateY.call(this)}if(null!==a&&0<=a&&(this.options.columns[a]||(a=this.options.columns.length-1),b||(b=c.getY.call(this)),!M.attached.call(this,a,b))){if(this.merged.cols[a]){for(d=b=0;d<this.rows.length;d++)this.records[d][a].merged&&(b=this.records[d][a].merged[0]);a-=b}c.reset.call(this);c.renderX.call(this,a);0<a&&c.renderX.call(this,a-1,!0);T.updateX.call(this)}this.refreshBorders()};
71
- c.pageUp=function(b,a,d){var e=parseInt(this.tbody.firstChild.getAttribute(_$_f495[43]));if(a){b=null;var f=this.results?this.results[0]:0}else this.results?(f=this.results.indexOf(e),0<f&&f--,f=this.results[f]):(f=e,0<f&&f--);if(f<e){if(null==b)this.tbody.textContent=_$_f495[3];else{e=b;if(this.options.mergeCells){var g=parseInt(this.tbody.lastChild.getAttribute(_$_f495[43]));e+=ba.getHeight.call(this,g)}for(g=0;g<e;g++)this.tbody.removeChild(this.tbody.lastChild)}c.renderY.call(this,f,!a,b);c.adjustY.call(this,
72
- !1);d&&d.preventDefault();T.updateY.call(this)}this.refreshBorders()};c.pageDown=function(b,a,d){var e=parseInt(this.tbody.lastChild.getAttribute(_$_f495[43]));if(a){b=null;var f=this.results?this.results[this.results.length-1]:this.rows.length-1}else this.results?(f=this.results.indexOf(e),f<this.results.length-1&&f++,f=this.results[f]):(f=e,e<this.options.data.length-1&&f++);if(f>e){if(null==b)this.tbody.textContent=_$_f495[3];else{e=b;if(this.options.mergeCells){var g=parseInt(this.tbody.firstChild.getAttribute(_$_f495[43]));
73
- e+=ba.getHeight.call(this,g)}for(g=0;g<e;g++)this.tbody.removeChild(this.tbody.firstChild)}c.renderY.call(this,f,a,b);c.adjustY.call(this,!0);d&&d.preventDefault();T.updateY.call(this)}this.refreshBorders()};c.removeColumns=function(b,a){var d=null===a?this.headerContainer.lastChild:this.headerContainer.children[a];if(d)d=parseInt(d.getAttribute(_$_f495[42]));else return!1;if(this.options.mergeCells){for(var e=0,f=d,g=0;g<b;g++){var h=ba.getWidth.call(this,f);h>e&&(e=h);null===a?f--:f++}b+=e}b>=this.headerContainer.children.length&&
74
- (b=this.headerContainer.children.length-1);if((e=this.options.nestedHeaders)&&e.length)for(f=0;f<e.length;f++)for(h=pa.getColumns.call(this,f),g=0;g<b;g++)if(void 0!==h[d+g]&&this.nested.content[f][h[d+g]]){var l=this.nested.content[f][h[d+g]].element,m=l.getAttribute(_$_f495[52]);0<m&&m--;0<m?l.setAttribute(_$_f495[52],m):l.parentNode&&this.thead.children[f].removeChild(l)}for(g=0;g<b;g++)null===a?(this.headerContainer.removeChild(this.headerContainer.lastChild),this.colgroupContainer.removeChild(this.colgroupContainer.lastChild)):
75
- this.headerContainer.children[a]&&(this.headerContainer.removeChild(this.headerContainer.children[a]),this.colgroupContainer.removeChild(this.colgroupContainer.children[a]));for(f=0;f<this.tbody.children.length;f++)for(g=0;g<b;g++)null===a?this.tbody.children[f].removeChild(this.tbody.children[f].lastChild):this.tbody.children[f].children[a]&&this.tbody.children[f].removeChild(this.tbody.children[f].children[a]);for(f=0;f<this.tfoot.children.length;f++)for(g=0;g<b;g++)null===a?this.tfoot.children[f].removeChild(this.tfoot.children[f].lastChild):
76
- this.tfoot.children[f].removeChild(this.tfoot.children[f].children[a])};c.pageLeft=function(b,a){var d=this.options.freezeColumns||0;if(a){b=null;var e=d}else e=parseInt(this.thead.lastChild.children[d+1].getAttribute(_$_f495[42]))-1;e>=d&&(null==b?c.reset.call(this):c.removeColumns.call(this,b,null),c.renderX.call(this,e,!a,b),c.adjustX.call(this,!1),T.updateX.call(this));this.refreshBorders()};c.pageRight=function(b,a){var d=this.options.freezeColumns||0;if(a){b=null;var e=this.options.columns.length-
77
- 1}else e=parseInt(this.thead.lastChild.lastChild.getAttribute(_$_f495[42]))+1;e<this.options.columns.length&&(null==b?c.reset.call(this):c.removeColumns.call(this,b,d+1),c.renderX.call(this,e,a,b),c.adjustX.call(this,!0),T.updateX.call(this));this.refreshBorders()};c.reset=function(b){1<this.headerContainer.children.length&&(b=b?0:this.options.freezeColumns||0,c.removeColumns.call(this,this.headerContainer.children.length-(b+1),b+1))};c.getX=function(){if(this.thead.lastChild)return parseInt(this.thead.lastChild.children[1].getAttribute(_$_f495[42]))};
78
- c.getY=function(){if(this.tbody.firstChild)return parseInt(this.tbody.firstChild.getAttribute(_$_f495[43]))};c.adjustX=function(b,a){var d=this.options.freezeColumns||0;if(b)var e=this.options.columns.length-1,f=parseInt(this.tbody.firstChild.lastChild.getAttribute(_$_f495[42])),g=parseInt(this.tbody.firstChild.children[d+1].getAttribute(_$_f495[42]));else e=d,f=parseInt(this.tbody.firstChild.children[d+1].getAttribute(_$_f495[42])),g=parseInt(this.tbody.firstChild.lastChild.getAttribute(_$_f495[42]));
79
- f===e&&(b?g--:g++,c.renderX.call(this,g,b));if(!0===a){for(b=0;b<this.tbody.children.length&&this.tbody.children[b].style.display===_$_f495[40];b++);a=[];for(d+=1;d<this.thead.lastChild.children.length;d++)k.call(this,this.tbody.children[b].children[d],2)||a.push(d);a.length&&c.removeColumns.call(this,a.length,a[0])}};c.adjustY=function(b,a){if(b)var d=this.rows.length-1,e=parseInt(this.tbody.lastChild.getAttribute(_$_f495[43])),f=parseInt(this.tbody.firstChild.getAttribute(_$_f495[43]));else d=0,
80
- e=parseInt(this.tbody.firstChild.getAttribute(_$_f495[43])),f=parseInt(this.tbody.lastChild.getAttribute(_$_f495[43]));e==d&&(this.results?(d=this.results.indexOf(f),f=b?this.results[d-1]:this.results[d+1]):b?f--:f++,c.renderY.call(this,f,b));if(!0===a){b=[];for(a=0;a<this.tbody.children.length;a++)this.tbody.children[a].style.display!==_$_f495[40]&&this.tbody.children[a].children[1]&&(k.call(this,this.tbody.children[a].children[1],2)||b.push(this.tbody.children[a].firstChild.getAttribute(_$_f495[43])));
81
- if(b.length)for(a=0;a<b.length;a++)this.rows[b[a]].element.remove()}};c.isVisible=k;return c}(),La=function(k,c,b,a){for(var d=this.options.columns,e=k,f,g=null;k<d.length-1;)if(k++,!1!==d[k].visible&&d[k].type!==_$_f495[49]){f=this.records[c]&&this.records[c][k].v===_$_f495[3]?!1:!0;null===g&&(g=f);if(this.records[c]&&this.records[c][k].element&&this.records[c][k].element.style.display==_$_f495[40]){if(this.records[c][k].merged){if(k==k+this.records[c][k].merged[0]&&(e=k,!b))break;f=!1}}else{if(b&&
82
- f!==g&&!a)break;if(b)e=k;else return k}g=f}return e},Ma=function(k,c,b,a){for(var d=this.options.columns,e=k,f,g=null;0<k;)if(k--,!1!==d[k].visible&&d[k].type!==_$_f495[49]){f=this.records[c]&&this.records[c][k].v===_$_f495[3]?!1:!0;null===g&&(g=f);if(this.records[c]&&this.records[c][k].element&&this.records[c][k].element.style.display==_$_f495[40]){if(this.records[c][k].merged){e=k-this.records[c][k].merged[0];if(!b)break;f=!0}}else{if(b&&f!==g&&!a)break;if(b)e=k;else return k}g=f}return e},Sa=function(){var k=
83
- function(b,a,d,e){1==b||3==b?za.attached.call(this,d)||(0<this.options.pagination?this.page(this.whichPage(d)):(1==b?G.pageUp.call(this,1,e):G.pageDown.call(this,1,e),za.attached.call(this,d)||G[_$_f495[46]].call(this,d))):M.attached.call(this,a,d)||(0==b?G.pageLeft.call(this,1,e):G.pageRight.call(this,1,e),M.attached.call(this,a,d)||G[_$_f495[46]].call(this,d,a))},c=function(b){b.up=c.up;b.down=c.down;b.right=c.right;b.left=c.left;b.last=c.last;b.first=c.first};c.up=function(b,a,d){if(b)var e=parseInt(this.selectedCell[2]),
84
- f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);a:{var g=e,h=f,l=h,m=null;if(this.results&&(h=this.results.indexOf(h),-1==h)){d=l;break a}for(;0<h;){h--;var n=this.results?this.results[h]:h;if(!1!==this.rows[n].visible){var p=this.records[n][g].v===_$_f495[3]?!1:!0;null===m&&(m=p);if(this.records[n][g].element&&this.records[n][g].element.style.display==_$_f495[40]){if(this.records[n][g].merged){l=n-this.records[n][g].merged[1];if(!a)break;p=
85
- !0}}else if(a&&p!==m&&!d){d=l;break a}else if(a)l=this.records[n][g].merged?n-this.records[n][g].merged[1]:n;else{d=n;break a}m=p}}d=l}d!=f&&(f=d,b?(b=this.selectedCell[0],d=this.selectedCell[1]):(b=e,d=f,e=b,f=d),k.call(this,1,e,f,a),this.updateSelectionFromCoords(b,d,e,f))};c.down=function(b,a,d){if(b)var e=parseInt(this.selectedCell[2]),f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);a:{var g=e,h=f,l=h,m=null;if(this.results){h=this.results.indexOf(h);
86
- if(-1==h){d=l;break a}var n=this.results.length-1}else n=this.rows.length-1;for(;h<n;){h++;var p=this.results?this.results[h]:h;if(!1!==this.rows[p].visible){var q=this.records[p][g].v===_$_f495[3]?!1:!0;null===m&&(m=q);if(this.records[p][g].element&&this.records[p][g].element.style.display==_$_f495[40]){if(this.records[p][g].merged){if(!this.records[p][g].merged[1]&&(l=p,!a))break;q=!0}}else if(a&&q!==m&&!d){d=l;break a}else if(a)l=p;else{d=p;break a}m=q}}d=l}d!=f&&(f=d,b?(b=this.selectedCell[0],
87
- d=this.selectedCell[1]):(b=e,d=f,e=b,f=d),k.call(this,3,e,f,a),this.updateSelectionFromCoords(b,d,e,f))};c.right=function(b,a,d){if(b)var e=parseInt(this.selectedCell[2]),f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);d=La.call(this,e,f,a,d);d!=e&&(e=d,b?(b=this.selectedCell[0],d=this.selectedCell[1]):(b=e,d=f,e=b,f=d),k.call(this,2,e,f,a),this.updateSelectionFromCoords(b,d,e,f))};c.left=function(b,a,d){if(b)var e=parseInt(this.selectedCell[2]),
88
- f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);d=Ma.call(this,e,f,a,d);d!=e&&(e=d,b?(b=this.selectedCell[0],d=this.selectedCell[1]):(b=e,d=f,e=b,f=d),k.call(this,0,e,f,a),this.updateSelectionFromCoords(b,d,e,f))};c.first=function(b,a){a?c.up.call(this,b,!0,!0):c.left.call(this,b,!0,!0)};c.last=function(b,a){a?c.down.call(this,b,!0,!0):c.right.call(this,b,!0,!0)};return c}(),Ta=function(){return function(k){k.save=Na;k.fullscreen=Ja;k.setReadOnly=
89
- Fa;k.getReadOnly=Fa;k.isReadOnly=Fa;k.setPlugins=function(c){na.call(this.parent,c)};k.showIndex=function(){xa.call(this,!0)};k.hideIndex=function(){xa.call(this,!1)};k[_$_f495[46]]=G[_$_f495[46]];k.undo=function(){U.undo.call(k.parent)};k.redo=function(){U.redo.call(k.parent)};k.isEditable=function(){return Q.call(k.parent,k)};k.dispatch=function(){return F.apply(this.parent,arguments)};k.setViewport=function(c,b){this.options.tableOverflow=!0;c=parseInt(c);b=parseInt(b);this.content.style.overflow=
90
- _$_f495[49];100<c&&(this.options.tableWidth=c+_$_f495[44],this.content.style.maxWidth=this.options.tableWidth);100<b&&(this.options.tableHeight=parseInt(b)+_$_f495[44],this.content.style.maxHeight=this.options.tableHeight);this.tbody.innerHTML=_$_f495[3];G.call(this);T.refresh.call(this);fa.update.call(this.parent,this)}}}(),Ca=function(){var k={logo:null,url:null,persistence:!1,sequence:!0,data:null,json:null,rows:[],columns:[],cells:{},role:null,nestedHeaders:null,defaultColWidth:100,defaultRowHeight:0,
91
- defaultColAlign:_$_f495[53],minSpareRows:0,minSpareCols:0,minDimensions:[0,0],csv:null,csvFileName:_$_f495[36],csvHeaders:!0,csvDelimiter:_$_f495[25],columnSorting:!0,columnDrag:!0,columnResize:!0,rowResize:!0,rowDrag:!0,editable:!0,allowInsertRow:!0,allowManualInsertRow:!0,allowInsertColumn:!0,allowManualInsertColumn:!0,allowDeleteRow:!0,allowDeletingAllRows:!1,allowDeleteColumn:!0,allowRenameColumn:!0,allowComments:!0,selectionCopy:!0,mergeCells:{},search:!1,pagination:!1,paginationOptions:null,
92
- textOverflow:!1,tableOverflow:!1,tableHeight:_$_f495[54],tableWidth:null,comments:null,meta:null,style:{},freezeColumns:0,orderBy:null,worksheetId:_$_f495[3],worksheetName:null,worksheetState:null,filters:!1,footers:null,validations:null,formify:null,applyMaskOnFooters:!1,pluginOptions:null,locked:!1,selectUnLockedCells:!0,selectLockedCells:!0},c={application:_$_f495[55],cloud:null,root:null,definedNames:{},sorting:null,server:null,toolbar:null,editable:!0,allowExport:!0,includeHeadersOnDownload:!1,
93
- forceUpdateOnPaste:!1,loadingSpin:!1,fullscreen:!1,secureFormulas:!0,parseFormulas:!0,debugFormulas:!1,editorFormulas:!0,autoIncrement:!0,autoCasting:!0,stripHTML:!1,tabs:!1,allowDeleteWorksheet:!0,allowRenameWorksheet:!0,allowMoveWorksheet:!0,onevent:null,onclick:null,onload:null,onundo:null,onredo:null,onbeforesave:null,onsave:null,onbeforechange:null,onchange:null,onafterchanges:null,oncopy:null,onbeforepaste:null,onpaste:null,onbeforeinsertrow:null,oninsertrow:null,onbeforedeleterow:null,ondeleterow:null,
94
- onbeforeinsertcolumn:null,oninsertcolumn:null,onbeforedeletecolumn:null,ondeletecolumn:null,onmoverow:null,onmovecolumn:null,onresizerow:null,onresizecolumn:null,onselection:null,onbeforecomments:null,oncomments:null,onbeforesort:null,onsort:null,onfocus:null,onblur:null,onmerge:null,onchangeheader:null,onchangefooter:null,onchangefootervalue:null,onchangenested:null,onchangenestedcell:null,oncreateeditor:null,oneditionstart:null,oneditionend:null,onchangestyle:null,onchangemeta:null,onbeforechangepage:null,
95
- onchangepage:null,onbeforecreateworksheet:null,oncreateworksheet:null,onrenameworksheet:null,ondeleteworksheet:null,onmoveworksheet:null,onopenworksheet:null,onchangerowid:null,onbeforesearch:null,onsearch:null,onbeforefilter:null,onfilter:null,oncreatecell:null,oncreaterow:null,onbeforeformula:null,updateTable:null,contextMenu:null,parseTableFirstRowAsHeader:!1,parseTableAutoCellType:!1,plugins:null,wordWrap:!0,about:!0,license:null,worksheets:null},b=function(e,f){f=JSON.parse(JSON.stringify(f));
96
- var g={},h;for(h in f)e&&e.hasOwnProperty(h)?g[h]=e[h]:g[h]=f[h];return g},a=function(e){e&&(typeof e==_$_f495[17]&&(e=JSON.parse(e)),this.options.data=e);this.options.json&&(this.options.data=this.options.json);this.options.data||(this.options.data=[]);e=this.options.columns.length;if(this.options.data&&typeof this.options.data[0]!==_$_f495[13]){var f=this.options.data[0].data&&0<Object.keys(this.options.data[0].data).length?Object.keys(this.options.data[0].data):Object.keys(this.options.data[0]);
97
- f.length>e&&(e=f.length)}this.options.minDimensions[0]>e&&(e=this.options.minDimensions[0]);e||(e=8);for(var g=0;g<e;g++)this.options.columns[g]?this.options.columns[g].type||(this.options.columns[g].type=_$_f495[56]):this.options.columns[g]={type:_$_f495[56]},this.options.columns[g].type==_$_f495[57]&&(this.options.columns[g].type=_$_f495[58],this.options.columns[g].autocomplete=!0),!this.options.columns[g].name&&f&&f[g]&&Number(f[g])!=f[g]&&(this.options.columns[g].name=f[g]),this.options.columns[g].width||
98
- (this.options.columns[g].width=this.options.defaultColWidth),this.options.columns[g].type!=_$_f495[58]||this.options.columns[g].source||(this.options.columns[g].source=[]),this.options.columns[g].type==_$_f495[58]&&this.options.columns[g].url&&jSuites.ajax({url:this.options.columns[g].url,index:g,method:_$_f495[59],dataType:_$_f495[60],worksheet:this,group:this.parent.name,success:function(h){this.worksheet.options.columns[this.index].source=h}})},d=function(e){e.getConfig=d[_$_f495[51]];e.setConfig=
99
- d[_$_f495[11]]};d.spreadsheet=function(e){this.config=b(e,c);1!=this.config.secureFormulas&&console.log(_$_f495[61])};d.worksheet=function(e){var f=this;f.options=b(e,k);f.options.csv?jSuites.ajax({url:f.options.csv,method:_$_f495[59],dataType:_$_f495[56],group:f.parent.name,success:function(g){g=E.parseCSV(g,f.options.csvDelimiter);if(1==f.options.csvHeaders&&0<g.length)for(var h=g.shift(),l=0;l<h.length;l++)f.options.columns[l]||(f.options.columns[l]={type:_$_f495[56],align:f.options.defaultColAlign,
100
- width:f.options.defaultColWidth}),typeof f.options.columns[l].title===_$_f495[13]&&(f.options.columns[l].title=h[l]);a.call(f,g)}}):f.options.url?jSuites.ajax({url:f.options.url,method:_$_f495[59],dataType:_$_f495[60],group:f.parent.name,success:function(g){a.call(f,g)}}):a.call(f)};d[_$_f495[51]]=function(){return this.options};d[_$_f495[11]]=function(e){typeof e==_$_f495[17]&&(e=JSON.parse(e));if(this.parent){f=Object.keys(e);for(g=0;g<f.length;g++)typeof k[f[g]]!==_$_f495[13]&&(this.options[f[g]]=
101
- e[f[g]]);!0===e.filters?ca.show.call(this):!1===e.filters&&ca.hide.call(this);!0===e.search?qa.show.call(this):!1===e.search&&qa.hide.call(this);!0===e.toolbar?fa.show.call(this.parent):!1===e.toolbar&&fa.hide.call(this.parent);e.minDimensions&&e.minDimensions[0]&&(f=parseInt(e.minDimensions[0])-this.headers.length,0<f&&this.insertColumn(f),f=parseInt(e.minDimensions[1])-this.rows.length,0<f&&this.insertRow(f));L.call(this,_$_f495[62],{data:JSON.stringify(e)})}else for(var f=Object.keys(e),g=0;g<
102
- f.length;g++)typeof c[f[g]]!==_$_f495[13]&&(this.config[f[g]]=e[f[g]])};return d}(),U=function(k){k=function(c){if(1!=this.ignoreHistory){var b=++this.historyIndex;this.history=this.history.slice(0,b+1);this.history[b]=c}};k.undo=function(){if(0<=this.historyIndex)var c=this.history[this.historyIndex--];if(c){this.ignoreHistory=!0;var b=c.worksheet;b.openWorksheet();var a=[];if(c.action==_$_f495[63])b.deleteRow(c.insertBefore?c.rowNumber:c.rowNumber+1,c.numOfRows);else if(c.action==_$_f495[64])b.insertRow(c.numOfRows,
103
- c.rowNumber,1,c.data),M.setAttributes.call(b,c.attributes);else if(c.action==_$_f495[65])b.deleteColumn(c.insertBefore?c.columnNumber:c.columnNumber+1,c.numOfColumns);else if(c.action==_$_f495[66])b.insertColumn(c.numOfColumns,c.columnNumber,1,c.properties,c.data,c.extra),M.setAttributes.call(b,c.attributes);else if(c.action==_$_f495[67])b.moveRow(c.newValue,c.oldValue);else if(c.action==_$_f495[68])b.moveColumn(c.newValue,c.oldValue);else if(c.action==_$_f495[69])b.removeMerge(c.newValue,!0),b.setMerge(c.oldValue);
104
- else if(c.action==_$_f495[70])b.setMerge(c.oldValue);else if(c.action==_$_f495[71])b.setStyle(c.oldValue,null,null,1);else if(c.action==_$_f495[72])b.setStyle(c.oldValue);else if(c.action==_$_f495[73])b.setWidth(c.column,c.oldValue);else if(c.action==_$_f495[74])b.setHeight(c.row,c.oldValue);else if(c.action==_$_f495[75])b.setHeader(c.column,c.oldValue);else if(c.action==_$_f495[76])b.setComments(c.oldValue);else if(c.action==_$_f495[77])b.setProperty(c.column,c.oldValue);else if(c.action==_$_f495[78])b.orderBy(c.column,
105
- c.direction?0:1,c.oldValue);else if(c.action==_$_f495[79]){for(var d=0;d<c.records.length;d++){var e={x:c.records[d].x,y:c.records[d].y,value:c.records[d].oldValue};c.records[d].oldStyle&&(e.style=c.records[d].oldStyle);a.push(e)}b.setValue(a)}else c.action==_$_f495[80]?b.renameWorksheet(c.index,c.oldValue):c.action==_$_f495[81]&&b.moveWorksheet(c.t,c.f);c.selection&&b.updateSelectionFromCoords(c.selection);this.ignoreHistory=!1;F.call(this,_$_f495[82],b,c)}};k.redo=function(){if(this.historyIndex<
106
- this.history.length-1)var c=this.history[++this.historyIndex];if(c){this.ignoreHistory=!0;var b=c.worksheet;b.openWorksheet();c.action==_$_f495[63]?b.insertRow(c.numOfRows,c.rowNumber,c.insertBefore,c.data):c.action==_$_f495[64]?b.deleteRow(c.rowNumber,c.numOfRows):c.action==_$_f495[65]?b.insertColumn(c.numOfColumns,c.columnNumber,c.insertBefore,c.properties,c.data):c.action==_$_f495[66]?b.deleteColumn(c.columnNumber,c.numOfColumns):c.action==_$_f495[67]?b.moveRow(c.oldValue,c.newValue):c.action==
107
- _$_f495[68]?b.moveColumn(c.oldValue,c.newValue):c.action==_$_f495[69]?b.setMerge(c.newValue):c.action==_$_f495[70]?b.removeMerge(c.newValue):c.action==_$_f495[71]?b.setStyle(c.newValue,null,null,1):c.action==_$_f495[72]?b.resetStyle(c.cells):c.action==_$_f495[73]?b.setWidth(c.column,c.newValue):c.action==_$_f495[74]?b.setHeight(c.row,c.newValue):c.action==_$_f495[75]?b.setHeader(c.column,c.newValue):c.action==_$_f495[76]?b.setComments(c.newValue):c.action==_$_f495[77]?b.setProperty(c.column,c.newValue):
108
- c.action==_$_f495[78]?b.orderBy(c.column,c.direction,c.newValue):c.action==_$_f495[79]?b.setValue(c.records):c.action==_$_f495[80]?b.renameWorksheet(c.index,c.newValue):c.action==_$_f495[81]&&b.moveWorksheet(c.f,c.t);c.selection&&b.updateSelectionFromCoords(c.selection);this.ignoreHistory=!1;F.call(this,_$_f495[83],b,c)}};return k}(),na=function(){var k=function(c){var b=null;if(Array.isArray(c))b=c;else if(typeof c==_$_f495[84]){b=[];var a=Object.keys(c);for(var d=0;d<a.length;d++)b.push({name:a[d],
109
- plugin:c[a[d]],options:{}})}if(b&&b.length)for(d=0;d<b.length;d++){if(b[d].name&&b[d].plugin){var e=b[d].name;var f=b[d].plugin;var g=b[d].options}typeof f===_$_f495[85]&&(this.plugins[e]=f.call(t,this,g,this.config),typeof f.license==_$_f495[85]&&t.license&&f.license(t.license))}};k.execute=function(c,b){if(this.plugins){var a=Object.keys(this.plugins);if(a.length)for(var d=0;d<a.length;d++)if(typeof this.plugins[a[d]][c]==_$_f495[85]){var e=this.plugins[a[d]][c].apply(this.plugins[a[d]],b);e&&(c==
110
- _$_f495[86]&&(b[4]=e),c==_$_f495[87]&&(b[0]=e))}return b}};return k}(),da=function(){var k=function(c){c.getEditor=k[_$_f495[51]];c.openEditor=k.open;c.closeEditor=k.close};k[_$_f495[51]]=function(c,b){c=Ga.getOptions.call(this,c,b);return[c.type&&typeof c.type==_$_f495[84]?c.type:t.editors[c.type],c]};k.open=function(c,b,a){if(!Q.call(this.parent,this))return!1;if(1!=c.classList.contains(_$_f495[18])){var d=parseInt(c.getAttribute(_$_f495[42])),e=parseInt(c.getAttribute(_$_f495[43]));if(!0===this.options.locked){var f=
111
- E.getColumnNameFromCoords(d,e);if(!this.options.cells||!this.options.cells[f]||!1!==this.options.cells[f].locked)return!1}if(f=this.records[e][d].merged)d-=f[0],e-=f[1],c=this.records[e][d].element;if(!M.attached.call(this,d,e)){if(this.results&&0<this.results.length)return console.error(_$_f495[88]),!1;G[_$_f495[46]].call(this,e,d)}k.position.call(this,d,e);f=this.parent.input;f.innerText=_$_f495[3];F.call(this.parent,_$_f495[89],this,c,d,e);b=1==b?_$_f495[3]:N.call(this,d,e);var g=k[_$_f495[51]].call(this,
112
- d,e),h=!0;typeof g[0].openEditor==_$_f495[85]&&(!1===g[0].openEditor(c,b,d,e,this,g[1],a)?h=!1:F.call(this.parent,_$_f495[90],this,c,d,e,f,g[1]));h&&(1==this.options.textOverflow&&(this.records[e][d].element.style.overflow=_$_f495[49],0<d&&(this.records[e][d-1].element.style.overflow=_$_f495[49])),this.edition=c,f.classList.add(_$_f495[91]),1==this.parent.config.editorFormulas&&P(b)&&(f.classList.add(_$_f495[92]),la.parse.call(this,f),c=document.createTextNode(_$_f495[3]),f.appendChild(c),jSuites.focus(f)))}};
113
- k.close=function(c,b){null===c&&(c=this.edition);this.parent.input.classList.contains(_$_f495[92])&&la.close.call(this,this.parent.input);var a,d=parseInt(c.getAttribute(_$_f495[42])),e=parseInt(c.getAttribute(_$_f495[43]));1==this.options.textOverflow&&(a=this.records[e][d+1])&&a.element&&a.element.innerText==_$_f495[3]&&(this.records[e][d].element.style.overflow=_$_f495[3]);a=k[_$_f495[51]].call(this,d,e);if(1==b){var f=null;if(typeof a[0].closeEditor==_$_f495[85]){var g=a[0].closeEditor(c,!0,d,
114
- e,this,a[1]);void 0!==g&&(f=g)}null!==f&&N.call(this,d,e)!=f&&this.setValue(c,f)}else a[0].closeEditor(c,!1,d,e,this,a[1]);F.call(this.parent,_$_f495[93],this,c,d,e,f,b);a[1]&&typeof a[1].render==_$_f495[85]&&a[1].render.call(this,c,this.records[e][d].v,d,e,this,a[1]);a=this.parent.input;a.onblur&&(a.onblur=null);a.children[0]&&a.children[0].onblur&&(a.children[0].onblur=null);a.update&&(a.update=null);da.build(this.parent);a.removeAttribute(_$_f495[94]);a.removeAttribute(_$_f495[95]);a.removeAttribute(_$_f495[96]);
115
- this.edition=a.mask=null;this.refreshBorders()};k.position=function(c,b){var a=null;if(a=this.records[b][c].element){var d=this.parent.element.getBoundingClientRect();a=a.getBoundingClientRect();var e=this.parent.input;e.x=c;e.y=b;0==a.width&&0==a.height?e.style.opacity=_$_f495[97]:(e.setAttribute(_$_f495[98],_$_f495[3]),c=a.top-d.top+1,b=a.left-d.left+1,e.style.top=c+_$_f495[44],e.style.left=b+_$_f495[44],e.style.minWidth=a.width-1+_$_f495[44],e.style.minHeight=a.height-1+_$_f495[44],setTimeout(function(){e.focus()},
116
- 0))}};k.build=function(c){c.input||(c.input=document.createElement(_$_f495[20]));c.input.className=_$_f495[99];c.input.setAttribute(_$_f495[100],!0);c.input.innerText=_$_f495[3];c.input.oninput=function(b){1==t.current.parent.config.editorFormulas&&(P(b.target.innerText)?b.target.classList.add(_$_f495[92]):b.target.classList.contains(_$_f495[92])&&la.close.call(t.current,this))};return c.input};return k}(),F=function(k){if(!this.ignoreEvents){if(typeof this.config.onevent==_$_f495[85])var c=this.config.onevent.apply(this,
117
- arguments);typeof this.config[k]==_$_f495[85]&&(c=this.config[k].apply(this,Array.prototype.slice.call(arguments,1)));na.execute.call(this,_$_f495[101],arguments)}return c},sa=function(){var k=function(c){c.sequence=0;c.getNextSequence=k.next;c.getRowId=k.getId;c.setRowId=k.setId;c.getRowById=k.getRowById};k[_$_f495[51]]=function(){return this.sequence};k[_$_f495[11]]=function(c,b){if(c>this.sequence||b)this.sequence=c};k.next=function(){return 1==this.options.sequence?++this.sequence:null};k.reset=
118
- function(){this.sequence=0};k.getId=function(c){if(this.rows[c]&&this.rows[c].id)return this.rows[c].id;var b=this.getPrimaryKey();if(!1!==b)return N.call(this,b,c)};k.setId=function(c,b){if(void 0!==b&&0<=parseInt(c)){var a={};a[c]=b}else a=c;c=Object.keys(a);if(c.length){for(var d=0;d<c.length;d++)b=a[c[d]],this.rows[c[d]].id=b,k[_$_f495[11]].call(this,b);L.call(this,_$_f495[102],[a]);F.call(this.parent,_$_f495[103],this,a)}};k.getRowById=function(c,b){for(var a=0;a<this.rows.length;a++)if(k.getId.call(this,
119
- a)==c)return!0===b?this.rows[a]:this.options.data[a];return!1};return k}(),Na=function(){var k=function(b){for(var a=[],d={},e=0;e<b.length;e++){var f=b[e].x,g=b[e].y,h=sa.getId.call(this,g);if(!h)if(d[g])h=d[g];else if(h=sa.next.call(this))d[g]=h;a[g]||(a[g]={id:h,row:g,data:{}});f=Z.call(this,f);a[g].data[f]=b[e].value}sa.setId.call(this,d);return a.filter(function(l){return null!=l})},c=function(b){var a=b[0];if(0<=[_$_f495[104],_$_f495[105],_$_f495[102],_$_f495[106]].indexOf(a))return!1;var d=
120
- {};a==_$_f495[79]||a==_$_f495[107]?(a=_$_f495[108],d[a]=k.call(this,b[1].data)):Array.isArray(b[1])&&1==b[1].length?d[a]=b[1][0]:d[a]=b[1];return d};return function(b,a,d,e){var f=this.parent,g=this;d=null;var h=c.call(this,a);if(h)a=h;else if(!1===h)return!1;if(h=F.call(f,_$_f495[109],f,g,a))a=h;else if(!1===h)return!1;Ka.call(f,!0);jSuites.ajax({url:b,method:_$_f495[110],dataType:_$_f495[60],data:{data:JSON.stringify(a)},queue:!0,beforeSend:function(l){d&&l.setRequestHeader(_$_f495[111],_$_f495[112]+
121
- d)},success:function(l){f.element.classList.contains(_$_f495[113])&&f.element.classList.remove(_$_f495[113]);l&&(l.message&&(l.name=f.config.application,jSuites.notification.isVisible()?console.log(l.name+_$_f495[114]+l.message):jSuites.notification(l)),l.success?typeof e===_$_f495[85]?e(l):l.data&&Array.isArray(l.data)&&M.updateAll.call(g,l.data):l.error&&(alert(_$_f495[115]),window.open(window.location.href,_$_f495[116])));F.call(f,_$_f495[117],f,g,a,l)},error:function(){f.element.classList.add(_$_f495[113])}})}}(),
122
- L=function(){return function(){na.execute.call(this.parent,_$_f495[118],[this,arguments[0],arguments[1]]);if(!this.parent.ignorePersistence){var k=null;if(this.parent.config.server){var c=this.parent.worksheets.indexOf(this);k=this.parent.config.server;k=-1==k.indexOf(_$_f495[119])?k+(_$_f495[120]+c):k+(_$_f495[121]+c)}else this.options.persistence&&(k=typeof this.options.persistence==_$_f495[17]?this.options.persistence:this.options.url);k&&Na.call(this,k,arguments)}}}(),Da=function(k){if(this.selectedCell){var c=
123
- this.selectedCell[0],b=this.selectedCell[1];this.records&&this.records[b]&&this.records[b][c]&&this.records[b][c].element||(this.selectedCell=this.getHighlighted(),c=this.selectedCell[0],b=this.selectedCell[1]);var a=this.getHighlighted(),d=a[0],e=a[1],f=a[2];a=a[3];k=k?_$_f495[122]:_$_f495[123];if(this.records[b]&&this.records[b][c]&&this.records[b][c].element)this.records[b][c].element.classList[k](_$_f495[124]);for(c=d;c<=f;c++)if(this.headers[c])this.headers[c].classList[k](_$_f495[125]);for(;e<=
124
- a;e++)if(this.rows[e]&&this.rows[e].element)this.rows[e].element.classList[k](_$_f495[125])}},ya=function(){var k=function(c){c.resetSelection=k.reset;c.updateSelection=k.fromElements;c.updateSelectionFromCoords=k[_$_f495[11]];c.selectAll=k.all;c.isSelected=k.isSelected;c.getHighlighted=k.getHighlighted;c.getRange=k.getRange};k.getHighlighted=function(){var c=this.borders;return(c=c.main)?[c.x1,c.y1,c.x2,c.y2]:null};k.isSelected=function(c,b,a){if(!a&&(a=this.getHighlighted(),!a))return!1;var d=a[0],
125
- e=a[1],f=a[2];a=a[3];f||(f=d);a||(a=e);return null==c?b>=e&&b<=a:null==b?c>=d&&c<=f:c>=d&&c<=f&&b>=e&&b<=a};k.reset=function(){if(this.selectedCell)c=1,this.edition&&da.close.call(this,this.edition,!0),this.resetBorders(_$_f495[126],!0),this.resetBorders(_$_f495[127],!0),this.selectedCell=null,1==c&&F.call(this.parent,_$_f495[128],this);else var c=0;return c};k.refresh=function(){this.selectedCell&&k[_$_f495[11]].call(this,this.selectedCell)};k.isValid=function(c,b,a,d){return!(c>=this.options.columns.length||
126
- b>=this.rows.length||a>=this.options.columns.length||d>=this.rows.length)};k[_$_f495[11]]=function(c,b,a,d,e,f,g){f||(f=_$_f495[126]);Array.isArray(c)&&(d=c[3],a=c[2],b=c[1],c=c[0]);null==a&&(a=c);null==d&&(d=b);if(!k.isValid.call(this,c,b,a,d))return!1;if(null!=c){if(parseInt(c)<parseInt(a))var h=parseInt(c),l=parseInt(a);else h=parseInt(a),l=parseInt(c);if(parseInt(b)<parseInt(d))var m=parseInt(b),n=parseInt(d);else m=parseInt(d),n=parseInt(b);var p;var q={};if(this.options.mergeCells){for(var v=
127
- m;v<=n;v++)for(var u=h;u<=l;u++)if(p=this.records[v][u].merged)p=E.getColumnNameFromCoords(u-p[0],v-p[1]),q[p]=!0;v=Object.keys(q);if(v.length)for(u=0;u<v.length;u++)p=E.getCoordsFromColumnName(v[u]),q=this.options.mergeCells[v[u]],p[0]<h&&(h=p[0]),p[0]+q[0]-1>l&&(l=p[0]+q[0]-1),p[1]<m&&(m=p[1]),p[1]+q[1]-1>n&&(n=p[1]+q[1]-1)}}f==_$_f495[126]&&(this.selectedCell?(Da.call(this,!1),p=1):p=0,this.selectedCell=[c,b,a,d],this.records[d][a].element&&G.isVisible.call(this,this.records[d][a].element),da.position.call(this,
128
- c,b),0==p&&F.call(this.parent,_$_f495[129],this));ha[_$_f495[11]].call(this,h,m,l,n,f,g);f==_$_f495[126]&&(na.execute.call(this.parent,_$_f495[130],[this,h,m,l,n,e]),F.call(this.parent,_$_f495[131],this,h,m,l,n,e),fa.update.call(this.parent,t.current,this.selectedCell))};k.fromElements=function(c,b,a){var d=c.getAttribute(_$_f495[42]);c=c.getAttribute(_$_f495[43]);if(b){var e=b.getAttribute(_$_f495[42]);b=b.getAttribute(_$_f495[43])}else e=d,b=c;this.updateSelectionFromCoords(d,c,e,b,a)};k.all=function(){k[_$_f495[11]].call(this,
129
- 0,0,this.options.columns.length-1,this.records.length-1)};k.getRange=function(){var c=this.selectedCell;if(!c)return _$_f495[3];var b=E.getColumnNameFromCoords(c[0],c[1]);c=E.getColumnNameFromCoords(c[2],c[3]);var a=this.options.worksheetName;a=-1!=a.indexOf(_$_f495[132])?_$_f495[133]+a+_$_f495[134]:a+_$_f495[135];return b==c?a+b:a+t.helpers.getRangeFromTokens(t.helpers.getTokensFromRange(b+_$_f495[136]+c))};return k}(),ha=function(){var k=function(a){a.borders=[];a.setBorder=k[_$_f495[11]];a.getBorder=
130
- k[_$_f495[51]];a.resetBorders=k.reset;a.refreshBorders=k.refresh};k[_$_f495[51]]=function(a){return this.borders[a]};var c=function(a,d,e,f,g,h){g||(g=0);if(!ya.isValid.call(this,a,d,e,f))return!1;if(this.borders[g])l=this.borders[g];else{var l={};l.element=document.createElement(_$_f495[20]);l.element.classList.add(_$_f495[137]);g==_$_f495[127]||g==_$_f495[138]||g==_$_f495[126]?l.element.classList.add(_$_f495[139]+g):(h=h?h:jSuites.randomColor(!0),l.color=h,l.element.style.backgroundColor=h+_$_f495[140],
131
- l.element.style.borderColor=h);this.content.appendChild(l.element)}l.x1=a;l.y1=d;l.x2=e;l.y2=f;h=this.headers[a]?this.headers[a].offsetLeft:0;var m=this.headers[e]?this.headers[e].offsetLeft:0,n=this.rows[d].element?this.rows[d].element.offsetTop:0,p=this.rows[f].element?this.rows[f].element.offsetTop:0;l.element.style.top=_$_f495[141];l.element.style.left=_$_f495[141];l.active=0;var q=this.options.freezeColumns||0,v=!1,u=null,w=null,x=null,y=null;this.tbody.firstChild&&(w=parseInt(this.tbody.firstChild.getAttribute(_$_f495[43])),
132
- y=parseInt(this.tbody.lastChild.getAttribute(_$_f495[43])));this.thead.lastChild&&(u=parseInt(this.thead.lastChild.children[q+1].getAttribute(_$_f495[42])),x=parseInt(this.thead.lastChild.lastChild.getAttribute(_$_f495[42])),this.thead.lastChild.children[1].style.display==_$_f495[40]&&(u=La.call(this,u,w)),this.thead.lastChild.lastChild.style.display==_$_f495[40]&&(x=Ma.call(this,x,y)));null==u||e<u&&a>=q||a>x||f<w||d>y||(h?l.element.style.borderLeftColor=l.color?l.color:_$_f495[3]:(h=this.thead.lastChild.children[q+
133
- 1].offsetLeft,l.element.style.borderLeftColor=g==_$_f495[127]?_$_f495[142]:_$_f495[143]),m?(m+=this.headers[e].offsetWidth,l.element.style.borderRightColor=l.color?l.color:_$_f495[3]):(e>x?(m=this.headers[x].offsetLeft+this.headers[x].offsetWidth,v=!0):m=this.thead.lastChild.children[q].offsetLeft+this.thead.lastChild.children[q].offsetWidth,l.element.style.borderRightColor=g==_$_f495[127]?_$_f495[142]:_$_f495[143]),m=m-h-1,n?l.element.style.borderTopColor=l.color?l.color:_$_f495[3]:(n=this.tbody.firstChild.offsetTop,
134
- l.element.style.borderTopColor=g==_$_f495[127]?_$_f495[142]:_$_f495[143]),p?(p+=this.rows[f].element.offsetHeight,l.element.style.borderBottomColor=l.color?l.color:_$_f495[3]):(p=this.rows[y].element.offsetTop+this.rows[y].element.offsetHeight,l.element.style.borderBottomColor=g==_$_f495[127]?_$_f495[142]:_$_f495[143],v=!0),p=p-n-1,this.options.freezeColumns&&(l.element.style.borderLeftWidth=_$_f495[3],l.element.style.borderRightWidth=_$_f495[3],d=0<this.content.scrollLeft?ka.getWidth.call(this):
135
- 0)&&(a=a<this.options.freezeColumns,e=e<this.options.freezeColumns,a&&e||!a&&e||(a&&!e?(e=d+this.content.scrollLeft,e>h+m&&(l.element.style.borderRightWidth=_$_f495[144],m+=e-(h+m))):(e=d+this.content.scrollLeft,e>h&&(e-=h,e>m?h=n=-2E3:(h=h+e+1,m-=e,l.element.style.borderLeftWidth=_$_f495[144]))))),l.element.style.top=n+_$_f495[44],l.element.style.left=h+_$_f495[44],l.element.style.width=m+_$_f495[44],l.element.style.height=p+_$_f495[44],l.t=n,l.l=h,l.w=m,l.h=p,l.active=1);g==_$_f495[126]&&(l.active&&
136
- 1!=v?(this.corner.style.top=n+p-2+_$_f495[44],this.corner.style.left=h+m-2+_$_f495[44]):(this.corner.style.top=_$_f495[141],this.corner.style.left=_$_f495[141]));this.borders[g]=l},b=function(a,d){a.element.style.top=_$_f495[141];a.element.style.left=_$_f495[141];a.active=0;d&&(a.x1=null,a.y1=null,a.x2=null,a.y2=null)};k[_$_f495[11]]=function(a,d,e,f,g,h){c.call(this,a,d,e,f,g,h);g==_$_f495[126]&&(Da.call(this,!0),L.call(this,_$_f495[104],{x1:a,y1:d,x2:e,y2:f}))};k.reset=function(a,d){a&&a!=_$_f495[126]||
137
- (this.corner.style.top=_$_f495[141],this.corner.style.left=_$_f495[141],Da.call(this,!1));if(a)this.borders[a]&&b(this.borders[a],d);else{d=Object.keys(this.borders);for(var e=0;e<d.length;e++)b(this.borders[d[e]])}a&&a!=_$_f495[126]||L.call(this,_$_f495[105])};k.refresh=function(a){var d=this.borders;if(a)d[a]&&null!=d[a].x1&&c.call(this,d[a].x1,d[a].y1,d[a].x2,d[a].y2,a);else{a=Object.keys(d);for(var e=0;e<a.length;e++)d[a[e]]&&null!=d[a[e]].x1&&c.call(this,d[a[e]].x1,d[a[e]].y1,d[a[e]].x2,d[a[e]].y2,
138
- a[e])}this.edition&&(d=this.parent.input,da.position.call(this,d.x,d.y))};k.destroy=function(a){var d;if(d=this.borders[a])d.element.remove(),delete this.borders[a]};return k}(),Ua=function(){var k=function(c){c.setGroup=k[_$_f495[11]];c.unsetGroup=k.unset};k[_$_f495[11]]=function(c,b,a){0==c&&(a=document.createElement(_$_f495[145]),a.classList.add(_$_f495[146]),this.thead.insertBefore(a,this.thead.firstChild),c=document.createElement(_$_f495[147]),c.innerHTML=_$_f495[148],a.appendChild(c),c=document.createElement(_$_f495[147]),
139
- a.appendChild(c),b=this.headers[b])&&(b=b.querySelector(_$_f495[149]),b||(b=document.createElement(_$_f495[20]),b.classList.add(_$_f495[150]),b.innerText=_$_f495[151],c.appendChild(b)))};k.unset=function(c,b){};return k}(),va=function(){var k={start:function(c){if(!Q.call(this.parent,this))return!1;if(null!==c.target.getAttribute(_$_f495[43])){var b=c.target.getAttribute(_$_f495[43]);k.event={y:parseInt(b),h:c.target.offsetHeight,p:c.pageY}}else null!==c.target.getAttribute(_$_f495[42])&&(b=c.target.getAttribute(_$_f495[42]),
140
- k.event={x:parseInt(b),w:c.target.offsetWidth,p:c.pageX})},end:function(c){var b=[];if(null!=k.event.y){var a=parseInt(this.rows[k.event.y].element.offsetHeight);var d=this.getSelectedRows(!0);c=d.indexOf(parseInt(k.event.y));if(d.length&&-1<c)for(var e=0;e<d.length;e++)b.push(parseInt(this.rows[d[e]].element.offsetHeight));else d=[];-1==c?(d.push(k.event.y),b.push(k.event.h)):b[c]=k.event.h;this.setHeight(d,a,b)}else if(null!=k.event.x){a=parseInt(this.colgroup[k.event.x].getAttribute(_$_f495[152]));
141
- d=this.getSelectedColumns();c=d.indexOf(parseInt(k.event.x));if(d.length&&-1<c)for(e=0;e<d.length;e++)b.push(parseInt(this.options.columns[d[e]].width));else d=[];-1==c?(d.push(k.event.x),b.push(k.event.w)):b[c]=k.event.w;this.setWidth(d,a,b)}k.event=null},update:function(c){null!=k.event.y?(c=c.pageY-k.event.p,0<k.event.h+c&&(this.rows[k.event.y].element.style.height=k.event.h+c+_$_f495[44],this.refreshBorders())):null!=k.event.x&&(c=c.pageX-k.event.p,0<k.event.w+c&&(this.colgroup[k.event.x].setAttribute(_$_f495[152],
142
- k.event.w+c),this.options.columns[k.event.x].width=k.event.w+c,0<this.options.freezeColumns&&ka.width.call(this),this.refreshBorders()))},cancel:function(){k.end.call(this)}};return k}(),Oa=function(){var k={start:function(c){var b=this.parent.helper;c=parseInt(c.target.getAttribute(_$_f495[42]));if(this.merged.cols[c])console.error(_$_f495[153]);else{k.event={x:c,d:c};this.headers[c].classList.add(_$_f495[154]);for(var a=0;a<this.tbody.children.length;a++){var d=this.tbody.children[a].getAttribute(_$_f495[43]);
143
- this.records[d][c].element.classList.add(_$_f495[154])}a=this.parent.element.getBoundingClientRect();c=this.headers[c].getBoundingClientRect();d=this.content.getBoundingClientRect();b.style.display=_$_f495[16];b.style.top=d.top-a.top+_$_f495[44];b.style.left=c.left-d.left+_$_f495[44];b.style.width=_$_f495[155];b.style.height=d.height+_$_f495[44];b.classList.add(_$_f495[156])}},end:function(){this.headers[k.event.x].classList.remove(_$_f495[154]);for(var c=0;c<this.tbody.children.length;c++){var b=
144
- this.tbody.children[c].getAttribute(_$_f495[43]);this.records[b][k.event.x].element.classList.remove(_$_f495[154])}null!=k.event.d&&k.event.x!=k.event.d&&(this.moveColumn(k.event.x,k.event.d),this.refreshBorders());this.parent.helper.classList.remove(_$_f495[156]);this.parent.helper.style.display=_$_f495[3];k.event=null},cancel:function(){k.event.d=null;k.end.call(this)},update:function(c){var b=c.target.getAttribute(_$_f495[42]);if(null!=b)if(b=parseInt(b),this.merged.cols[b])console.error(_$_f495[153]);
145
- else{c=c.target.clientWidth/2>c.offsetX;k.event.d=c?k.event.x<b?parseInt(b)-1:parseInt(b):k.event.x>b?parseInt(b)+1:parseInt(b);b=this.headers[b].getBoundingClientRect();var a=this.content.getBoundingClientRect();this.parent.helper.style.left=(c?b.left:b.right)-a.left+_$_f495[44]}}};return k}(),ra=function(){var k={start:function(c){if(Q.call(this.parent,this)){this.resetSelection();var b=this.parent.helper;if(null!==c.target.getAttribute(_$_f495[43])){var a=parseInt(c.target.getAttribute(_$_f495[43]));
146
- this.merged.rows[a]?console.error(_$_f495[157]):this.results?console.error(_$_f495[158]):(k.event={y:a,d:a},this.rows[a].element.classList.add(_$_f495[154]),c=this.parent.element.getBoundingClientRect(),a=this.rows[a].element.getBoundingClientRect(),b.style.display=_$_f495[16],b.style.top=a.top-c.top+_$_f495[44],b.style.left=_$_f495[159],b.style.width=this.content.offsetWidth-50+_$_f495[44],b.style.height=_$_f495[155],b.classList.add(_$_f495[160]))}else if(null!==c.target.getAttribute(_$_f495[42]))if(a=
147
- parseInt(c.target.getAttribute(_$_f495[42])),this.merged.cols[a])console.error(_$_f495[153]);else{k.event={x:a,d:a};this.headers[a].classList.add(_$_f495[154]);for(c=0;c<this.tbody.children.length;c++){var d=this.tbody.children[c].getAttribute(_$_f495[43]);this.records[d][a].element.classList.add(_$_f495[154])}c=this.parent.element.getBoundingClientRect();a=this.headers[a].getBoundingClientRect();d=this.content.getBoundingClientRect();b.style.display=_$_f495[16];b.style.top=d.top-c.top+_$_f495[44];
148
- b.style.left=a.left-d.left+_$_f495[44];b.style.width=_$_f495[155];b.style.height=d.height+_$_f495[44];b.classList.add(_$_f495[156])}}else return!1},end:function(){if(null!=k.event.y)this.rows[k.event.y].element.classList.remove(_$_f495[154]),null!=k.event.d&&k.event.y!=k.event.d&&(this.moveRow(k.event.y,k.event.d),this.updateSelectionFromCoords(0,k.event.d,this.options.columns.length-1,k.event.d)),this.parent.helper.classList.remove(_$_f495[160]);else if(null!=k.event.x){this.headers[k.event.x].classList.remove(_$_f495[154]);
149
- for(var c=0;c<this.tbody.children.length;c++){var b=this.tbody.children[c].getAttribute(_$_f495[43]);this.records[b][k.event.x].element.classList.remove(_$_f495[154])}null!=k.event.d&&k.event.x!=k.event.d&&(this.moveColumn(k.event.x,k.event.d),this.refreshBorders());this.parent.helper.classList.remove(_$_f495[156])}this.parent.helper.style.display=_$_f495[3];k.event=null},cancel:function(){k.event.d=null;k.end.call(this)},update:function(c){if(null!=k.event.y){var b=c.target.getAttribute(_$_f495[43]);
150
- if(null!=b){var a=b=parseInt(b),d=c.target.clientHeight/2>c.offsetY;d?k.event.y<b&&(a=b-1):k.event.y>b&&(a=b+1);c=!1;this.merged.rows[a]&&(k.event.y>a?this.merged.rows[a-1]&&(c=!0):this.merged.rows[a+1]&&(c=!0));c||(k.event.d=a,a=this.parent.element.getBoundingClientRect(),b=this.rows[b].element.getBoundingClientRect(),this.parent.helper.style.top=(d?b.top:b.bottom)-a.top+_$_f495[44])}}else d=c.target.getAttribute(_$_f495[42]),null!=d&&(a=d=parseInt(d),(b=c.target.clientWidth/2>c.offsetX)?k.event.x<
151
- d&&(a=d-1):k.event.x>d&&(a=d+1),c=!1,this.merged.cols[a]&&(k.event.x>a?this.merged.cols[a-1]&&(c=!0):this.merged.cols[a+1]&&(c=!0)),c||(k.event.d=a,a=this.headers[d].getBoundingClientRect(),d=this.content.getBoundingClientRect(),this.parent.helper.style.left=(b?a.left:a.right)-d.left+_$_f495[44]))}};return k}(),ba=function(){var k=function(c){c.getMerge=k[_$_f495[51]];c.setMerge=k[_$_f495[11]];c.updateMerge=k.update;c.removeMerge=k.remove;c.destroyMerged=c.destroyMerge=k.destroy};k.getHeight=function(c,
152
- b){var a,d=1;if(this.merged.rows[c])for(var e=0;e<this.options.columns.length;e++){var f=E.getColumnNameFromCoords(e,c);if(f=this.merged.cells[f])if(a=this.options.mergeCells[f])b&&void 0!==b[f]||(a[1]>d&&(d=a[1]),b&&(b[f]=this.records[c][e].element&&!this.records[c][e].merged?!0:!1))}return d-1};k.getWidth=function(c,b){var a,d=1;if(this.merged.cols[c])for(var e=0;e<this.options.data.length;e++){var f=E.getColumnNameFromCoords(c,e);if(f=this.merged.cells[f])if(a=this.options.mergeCells[f])b&&void 0!==
153
- b[f]||(a[0]>d&&(d=a[0]),b&&(b[f]=this.records[e][c].element&&!this.records[e][c].merged?!0:!1))}return d-1};k[_$_f495[51]]=function(c){return c?this.options.mergeCells[c]:this.options.mergeCells};k[_$_f495[11]]=function(c,b,a){if(!Q.call(this.parent,this))return!1;this.options.mergeCells||(this.options.mergeCells={});var d,e=null,f={},g={},h={},l=!1;typeof c==_$_f495[17]?h[c]=[b,a]:typeof c==_$_f495[84]?h=c:((e=this.getHighlighted())?e=[E.getColumnNameFromCoords(e[0],e[1]),e[2]-e[0]+1,e[3]-e[1]+1]:
154
- (jSuites.notification({message:C(_$_f495[161])}),e=!1),e&&(h[e[0]]=[e[1],e[2]]));b=Object.keys(h);if(b.length){for(a=0;a<b.length;a++){var m=b[a],n=h[b[a]][0],p=h[b[a]][1];n=parseInt(n);p=parseInt(p);if((!n||2>n)&&(!p||2>p))console.log(C(_$_f495[162])+_$_f495[136]+m);else if(this.options.mergeCells[m])g[m]=[n,p],f[m]=this.options.mergeCells[m],k.update.call(this,m,n,p);else{e=E.getCoordsFromColumnName(m);for(var q=e[1];q<e[1]+p;q++)for(var v=e[0];v<e[0]+n;v++)c=E.getColumnNameFromCoords(v,q),(d=this.merged.cells[c])&&
155
- this.options.mergeCells[d]&&(f[d]=this.options.mergeCells[d],k.applyDestroy.call(this,d));g[m]=this.options.mergeCells[m]=[n,p];k.applyCreate.call(this,m);M.attached.call(this,e[0],e[1])||(l=e)}}Object.keys(g).length&&(l&&G[_$_f495[46]].call(this,e[1],e[0]),U.call(this.parent,{worksheet:this,action:_$_f495[69],newValue:g,oldValue:f}),L.call(this,_$_f495[69],[g]),k.build.call(this),ya.refresh.call(this),ha.refresh.call(this),F.call(this.parent,_$_f495[163],this,g,f))}};k.update=function(c,b,a){var d=
156
- this.options.mergeCells;if(d[c]){var e=d[c][1];if(b!==d[c][0]||e!==a)k.applyDestroy.call(this,c),b&&a&&(d[c]=[b,a],k.applyCreate.call(this,c))}};k.remove=function(c,b){if(!Q.call(this.parent,this))return!1;b={};var a={},d={};typeof c==_$_f495[17]?d[c]=!0:typeof c==_$_f495[84]&&(d=c);c=Object.keys(d);for(d=0;d<c.length;d++)this.options.mergeCells[c[d]]&&(b[c[d]]=this.options.mergeCells[c[d]],a[c[d]]=!0,k.applyDestroy.call(this,c[d],!0));U.call(this.parent,{worksheet:this,action:_$_f495[70],newValue:a,
157
- oldValue:b});L.call(this,_$_f495[70],{data:a})};k.destroy=function(){k.remove.call(this,this.options.mergeCells,!0)};k.applyCreate=function(c,b){var a=this.options.mergeCells;if(a[c]){var d=a[c][0]||1,e=a[c][1]||1;c=E.getCoordsFromColumnName(c);if(!this.records[c[1]][c[0]].merged||1==b)if(a=M[_$_f495[51]].call(this,c[0],c[1])){a.style.display=_$_f495[3];1<d?a.setAttribute(_$_f495[52],d):a.removeAttribute(_$_f495[52]);1<e?a.setAttribute(_$_f495[164],e):a.removeAttribute(_$_f495[164]);1==this.options.textOverflow&&
158
- (a.style.overflow=_$_f495[49]);for(var f=0;f<e;f++)for(var g=0;g<d;g++){b=c[0]+g;var h=c[1]+f;if(a=this.records[h][b])if(a.merged=[g,f,a.v,a.v],0!=g||0!=f)a.element||M[_$_f495[51]].call(this,b,h),a.element.style.display=_$_f495[40],a.merged[3]=a.element.innerText,a.element.innerText=_$_f495[3],N.call(this,b,h,_$_f495[3])}}}};k.applyDestroy=function(c,b){var a=this.options.mergeCells;if(a[c]){var d=E.getCoordsFromColumnName(c),e=d[0];d=d[1];var f=a[c][0],g=a[c][1];delete this.options.mergeCells[c];
159
- for(c=0;c<g;c++)for(var h=0;h<f;h++)if(a=this.records[d+c][e+h])a.element&&(0==h&&0==c?(a.element.removeAttribute(_$_f495[52]),a.element.removeAttribute(_$_f495[164])):(a.element.style.display=_$_f495[3],1==b&&(N.call(this,e+h,d+c,a.merged[2]),a.element.innerHTML=a.merged[3]))),a.merged&&delete a.merged}};k.updateConfig=function(c,b,a,d){if(1==b)var e=[a];else{e=[];for(var f=a;f<a+d;f++)e.push(f)}var g=this.options.mergeCells,h=Object.keys(g),l={};for(f=0;f<h.length;f++){a=E.getCoordsFromColumnName(h[f]);
160
- for(var m=a[c];m<a[c]+g[h[f]][c];m++)-1!==e.indexOf(m)&&(l[h[f]]||(l[h[f]]=[g[h[f]][0],g[h[f]][1]],1==b&&(l[h[f]][c]+=d)),0==b&&l[h[f]][c]--)}h=Object.keys(l);for(f=0;f<h.length;f++)k.update.call(this,h[f],l[h[f]][0],l[h[f]][1]);k.build.call(this)};k.build=function(){var c=this.options.mergeCells;this.merged={cols:[],rows:[],cells:[]};if(c)for(var b=Object.keys(c),a=0;a<b.length;a++){for(var d=E.getCoordsFromColumnName(b[a]),e=parseInt(c[b[a]][0]),f=parseInt(c[b[a]][1]),g=0;g<e;g++)this.merged.cols[d[0]+
161
- g]=!0;for(var h=0;h<f;h++)this.merged.rows[d[1]+h]=!0;for(h=0;h<f;h++)for(g=0;g<e;g++){var l=E.getColumnNameFromCoords(d[0]+g,d[1]+h);this.merged.cells[l]=b[a]}}};k.batch=function(c){var b=Object.keys(c);if(b.length)for(var a=0;a<b.length;a++)!1===c[b[a]]&&k.applyCreate.call(this,b[a])};return k}(),Ba=function(){var k=function(c){c.getHeader=k[_$_f495[51]];c.setHeader=k[_$_f495[11]];c.getHeaders=k.all};k[_$_f495[51]]=function(c){var b;if(b=this.options.columns)return b[c].title||E.getColumnName(c)};
162
- k.all=function(c){for(var b=[],a=0;a<this.options.columns.length;a++)b.push(k[_$_f495[51]].call(this,a));return c?b:b.join(this.options.csvDelimiter)};k[_$_f495[11]]=function(c,b){if(!Q.call(this.parent,this))return!1;var a;if(a=this.options.columns[c]){var d=k[_$_f495[51]].call(this,c);if(!b&&(b=prompt(C(_$_f495[165]),d),!b))return!1;a.title=b;if(a=this.headers[c])a.innerHTML=b,a.setAttribute(_$_f495[166],b);U.call(this.parent,{worksheet:this,action:_$_f495[75],column:c,oldValue:d,newValue:b});L.call(this,
163
- _$_f495[75],{column:c,title:b});F.call(this.parent,_$_f495[167],this,c,b,d)}};k.create=function(c){var b=this.options.columns[c],a=b.width||this.options.defaultColWidth,d=b.align||_$_f495[53],e=b.title||E.getColumnName(c),f=document.createElement(_$_f495[147]);this.parent.config.stripHTML?f.innerText=e:f.innerHTML=e;f.setAttribute(_$_f495[42],c);f.style.textAlign=d;b.title&&f.setAttribute(_$_f495[166],f.innerText);b.tooltip&&(f.title=b.tooltip);d=this.options.filters;!0===b.filter&&(d=!0);!1===b.filter&&
164
- (d=!1);!0===d&&f.classList.add(_$_f495[168]);!1===b.visible&&(a=_$_f495[97]);d=document.createElement(_$_f495[169]);d.setAttribute(_$_f495[152],a);b.type==_$_f495[49]&&(f.style.display=_$_f495[40],d.style.display=_$_f495[40]);this.headers[c]=f;this.colgroup[c]=d};return k}(),aa=function(){var k=function(b,a,d){var e=this.footers.content,f;e&&e[a]&&e[a][b]&&(f=e[a][b].element)&&(void 0===d&&(e=this.options.footers,d=e[a]&&e[a][b]?e[a][b]:_$_f495[3]),P(d)&&1==this.parent.config.parseFormulas&&(d=V.execute.call(this,
165
- d,b,null,!1)),this.options.applyMaskOnFooters&&(e=da[_$_f495[51]].call(this,b),d=t.editors.general.parseValue(b,a,d,this,e[1],f)),d instanceof Element||d instanceof HTMLDocument?(f.innerHTML=_$_f495[3],f.appendChild(d)):1==this.parent.config.stripHTML?f.innerText=d:f.innerHTML=d)},c=function(b){b.getFooter=c[_$_f495[51]];b.setFooter=c[_$_f495[11]];b.resetFooter=c.reset;b.refreshFooter=c.refresh;b.getFooterValue=c.value;b.setFooterValue=c.value};c[_$_f495[51]]=function(){return this.options.footers};
166
- c[_$_f495[11]]=function(b){if(b){var a=this.options.footers;this.options.footers=b}this.options.footers!=a&&(aa.build.call(this),c.render.call(this),G.limited.call(this)&&(this.scrollY.style.display=_$_f495[40],G.resetY.call(this)),L.call(this,_$_f495[170],{data:this.options.footers}),F.call(this.parent,_$_f495[171],this,this.options.footers,a))};c.refresh=function(){var b=this.options.footers;if(b&&b.length)for(var a=0;a<b.length;a++)for(var d=0;d<b[a].length;d++)k.call(this,d,a,b[a][d])};c.value=
167
- function(b,a,d){if(void 0===d)return this.options.footers[a][b];k.call(this,b,a,d);L.call(this,_$_f495[172],{x:b,y:a,value:d});F.call(this.parent,_$_f495[173],this,b,a,d)};c.reset=function(){var b=this.options.footers;this.options.footers=null;this.footers.content=null;this.tfoot.innerHTML=_$_f495[3];L.call(this,_$_f495[174],{});F.call(this.parent,_$_f495[171],this,null,b)};c.create=function(b,a){var d=this.footers.content[a][b];if(d&&d.element)return d.element;d=this.footers.content[a][b]={};var e=
168
- this.options.columns[b].align?this.options.columns[b].align:_$_f495[53];d.element=document.createElement(_$_f495[147]);d.element.style.textAlign=e;d.element.setAttribute(_$_f495[42],b);d.element.setAttribute(_$_f495[43],a);k.call(this,b,a);this.options.columns[b].type==_$_f495[49]&&(d.element.style.display=_$_f495[40]);return d.element};c.build=function(){this.footers={element:this.tfoot,content:[]};if(this.options.footers){this.tfoot.innerHTML=_$_f495[3];for(var b=0;b<this.options.footers.length;b++){if(!this.footers.content[b]){this.footers.content[b]=
169
- [];var a=document.createElement(_$_f495[145]),d=document.createElement(_$_f495[147]);d.innerHTML=_$_f495[148];a.appendChild(d);this.footers.element.appendChild(a)}for(a=0;a<this.options.columns.length;a++)this.options.footers[b][a]||(this.options.footers[b][a]=_$_f495[3]),this.footers.content[b][a]||(this.footers.content[b][a]={})}}};c.render=function(){for(var b=this.options.footers,a=0;a<b.length;a++)for(var d=0;d<b[a].length;d++){var e=aa.create.call(this,d,a);this.tfoot.children[a].appendChild(e)}};
170
- c.adjust=function(b,a,d){var e=[],f=this.options.footers,g=this.footers.content;if(f)if(1==d){if(this.headers[b]&&this.headers[b].parentNode)var h=this.headers[b]==this.thead.lastChild.lastChild?!0:!1,l=!0;for(d=0;d<f.length;d++){for(var m=f[d].splice(b),n=b;n<b+a;n++)f[d][n]=_$_f495[3];f[d]=f[d].concat(m);m=g[d].splice(b);for(n=b;n<b+a;n++)g[d][n]={element:c.create.call(this,n,d)},l&&(1==h?this.tfoot.children[d].appendChild(g[d][n].element):this.tfoot.children[d].insertBefore(g[d][n].element,this.tfoot.children[d].children[b].nextSibling));
171
- g[d]=g[d].concat(m)}}else for(d=0;d<f.length;d++){for(n=b;n<b+a;n++)(h=this.footers.content[d][n].element)&&h.parentNode&&h.parentNode.removeChild(h);g[d].splice(b,a);e[d]=f[d].splice(b,a)}return e};return c}(),pa=function(){var k=function(c){c.setNestedCell=k.cell;c.getNestedCell=k.cell;c.setNestedHeaders=k[_$_f495[11]];c.getNestedHeaders=k[_$_f495[51]];c.resetNestedHeaders=k.reset};k[_$_f495[51]]=function(){return this.options.nestedHeaders};k[_$_f495[11]]=function(c){k.reset.call(this);this.options.nestedHeaders=
172
- c;k.build.call(this);k.render.call(this);ha.refresh.call(this);T.call(this);L.call(this,_$_f495[175],{data:c});F.call(this.parent,_$_f495[176],this,c)};k.reset=function(){var c=[],b=this.thead.children;this.options.nestedHeaders=null;for(var a=0;a<b.length;a++)b[a].classList.contains(_$_f495[177])&&c.push(b[a]);if(c.length)for(;b=c.shift();)b.remove();this.nested=null;ha.refresh.call(this);T.call(this);L.call(this,_$_f495[178]);F.call(this.parent,_$_f495[176],this,[])};k.cell=function(c,b,a){if(a){if(!Q.call(this.parent,
173
- this))return!1;var d=this.options.nestedHeaders[b][c],e=this.nested.content[b][c].element;void 0!==a.title&&(e.innerText=a.title);void 0!==a.tooltip&&(e.title=a.tooltip);void 0!==a.colspan&&(d.colspan=a.colspan,e.setAttribute(_$_f495[52],a.colspan),e.style.display=0==d.colspan?_$_f495[40]:_$_f495[3]);L.call(this,_$_f495[179],{x:c,y:b,properties:a});F.call(this.parent,_$_f495[180],this,c,b,a)}else return this.nested.content[b][c].element};k.range=function(c){c=this.options.nestedHeaders[c];for(var b=
174
- [],a=0,d=0;d<c.length;d++){var e=parseInt(c[d].colspan);b[d]=[a,a+e-1];a+=e}return b};k.getColumns=function(c){c=this.options.nestedHeaders[c];for(var b=[],a=0;a<c.length;a++)for(var d=c[a].colspan,e=0;e<d;e++)b.push(a);return b};k.create=function(c,b){if(this.nested.content[b][c])return this.nested.content[b][c].element;var a=this.options.nestedHeaders[b][c]||{},d=this.nested.content[b][c]={};a.colspan||(a.colspan=1);a.align||(a.align=_$_f495[53]);a.title||(a.title=_$_f495[3]);var e=document.createElement(_$_f495[147]);
175
- e.setAttribute(_$_f495[181],c);e.setAttribute(_$_f495[182],b);e.setAttribute(_$_f495[52],a.colspan);e.setAttribute(_$_f495[183],a.align);e.innerHTML=a.title;a.tooltip&&(e.title=a.tooltip);return d.element=e};k.build=function(){this.nested||(this.nested={content:[]});if(this.options.nestedHeaders)for(var c=0;c<this.options.nestedHeaders.length;c++){this.nested.content[c]=[];var b=document.createElement(_$_f495[147]);b.innerHTML=_$_f495[148];var a=document.createElement(_$_f495[145]);a.classList.add(_$_f495[177]);
176
- a.appendChild(b);this.thead.insertBefore(a,this.thead.lastChild)}};k.render=function(){for(var c,b=this.options.nestedHeaders,a=0;a<b.length;a++)for(var d=0;d<this.thead.lastChild.children.length;d++){c=this.thead.lastChild.children[d].getAttribute(_$_f495[42]);var e=k.getColumns.call(this,a);void 0!==e[c]&&k.renderCell.call(this,e[c],a)}};k.renderCell=function(c,b,a){var d=pa.create.call(this,c,b);d.parentNode?(c=d.getAttribute(_$_f495[52]),c++,d.setAttribute(_$_f495[52],c)):(d.setAttribute(_$_f495[52],
177
- 1),a?this.thead.children[b].insertBefore(d,this.thead.children[b].children[a]):this.thead.children[b].appendChild(d),0==c&&0<this.options.freezeColumns&&(d.classList.add(_$_f495[50]),d.style.left=xa.call(this)?_$_f495[159]:_$_f495[155]))};k.adjust=function(c,b,a,d){var e=this.options.nestedHeaders;if(e)if(1==a)if(d&&d.nested)for(a=0;a<e.length;a++)for(var f=0;f<e[a].length;f++)k.cell.call(this,f,a,{colspan:d.nested[a][f]});else for(a=0;a<e.length;a++){if(f=k.getColumns.call(this,a)){f=f[c];var g=
178
- parseInt(e[a][f].colspan)+b;k.cell.call(this,f,a,{colspan:g})}}else{d=[];for(a=0;a<e.length;a++)if(g=k.getColumns.call(this,a)){d[a]=[];for(f=0;f<b;f++){var h=g[c+f];typeof d[a][h]==_$_f495[13]&&(d[a][h]=e[a][h].colspan);e[a][h].colspan--}g=Object.keys(d[a]);for(f=0;f<g.length;f++)k.cell.call(this,g[f],a,{colspan:e[a][g[f]].colspan})}return d}};return k}(),ma=function(){var k=function(c,b){var a=function(n){var p;(p=this.results)?n=p.indexOf(n):p=this.rows;n--;for(var q=n;0<=q;q--)if(n=this.results?
179
- p[q]:q,this.rows[n]&&this.rows[n].element)return n;return 0},d=function(n){var p;(p=this.results)?n=p.indexOf(n):p=this.rows;n++;for(var q=n;q<p.length;q++)if(n=this.results?p[q]:q,this.rows[n]&&this.rows[n].element)return n;return p[p.length-1]},e=function(n,p){for(;0<=n;n--)if(this.records[p][n].element&&this.records[p][n].element.style.display!=_$_f495[40])return n;return 0},f=function(n,p){for(;n<this.options.columns.length;n++)if(this.records[p][n].element&&this.records[p][n].element.style.display!=
180
- _$_f495[40])return n;return this.options.columns-1},g=this.getHighlighted(),h=g[0],l=g[1],m=g[2];g=g[3];c=parseInt(c);b=parseInt(b);null!=c&&null!=b&&(0<c-m?(f=f.call(this,parseInt(m)+1,b),c=parseInt(c)):(f=parseInt(c),c=e.call(this,parseInt(h)-1,b)),0<b-g?(d=d.call(this,parseInt(g)),b=parseInt(b)):(d=parseInt(b),b=a.call(this,parseInt(l))),c-f<=b-d?(f=parseInt(h),c=parseInt(m)):(d=parseInt(l),b=parseInt(g)),this.setBorder(f,d,c,b,_$_f495[138]))};k.execute=function(c){if(!Q.call(this.parent,this))return!1;
181
- var b=this.borders.cloning;if(c)if(b&&b.active){c=b.x1;var a=b.y1,d=b.x2,e=b.y2}else return!1;else if(d=this.getSelected(),d.length)c=d[0].x,a=parseInt(d[d.length-1].y)+1,d=d[d.length-1].x,e=this.options.data.length-1;else return!1;var f,g=0,h=[],l=[],m=!1,n=this.getHighlighted(),p=Ea[_$_f495[51]].call(this,n,!1,!1),q=this.getSelected();if(f=this.getStyle(q,!0)){var v=Object.keys(f);if(v.length)for(var u=0;u<v.length;u++)h.push(f[v[u]])}if(n[0]==c)var w=a<n[1]?a-n[1]:1,x=0;else x=c<n[0]?c-n[0]:1,
182
- w=0;v=0;c=parseInt(c);d=parseInt(d);a=parseInt(a);e=parseInt(e);for(var y=a;y<=e;y++)if(!this.results||-1!=this.results.indexOf(y)){void 0==p[g]&&(g=0);f=0;n[0]!=c&&(x=c<n[0]?c-n[0]:1);for(u=c;u<=d;u++){if(!(0!=m||this.records[y][u].element&&this.records[y][u].element.classList.contains(_$_f495[18]))){if((!b||1!=b.active)&&N.call(this,u,y)){m=!0;continue}void 0==p[g]?f=0:void 0==p[g][f]&&(f=0);var D=p[g][f];D&&!p[1]&&1==this.parent.config.autoIncrement&&(this.options.columns[u].type==_$_f495[56]||
183
- this.options.columns[u].type==_$_f495[14]||1==this.options.columns[u].shiftFormulas?P(D)?D=V.shiftFormula(D,x,y-n[1]):D==Number(D)&&(D=Number(D)+w):this.options.columns[u].type==_$_f495[184]&&(D=new Date(D),D.setDate(D.getDate()+w),D=D.getFullYear()+_$_f495[185]+jSuites.two(parseInt(D.getMonth()+1))+_$_f495[185]+jSuites.two(D.getDate())+_$_f495[132]+_$_f495[186]));D={x:u,y,value:D};h&&null!=h[v]&&(D.style=h[v],v++,v>=h.length&&(v=0));l.push(D)}f++;n[0]!=c&&x++}g++;w++}l.length&&(q[0].x<c&&(c=q[0].x),
184
- q[0].y<a&&(a=q[0].y),q[q.length-1].x>d&&(d=q[q.length-1].x),q[q.length-1].y>e&&(e=q[q.length-1].y),this.setValue(l),this.resetBorders(_$_f495[138],!0),this.updateSelectionFromCoords(c,a,d,e))};k.end=function(c){ma.event=!1;ma.execute.call(this,!0)};k.cancel=function(c){ma.event=!1;this.resetBorders(_$_f495[138],!0)};return k}(),Ea=function(){var k=function(c){c.getData=k[_$_f495[51]];c.getJson=k[_$_f495[51]];c.setData=k[_$_f495[11]];c.loadData=k.load;c.getRowData=k.getRowData;c.setRowData=k.setRowData;
185
- c.getColumnData=k.getColumnData;c.setColumnData=k.setColumnData;c.updateData=k.update;c.refresh=k.refresh;c.data=k[_$_f495[51]];c.download=k.download;c.copy=k.copy;c.paste=k.paste;c.cut=function(){return c.copy(!0)}};k[_$_f495[51]]=function(c,b,a){!0===c&&(c=this.getHighlighted());for(var d=c?!0:!1,e,f=[],g=this.options.columns.length,h=this.options.data.length,l,m=this.dataType&&typeof a==_$_f495[13]?1:0,n=0;n<h;n++){l=null;e=m?{}:[];for(var p=0;p<g;p++){var q;if(!(q=!d)){q=c[1];var v=c[2],u=c[3];
186
- q=p>=c[0]&&p<=v&&n>=q&&n<=u?!0:!1}if(q&&(!d||!this.results||-1!=this.results.indexOf(n))){q=N.call(this,p,n);if(b){if(d&&!1===this.rows[n].visible)continue;l=ea.processed.call(this,p,n);void 0!==l&&(q=l)}a&&q.match&&(q.match(a)||q.match(/\n/)||q.match(/"/))&&(q=q.replace(new RegExp(_$_f495[187],_$_f495[188]),_$_f495[189]),q=_$_f495[187]+q+_$_f495[187]);m?jSuites.path.call(e,_$_f495[3]+Z.call(this,p),q):e.push(q);l=!0}}l&&(a?f.push(e.join(a)):f.push(e))}return a?f.join(_$_f495[10])+_$_f495[10]:f};
187
- k.parse=function(){for(var c,b={},a=0,d,e=[],f=this.options.data,g=0;g<f.length;g++)c=null,d=g,f[g].data&&(Array.isArray(f[g].data)||typeof f[g].data==_$_f495[84])&&(typeof f[g].id==_$_f495[14]&&(c=parseInt(f[g].id)),typeof f[g].row==_$_f495[14]&&(d=f[g].row),e[d]=f[g].data,f[g]=[]),d>a&&(a=d),c&&(b[d]=c);if(Object.keys(e).length)for(g=0;g<=a;g++)e[g]&&(f[g]=e[g]);a=this.getPrimaryKey();if(!1!==a)for(a=Z.call(this,a),g=0;g<f.length;g++)b[g]||!1===a||(c=parseInt(f[g][a]),0<c&&(b[g]=c));return b};k.type=
188
- function(){for(var c=this.dataType=0;c<this.options.columns.length;c++)typeof this.options.columns[c].name!==_$_f495[13]&&(this.dataType=1)};k[_$_f495[11]]=function(c){c=k.standardize(c);var b={},a=[],d={};var e=Object.keys(c[0]).length-this.options.columns.length;0<e&&this.insertRow(e);var f=c.length-this.options.data.length;0<f&&this.insertRow(f);for(var g=0;g<this.options.data.length;g++){void 0===c[g]&&(c[g]={row:g,data:[]});for(var h=0;h<this.options.columns.length;h++)c[g].data[h]||(c[g].data[h]=
189
- _$_f495[3])}for(h=0;h<this.options.columns.length;h++){var l=Z.call(this,h);d[l]=h}for(g=0;g<c.length;g++){f=c[g].row;l=Object.keys(c[g].data);for(h=0;h<l.length;h++)e=null,void 0!==d[l[h]]?e=d[l[h]]:-1<l[h]&&(e=parseInt(l[h])),null!==e&&a.push({x:e,y:f,value:c[g].data[l[h]]});c[g].id&&(b[f]=c[g].id)}sa.setId.call(this,b);ea[_$_f495[11]].call(this,a,null,!0)};k.build=function(){this.results=null;this.rows=[];this.records=[];this.sequence=0;k.type.call(this);if(this.options.data){var c=k.parse.call(this),
190
- b=this.options.data.length;this.options.minDimensions[1]>b&&(b=this.options.minDimensions[1]);for(var a=0;a<b;a++){var d=c[a]?c[a]:null;oa.row.call(this,a,d)}}};k.load=function(c){this.resetBorders();this.resetSelection();this.tbody.innerText=_$_f495[3];this.options.data=c;k.build.call(this);G.call(this)};k.refresh=function(c){if(typeof c!==_$_f495[13])for(var b=0;b<this.options.columns.length;b++){var a=this.records[c]&&this.records[c][b].element?this.records[c][b].element:null,d=da[_$_f495[51]].call(this,
191
- b,c);typeof d[0].updateCell==_$_f495[85]&&d[0].updateCell(a,N.call(this,b,c),b,c,this,d[1]);a&&M.applyOverflow.call(this,a,b,c)}else if(this.options.url){var e=this;1==this.parent.config.loadingSpin&&jSuites.loading.show();jSuites.ajax({url:this.options.url,method:_$_f495[59],dataType:_$_f495[60],success:function(f){e.setData(f);jSuites.loading.hide()}})}};k.getRowData=function(c,b){if(typeof this.options.data[c]===_$_f495[13])return!1;if(b){if(this.dataType){b={};for(var a=0;a<this.options.columns.length;a++){var d=
192
- _$_f495[3]+Z.call(this,a),e=_$_f495[3]+ea.processed.call(this,a,c,!0);jSuites.path.call(b,d,e)}}else for(b=[],a=0;a<this.options.columns.length;a++)b.push(ea.processed.call(this,a,c,!0));return b}return JSON.parse(JSON.stringify(this.options.data[c]))};k.setRowData=function(c,b,a){for(var d=[],e=0;e<this.options.columns.length;e++)typeof b[e]===_$_f495[13]&&(b[e]=_$_f495[3]),d.push({x:e,y:c,value:b[e]});d.length&&this.setValue(d,null,a)};k.getColumnData=function(c,b){if(typeof this.options.columns[c]===
193
- _$_f495[13])return!1;for(var a=[],d=0;d<this.options.data.length;d++){var e=b?ea.processed.call(this,c,d,!0):N.call(this,c,d);a.push(e)}return a};k.setColumnData=function(c,b,a){for(var d=[],e=0;e<this.rows.length;e++)typeof b[e]===_$_f495[13]&&(b[e]=_$_f495[3]),d.push({x:c,y:e,value:b[e]});d.length&&this.setValue(d,null,a)};k.copy=function(c){var b=this,a=this.getHighlighted(),d=function(){b.setBorder(a[0],a[1],a[2],a[3],_$_f495[127]);b.borders.copying.clear=1==c?!0:!1},e=k[_$_f495[51]].call(this,
194
- a,!0,_$_f495[190]),f=F.call(this.parent,_$_f495[191],this,a,e);if(f)e=f;else if(!1===f)return!1;navigator.clipboard?navigator.clipboard.writeText(e).then(d):(this.parent.textarea.value=e,this.parent.textarea.select(),document.execCommand(_$_f495[192]),d());return e};k.paste=function(c,b,a){if(!Q.call(this.parent,this))return!1;var d=this,e=function(){d.borders.copying&&(d.resetBorders(_$_f495[127],!0),d.borders.copying.clear=!1)},f=a,g=null,h=this.options.style,l=null,m=null,n=[];if(this.borders.copying){var p=
195
- [this.borders.copying.x1,this.borders.copying.y1,this.borders.copying.x2,this.borders.copying.y2];l=p[0];m=p[1];var q=jSuites.hash(a),v=jSuites.hash(k[_$_f495[51]].call(this,p,!0,_$_f495[190]));if(q!=v)e();else{var u=0,w=0;a=k[_$_f495[51]].call(this,p,!1,!1);for(q=p[1];q<=p[3];q++)if(!this.results||-1!=this.results.indexOf(q)){n[w]=[];u=0;for(v=p[0];v<=p[2];v++)g=E.getColumnNameFromCoords(v,q),n[w][u]=h&&h[g]?h[g]:_$_f495[193],u++;w++}}}c=parseInt(c);b=parseInt(b);100<f.length&&!this.options.pagination&&
196
- !G.limited.call(this)&&console.log(_$_f495[194]);if(q=F.call(this.parent,_$_f495[195],this,a,c,b,n,f))a=q;else if(!1===q)return!1;if(a){Array.isArray(a)||(a=E.parseCSV(a,_$_f495[190]));if(f=this.getHighlighted()){g=[];u=[];w=[];h=[];var x=0,y=0;for(q=f[1];q<=f[3];q++)if(!this.results||-1!=this.results.indexOf(q)){g=[];u=[];for(v=f[0];v<=f[2];v++)g.push(a[y][x]),n&&n[y]&&n[y][x]?u.push(n[y][x]):u.push(_$_f495[3]),x++,x>=a[0].length&&(x=0);w.push(g);h.push(u);y++;y>=a.length&&(y=0)}0==w.length%a.length&&
197
- 0==w[0].length%a[0].length&&(a=w,n=h)}h=null;f=[];if(this.borders.copying&&!0===this.borders.copying.clear){for(q=p[1];q<=p[3];q++)for(v=p[0];v<=p[2];v++)(!this.results||this.results&&0<=this.results.indexOf(q))&&f.push({x:v,y:q,value:_$_f495[3],style:_$_f495[3]});e()}q=c+a[0].length-this.options.columns.length;0<q&&this.insertColumn(q);q=b+a.length-this.rows.length;0<q&&this.insertRow(q);u=g=c;x=w=b;y=null;this.results&&(h=this.results.indexOf(b));for(q=0;q<a.length;q++)for(v=0;v<a[q].length;v++){null!==
198
- l&&null!==m&&a[q][v][0]==_$_f495[12]&&(a[q][v]=V.shiftFormula(a[q][v],c-l,b-m));u=c+v;x=b+q;this.results&&(x=this.results[h+q]);var D={x:u,y:x,value:a[q][v]};n&&n[q]&&n[q][v]&&(D.style=n[q][v]);f.push(D);null===y&&ya.isSelected.call(this,u,x,p)&&(y=!0)}y&&e();f.length&&(ea[_$_f495[11]].call(this,f,null,this.parent.config.forceUpdateOnPaste?!0:!1),F.call(this.parent,_$_f495[196],this,f),this.updateSelectionFromCoords(g,w,u,x))}};k.download=function(c,b){if(this.parent.config.allowExport){void 0===
199
- b&&(b=!0);var a=_$_f495[3];if(1==c||1==this.parent.config.includeHeadersOnDownload)a+=this.getHeaders().replace(/\s+/gm,_$_f495[132])+_$_f495[10];a+=k[_$_f495[51]].call(this,null,b,this.options.csvDelimiter);b=new Blob([_$_f495[198]+a],{type:_$_f495[199]});window.navigator&&window.navigator.msSaveOrOpenBlob?window.navigator.msSaveOrOpenBlob(b,this.options.csvFileName+_$_f495[200]):(c=document.createElement(_$_f495[201]),b=URL.createObjectURL(b),c.href=b,c.setAttribute(_$_f495[202],this.options.csvFileName+
200
- _$_f495[200]),document.body.appendChild(c),c.click(),c.parentNode.removeChild(c))}else console.error(_$_f495[197])};k.standardize=function(c){c||(c=[]);Array.isArray(c)||(c=[c]);void 0==c[0]||Array.isArray(c[0])||typeof c[0]==_$_f495[84]||(c=[c]);for(var b=0;b<c.length;b++){var a={};Array.isArray(c[b])||void 0==c[b].data?a.data=c[b]:a=c[b];a.row=void 0==c[b].row?b:c[b].row;c[b]=a}return c};return k}(),Va=function(){var k=function(c){c.getLabel=k[_$_f495[51]];c.getLabelFromCoords=k[_$_f495[51]]};k[_$_f495[51]]=
201
- function(c,b,a){if(typeof c==_$_f495[17]){c=E.getCoordsFromColumnName(c);var d=c[0];b=c[1]}else d=c;return this.getProcessed(d,b,a)};return k}(),Ha=function(){var k=function(c){c.getDefinedNames=k[_$_f495[51]];c.setDefinedNames=k[_$_f495[11]]};k[_$_f495[11]]=function(c){var b=Object.keys(c);if(b.length){for(var a=0;a<b.length;a++)this.parent.config.definedNames[b[a]]=c[b[a]];L.call(this,_$_f495[203],[c])}};k[_$_f495[51]]=function(c){var b=this.parent.config.definedNames;return c?b[c]:b};k.updateAll=
202
- function(c,b){var a,d={};if(a=this.parent.config.definedNames){var e=Object.keys(a);if(e.length){for(var f=this.getWorksheetName(),g=0;g<e.length;g++){var h=V.update.call(this,a[e[g]],c,b,f);h!==a[e[g]]&&(d[e[g]]=h)}k[_$_f495[11]].call(this,d)}}};k.updateWorksheetName=function(c,b){var a,d={};if(a=this.parent.config.definedNames){var e=Object.keys(a);if(e.length){for(var f=0;f<e.length;f++){var g=V.updateWorksheetName(a[e[f]],c,b);g!==a[e[f]]&&(d[e[f]]=g)}k[_$_f495[11]].call(this,d)}}};return k}(),
203
- la=function(){var k=[_$_f495[204],_$_f495[205],_$_f495[206],_$_f495[207],_$_f495[208]],c=[_$_f495[185],_$_f495[151],_$_f495[209],_$_f495[210],_$_f495[211],_$_f495[212],_$_f495[1],_$_f495[213],_$_f495[25],_$_f495[214],_$_f495[12],_$_f495[215],_$_f495[216]],b=[],a=function(){if(0<b.length){for(var f=0;f<b.length;f++)ha.destroy.call(this,b[f]);b=[]}},d=function(f){a.call(this);for(var g=0,h=[],l,m=0;m<f.children.length;m++)if(l=f.children[m].getAttribute(_$_f495[217])){h[l]||(h[l]=k[g++],4<g&&(g=0));
204
- f.children[m].style.color=h[l];if(-1===l.indexOf(_$_f495[135])){if(0<=l.indexOf(_$_f495[136])){var n=l.split(_$_f495[136]),p=E.getCoordsFromColumnName(n[0]);n=E.getCoordsFromColumnName(n[1])}else n=p=E.getCoordsFromColumnName(l);ya[_$_f495[11]].call(this,p[0],p[1],n[0],n[1],null,l,h[l])}b.push(l)}},e=function(f,g){f.classList.add(_$_f495[92]);f.classList.add(_$_f495[218]);f.classList.add(_$_f495[219]);f.classList.add(_$_f495[220]);f.setAttribute(_$_f495[221],!0);f.onclick=function(h){h=h.changedTouches&&
205
- h.changedTouches[0]?h.changedTouches[0].clientX:h.clientX;var l=this.getBoundingClientRect();24>l.width-(h-l.left)&&(e.current=f,f.classList.add(_$_f495[222]))};f.onblur=function(){f.worksheet&&(a.call(f.worksheet),typeof f.onchange==_$_f495[85]&&f.onchange.call(f),f.worksheet=null)};f.onchange=g};e.current=null;e.parse=function(f){for(var g=_$_f495[3],h=_$_f495[3],l=window.getSelection(),m=document.createRange(),n=E.getCaretIndex.call(this.parent,f),p=V.tokenize(f.innerText.replace(/(\r\n|\n|\r)/gm,
206
- _$_f495[3])),q=0;q<p.length;q++)p[q]&&V.tokenIdentifier.test(p[q].trim())?(q==p.length-1&&(h=_$_f495[223]),g+=_$_f495[224]+h+_$_f495[225]+p[q].trim().replace(/\$/g,_$_f495[3])+_$_f495[226]+p[q]+_$_f495[227]):g+=p[q];f.innerHTML=g;g=null;for(q=0;q<f.childNodes.length&&!(g=f.childNodes[q],h=g.tagName?g.innerText.length:g.length,0>=n-h);q++)n-=h;g&&(g.tagName?m.setStart(g.firstChild,n):m.setStart(g,n),l.removeAllRanges(),l.addRange(m));d.call(this,f)};e.close=function(f){a.call(this);f?f.classList.remove(_$_f495[92]):
207
- e.current&&(typeof e.current.onchange==_$_f495[85]&&e.current.onchange.call(e.current),e.current.classList.remove(_$_f495[222]),e.current.worksheet=null,e.current=null)};e.getName=function(f,g,h,l,m){f=E.getColumnNameFromCoords(f,g);h=E.getColumnNameFromCoords(h,l);m.ctrlKey&&(f=h);return f!==h?(m=f+_$_f495[136]+h,m=V.getTokensFromRange.call(this,m),V.getRangeFromTokens.call(this,m)):f};e.range=function(f,g,h,l,m){e.current.getAttribute(_$_f495[228])==_$_f495[229]&&(f=h,g=l);f=e.getName.call(this,
208
- f,g,h,l,m);g=document.createElement(_$_f495[230]);g.innerText=f;g.setAttribute(_$_f495[217],f);e.current.innerText=_$_f495[3];e.current.appendChild(g);d.call(this,e.current);jSuites.focus(g);m.preventDefault()};e.update=function(f,g,h,l,m){var n=this,p=jSuites.getNode();if(p){var q=e.getName.call(this,f,g,h,l,m);f=function(v){var u=document.createElement(_$_f495[230]);u.innerText=q;u.setAttribute(_$_f495[217],q);p.parentNode===n.parent.input&&!1===v?p.parentNode.insertBefore(u,p.nextSibling):n.parent.input.appendChild(u);
209
- p=u};if(p.getAttribute(_$_f495[217]))m.ctrlKey?(n.parent.input.appendChild(document.createTextNode(_$_f495[25])),f(!0)):(p.innerText=q,p.setAttribute(_$_f495[217],q));else{if(p.innerText!==_$_f495[3]&&-1==c.indexOf(p.innerText.slice(-1))||p.nextElementSibling&&p.nextElementSibling.getAttribute(_$_f495[217]))return!1;f(!1)}jSuites.focus(p);d.call(n,n.parent.input);m.preventDefault();return!0}return!1};e.onkeydown=function(f){f.target.worksheet=this;if(f.ctrlKey){if(67==f.which||88==f.which)f=window.getSelection().toString().replace(/(\r\n|\n|\r)/gm,
210
- _$_f495[3]),navigator.clipboard?navigator.clipboard.writeText(f):(this.parent.textarea.value=f,this.parent.textarea.select(),document.execCommand(_$_f495[192]))}else if(36==f.which){var g=window.getSelection(),h=document.createRange();h.setStart(f.target,0);g.removeAllRanges();g.addRange(h)}else 35==f.which?jSuites.focus(f.target):187==f.which&&!f.target.innerText.replace(/(\r\n|\n|\r)/gm,_$_f495[3])&&f.target.getAttribute(_$_f495[94])&&f.target.removeAttribute(_$_f495[94])};return e}(),V=function(){var k=
211
- new RegExp(/^(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]+)(:\$?[A-Z]+\$?[0-9]+)?$/i),c=function(h){h=b(h);for(var l=[_$_f495[185],_$_f495[151],_$_f495[209],_$_f495[210],_$_f495[211],_$_f495[231]],m=[_$_f495[212],_$_f495[232],_$_f495[1],_$_f495[2],_$_f495[213],_$_f495[233],_$_f495[25],_$_f495[214],_$_f495[12],_$_f495[215],_$_f495[216]],n=_$_f495[3],p=[],q=0,v=0;v<h.length;v++){if(h[v]==_$_f495[187]||h[v]==_$_f495[133])q=0==q?1:0;0==q&&(-1<l.indexOf(h[v])||-1<m.indexOf(h[v]))?(n&&(p.push(n),n=_$_f495[3]),
212
- p.push(h[v])):n+=h[v]}n&&p.push(n);for(v=0;v<p.length;v++)-1==p[v].indexOf(_$_f495[187])&&-1==p[v].indexOf(_$_f495[133])&&(p[v]=p[v].replace(/\s/g,_$_f495[3]));return p},b=function(h,l){for(var m=_$_f495[3],n=0,p=[_$_f495[12],_$_f495[135],_$_f495[216],_$_f495[215]],q=0;q<h.length;q++)h[q]==_$_f495[187]&&(n=0==n?1:0),1==n?m+=h[q]:(m+=h[q].toUpperCase(),1==l&&0<q&&h[q]==_$_f495[12]&&-1==p.indexOf(h[q-1])&&-1==p.indexOf(h[q+1])&&(m+=_$_f495[12]));return m},a=function(h){h.setFormula=a[_$_f495[11]];h.executeFormula=
213
- a.execute;h.formula=[]};a.run=function(h,l){var m=_$_f495[3],n=Object.keys(l);if(n.length){for(var p={},q=0;q<n.length;q++){var v=n[q].replace(/!/g,_$_f495[27]);0<v.indexOf(_$_f495[27])&&(v=v.split(_$_f495[27]),p[v[0]]=!0)}v=Object.keys(p);for(q=0;q<v.length;q++)m+=_$_f495[234]+v[q]+_$_f495[235];for(q=0;q<n.length;q++)v=n[q].replace(/!/g,_$_f495[27]),jSuites.isNumeric(l[n[q]])||(p=l[n[q]].match(/(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&p.length&&(l[n[q]]=e(p,l[n[q]])),m=0<
214
- v.indexOf(_$_f495[27])?m+(v+_$_f495[236]+l[n[q]]+_$_f495[237]):m+(_$_f495[234]+v+_$_f495[236]+l[n[q]]+_$_f495[237])}h=h.replace(/\$/g,_$_f495[3]);(p=h.match(/(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&p.length&&(h=e(p,h));h=h.replace(/!/g,_$_f495[27]);return(new Function(m+_$_f495[238]+h))()};a[_$_f495[11]]=function(){};var d=function(h){h=b(h,!0);return h.replace(/\$/g,_$_f495[3])},e=function(h,l){for(var m=0;m<h.length;m++){var n=a.getTokensFromRange.call(this,h[m]);l=l.replace(h[m],
215
- _$_f495[213]+n.join(_$_f495[25])+_$_f495[233])}return l},f=function(h,l,m){for(var n=this.config.definedNames,p=0;p<h.length;p++)h[p]&&n&&n[h[p]]&&(l=l.replace(h[p],n[h[p]]),m&&(m[h[p]]=n[h[p]]));return d(l)},g=function(h,l){var m;if(m=this.records[l][h].a)for(var n=0;n<m.length;n++)for(var p=0;p<m[n].length;p++)m[n][p]&&(m[n][p].innerText=_$_f495[3],this.records[l+n][h+p].v=_$_f495[3]);this.records[l][h].a=[]};a.execute=function(h,l,m,n,p){if(1==this.parent.processing)return null!==l&&null!==m&&
216
- this.parent.queue.push([this,l,m]),_$_f495[3];if(typeof this.parent.config.onbeforeformula==_$_f495[85]){var q=F.call(this.parent,_$_f495[239],this,h,l,m);if(!1===q)return h;q&&(h=q)}var v=[],u=function(R,O,r,A){if(void 0!=O&&void 0!=r){var z=E.getColumnNameFromCoords(O,r);r=A.getWorksheetName()+_$_f495[27]+z;v[r]||(v[r]=0);v[r]++;if(3<v[r])throw{error:_$_f495[240],message:_$_f495[241],reference:r};}else z=null;p||(R=d(R));var B=R,I=B.match(/[A-Z_]+[A-Z0-9_\.]*/g);I&&I.length&&(B=f.call(A.parent,
217
- I,B,w));(I=B.match(/(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&I.length&&(B=e.call(A,I,B));I=[];B=c(B);for(var J=0;J<B.length;J++)B[J]&&k.test(B[J])&&I.push(B[J]);if(I){if(-1<I.indexOf(z))throw{error:_$_f495[242],message:_$_f495[243]};for(B=0;B<I.length;B++){J=I[B].split(_$_f495[135]);J[1]?(O=J[1],J=H(J[0]),r=A.getWorksheetName()+_$_f495[27]+z):(O=J[0],J=A,r=z);if(typeof J==_$_f495[13]||typeof J.formula==_$_f495[13])throw{error:_$_f495[244],message:_$_f495[245]};r&&(J.formula[O]||
218
- (J.formula[O]=[]),0>J.formula[O].indexOf(r)&&J.formula[O].push(r));if(!w[I[B]]){r=E.getCoordsFromColumnName(O);O=r[0];r=r[1];var Y=void 0!==J.records[r][O].v?J.records[r][O].v:N.call(J,O,r);w[I[B]]||((_$_f495[3]+Y).substr(0,1)==_$_f495[12]?w[I[B]]=u(Y,O,r,J):(Y?Y!=Number(Y)&&(Y=_$_f495[187]+Y+_$_f495[187]):Y=0,w[I[B]]=Y))}}}return R.substr(1)},w={};try{if(h=u(h,l,m,this)){var x=p?a.run(h,w):t.formula(h,w,l,m,this);if(!1!==n&&void 0!=l&&void 0!=m)if(x instanceof Date)this.records[m][l].v=jSuites.calendar.dateToNum(x);
219
- else if(Array.isArray(x)){g.call(this,l,m);n=[];q=null;for(var y=0;y<x.length;y++)for(var D=0;D<x[y].length;D++)null===q&&(0<y&&y>D&&this.options.data[m+y][l+D]?q=_$_f495[246]:(this.records[m+y][l+D].v=x[y][D],this.records[m+y][l+D].element&&(n[y]||(n[y]=[]),n[y][D]=this.records[m+y][l+D].element,this.records[m+y][l+D].element.innerText=x[y][D])));null===q?(q=x[0][0],this.records[m][l].a=n):g.call(this,l,m);x=this.records[m][l].v=q}else this.records[m][l].v=x;return x}}catch(R){return 1==this.parent.config.debugFormulas&&
220
- console.log(h,w,R),R&&R.error?R.error:_$_f495[244]}};a.update=function(h,l,m,n){var p=null,q=null,v=function(x){m&&m[x]&&(x=_$_f495[247]);l[x]&&(x=l[x]);return x};h=b(h,!0);h=c(h);for(var u=0;u<h.length;u++)if(h[u]&&k.test(h[u])){if(-1==h[u].indexOf(_$_f495[135])){if(q=h[u],p=_$_f495[3],n)continue}else if(q=h[u].split(_$_f495[135]),p=q[0],q=q[1],n!=p)continue;if(0<=q.indexOf(_$_f495[136])){q=a.getTokensFromRange.call(this,q);for(var w=0;w<q.length;w++)q[w]=v(q[w]);q=a.getRangeFromTokens.call(this,
221
- q)}else-1==q.indexOf(_$_f495[248])?q=v(q):(q=v(q.replace(/\$/g,_$_f495[3])),q=_$_f495[248]+q.match(/[A-Z]+/g)+_$_f495[248]+q.match(/[0-9]+/g));p&&(q=p+_$_f495[135]+q);h[u]=q}return h.join(_$_f495[3])};a.getChain=function(h){if(void 0===h)return[];var l=[],m=[],n=[],p=function(u){if(0<=u.indexOf(_$_f495[27])){var w=u.split(_$_f495[27]),x=w[0],y=w[1];w=H(w[0])}else w=this,x=w.getWorksheetName(),y=u;if(w.formula[y]&&!n[u]){var D=!1;n[u]=!0;for(u=0;u<w.formula[y].length;u++){var R=w.formula[y][u];-1==
222
- R.indexOf(_$_f495[27])&&(R=x+_$_f495[27]+R);if(!m[R]){var O=w.getValue(R);P(O)?l.push([R,O,a.getTokens.call(w,O,x)]):(D=!0,w.formula[y][u]=null);p.call(w,R);m[R]=!0}}1==D&&(w.formula[y]=w.formula[y].filter(function(r){return null!=r}))}},q=Object.keys(h);for(h=0;h<q.length;h++)p.call(this,q[h]);q=0;for(h=l.length-1;0<=h;h--){for(var v=0;v<h;v++)if(0<=l[v][2].indexOf(l[h][0])){l.splice(v,0,l.splice(h,1)[0]);h=l.length;break}q++;if(1E6<q){console.error(_$_f495[249]);break}}m=[];for(h=0;h<l.length;h++)m[l[h][0]]=
223
- l[h][1];return m};a.updateAll=function(h,l){var m,n;Ha.updateAll.call(this,h,l);var p=Object.keys(this.formula);var q=[];var v=[];for(m=0;m<p.length;m++){var u=p[m];var w=this.formula[u];if(l&&l[u])for(var x=0;x<w.length;x++)h[w[x]]&&(w[x]=h[w[x]]),v[w[x]]=!0;else{var y=[];for(x=0;x<w.length;x++)l&&l[w[x]]||(h[w[x]]&&(w[x]=h[w[x]]),v[w[x]]=!0,y.push(w[x]));y.length&&(h[u]&&(u=h[u]),q[u]=y)}}this.formula=q;y=this.getWorksheetName();for(var D=0;D<t.spreadsheet.length;D++)for(var R=t.spreadsheet[D].worksheets,
224
- O=0;O<R.length;O++)if(R[O].getWorksheetName()!==y)for(p=Object.keys(R[O].formula),m=0;m<p.length;m++){q=[];w=R[O].formula[p[m]];for(x=0;x<w.length;x++)u=w[x].split(_$_f495[27]),u[0]==y&&u[1]?l&&l[u[1]]||(h[u[1]]&&(u[1]=h[u[1]]),q.push(u[0]+_$_f495[27]+u[1])):q.push(w[x]);R[O].formula[p[m]]=q}p=[];u=Object.keys(v);for(x=0;x<u.length;x++)0<=u[x].indexOf(_$_f495[27])?(w=u[x].split(_$_f495[27]),q=H(w[0]),m=w[1],y=this.getWorksheetName(),w=w[0]):(q=this,m=u[x],y=null,w=this.getWorksheetName()),(n=q.getValue(m))&&
225
- P(n)&&(q=a.update.call(q,n,h,l,y),q!=n&&(v[u[x]]=q,m=E.getCoordsFromColumnName(m),p[w]||(p[w]=[]),p[w].push({x:m[0],y:m[1],value:q,force:!0})));u=Object.keys(p);for(h=0;h<u.length;h++)q=H(u[h]),p[u[h]]=ea.applyValues.call(q,p[u[h]]),ea.setValueChained.call(q,p[u[h]]),L.call(q,_$_f495[107],{data:p[u[h]]})};a.updateWorksheetName=function(h,l,m){for(var n=c(h),p=0;p<n.length;p++)h=n[p].split(_$_f495[135]),h[1]&&(h[0]=h[0].replace(new RegExp(_$_f495[133],_$_f495[188]),_$_f495[3]),h[0].toUpperCase()==
226
- l.toUpperCase()&&(h[0]=m,0<=h[0].indexOf(_$_f495[132])&&(h[0]=_$_f495[133]+h[0]+_$_f495[133]),n[p]=h.join(_$_f495[135])));return n.join(_$_f495[3])};a.updateWorksheetNames=function(h,l){for(var m,n,p=0;p<t.spreadsheet.length;p++)for(var q=[],v=t.spreadsheet[p].worksheets,u=0;u<v.length;u++){for(var w=0;w<v[u].options.data.length;w++)for(var x=0;x<v[u].options.data[w].length;x++)(m=v[u].options.data[w][x])&&P(m)&&(n=a.updateWorksheetName(m,h,l),n!=m&&q.push({x,y:w,value:n,force:!0}));q.length&&(q=
227
- ea.applyValues.call(v[u],q),L.call(v[u],_$_f495[107],{data:q}))}};a.shiftFormula=function(h,l,m){var n=c(h,!0);h=function(u){if(-1==u.indexOf(_$_f495[135])){u=E.getCoordsFromColumnName(u);var w=_$_f495[3]}else w=n[p].split(_$_f495[135]),u=E.getCoordsFromColumnName(w[1]),w=w[0]+_$_f495[135];var x=u[0]+l;u=u[1]+m;return u=0>x||0>u?_$_f495[247]:w+E.getColumnNameFromCoords(x,u)};for(var p=0;p<n.length;p++)if(k.test(n[p])&&-1==n[p].indexOf(_$_f495[248])){var q=-1==n[p].indexOf(_$_f495[135])?[_$_f495[3],
228
- n[p]]:n[p].split(_$_f495[135]);if(-1==q[1].indexOf(_$_f495[136]))q[1]=h(q[1]);else{var v=q[1].split(_$_f495[136]);q[1]=h(v[0])+_$_f495[136]+h(v[1])}n[p]=q[0]?q.join(_$_f495[135]):q[1]}return n.join(_$_f495[3])};a.getTokensFromRange=function(h){var l=this,m=_$_f495[3],n=_$_f495[3];0<=h.indexOf(_$_f495[27])?n=_$_f495[27]:0<=h.indexOf(_$_f495[135])&&(n=_$_f495[135]);h=h.replace(/\$/g,_$_f495[3]);n&&(m=h.split(n),l=H(m[0]),h=m[1],m=m[0]+n);n=[];h=h.split(_$_f495[136]);var p=E.getCoordsFromColumnName(h[0]),
229
- q=E.getCoordsFromColumnName(h[1]);if(p[0]<=q[0]){h=p[0];var v=q[0]}else h=q[0],v=p[0];if(null===p[1]&&null==q[1]){var u=0;p=0;l.options&&l.options.data&&(p=l.options.data.length-1)}else p[1]<=q[1]?(u=p[1],p=q[1]):(u=q[1],p=p[1]);for(l=u;l<=p;l++)for(u=h;u<=v;u++)n.push(m+E.getColumnNameFromCoords(u,l));return n};a.getRangeFromTokens=function(h){h=h.filter(function(n){return n!=_$_f495[247]});for(var l=_$_f495[3],m=0;m<h.length;m++)0<=h[m].indexOf(_$_f495[27])&&(l=h[m].split(_$_f495[27]),h[m]=l[1],
230
- l=l[0]);l&&(l+=_$_f495[27]);h.sort(function(n,p){n=E.getCoordsFromColumnName(n);p=E.getCoordsFromColumnName(p);return n[1]>p[1]?1:n[1]<p[1]?-1:n[0]>p[0]?1:n[0]<p[0]?-1:0});return h.length?l+(h[0]+_$_f495[136]+h[h.length-1]):_$_f495[247]};a.getTokens=function(h,l){var m=d(h);h.replace(/!/g,_$_f495[27]);(h=m.match(/[A-Z_]+[A-Z0-9_\.]*/g))&&h.length&&(m=f.call(this.parent,h,m));(h=m.match(/('.*?'?|\w*\.)?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&h.length&&(m=e.call(this,h,m));h=m.match(/('.*?'?|\w*\.)?(\$?[A-Z]+\$?[0-9]+)(:\$?[A-Z]+\$?[0-9]+)?/g);
231
- for(m=0;m<h.length;m++)-1==h[m].indexOf(_$_f495[27])&&l&&(h[m]=l+_$_f495[27]+h[m]);return h};a.tokenIdentifier=k;a.tokenize=c;return a}(),ea=function(){var k=function(c){c.name=Z;c.value=N;c.getValue=k[_$_f495[51]];c.getValueFromCoords=k.getFromCoords;c.setValue=k[_$_f495[11]];c.setValueFromCoords=k.setFromCoords;c.setCheckRadioValue=k.setCheckRadio;c.getProcessed=k.processed};k[_$_f495[51]]=function(c,b){var a=this;if(typeof c==_$_f495[84]){var d=c.x;c=c.y}else 0<=c.indexOf(_$_f495[27])&&(a=c.split(_$_f495[27]),
232
- c=a[1],a=H(a[0])),c=E.getCoordsFromColumnName(c),d=c[0],c=c[1];return k.getFromCoords.call(a,d,c,b)};k.getFromCoords=function(c,b,a){var d=null;null!=c&&null!=b&&(d=a?k.processed.call(this,c,b):N.call(this,c,b));return d};k[_$_f495[11]]=function(c,b,a){if(!Q.call(this.parent,this))return!1;var d=null,e=null,f=null,g=[];a=a?!0:!1;var h=function(n,p){var q=null;typeof n==_$_f495[17]?(f=E.getCoordsFromColumnName(n),d=f[0],e=f[1]):n.tagName?(d=n.getAttribute(_$_f495[42]),e=n.getAttribute(_$_f495[43])):
233
- n.element&&n.element.tagName?(d=n.element.getAttribute(_$_f495[42]),e=n.element.getAttribute(_$_f495[43])):(d=n.x,e=n.y,void 0!==n.value&&(p=n.value),void 0!==n.style&&(q=n.style));n={x:d,y:e,value:p,force:a};null!==q&&(n.style=q);g.push(n)};if(c&&Array.isArray(c))for(var l=0;l<c.length;l++)h(c[l],b);else if(typeof c==_$_f495[84]&&void 0==c.x&&void 0==c.tagName)for(b=Object.keys(c),l=0;l<b.length;l++)h(b[l],c[b[l]]);else h(c,b);if(g.length){g=k.applyValues.call(this,g);this.parent.config.parseFormulas&&
234
- k.setValueChained.call(this,g);X.update.call(this,!0);this.refreshBorders();var m=this;setTimeout(function(){ha.refresh.call(m)},250);if(g.length){U.call(this.parent,{worksheet:m,action:_$_f495[79],records:g,selection:this.selectedCell});c=this.getPrimaryKey();if(!1!==c)for(l=0;l<g.length;l++)g[l].x===c&&g[l].value&&S.call(this,g[l]);L.call(this,_$_f495[79],{data:g});F.call(this.parent,_$_f495[250],this,g)}}};k.setFromCoords=function(c,b,a,d){var e=[];e.push({x:c,y:b,value:a});k[_$_f495[11]].call(this,
235
- e,null,d)};k.setCheckRadio=function(){for(var c=[],b=this.getSelected(),a=0;a<b.length;a++){var d=b[a].x,e=b[a].y;if(!this.options.columns[d].readOnly&&this.options.columns[d].type==_$_f495[251]){var f=N.call(this,d,e)?!1:!0;c.push({x:d,y:e,value:f})}}c.length&&k[_$_f495[11]].call(this,c)};k.applyValues=function(c){for(var b,a,d=this.options.style||{},e=[],f={},g=0;g<c.length;g++)if(b=c[g],a=this.updateCell(b.x,b.y,b.value,b.force),void 0!==a.value){if(void 0!==b.style){var h=E.getColumnNameFromCoords(b.x,
236
- b.y);a.style=f[h]=b.style;a.oldStyle=d&&d[h]?d[h]:_$_f495[193]}e.push(a)}0<Object.keys(f).length&&Pa.update.call(this,f);return e};k.processed=function(c,b,a){var d=N.call(this,c,b);if(null===d)return null;var e=da[_$_f495[51]].call(this,c,b),f=e[1];f.type!=_$_f495[49]&&f.type!=_$_f495[252]&&f.type!=_$_f495[253]&&f.type!=_$_f495[254]&&f.type!=_$_f495[255]&&0!=f.process&&(!0===a||f.type!=_$_f495[256]&&f.type!=_$_f495[257]&&f.type!=_$_f495[258])&&(f.type==_$_f495[251]?d=e[0][_$_f495[51]](f,d,a):this.records[b][c].element?
237
- d=1==this.parent.config.stripHTML?this.records[b][c].element.innerText:this.records[b][c].element.innerHTML:((_$_f495[3]+d).substr(0,1)==_$_f495[12]&&(d=this.executeFormula(d,c,b,!1)),e[0]&&typeof e[0][_$_f495[51]]==_$_f495[85]&&(d=e[0][_$_f495[51]](f,d,a))));return d};k.setValueChained=function(c){for(var b,a=[],d,e=0;e<c.length;e++)b=c[e],d=E.getColumnNameFromCoords(b.x,b.y),a[d]=b.value;a=V.getChain.call(this,a);c=Object.keys(a);for(e=0;e<c.length;e++)0<=c[e].indexOf(_$_f495[27])?(b=c[e].split(_$_f495[27]),
238
- d=b[1],b=H(b[0])):(d=c[e],b=this),d=E.getCoordsFromColumnName(d),M.update.call(b,d[0],d[1],a[c[e]],!0)};return k}(),M=function(){var k=function(c){c.getCell=k[_$_f495[51]];c.getCellFromCoords=k[_$_f495[51]];c.updateCell=k.update;c.updateCells=k.updateAll;c.getSelected=k.selected;c.getCells=k.getCells;c.setCells=k.setCells;c.isAttached=k.attached};k.attached=function(c,b){return this.records[b]&&this.records[b][c]&&this.records[b][c].element&&this.records[b][c].element.parentNode&&this.records[b][c].element.parentNode.parentNode?
239
- !0:!1};k[_$_f495[51]]=function(c,b,a){typeof c==_$_f495[17]&&(b=E.getCoordsFromColumnName(c),c=b[0],b=b[1]);c=parseInt(c);b=parseInt(b);if(this.records[b]&&this.records[b][c]&&this.records[b][c].element)return this.records[b][c].element;var d=N.call(this,c,b);null===d&&(d=_$_f495[3]);return M.create.call(this,c,b,d,a)};k.getFromCoords=function(c,b,a){if(!c)return null;var d=[],e=c[0],f=c[1],g=c[2];c=c[3];for(a&&(a=this.results?E.invert(this.results):null);f<=c;f++)for(var h=e;h<=g;h++)if(!a||a[f])b?
240
- d.push(E.getColumnNameFromCoords(h,f)):d.push(this.records[f][h]);return d};k.selected=function(c,b){return k.getFromCoords.call(this,this.getHighlighted(),c,b)};k.getSelectedColumns=function(){var c=[],b=this.getHighlighted();if(b)for(var a=b[0];a<=b[2];a++)c.push(a);return c};k.updateAll=function(c){for(var b=this.getPrimaryKey(),a=[],d=0;d<c.length;d++)void 0!==c[d].id?(S.call(this,c[d]),a.push({id:c[d].id,y:c[d].y}),!1!==b&&k.update.call(this,b,c[d].y,c[d].id,!0)):a.push(k.update.call(this,c[d].x,
241
- c[d].y,c[d].value,c[d].force));L.call(this,_$_f495[106],[a])};k.update=function(c,b,a,d){var e=this.records[b];if(e=e&&e[c]?e[c]:null)if(e=e.element,!d&&e&&1==e.classList.contains(_$_f495[18]))d={x:c,y:b};else{d=F.call(this.parent,_$_f495[259],this,e,c,b,a);void 0!==d&&(a=d);d=da[_$_f495[51]].call(this,c,b);typeof d[0].updateCell==_$_f495[85]&&(d=d[0].updateCell(e,a,c,b,this,d[1]),void 0!==d&&(a=d));d={x:c,y:b};var f=N.call(this,c,b);f!==a&&(a=N.call(this,c,b,a),d.oldValue=f,d.value=a,e&&k.applyOverflow.call(this,
242
- e,c,b),F.call(this.parent,_$_f495[260],this,e,c,b,d.value,d.oldValue))}else return!1;return d};k.create=function(c,b,a,d){var e=document.createElement(_$_f495[147]);e.setAttribute(_$_f495[42],c);e.setAttribute(_$_f495[43],b);var f=da[_$_f495[51]].call(this,c,b);f[0]&&typeof f[0].createCell==_$_f495[85]&&(f=f[0].createCell(e,a,c,b,this,f[1]),void 0!==f&&(a=f));N.call(this,c,b,a);this.records[b][c]||oa.cell.call(this,c,b,a);this.records[b][c].element=e;!a&&this.records[b][c].v&&(e.innerText=this.records[b][c].v);
243
- k.applyProperties.call(this,e,c,b,d);k.applyOverflow.call(this,e,c,b);F.call(this.parent,_$_f495[261],this,e,c,b,a);return e};k.getAttributes=function(c,b,a){a[c]||(a[c]={});c==_$_f495[262]?a[c][b]=this.getValue(b):c==_$_f495[263]?this.merged.cells&&(b=this.merged.cells[b])&&(a[c][b]=this.options.mergeCells[b]):this.options[c]&&this.options[c][b]&&(a[c][b]=this.options[c][b])};k.setAttributes=function(c){c&&c.style&&this.setStyle(c.style);c&&c.comments&&this.setComments(c.comments);c&&c.meta&&this.setMeta(c.meta);
244
- c&&c.cells&&this.setCells(c.cells);c&&c.mergeCells&&this.setMerge(c.mergeCells);c&&c.values&&k.batch.call(this,c.values);c&&c.formulas&&k.batch.call(this,c.formulas,!0)};k.applyProperties=function(c,b,a,d){if(!d){d=E.getColumnNameFromCoords(b,a);var e=this.options.style,f=this.options.comments,g=this.options.cells,h=this.options.rows;if(e&&e[d]){var l=(l=c.getAttribute(_$_f495[98]))?l+(_$_f495[264]+e[d]):e[d];c.setAttribute(_$_f495[98],l)}f&&f[d]&&c.setAttribute(_$_f495[265],f[d]);g&&g[d]&&(1==g[d].readOnly&&
245
- c.classList.add(_$_f495[18]),!1===g[d].locked&&!0===this.options.selectUnLockedCells&&c.classList.add(_$_f495[266]));h&&h[a]&&1==h[a].readOnly&&c.classList.add(_$_f495[18])}f=this.options.columns[b];c.style.textAlign||(c.style.textAlign=f.align?f.align:this.options.defaultColAlign);!1===this.records[a][b].readonly||1!=this.records[a][b].readonly&&1!=f.readOnly&&1!=f.readonly||c.classList.add(_$_f495[18])};k.applyOverflow=function(c,b,a){1==this.options.textOverflow&&0<b&&(b==this.options.columns.length-
246
- 1&&(c.style.overflow=_$_f495[49]),this.records[a][b-1]&&this.records[a][b-1].element&&(this.records[a][b-1].element.style.overflow=!c.innerText&&this.headers[b-1]&&this.headers[b-1].offsetWidth?_$_f495[3]:_$_f495[49]))};k.batch=function(c,b){var a=[],d=Object.keys(c);if(d.length)for(var e=0;e<d.length;e++){if(0<=d[e].indexOf(_$_f495[27])){var f=d[e].split(_$_f495[27]);var g=H(f[0]);var h=f[1];f=f[0]}else g=this,h=d[e],f=this.getWorksheetName();h=E.getCoordsFromColumnName(h);h=g.updateCell(h[0],h[1],
247
- c[d[e]],!0);a[f]||(a[f]=[]);a[f].push(h)}if(1==b&&(d=Object.keys(a),d.length))for(e=0;e<d.length;e++)g=H(d[e]),L.call(g,_$_f495[107],a[d[e]])};k.getCells=function(c){return c?this.options.cells[c]:this.options.cells};k.setCells=function(c,b){if(!Q.call(this.parent,this))return!1;if(typeof c==_$_f495[17])this.options.cells[c]=b;else{b=Object.keys(c);for(var a=0;a<b.length;a++)this.options.cells[b[a]]=c[b[a]]}};return k}(),za=function(){var k=function(b,a){Array.isArray(a)||(a=[a]);for(var d,e=b?_$_f495[3]:
248
- _$_f495[40],f=Object.keys(a),g=0;g<f.length;g++)if(d=this.rows[a[f[g]]])d.element&&(d.element.style.display=e),d.visible=b;this.resetBorders();G.refresh.call(this)},c=function(b){b.getRow=c[_$_f495[51]];b.moveRow=c.move;b.insertRow=c.add;b.deleteRow=c.del;b.getSelectedRows=c.selected;b.showRow=k.bind(b,!0);b.hideRow=k.bind(b,!1)};c[_$_f495[51]]=function(b){return this.rows[b]};c.attached=function(b){return this.rows[b]&&this.rows[b].element&&this.rows[b].element.parentNode?!0:!1};c.selected=function(b){var a=
249
- [],d=this.getHighlighted();if(d)for(var e=d[1];e<=d[3];e++)b?a.push(e):a.push(this.rows[e].element);return a};c.create=function(b,a){if(this.rows[b]&&this.rows[b].element)return this.rows[b].element;this.rows[b]||oa.row.call(this,b);var d=document.createElement(_$_f495[145]);d.setAttribute(_$_f495[43],b);this.rows[b].element=d;var e=null;this.options.rows[b]&&!a&&(this.options.rows[b].style&&d.setAttribute(_$_f495[98],this.options.rows[b].style),this.options.rows[b].height&&(d.style.height=parseInt(this.options.rows[b].height)+
250
- _$_f495[44]),this.options.rows[b].title&&(e=this.options.rows[b].title),0==this.options.rows[b].visible&&(this.rows[b].visible=!1),this.options.rows[b].id&&(this.rows[b].id=this.options.rows[b].id));F.call(this.parent,_$_f495[267],this,b,d);0==this.rows[b].visible&&(d.style.display=_$_f495[40]);e||(e=parseInt(b+1));a=document.createElement(_$_f495[147]);a.innerHTML=e;a.setAttribute(_$_f495[43],b);a.className=_$_f495[268];d.appendChild(a);return d};c.move=function(b,a){if(!Q.call(this.parent,this))return!1;
251
- b=parseInt(b);a=parseInt(a);if(!this.rows[a]||!this.rows[b])return console.error(_$_f495[269]),!1;if(0<Object.keys(this.getMerge()).length){var d=null;this.merged.rows[b]?d=!0:this.merged.rows[a]&&(b>a?this.merged.rows[a-1]&&(d=!0):this.merged.rows[a+1]&&(d=!0));d&&this.destroyMerged()}this.resetBorders();0<=Array.prototype.indexOf.call(this.tbody.children,this.rows[a].element)?(d=G.renderRow.call(this,b),b>a?this.tbody.insertBefore(d,this.rows[a].element):this.tbody.insertBefore(d,this.rows[a].element.nextSibling)):
252
- this.rows[b].element&&(this.tbody.removeChild(this.rows[b].element),G.refresh.call(this));this.rows.splice(a,0,this.rows.splice(b,1)[0]);this.records.splice(a,0,this.records.splice(b,1)[0]);this.options.data.splice(a,0,this.options.data.splice(b,1)[0]);0<this.options.pagination&&this.tbody.children.length!=this.options.pagination&&this.page(this.pageNumber);L.call(this,_$_f495[67],{f:b,t:a});X.references.call(this);X.update.call(this);U.call(this.parent,{worksheet:this,action:_$_f495[67],oldValue:b,
253
- newValue:a});F.call(this.parent,_$_f495[270],this,b,a)};c.add=function(b,a,d,e){if(!Q.call(this.parent,this))return!1;if(!this.options.allowInsertRow)return console.error(_$_f495[271]),!1;var f=[];if(0<b)var g=parseInt(b);else g=1,Array.isArray(b)&&!e&&(Array.isArray(b[0])?e=b:(e=[],e.push(b)));e=Ea.standardize(e);d=d?!0:!1;var h=this.options.data?this.options.data.length-1:0;if(void 0==a||a>h||0>a)a=h,d=!1;g||(g=1);if(!1===F.call(this.parent,_$_f495[272],this,a,g,d))return console.log(_$_f495[273]),
254
- !1;this.resetBorders();var l=d?a:a+1,m=0;b=[];for(var n=[],p=this.rows.splice(l),q=this.options.data?this.options.data.splice(l):[],v=this.records.splice(l),u=l;u<g+l;u++){var w=e[m]&&e[m].id?e[m].id:sa.next.call(this);oa.row.call(this,u,w);var x=this.dataType?{}:[];for(var y=0;y<this.options.columns.length;y++){var D=Z.call(this,y);x[D]=_$_f495[3];e&&e[m]&&e[m].data&&(typeof e[m].data[D]!==_$_f495[13]?x[D]=e[m].data[D]:typeof e[m].data[y]!==_$_f495[13]&&(x[D]=e[m].data[y]));f.push({x:y,y:u,value:x[D],
255
- force:!0})}n.push({id:w,data:x});m++}this.rows=this.rows.concat(p);this.records=this.records.concat(v);this.options.data=this.options.data.concat(q);this.results&&0<this.results.length&&(h=this.results[this.results.length-1]);e=!1;p[0]?0<=Array.prototype.indexOf.call(this.tbody.children,p[0].element)&&(e=!0):this.rows[h]?this.rows[h].element&&0<=Array.prototype.indexOf.call(this.tbody.children,this.rows[h].element)&&(e=!0):e=!0;for(u=l;u<g+l;u++)this.results&&(this.rows[u].results=!0),1==e&&(h=p[0]?
256
- p[0].element:null,D=G.renderRow.call(this,u,null,null,!0),h?this.tbody.insertBefore(D,h):this.tbody.appendChild(D),0<this.options.pagination?Array.prototype.indexOf.call(this.tbody.children,D)>=this.options.pagination&&(e=!1):G.limited.call(this)&&(G.isVisible.call(this,D.children[1])||(e=!1))),b.push(this.records[u]);this.merged.rows[l]&&ba.updateConfig.call(this,1,1,l-1,g);L.call(this,_$_f495[63],{numOfRows:g,rowNumber:a,insertBefore:d?1:0,data:n});l=this.tbody.firstChild.getAttribute(_$_f495[43]);
257
- this.results&&(l=this.results.indexOf(parseInt(l)),this.results=ua.refresh.call(this));X.references.call(this);f.length&&ea.applyValues.call(this,f);0<this.options.pagination?ta[_$_f495[11]].call(this,this.pageNumber):(this.results&&(l=this.results[l]),this.tbody.textContent=_$_f495[3],G[_$_f495[46]].call(this,l));X.update.call(this);T.call(this);ha.refresh.call(this);U.call(this.parent,{worksheet:this,action:_$_f495[63],rowNumber:a,numOfRows:g,insertBefore:d,data:n});F.call(this.parent,_$_f495[274],
258
- this,a,g,b,d)};c.del=function(b,a){if(!Q.call(this.parent,this))return!1;if(!this.options.allowDeleteRow)return console.error(_$_f495[275]),!1;var d=null,e={},f=[],g=0;void 0==b&&(a=this.getSelectedRows(),a[0]?(b=parseInt(a[0].getAttribute(_$_f495[43])),a=a.length):(b=this.options.data.length-1,a=1));var h=this.options.data.length-1;if(void 0==b||b>h||0>b)b=h;a||(a=1);b+a>=this.options.data.length&&(a=this.options.data.length-b,a>=this.options.data.length&&(a=this.options.data.length,this.resetSelection()));
259
- if(!1===F.call(this.parent,_$_f495[276],this,b,a))return console.log(_$_f495[277]),!1;if(-1<parseInt(b)&&0<parseInt(a)){h=parseInt(this.thead.lastChild.children[1].getAttribute(_$_f495[42]));var l=parseInt(this.tbody.firstChild.getAttribute(_$_f495[43]));this.resetBorders();for(var m=b;m<b+a;m++)for(var n=0;n<this.options.columns.length;n++)d=E.getColumnNameFromCoords(n,m),M.getAttributes.call(this,_$_f495[278],d,e),M.getAttributes.call(this,_$_f495[98],d,e),M.getAttributes.call(this,_$_f495[279],
260
- d,e),M.getAttributes.call(this,_$_f495[280],d,e),M.getAttributes.call(this,_$_f495[263],d,e),M.getAttributes.call(this,_$_f495[262],d,e),f[d]=!0;if(d=V.getChain.call(this,e.values))e.formulas=d;for(m=b;m<b+a;m++)0<=Array.prototype.indexOf.call(this.tbody.children,this.rows[m].element)&&(this.rows[m].element.parentNode.removeChild(this.rows[m].element),g++);d=[];for(m=b;m<b+a;m++)d.push({id:this.getRowId(m),row:m,data:this.getRowData(m)});this.rows.splice(b,a);m=this.records.splice(b,a);this.options.data.splice(b,
261
- a);ba.updateConfig.call(this,1,0,b,a);L.call(this,_$_f495[64],{rowNumber:b,numOfRows:a,data:d});X.references.call(this,f);this.results&&(this.results=ua.refresh.call(this));0<this.options.pagination?this.page(this.pageNumber,function(){if(0==this.tbody.children.length){var p=this.whichPage(this.options.data.length-1);this.page(p)}}):G.limited.call(this)&&0<g&&(this.tbody.textContent=_$_f495[3],G.call(this),G[_$_f495[46]].call(this,l,h));X.update.call(this,!0);U.call(this.parent,{worksheet:this,action:_$_f495[64],
262
- rowNumber:b,numOfRows:a,insertBefore:1,data:d,attributes:e});F.call(this.parent,_$_f495[281],this,b,a,m,d,e)}};return c}(),Ga=function(){var k=function(b,a){Array.isArray(a)||(a=[a]);for(var d,e,f=Object.keys(a),g=0;g<f.length;g++)if(d=a[f[g]],e=this.options.columns[d])this.colgroup[d]&&(this.colgroup[d].style.width=b?parseInt(e.width||this.options.defaultColWidth)+_$_f495[44]:_$_f495[144]),e.visible=b;G.refresh.call(this);0<this.options.freezeColumns&&ka[_$_f495[11]].call(this,this.options.freezeColumns);
263
- this.resetBorders()},c=function(b){b.getColumn=c[_$_f495[51]];b.getColumnIdByName=c.getByName;b.getPrimaryKey=c.getPrimaryKey;b.getSelectedColumns=c.selected;b.getOptions=c.getOptions;b.getColumnOptions=c.getOptions;b.moveColumn=c.move;b.insertColumn=c.add;b.deleteColumn=c.del;b.getProperties=c.properties;b.setProperties=c.properties;b.getProperty=c.properties;b.setProperty=c.properties;b.showColumn=k.bind(b,!0);b.hideColumn=k.bind(b,!1)};c[_$_f495[51]]=function(b){return this.options.columns[b]||
264
- !1};c.getByName=function(b){for(var a=this.options.columns,d=0;d<a.length;d++)if(a[d].name==b)return d;return!1};c.getPrimaryKey=function(){for(var b=0;b<this.options.columns.length;b++)if(1==this.options.columns[b].primaryKey)return b;return!1};c.getOptions=function(b,a){var d=this.options.columns[b];Object.keys(this.options.cells).length&&void 0!==a&&(b=E.getColumnNameFromCoords(b,a),this.options.cells[b]&&(d=this.options.cells[b]));if(!d)d={type:_$_f495[56]};else if(!d.type||typeof d.type==_$_f495[17]&&
265
- !t.editors[d.type])d.type=_$_f495[56];return d};c.selected=function(b){b=[];var a=this.getHighlighted();if(a)for(var d=a[0];d<=a[2];d++)b.push(d);return b};c.move=function(b,a){if(!Q.call(this.parent,this))return!1;b=parseInt(b);a=parseInt(a);if(!this.options.columns[b])return console.error(_$_f495[282]),!1;if(!this.options.columns[a])return console.error(_$_f495[283]),!1;if(0<Object.keys(this.getMerge()).length){var d=null;this.merged.cols[b]?d=!0:this.merged.cols[a]&&(b>a?this.merged.cols[a-1]&&
266
- (d=!0):this.merged.cols[a+1]&&(d=!0));d&&this.destroyMerged()}this.resetBorders();d=this.options.freezeColumns;0<d&&(b<d||a<d)?ka.reset.call(this):d=null;if(this.headers[a]&&this.headers[a].parentNode){this.headers[b]||Ba.create.call(this,b);var e=(b>a?this.headers[a]:this.headers[a].nextSibling)||null;this.headerContainer.insertBefore(this.headers[b],e);e=(b>a?this.colgroup[a]:this.colgroup[a].nextSibling)||null;this.colgroupContainer.insertBefore(this.colgroup[b],e);for(var f=0;f<this.tbody.children.length;f++){var g=
267
- this.tbody.children[f].getAttribute(_$_f495[43]);e=(b>a?this.records[g][a].element:this.records[g][a].element.nextSibling)||null;this.tbody.children[f].insertBefore(M[_$_f495[51]].call(this,b,g),e)}if(this.options.footers)for(f=0;f<this.tfoot.children.length;f++)e=(b>a?this.footers.content[f][a].element:this.footers.content[f][a].element.nextSibling)||null,this.tfoot.children[f].insertBefore(aa.create.call(this,b,f),e)}else if(this.headers[b]&&this.headers[b].parentNode){this.headerContainer.removeChild(this.headers[b]);
268
- this.colgroupContainer.removeChild(this.colgroup[b]);for(f=0;f<this.tbody.children.length;f++)g=parseInt(this.tbody.children[f].getAttribute(_$_f495[43])),this.tbody.children[f].removeChild(this.records[g][b].element);if(this.options.footers)for(f=0;f<this.tfoot.children.length;f++)this.tfoot.children[f].removeChild(this.footers.content[f][b].element)}this.options.columns.splice(a,0,this.options.columns.splice(b,1)[0]);this.headers.splice(a,0,this.headers.splice(b,1)[0]);this.colgroup.splice(a,0,
269
- this.colgroup.splice(b,1)[0]);for(f=0;f<this.rows.length;f++)this.dataType||this.options.data[f].splice(a,0,this.options.data[f].splice(b,1)[0]),this.records[f].splice(a,0,this.records[f].splice(b,1)[0]);if(this.options.footers)for(f=0;f<this.options.footers.length;f++)this.options.footers[f].splice(a,0,this.options.footers[f].splice(b,1)[0]),this.footers.content[f].splice(a,0,this.footers.content[f].splice(b,1)[0]);L.call(this,_$_f495[68],{f:b,t:a});X.references.call(this);X.update.call(this);0<
270
- d&&(b<=d||d<=d)&&ka[_$_f495[11]].call(this,d);U.call(this.parent,{worksheet:this,action:_$_f495[68],oldValue:b,newValue:a});F.call(this.parent,_$_f495[284],this,b,a)};c.add=function(b,a,d,e,f,g){if(!Q.call(this.parent,this))return!1;if(!this.options.allowInsertColumn)return console.error(_$_f495[285]),!1;var h=[];if(0<b)var l=parseInt(b);else if(l=1,Array.isArray(b)&&!f)if(Array.isArray(b[0]))f=b;else{f=[];for(var m=0;m<b.length;m++)f[m]=[b[m]]}f||(f=[]);d=d?!0:!1;b=this.options.columns.length-1;
271
- if(void 0==a||a>b||0>a)a=b,d=!1;l||(l=1);if(!1===F.call(this.parent,_$_f495[286],this,a,l,d))return console.log(_$_f495[287]),!1;ha.reset.call(this);if(1==this.dataType)var n=parseInt((_$_f495[3]+Date.now()).substr(-8));e||(e=[]);for(m=0;m<l;m++)e[m]||(e[m]={type:_$_f495[56],source:[],options:[],width:this.options.defaultColWidth,align:this.options.defaultColAlign}),1==this.dataType&&typeof e[m].name==_$_f495[13]&&(e[m].name=_$_f495[288]+(n+m));var p=d?a:a+1;this.options.columns=E.injectArray(this.options.columns,
272
- p,e);n=function(x,y){for(var D=p;D<l+p;D++)Ba.create.call(this,D),x?(this.headerContainer.insertBefore(this.headers[D],x),this.colgroupContainer.insertBefore(this.colgroup[D],y)):(this.headerContainer.appendChild(this.headers[D]),this.colgroupContainer.appendChild(this.colgroup[D]))};m=function(x,y){if(y)for(var D=p;D<l+p;D++)this.rows[x].element.insertBefore(M[_$_f495[51]].call(this,D,x,!0),y);else for(D=p;D<l+p;D++)this.rows[x].element.appendChild(M[_$_f495[51]].call(this,D,x,!0))};var q=this.headers.splice(p),
273
- v=this.colgroup.splice(p);q[0]?0<=Array.prototype.indexOf.call(this.headerContainer.children,q[0])&&n.call(this,q[0],v[0]):this.headers[b]&&0<=Array.prototype.indexOf.call(this.headerContainer.children,this.headers[b])&&n.call(this);this.headers=this.headers.concat(q);this.colgroup=this.colgroup.concat(v);aa.adjust.call(this,p,l,1);pa.adjust.call(this,a,l,1,g);g=0;v=q=n=null;for(var u=0;u<this.options.data.length;u++){this.dataType||(q=this.options.data[u].splice(p));v=this.records[u].splice(p);g=
274
- 0;for(var w=p;w<l+p;w++)n=f[u]&&f[u][g]?f[u][g]:_$_f495[3],N.call(this,w,u,n),h.push({x:w,y:u,value:n}),oa.cell.call(this,w,u),g++;this.rows[u].element&&this.rows[u].element.parentNode&&(v[0]?0<=Array.prototype.indexOf.call(this.rows[u].element.children,v[0].element)&&m.call(this,u,v[0].element):this.records[u][b].element&&0<=Array.prototype.indexOf.call(this.rows[u].element.children,this.records[u][b].element)&&m.call(this,u));this.dataType||(this.options.data[u]=this.options.data[u].concat(q));
275
- this.records[u]=this.records[u].concat(v)}this.merged.cols[p]&&ba.updateConfig.call(this,0,1,p-1,l);L.call(this,_$_f495[65],{numOfColumns:l,columnNumber:a,insertBefore:d?1:0,properties:e,data:f});X.references.call(this);h.length&&ea.applyValues.call(this,h);X.update.call(this);this.refreshBorders();U.call(this.parent,{worksheet:this,action:_$_f495[65],columnNumber:a,numOfColumns:l,insertBefore:d,properties:e,data:f});F.call(this.parent,_$_f495[289],this,a,l,[],d)};c.del=function(b,a){if(!Q.call(this.parent,
276
- this))return!1;if(!this.options.allowDeleteColumn)return console.error(_$_f495[290]),!1;var d={},e=[],f=0;if(1<this.options.columns.length){void 0==b&&(a=this.getSelectedColumns(!0),a.length?(b=parseInt(a[0]),a=parseInt(a.length)):(b=this.options.columns.length-1,a=1));var g=this.options.columns.length-1;if(void 0==b||b>g||0>b)b=g;a||(a=1);b+a>=this.options.columns.length&&(a=this.options.columns.length-b,a>=this.options.columns.length&&(a--,console.error(_$_f495[291])));if(!1===F.call(this.parent,
277
- _$_f495[292],this,b,a))return console.log(_$_f495[293]),!1;if(-1<parseInt(b)&&0<parseInt(a)){g=parseInt(this.thead.lastChild.children[1].getAttribute(_$_f495[42]));var h=parseInt(this.tbody.firstChild.getAttribute(_$_f495[43]));this.resetBorders();var l=null,m=[],n=[],p=[];var q=0;for(var v=b;v<b+a;v++)0<=Array.prototype.indexOf.call(this.headerContainer.children,this.headers[v])&&(this.colgroup[v].parentNode.removeChild(this.colgroup[v]),this.headers[v].parentNode.removeChild(this.headers[v]),f++),
278
- p[q]=this.options.columns[v],q++;for(var u=0;u<this.options.data.length;u++)for(v=b;v<b+a;v++)q=E.getColumnNameFromCoords(v,u),M.getAttributes.call(this,_$_f495[278],q,d),M.getAttributes.call(this,_$_f495[98],q,d),M.getAttributes.call(this,_$_f495[279],q,d),M.getAttributes.call(this,_$_f495[280],q,d),M.getAttributes.call(this,_$_f495[263],q,d),M.getAttributes.call(this,_$_f495[262],q,d),e[q]=!0,this.records[u][v].element&&0<=Array.prototype.indexOf.call(this.rows[u].element.children,this.records[u][v].element)&&
279
- this.records[u][v].element.parentNode.removeChild(this.records[u][v].element);if(v=V.getChain.call(this,d.values))d.formulas=v;this.options.columns.splice(b,a);this.headers.splice(b,a);this.colgroup.splice(b,a);for(u=0;u<this.options.data.length;u++)this.dataType||(n[u]=this.options.data[u].splice(b,a)),m[u]=this.records[u].splice(b,a);aa.adjust.call(this,b,a,0);(v=pa.adjust.call(this,b,a,0))&&(l={nested:v});ba.updateConfig.call(this,0,0,b,a);L.call(this,_$_f495[66],{columnNumber:b,numOfColumns:a});
280
- X.references.call(this,e);G.limited.call(this)&&0<f&&(this.tbody.textContent=_$_f495[3],G.call(this),G[_$_f495[46]].call(this,h,g));X.update.call(this,!0);U.call(this.parent,{worksheet:this,action:_$_f495[66],columnNumber:b,numOfColumns:a,insertBefore:1,data:n,properties:p,attributes:d,extra:l});F.call(this.parent,_$_f495[294],this,b,a,m,p,d)}}};c.properties=function(b,a){if(this.options.columns[b]){if(a){if(!Q.call(this.parent,this))return!1;a=typeof a==_$_f495[17]?{type:a}:a;a.type&&t.editors[a.type]||
281
- (a.type=_$_f495[56]);parseInt(a.width)||(a.width=this.options.defaultColWidth||100);this.edition&&this.closeEditor(this.edition,!1);var d=this.options.columns[b],e=t.editors[d.type],f=t.editors[a.type];if(e&&typeof e.destroyCell==_$_f495[85])for(var g=0;g<this.records.length;g++)this.records[g][b].element&&e.destroyCell(this.records[g][b].element);this.options.columns[b]=a;if(f&&typeof f.createCell==_$_f495[85])for(g=0;g<this.records.length;g++)this.records[g]&&this.records[g][b]&&this.records[g][b].element&&
282
- (M.applyProperties.call(this,this.records[g][b].element,b,g),f.createCell(this.records[g][b].element,N.call(this,b,g),b,g,this,a));a.width&&this.colgroup[b]&&this.colgroup[b].setAttribute(_$_f495[152],parseInt(a.width));typeof a.title!==_$_f495[13]&&this.headers[b]&&(a.title?(this.headers[b].innerText=a.title,this.headers[b].setAttribute(_$_f495[166],a.title)):(this.headers[b].innerText=E.getColumnName(b),this.headers[b].removeAttribute(_$_f495[166])));a.tooltip&&this.headers[b]&&(this.headers[b].title=
283
- a.tooltip);this.refreshBorders();U.call(this.parent,{worksheet:this,action:_$_f495[77],column:b,newValue:a,oldValue:d});L.call(this,_$_f495[77],{column:b,options:a});return!0}return this.options.columns[b]}console.error(_$_f495[295])};return c}(),Pa=function(){var k={},c={},b=function(d){if(typeof d==_$_f495[17]){var e=d;d=E.getCoordsFromColumnName(d);var f=d[0];d=d[1]}else f=d.x,d=d.y,e=E.getColumnNameFromCoords(f,d);if(this.records[d]&&this.records[d][f]&&this.records[d][f].element){c[e]=this.options.style[e];
284
- this.records[d][f].element.setAttribute(_$_f495[98],_$_f495[3]);var g=this.options.columns[f].align?this.options.columns[f].align:this.options.defaultColAlign;g&&(this.records[d][f].element.style.textAlign=g)}this.options.style&&this.options.style[e]&&delete this.options.style[e]},a=function(d){d.getStyle=a[_$_f495[51]];d.setStyle=a[_$_f495[11]];d.resetStyle=a.reset};a[_$_f495[51]]=function(d){var e=this.options.style;if(!e)return!1;if(d){if(typeof d==_$_f495[17])return e[d];var f=[],g=Object.keys(d);
285
- if(0<g.length)for(var h=0;h<g.length;h++){if(typeof d[h]==_$_f495[17])var l=e&&e[d[h]]?e[d[h]]:_$_f495[3];else l=E.getColumnNameFromCoords(d[h].x,d[h].y),l=e&&e[l]?e[l]:_$_f495[3];f.push(l)}return f}return this.options.style};a[_$_f495[11]]=function(d,e,f,g){if(!Q.call(this.parent,this))return!1;this.options.style||(this.options.style={});var h=this.options.style,l=null,m=[],n=[],p={};n=function(u,w,x){if(!p[u]&&(h[u]?m=h[u].split(_$_f495[264]):(h[u]=_$_f495[3],m=[]),p[u]={},m.length))for(var y=0;y<
286
- m.length;y++)m[y]&&m[y].trim()&&(l=m[y].split(_$_f495[136]),p[u][l[0].trim()]=l[1].trim());c[u]||(c[u]=[]);k[u]||(k[u]=[]);p[u][w]||(p[u][w]=_$_f495[3]);c[u].push([w+_$_f495[136]+p[u][w]]);p[u][w]=p[u][w]&&p[u][w]==x&&!g?_$_f495[3]:x;k[u].push([w+_$_f495[136]+p[u][w]]);x=E.getCoordsFromColumnName(u);this.records[x[1]]&&this.records[x[1]][x[0]]&&this.records[x[1]][x[0]].element&&(this.records[x[1]][x[0]].element.style[w]=p[u][w]);p[u][w]||delete p[u][w]};k={};c={};if(e)if(typeof d==_$_f495[17])n.call(this,
287
- d,e,f);else{if(d&&d.length)for(var q=0;q<d.length;q++){var v=E.getColumnNameFromCoords(d[q].x,d[q].y);n.call(this,v,e,f)}}else for(f=Object.keys(d),q=0;q<f.length;q++)if(v=d[f[q]])for(typeof v==_$_f495[17]&&(v=v.split(_$_f495[264])),e=0;e<v.length;e++)v[e]&&(typeof v[e]==_$_f495[17]&&(v[e]=v[e].split(_$_f495[136])),v[e][0].trim()&&n.call(this,f[q],v[e][0].trim(),v[e][1].trim()));m={};n=Object.keys(p);if(n.length){for(q=0;q<n.length;q++){m[n[q]]||(m[n[q]]=[]);d=Object.keys(p[n[q]]);for(e=0;e<d.length;e++)m[n[q]].push(d[e]+
288
- _$_f495[114]+p[n[q]][d[e]]);this.options.style[n[q]]=m[n[q]].join(_$_f495[296])}n=Object.keys(k);for(q=0;q<n.length;q++)k[n[q]]=k[n[q]].join(_$_f495[264]);n=Object.keys(c);for(q=0;q<n.length;q++)c[n[q]]=c[n[q]].join(_$_f495[264]);this.refreshBorders();U.call(this.parent,{worksheet:this,action:_$_f495[71],oldValue:c,newValue:k});L.call(this,_$_f495[71],[k]);F.call(this.parent,_$_f495[297],this,k,c)}};a.reset=function(d){if(!Q.call(this.parent,this))return!1;if(d){c={};if(Array.isArray(d))for(var e=
289
- 0;e<d.length;e++)b.call(this,d[e]);else b.call(this,d);this.refreshBorders();U.call(this.parent,{worksheet:this,action:_$_f495[72],cells:d,oldValue:c});L.call(this,_$_f495[72],[d]);F.call(this.parent,_$_f495[299],this,d)}else console.error(_$_f495[298])};a.update=function(d){k={};c={};for(var e=Object.keys(d),f=0;f<e.length;f++){c[e[f]]=this.options.style[e[f]]||_$_f495[3];k[e[f]]=this.options.style[e[f]]=d[e[f]];var g=E.getCoordsFromColumnName(e[f]),h=g[0];g=g[1];this.records[g]&&this.records[g][h]&&
290
- this.records[g][h].element&&(this.records[g][h].element.setAttribute(_$_f495[98],d[e[f]]),this.records[g][h].element.style.textAlign||(this.records[g][h].element.style.textAlign=this.options.columns[h].align||this.options.defaultColAlign||_$_f495[53]))}L.call(this,_$_f495[72],[e]);L.call(this,_$_f495[71],[k]);F.call(this.parent,_$_f495[297],this,k,c)};return a}(),Wa=function(){var k=function(c){c.getComments=k[_$_f495[51]];c.setComments=k[_$_f495[11]]};k[_$_f495[51]]=function(c){return c&&typeof c==
291
- _$_f495[17]?this.options.comments&&this.options.comments[c]?this.options.comments[c]:!1:this.options.comments};k[_$_f495[11]]=function(c,b){if(!Q.call(this.parent,this))return!1;if(typeof c==_$_f495[17]){var a={};a[c]=b}else a=c;if(b=F.call(this.parent,_$_f495[300],this,a))a=b;else if(!1===b)return!1;this.options.comments||(this.options.comments={});c={};var d=Object.keys(a);if(d.length){for(var e=0;e<d.length;e++){var f=E.getCoordsFromColumnName(d[e]);this.records[f[1]]&&this.records[f[1]][f[0]]&&
292
- (c[d[e]]=this.options.comments[d[e]]||_$_f495[3],(b=a[d[e]])?this.options.comments[d[e]]=b:delete this.options.comments[d[e]],this.records[f[1]][f[0]].element&&(b?this.records[f[1]][f[0]].element.setAttribute(_$_f495[265],b):this.records[f[1]][f[0]].element.removeAttribute(_$_f495[265])))}U.call(this.parent,{worksheet:this,action:_$_f495[76],newValue:a,oldValue:c});L.call(this,_$_f495[76],[a]);F.call(this.parent,_$_f495[301],this,a,c)}};return k}(),Xa=function(){var k=function(c){c.getMeta=k[_$_f495[51]];
293
- c.setMeta=k[_$_f495[11]];c.resetMeta=k.reset};k[_$_f495[51]]=function(c,b){if(c){if(this.options.meta[c])return b?this.options.meta[c][b]:this.options.meta[c]}else return this.options.meta};k[_$_f495[11]]=function(c,b,a){if(!Q.call(this.parent,this))return!1;this.options.meta||(this.options.meta={});if(typeof c==_$_f495[17]&&b){a||(a=_$_f495[3]);var d={};d[c]={};d[c][b]=a;c=d}b=Object.keys(c);if(b.length){a={};for(d=0;d<b.length;d++){this.options.meta[b[d]]||(this.options.meta[b[d]]={});a[b[d]]||
294
- (a[b[d]]={});for(var e=Object.keys(c[b[d]]),f=0;f<e.length;f++)this.options.meta[b[d]][e[f]]=c[b[d]][e[f]],a[b[d]][e[f]]=c[b[d]][e[f]]}Object.keys(a).length&&(L.call(this,_$_f495[302],[a]),F.call(this.parent,_$_f495[303],this,a))}};k.reset=function(){this.options.meta={};L.call(this,_$_f495[304],{});F.call(this.parent,_$_f495[305],this,{})};return k}(),Ya=function(){var k=function(c){c.orderBy=k.execute};k.handler=function(c,b){return function(a,d){a=a[1];d=d[1];return c?a===_$_f495[3]&&d!==_$_f495[3]?
295
- 1:a!==_$_f495[3]&&d===_$_f495[3]?-1:a>d?-1:a<d?1:0:a===_$_f495[3]&&d!==_$_f495[3]?1:a!==_$_f495[3]&&d===_$_f495[3]?-1:a>d?1:a<d?-1:0}};k.execute=function(c,b,a){if(0<=c){b=null==b?this.headers[c].classList.contains(_$_f495[306])?1:0:b?1:0;for(var d,e,f=[],g=0;g<this.options.data.length;g++)d=Ga.getOptions.call(this,c,g),e=this.records[g][c].v,e=d.type==_$_f495[252]||d.type==_$_f495[257]||d.type==_$_f495[258]||d.type==_$_f495[307]||d.type==_$_f495[14]||d.type==_$_f495[308]?Number(e):jSuites.isNumeric(e)?
296
- Number(e):e.toLowerCase(),f[g]=[g,e];g=typeof this.parent.config.sorting===_$_f495[85]?this.parent.config.sorting(b,c):k.handler(b,c);f.sort(g);d=a?!0:!1;if(!a)for(a=[],g=0;g<f.length;g++)a[g]=f[g][0];if(g=F.call(this.parent,_$_f495[309],this,c,b,a))a=g;else if(!1===g)return!1;if(d)this.destroyMerged();else if(0<Object.keys(this.getMerge()).length)if(confirm(C(_$_f495[310])))this.destroyMerged();else return!1;if(a.length<f.length)for(g=0;g<f.length;g++)-1==a.indexOf(f[g][0])&&a.push(f[g][0]);f=[];
297
- for(g=0;g<a.length;g++)f[a[g]]=g;Da.call(this,!1);ha.reset.call(this);L.call(this,_$_f495[78],{column:c,direction:b,order:a});k.update.call(this,a);k.arrow.call(this,c,b);ha.refresh.call(this);U.call(this.parent,{worksheet:this,action:_$_f495[78],column:c,newValue:a,oldValue:f,direction:b});F.call(this.parent,_$_f495[311],this,c,b,a);return!0}};k.update=function(c){for(var b=[],a=0;a<c.length;a++)b[a]=this.options.data[c[a]];for(a=0;a<c.length;a++)this.options.data[a]=b[a];b=[];for(a=0;a<c.length;a++)b[a]=
298
- this.records[c[a]];this.records=b;b=[];for(a=0;a<c.length;a++)b[a]=this.rows[c[a]];this.rows=b;X.references.call(this);this.searchInput&&this.searchInput.value?qa.update.call(this,null):ca.update.call(this)};k.arrow=function(c,b){for(var a=0;a<this.headers.length;a++)this.headers[a].classList.remove(_$_f495[312]),this.headers[a].classList.remove(_$_f495[306]);b?this.headers[c].classList.add(_$_f495[312]):this.headers[c].classList.add(_$_f495[306])};return k}(),ta=function(){var k=function(c){c.whichPage=
299
- k.whichPage;c.quantityOfPages=k.quantityOfPages;c.page=k[_$_f495[11]];c.updatePagination=k.update};k.build=function(){this.pageNumber=0;var c=document.createElement(_$_f495[20]),b=document.createElement(_$_f495[20]);this.pagination=document.createElement(_$_f495[20]);this.pagination.classList.add(_$_f495[313]);this.pagination.appendChild(c);this.pagination.appendChild(b);this.options.pagination||(this.pagination.style.display=_$_f495[40]);this.element.appendChild(this.pagination)};k.pageUp=function(){0<
300
- this.pageNumber&&(this.pageNumber--,k[_$_f495[11]].call(this,this.pageNumber))};k.pageDown=function(){this.pageNumber<k.quantityOfPages.call(this)-1&&(this.pageNumber++,k[_$_f495[11]].call(this,this.pageNumber))};k.whichPage=function(c){if(0<this.options.pagination)return this.rows[c]?(this.results&&(c=this.results.indexOf(parseInt(c))),Math.ceil((parseInt(c)+1)/parseInt(this.options.pagination))-1):null;console.log(_$_f495[314]);return!1};k.quantityOfPages=function(){if(0<this.options.pagination)return Math.ceil((this.results?
301
- this.results.length:this.rows.length)/parseInt(this.options.pagination));console.log(_$_f495[314]);return!1};k[_$_f495[11]]=function(c,b){var a=this.pageNumber,d=parseInt(this.options.pagination);if(d){if(null==c||-1==c)c=Math.ceil((this.results?this.results:this.rows).length/d)-1;if(!1===F.call(this.parent,_$_f495[316],this,c,a,d))return!1;this.pageNumber=c;G.resetY.call(this);aa.refresh.call(this);typeof b==_$_f495[85]&&b.call(this);F.call(this.parent,_$_f495[317],this,c,a,d)}else console.error(_$_f495[315])};
302
- k.update=function(){this.pagination.children[0].innerHTML=_$_f495[3];this.pagination.children[1].innerHTML=_$_f495[3];if(this.options.pagination){var c=this.results?this.results.length:this.rows.length;if(c){c=Math.ceil(c/this.options.pagination);if(6>this.pageNumber)var b=1,a=10>c?c:10;else 5>c-this.pageNumber?(b=c-9,a=c,1>b&&(b=1)):(b=this.pageNumber-4,a=this.pageNumber+5);if(1<b){var d=document.createElement(_$_f495[20]);d.className=_$_f495[319];d.innerHTML=_$_f495[215];d.title=1;this.pagination.children[1].appendChild(d)}for(;b<=
303
- a;b++)d=document.createElement(_$_f495[20]),d.className=_$_f495[319],d.innerHTML=b,this.pagination.children[1].appendChild(d),this.pageNumber==b-1&&d.classList.add(_$_f495[320]);a<c&&(d=document.createElement(_$_f495[20]),d.className=_$_f495[319],d.innerHTML=_$_f495[216],d.title=c,this.pagination.children[1].appendChild(d));this.pagination.children[0].innerHTML=C(_$_f495[321],[this.pageNumber+1,c])}else this.pagination.children[0].innerHTML=C(_$_f495[318])}};return k}(),ka=function(){var k=function(c){c.setFreezeColumns=
304
- k[_$_f495[11]];c.resetFreezeColumns=k.reset};k.width=function(){if(this.options.freezeColumns){k.headers.call(this);for(var c=0;c<this.rows.length;c++)this.rows[c].element&&k.update.call(this,c)}};k.update=function(c){var b,a;if(a=this.options.freezeColumns){var d=xa.call(this)?50:0;if(this.rows[c].element)for(var e=0;e<a;e++){if(b=this.records[c][e].element)b.classList.add(_$_f495[50]),b.style.left=d+1+_$_f495[44];!1!==this.options.columns[e].visible&&(d+=this.options.columns[e].width)}}};k.headers=
305
- function(){var c=xa.call(this)?50:0,b;if(b=this.options.freezeColumns)for(var a=0;a<b;a++){if(this.headers[a]){this.headers[a].classList.add(_$_f495[50]);this.headers[a].style.left=c+1+_$_f495[44];if(this.options.footers)for(var d=0;d<this.options.footers.length;d++)this.footers.content[d][a].element.classList.add(_$_f495[50]),this.footers.content[d][a].element.style.left=c+1+_$_f495[44];!1!==this.options.columns[a].visible&&(c+=this.options.columns[a].width)}}else k.reset.call(this)};k[_$_f495[11]]=
306
- function(c){k.reset.call(this);this.options.freezeColumns=c;k.width.call(this);G.limited.call(this)&&T.call(this)};k.reset=function(){G[_$_f495[46]].call(this,null,this.options.freezeColumns);for(var c,b=1;b<=this.options.freezeColumns;b++){if(c=this.thead.lastChild)c.children[b].classList.remove(_$_f495[50]),c.children[b].style.left=_$_f495[3];for(var a=0;a<this.rows.length;a++)if(c=this.rows[a].element)c.children[b].classList.remove(_$_f495[50]),c.children[b].style.left=_$_f495[3];if(this.options.footers)for(a=
307
- 0;a<this.options.footers.length;a++)this.tfoot.children[a].children[b].classList.remove(_$_f495[50]),this.tfoot.children[a].children[b].style.left=_$_f495[3]}this.options.freezeColumns=0};k.getWidth=function(){var c=xa.call(this)?50:0;if(0<this.options.freezeColumns)for(var b=0;b<=this.options.freezeColumns;b++)c=this.thead.lastChild.children[b]?c+this.thead.lastChild.children[b].offsetWidth:c+this.options.columns[b].width;return c};return k}(),X=function(){var k=function(a,d){if(this.options[a]){for(var e=
308
- {},f=Object.keys(this.options[a]),g=0;g<f.length;g++)e[d&&void 0!=d[f[g]]?d[f[g]]:f[g]]=this.options[a][f[g]];this.options[a]=e}},c=function(){if(0<this.options.minSpareRows){for(var a=0,d=this.rows.length-1;0<=d;d--){for(var e=!1,f=0;f<this.options.columns.length;f++)N.call(this,f,d)&&(e=!0);if(e)break;else a++}0<this.options.minSpareRows-a&&this.insertRow(this.options.minSpareRows-a)}if(0<this.options.minSpareCols){a=0;for(f=this.options.columns.length-1;0<=f;f--){e=!1;for(d=0;d<this.rows.length;d++)N.call(this,
309
- f,d)&&(e=!0);if(e)break;else a++}0<this.options.minSpareCols-a&&this.insertColumn(this.options.minSpareCols-a)}},b=function(){};b.build=function(){var a=this;this.content=document.createElement(_$_f495[20]);this.content.classList.add(_$_f495[322]);this.content.addEventListener(_$_f495[323],function(f){if(G.limited.call(a)&&!a.options.pagination){var g=Math.abs(f.deltaX),h=Math.abs(f.deltaY);f.shiftKey||g>h?0>f.deltaX||0>f.deltaY?G.pageLeft.call(a,1,null,f):G.pageRight.call(a,1,null,f):0>f.deltaY?
310
- G.pageUp.call(a,1,null,f):G.pageDown.call(a,1,null,f)}});this.content.addEventListener(_$_f495[324],function(f){if(!a.edition)return f.preventDefault(),!1});this.table=document.createElement(_$_f495[325]);this.thead=document.createElement(_$_f495[326]);this.tbody=document.createElement(_$_f495[327]);this.tfoot=document.createElement(_$_f495[328]);this.headers=[];this.colgroup=[];this.colgroupContainer=document.createElement(_$_f495[329]);var d=document.createElement(_$_f495[169]);d.setAttribute(_$_f495[152],
311
- _$_f495[330]);this.colgroupContainer.appendChild(d);this.headerContainer=document.createElement(_$_f495[145]);d=document.createElement(_$_f495[147]);d.classList.add(_$_f495[331]);this.headerContainer.appendChild(d);this.thead.appendChild(this.headerContainer);this.table.classList.add(_$_f495[332]);this.table.setAttribute(_$_f495[333],_$_f495[97]);this.table.setAttribute(_$_f495[334],_$_f495[97]);this.table.setAttribute(_$_f495[335],_$_f495[336]);this.table.appendChild(this.colgroupContainer);this.table.appendChild(this.thead);
312
- this.table.appendChild(this.tbody);this.table.appendChild(this.tfoot);this.parent.config.wordWrap&&this.table.classList.add(_$_f495[337]);this.options.textOverflow||this.table.classList.add(_$_f495[338]);!1===this.options.selectLockedCells&&this.table.classList.add(_$_f495[339]);this.corner=document.createElement(_$_f495[20]);this.corner.className=_$_f495[340];this.corner.setAttribute(_$_f495[335],_$_f495[341]);this.corner.setAttribute(_$_f495[342],_$_f495[343]);0==this.options.selectionCopy&&(this.corner.style.display=
313
- _$_f495[40]);this.scrollX=T.build.call(a,_$_f495[45]);this.scrollY=T.build.call(a,_$_f495[344]);d=document.createElement(_$_f495[20]);d.appendChild(this.content);d.appendChild(this.scrollY);d.classList.add(_$_f495[345]);var e=document.createElement(_$_f495[20]);e.appendChild(d);e.appendChild(this.scrollX);e.classList.add(_$_f495[346]);this.content.appendChild(this.table);this.content.appendChild(this.corner);this.element.appendChild(e);1==this.options.tableOverflow&&(this.options.tableHeight||(this.options.tableHeight=
314
- 300),this.options.tableWidth||(this.options.tableWidth=document.body.offsetWidth-8),this.content.style.overflow=_$_f495[49],this.content.style.maxHeight=parseInt(this.options.tableHeight)+_$_f495[44],this.content.style.maxWidth=parseInt(this.options.tableWidth)+_$_f495[44]);this.options.freezeColumns>this.options.columns.length&&console.error(_$_f495[347]);qa.build.call(this);pa.build.call(this);ta.build.call(this);Ea.build.call(this);ba.build.call(this);aa.build.call(this);G.call(this);ca.onload.call(this);
315
- c.call(this)};b.references=function(a){var d=[],e=[],f=null,g=null,h=null,l=null;for(f=0;f<this.options.columns.length;f++)if(g=this.headers[f])h=g.getAttribute(_$_f495[42]),h!=f&&(g.setAttribute(_$_f495[42],f),g.getAttribute(_$_f495[166])||(g.innerHTML=E.getColumnName(f)));for(var m=0;m<this.rows.length;m++)g=this.rows[m],l=g.y,l!=m&&(g.y=m,d[l]=m,g.element&&(g.element.setAttribute(_$_f495[43],m),g.element.children[0].setAttribute(_$_f495[43],m),f=this.options.rows&&this.options.rows[l]&&this.options.rows[l].title?
316
- this.options.rows[l].title:m+1,g.element.children[0].innerHTML=f));var n=function(q,v){g=this.records[v][q];h=g.x;l=g.y;h!=q&&(g.x=q,g.element&&g.element.setAttribute(_$_f495[42],q));l!=v&&(g.y=v,g.element&&g.element.setAttribute(_$_f495[43],v));if(h!=q||l!=v){var u=E.getColumnNameFromCoords(h,l);q=E.getColumnNameFromCoords(q,v);e[u]=q}};if(a){m=function(q,v){q&&q[v]&&delete q[v]};var p=Object.keys(a);for(f=0;f<p.length;f++)m(this,p[f]),m(this.options.meta,p[f]),m(this.options.cells,p[f]),m(this.options.style,
317
- p[f]),m(this.options.comments,p[f])}for(m=0;m<this.rows.length;m++)for(f=0;f<this.options.columns.length;f++)n.call(this,f,m);k.call(this,_$_f495[348],d);k.call(this,_$_f495[278],e);k.call(this,_$_f495[279],e);k.call(this,_$_f495[98],e);k.call(this,_$_f495[280],e);k.call(this,_$_f495[263],e);this.options.mergeCells&&ba.build.call(this);V.updateAll.call(this,e,a);return e};b.update=function(a){a&&c.call(this);if(typeof this.parent.config.updateTable==_$_f495[85])for(var d=0;d<this.rows.length;d++)for(var e=
318
- 0;e<this.options.columns.length;e++)a=this.records[d][e],this.parent.config.updateTable.call(this,this,a.element,e,d,N.call(this,e,d),a.r?a.r:a.v);T.call(this);aa.refresh.call(this)};return b}(),oa=function(){var k={spreadsheet:function(c,b){var a={name:null,config:{},el:c,element:c,plugins:[],worksheets:[],history:[],historyIndex:-1,queue:[],ignoreEvents:!1,ignoreHistory:!1,ignorePersistence:!1};Ca.spreadsheet.call(a,b);a.config.license&&(t.license=a.config.license);c.spreadsheet=a;c.jspreadsheet=
319
- c.jexcel=a.worksheets;t.spreadsheet.push(a);a.name||(a.name=jSuites.guid());k.bind(a.config.root?a.config.root:document);var d=a.config.tabs;typeof d!==_$_f495[84]&&(d={allowCreate:d?!0:!1,hideHeaders:d?!1:!0,allowChangePosition:a.config.allowMoveWorksheet?!0:!1});d.maxWidth||(d.maxWidth=c.offsetWidth-50+_$_f495[44]);d.animation=void 0==d.animation?!0:d.animation;d.onbeforecreate=function(){a.createWorksheet();return!1};d.onclick=function(f,g,h,l,m){0<=h&&a.openWorksheet(h)};d.onchangeposition=function(f,
320
- g,h){a.updateWorksheet(g,h)};jSuites.tabs(c,d);c.classList.add(_$_f495[349]);1==b.fullscreen&&c.classList.add(_$_f495[15]);var e=document.createElement(_$_f495[20]);a.toolbar=document.createElement(_$_f495[20]);a.toolbar.className=_$_f495[350];e.appendChild(a.toolbar);a.filter=ca.build.call(a);e.appendChild(a.filter);a.helper=document.createElement(_$_f495[20]);a.helper.className=_$_f495[351];e.appendChild(a.helper);a.loading=document.createElement(_$_f495[20]);a.loading.classList.add(_$_f495[352]);
321
- e.appendChild(a.loading);e.appendChild(da.build(a));e.appendChild(Qa(a));a.textarea=document.createElement(_$_f495[353]);a.textarea.className=_$_f495[354];a.textarea.tabIndex=_$_f495[355];e.appendChild(a.textarea);d.position===_$_f495[356]?c.insertBefore(e,c.children[0]):c.insertBefore(e,c.children[1]);c.appendChild(Ia.call(a,t.license));a.createWorksheet=ia.createWorksheet;a.deleteWorksheet=ia.deleteWorksheet;a.renameWorksheet=ia.renameWorksheet;a.updateWorksheet=ia.updateWorksheet;a.openWorksheet=
322
- ia.openWorksheet;a.moveWorksheet=ia.moveWorksheet;a.getWorksheet=ia.getWorksheet;a.getWorksheetActive=ia.getWorksheetActive;a.getWorksheetInstance=ia.getWorksheetInstance;a.getConfig=function(){var f=a.config;f.worksheets=[];for(var g=0;g<a.worksheets.length;g++)f.worksheets.push(a.worksheets[g].getConfig());return f};a.fullscreen=Ja;a.progress=Ka;a.undo=U.undo;a.redo=U.redo;a.setToolbar=fa[_$_f495[11]];a.getToolbar=fa[_$_f495[51]];a.showToolbar=fa.show;a.hideToolbar=fa.hide;a.tools=e;1!==a.edition&&
323
- (c=Object.keys(a.config.definedNames))&&c.length&&(a.config.definedNames={},console.log(_$_f495[357]));b.plugins&&na.call(a,b.plugins);a.setPlugins=function(f){na.call(a,f)};c=Object.keys(t.extensions);if(c.length)for(d=0;d<c.length;d++)if(typeof t.extensions[c[d]].oninit==_$_f495[85])t.extensions[c[d]].oninit(a,b);return a},worksheet:function(c,b){var a={};c.worksheets.push(a);a.parent=c;Ca(a);Sa(a);ya(a);ha(a);da(a);Ea(a);Ua(a);ba(a);Pa(a);Va(a);ea(a);V(a);M(a);za(a);Ga(a);Xa(a);Wa(a);Ba(a);aa(a);
324
- pa(a);qa(a);ca(a);fa(a);sa(a);Za(a);$a(a);ta(a);ia(a);ka(a);Ta(a);Ya(a);Ha(a);Ca.worksheet.call(a,b);!t.license&&a.options.license&&(t.license=a.options.license);c.element.jexcel=c.worksheets?c.worksheets:a;na.execute.call(a.parent,_$_f495[358],[a]);a.onload=function(){this.options.worksheetName||(this.options.worksheetName=_$_f495[359]+ia.nextName());var d=this.options.worksheetName;H(d)&&console.log(_$_f495[360]+d+_$_f495[361]);H(d,a);this.element=c.element.tabs.appendElement(this.options.worksheetName,
325
- function(e,f){a.options.worksheetState===_$_f495[49]&&(f.style.display=_$_f495[40])});this.element.classList.add(_$_f495[362]);this.element.jexcel=this;X.build.call(this);na.execute.call(this.parent,_$_f495[363],[this]);this.options.data&&500<this.options.data.length&&!G.limited.call(this)&&!this.options.pagination&&console.error(_$_f495[364])};return a},row:function(c,b){this.rows[c]||(this.rows[c]={element:null,y:c});b&&(this.rows[c].id=b,sa[_$_f495[11]].call(this,b));this.options.rows&&this.options.rows[c]&&
326
- this.options.rows[c].height&&(this.rows[c].height=this.options.rows[c].height);this.records[c]||(this.records[c]=[]);this.options.data[c]||(this.options.data[c]=this.dataType?{}:[]);for(b=0;b<this.options.columns.length;b++)k.cell.call(this,b,c)},cell:function(c,b,a){typeof a==_$_f495[13]&&(a=N.call(this,c,b),null===a||void 0===a)&&(a=_$_f495[3],N.call(this,c,b,a));this.records[b][c]||(this.records[b][c]={element:null,x:c,y:b,v:a})},bind:function(c){for(var b=Object.keys(Aa),a=0;a<b.length;a++)(b[a]==
327
- _$_f495[365]?window:c).addEventListener(b[a],Aa[b[a]],b[a]==_$_f495[366]||b[a]==_$_f495[367]||b[a]==_$_f495[368]?{passive:!1}:{})},unbind:function(c){for(var b=Object.keys(Aa),a=0;a<b.length;a++)(b[a]==_$_f495[365]?window:c).removeEventListener(b[a],Aa[b[a]])}};return k}(),Za=function(){var k=function(c){c.getWidth=k[_$_f495[51]];c.setWidth=k[_$_f495[11]]};k[_$_f495[51]]=function(c){var b=this.options.columns;if(typeof c===_$_f495[13]){c=[];for(var a=0;a<b.length;a++)c.push(b[a].width)}else c=b[c].width;
328
- return c};k[_$_f495[11]]=function(c,b,a){if(!Q.call(this.parent,this))return!1;if(b){if(Array.isArray(c)){a||(a=[]);for(var d=0;d<c.length;d++){a[d]||(a[d]=this.options.columns[c[d]].width);var e=Array.isArray(b)&&b[d]?b[d]:b;this.options.columns[c[d]].width=e;this.colgroup[c[d]]&&this.colgroup[c[d]].setAttribute(_$_f495[152],e)}}else a||(a=this.options.columns[c].width),this.options.columns[c].width=b,this.colgroup[c]&&this.colgroup[c].setAttribute(_$_f495[152],b);this.refreshBorders();U.call(this.parent,
329
- {worksheet:this,action:_$_f495[73],column:c,oldValue:a,newValue:b});L.call(this,_$_f495[73],{column:c,width:b,oldWidth:a});F.call(this.parent,_$_f495[369],this,c,b,a)}G.refresh.call(this)};return k}(),$a=function(){var k=function(b){b.getHeight=k[_$_f495[51]];b.setHeight=k[_$_f495[11]]};k[_$_f495[51]]=function(b){if(b)b=this.rows[b].element.style.height;else{b=[];for(var a=0;a<this.rows.length;a++){var d=this.rows[a].element.style.height;d&&(b[a]=d)}}return b};var c=function(b,a){a=parseInt(a);var d=
330
- this.rows[b].height?this.rows[b].height:this.rows[b].element.offsetHeight||this.options.defaultRowHeight;this.rows[b].element.style.height=a+_$_f495[44];this.options.rows[b]||(this.options.rows[b]={});this.options.rows[b].height=a+_$_f495[44];this.rows[b].height=a;return d};k[_$_f495[11]]=function(b,a,d){if(!Q.call(this.parent,this))return!1;var e,f=typeof d==_$_f495[13]?!0:!1;if(a){if(Array.isArray(b))for(!0===f&&(d=[]),e=0;e<b.length;e++){var g=Array.isArray(a)&&a[e]?a[e]:a;c.call(this,b[e],g);
331
- 1==f&&d.push(f)}else e=c.call(this,b,a),1==f&&(d=e);this.refreshBorders();U.call(this.parent,{worksheet:this,action:_$_f495[74],row:b,oldValue:d,newValue:a});L.call(this,_$_f495[74],{row:b,height:a,oldHeight:d});F.call(this.parent,_$_f495[370],this,b,a,d)}G.refresh.call(this)};return k}(),ca=function(){var k=function(g){var h=e[g];g=a[e[g]];if(!g.element){g.element=document.createElement(_$_f495[371]);g.element.innerHTML=g.value;var l=document.createElement(_$_f495[220]);l.type=_$_f495[251];l.value=
332
- h;l.o=g;g.element.insertBefore(l,g.element.firstChild)}g.element.firstChild.checked=g.selected;return g.element},c=null,b=null,a=[],d=0,e=null,f=function(g){g.setFilter=f[_$_f495[11]];g.getFilter=f[_$_f495[51]];g.openFilter=f.open;g.closeFilter=f.close;g.resetFilters=f.reset;g.showFilter=f.show;g.hideFilter=f.hide};f.isVisible=function(){return b};f[_$_f495[11]]=function(g,h){var l=this.headers[g];g=this.options.columns[g];Array.isArray(h)&&0<h.length?(l&&l.classList.add(_$_f495[372]),g.filters=h):
333
- (l&&l.classList.remove(_$_f495[372]),g.filters=null);f.update.call(this)};f[_$_f495[51]]=function(g){if(g)return this.options.columns[g].filters||null;g={};for(var h=0;h<this.options.columns.length;h++)g[h]=this.options.columns[h].filters||null;return g};f.open=function(g){c=parseInt(g);if(this.headers[c].classList.contains(_$_f495[168])){b=!0;var h=this.parent.element.getBoundingClientRect(),l=this.headers[c].getBoundingClientRect();g=l.left-h.left;l=l.top-h.top+l.height;h=this.parent.filter;h.style.display=
334
- _$_f495[16];h.style.top=l+_$_f495[44];h.style.left=g+_$_f495[44];h.children[0].focus();g=h.children[1].selectAll;h.children[1].textContent=_$_f495[3];h.children[1].appendChild(g);this.options.columns[c].filters||(g.children[0].checked=!0);g=qa.execute.call(this,null,c);g=E.invert(g);h=[];for(l=0;l<this.rows.length;l++)if(g[l]){var m=_$_f495[3]+N.call(this,c,l),n=_$_f495[3]+ea.processed.call(this,c,l,!0);m.substr(0,1)==_$_f495[12]&&(m=n);h.push([m,n])}h.sort(function(p,q){return p[0]>q[0]?1:p[0]<q[0]?
335
- -1:0});a=[];for(l=0;l<h.length;l++)a[h[l][0]]={value:h[l][1],element:null};void 0!==a[_$_f495[3]]&&(delete a[_$_f495[3]],a[_$_f495[3]]={value:_$_f495[212]+C(_$_f495[374])+_$_f495[232],element:null});f.search.call(this,_$_f495[3])}else console.log(_$_f495[373])};f.close=function(g){if(g){g=this.parent.filter.children[1];if(1==g.selectAll.firstChild.checked&&e.length==Object.keys(a).length)g=null;else{g=1==g.currentSelection.firstChild.checked?this.options.columns[c].filters||[]:[];for(var h=0;h<e.length;h++)a[e[h]].selected&&
336
- g.push(e[h])}f[_$_f495[11]].call(this,c,g)}this.parent.filter.style.display=_$_f495[3];this.parent.filter.children[0].value=_$_f495[3];c=null;b=!1;a=null;d=0;e=null};f.reset=function(g){f.updateDOM.call(this,g,!1);ua.reset.call(this);f.update.call(this)};f.execute=function(g){for(var h=this.options.columns,l=[],m=0;m<this.options.data.length;m++){for(var n=!0,p=0;p<h.length;p++)if(h[p].filters&&g!==p){var q=_$_f495[3]+N.call(this,p,m),v=_$_f495[3]+this.getLabelFromCoords(p,m,!0);-1==h[p].filters.indexOf(q)&&
337
- -1==h[p].filters.indexOf(v)&&(n=!1)}n&&l.push(m)}return l};f.update=function(){ua.reset.call(this);this.resetSelection();this.resetBorders();var g=qa.execute.call(this,null);if(typeof this.parent.config.onbeforefilter==_$_f495[85]){var h=f[_$_f495[51]].call(this),l=F.call(this.parent,_$_f495[375],this,h,g);if(l)g=l;else if(!1===l)return!1}this.pageNumber=0;g&&g.length<this.rows.length&&ua[_$_f495[11]].call(this,g);G.resetY.call(this);aa.refresh.call(this);F.call(this.parent,_$_f495[376],this,h,g)};
338
- f.show=function(g){f.updateDOM.call(this,g,!0)};f.hide=function(g){f.updateDOM.call(this,g,!1,!0);f.update.call(this)};f.search=function(g){for(var h=this.parent.filter.children[1];h.children[1];)h.removeChild(h.lastChild);h.currentSelection.firstChild.checked=!1;if(g){e=[];g=new RegExp(g,_$_f495[377]);for(var l=Object.keys(a),m=0;m<l.length;m++)(_$_f495[3]+l[m]).match(g)||(_$_f495[3]+a[l[m]]).match(g)?(e.push(l[m]),a[l[m]].selected=!0):a[l[m]].selected=!1;h.firstChild.checked=!0;this.options.columns[c].filters&&
339
- h.appendChild(h.currentSelection)}else{e=Object.keys(a);if(g=this.options.columns[c].filters)for(m=0;m<e.length;m++)a[e[m]].selected=!1,0<=g.indexOf(e[m])&&(a[e[m]].selected=!0);else for(m=0;m<e.length;m++)a[e[m]].selected=!0;h.firstChild.checked=g?!1:!0}for(m=d=0;m<e.length;m++)200>m&&(g=d++,h.appendChild(k(g)))};f.build=function(){var g=document.createElement(_$_f495[20]);g.className=_$_f495[378];g.onclick=function(n){n.target.tagName==_$_f495[379]&&n.target.o&&(n.target.o.selected=n.target.checked);
340
- n=!0;for(var p=1;p<this.children.length;p++)this.children[p].children[0].checked||(n=!1);this.children[0].children[0].checked=n};var h=document.createElement(_$_f495[220]);h.type=_$_f495[56];h.placeholder=C(_$_f495[380]);h.className=_$_f495[381];var l=document.createElement(_$_f495[220]);l.type=_$_f495[382];l.value=_$_f495[383];l.className=_$_f495[384];var m=document.createElement(_$_f495[20]);m.className=_$_f495[385];m.appendChild(h);m.appendChild(g);m.appendChild(l);g.currentSelection=document.createElement(_$_f495[371]);
341
- g.currentSelection.innerHTML=_$_f495[386]+C(_$_f495[387]);g.selectAll=document.createElement(_$_f495[371]);g.selectAll.innerHTML=_$_f495[388]+C(_$_f495[389])+_$_f495[232];g.selectAll.onclick=function(){for(var n=this.children[0].checked,p=1;p<this.parentNode.children.length;p++)this.parentNode.children[p].children[0].checked=n;if(1==n)for(p=0;p<e.length;p++)a[e[p]].selected=!0;else for(n=Object.keys(a),p=0;p<n.length;p++)a[n[p]].selected=!1};jSuites.lazyLoading(g,{loadDown:function(n){for(n=0;d<e.length-
342
- 1&&10>n;){var p=d++;g.appendChild(k(p));n++}}});return m};f.updateDOM=function(g,h,l){var m=this.headers,n=function(p){1==h?m[p].classList.add(_$_f495[168]):(this.options.columns[p].filters=null,m[p].classList.remove(_$_f495[372]),1==l&&m[p].classList.remove(_$_f495[168]))};if(g)n.call(this,g);else for(g=0;g<m.length;g++)n.call(this,g)};f.onload=function(){var g,h=!1;if(g=this.options.columns)for(var l=0;l<g.length;l++)Array.isArray(g[l].filters)&&0<g[l].filters.length&&this.headers[l]&&(this.headers[l].classList.add(_$_f495[372]),
343
- h=!0);1==h&&f.update.call(this)};return f}(),ua=function(){var k={};k[_$_f495[11]]=function(c){for(var b=0;b<c.length;b++)this.rows[c[b]].results=!0;this.results=c};k.reset=function(){for(var c=0;c<this.rows.length;c++)!0===this.rows[c].results&&delete this.rows[c].results;this.results=null};k.refresh=function(){for(var c=[],b=0;b<this.rows.length;b++)!0===this.rows[b].results&&c.push(b);return c};return k}(),qa=function(){var k=function(a){var d=document.createElement(_$_f495[20]);if(0<a.options.pagination&&
344
- a.options.paginationOptions&&0<a.options.paginationOptions.length){a.paginationDropdown=document.createElement(_$_f495[390]);a.paginationDropdown.classList.add(_$_f495[391]);a.paginationDropdown.onchange=function(){a.options.pagination=parseInt(this.value);a.page(0)};for(var e=0;e<a.options.paginationOptions.length;e++){var f=document.createElement(_$_f495[392]);f.value=a.options.paginationOptions[e];f.innerHTML=a.options.paginationOptions[e];a.paginationDropdown.appendChild(f)}a.paginationDropdown.value=
345
- a.options.pagination;d.appendChild(document.createTextNode(C(_$_f495[393])));d.appendChild(a.paginationDropdown);d.appendChild(document.createTextNode(C(_$_f495[394])))}return d},c=function(a,d){var e=this.merged.rows;if(e[d]){for(;0<d&&e[d-1];)d--;for(;e[d];)a.push(d++)}else a.push(d)},b=function(a){a.search=b.update;a.resetSearch=b.reset;a.updateSearch=b.refresh;a.showSearch=b.show;a.hideSearch=b.hide};b.execute=function(a,d){null===a?a=this.searchInput.value||_$_f495[3]:a!==this.searchInput.value&&
346
- (this.searchInput.value=a);this.pageNumber=0;var e=[],f=null;d=ca.execute.call(this,d);if(a)try{a=new RegExp(a,_$_f495[377]);for(var g=0;g<this.rows.length;g++){f=!1;if(!d||0<=d.indexOf(g))for(var h=0;h<this.options.columns.length;h++){var l=_$_f495[3]+N.call(this,h,g),m=_$_f495[3]+this.getLabelFromCoords(h,g);if(l.match(a)||m.match(a))f=!0}1==f&&c.call(this,e,g)}}catch(n){}else e=d;if(e.length){for(g=0;g<this.rows.length;g++)!0===this.rows[g].results&&e.push(g);e.sort(function(n,p){return n-p})}return e};
347
- b.update=function(a){ua.reset.call(this);this.resetSelection();this.resetBorders();var d=b.execute.call(this,a);if(typeof this.parent.config.onbeforesearch==_$_f495[85]){var e=F.call(this.parent,_$_f495[396],this,a,d);if(e)d=e;else if(!1===e)return!1}this.pageNumber=0;d&&d.length<this.rows.length&&ua[_$_f495[11]].call(this,d);G.resetY.call(this);aa.refresh.call(this);F.call(this.parent,_$_f495[397],this,a,d)};b.refresh=function(){G.resetY.call(this);aa.refresh.call(this)};b.reset=function(){this.searchInput.value=
348
- _$_f495[3];ua.reset.call(this);G.resetY.call(this);aa.refresh.call(this)};b.show=function(){this.options.search=!0;this.searchContainer.style.display=_$_f495[3]};b.hide=function(){this.options.search=!1;this.searchContainer.style.display=_$_f495[40]};b.build=function(){this.searchContainer=document.createElement(_$_f495[20]);this.searchContainer.classList.add(_$_f495[398]);this.searchContainer.appendChild(k(this));var a=this.searchContainer,d=a.appendChild,e=document.createElement(_$_f495[20]);e.innerHTML=
349
- C(_$_f495[380])+_$_f495[114];this.searchInput=document.createElement(_$_f495[220]);this.searchInput.classList.add(_$_f495[395]);e.appendChild(this.searchInput);d.call(a,e);0==this.options.search&&(this.searchContainer.style.display=_$_f495[40]);this.element.insertBefore(this.searchContainer,this.element.firstChild)};return b}(),Qa=function(){var k=function(c){c.contextmenu=document.createElement(_$_f495[20]);c.contextmenu.className=_$_f495[399];jSuites.contextmenu(c.contextmenu,{onclick:function(b,
350
- a,d){b.close()}});return c.contextmenu};k.open=function(c,b){var a=c.target.getAttribute(_$_f495[42]),d=c.target.getAttribute(_$_f495[43]),e=k[_$_f495[51]](this,a,d,c,b[0],b[1],b[2]);if(typeof this.parent.config.contextMenu==_$_f495[85]){var f=this.parent.config.contextMenu(this,a,d,c,e,b[0],b[1],b[2]);if(f)e=f;else if(!1===f)return!1}c.preventDefault();f=na.execute.call(this.parent,_$_f495[86],[this,a,d,c,e,b[0],b[1],b[2]]);e=f[4];this.parent.contextmenu.contextmenu.open(c,e)};k[_$_f495[51]]=function(c,
351
- b,a,d,e,f,g){var h=[],l=c.parent.config,m=-1!=navigator.userAgent.indexOf(_$_f495[400])?_$_f495[401]:_$_f495[402];e==_$_f495[403]&&(1==l.allowRenameWorksheet&&h.push({title:C(_$_f495[404]),onclick:function(){var p=prompt(C(_$_f495[404]),d.target.innerText);p&&c.parent.renameWorksheet(f,p)}}),1==l.allowDeleteWorksheet&&h.push({title:C(_$_f495[405]),onclick:function(){confirm(C(_$_f495[406]),d.target.innerText)&&c.parent.deleteWorksheet(f)}}),h.push({type:_$_f495[407]}));e==_$_f495[408]&&(h.push({title:C(_$_f495[409]),
352
- onclick:function(){var p=prompt(C(_$_f495[409]),d.target.innerText);c.setNestedCell(f,g,{title:p})}}),h.push({type:_$_f495[407]}));if(e==_$_f495[410]||e==_$_f495[411]||e==_$_f495[412]||e==_$_f495[408])h.push({title:C(_$_f495[413]),icon:_$_f495[414],shortcut:m+_$_f495[415],onclick:function(){c.cut()}}),h.push({title:C(_$_f495[416]),icon:_$_f495[417],shortcut:m+_$_f495[418],onclick:function(){c.copy()}}),navigator&&navigator.clipboard&&navigator.clipboard.readText&&h.push({title:C(_$_f495[419]),icon:_$_f495[420],
353
- shortcut:m+_$_f495[421],onclick:function(){c.selectedCell&&navigator.clipboard.readText().then(function(p){p&&c.paste(c.selectedCell[0],c.selectedCell[1],p)})}}),h.push({type:_$_f495[407]});e==_$_f495[410]&&(1==c.options.allowInsertColumn&&h.push({title:C(_$_f495[422]),onclick:function(){c.insertColumn(1,parseInt(f),1)}}),1==c.options.allowInsertColumn&&h.push({title:C(_$_f495[423]),onclick:function(){c.insertColumn(1,parseInt(f),0)}}),1==c.options.allowDeleteColumn&&h.push({title:C(_$_f495[424]),
354
- onclick:function(){c.deleteColumn(c.getSelectedColumns().length?void 0:parseInt(b))}}),1==c.options.allowRenameColumn&&h.push({title:C(_$_f495[425]),onclick:function(){c.setHeader(f)}}),c.options.data.length||(h.push({type:_$_f495[407]}),h.push({title:C(_$_f495[426]),onclick:function(){c.insertRow(0)}})),1==c.options.columnSorting&&(h.push({type:_$_f495[407]}),h.push({title:C(_$_f495[427]),onclick:function(){c.orderBy(f,0)}}),h.push({title:C(_$_f495[428]),onclick:function(){c.orderBy(f,1)}}),h.push({type:_$_f495[407]})));
355
- if(e==_$_f495[412]||e==_$_f495[411])1==c.options.allowInsertRow&&(h.push({title:C(_$_f495[429]),onclick:function(){c.insertRow(1,parseInt(a),1)}}),h.push({title:C(_$_f495[430]),onclick:function(){c.insertRow(1,parseInt(a))}})),1==c.options.allowDeleteRow&&h.push({title:C(_$_f495[431]),onclick:function(){c.deleteRow(c.getSelectedRows().length?void 0:parseInt(a))}}),h.push({type:_$_f495[407]});if(e==_$_f495[412]&&1==c.options.allowComments){var n=c.records[g][f].element.getAttribute(_$_f495[265])||
356
- _$_f495[3];h.push({title:n?C(_$_f495[432]):C(_$_f495[433]),icon:_$_f495[434],onclick:function(){var p=E.getColumnNameFromCoords(f,g),q=prompt(C(_$_f495[435]),n);q&&c.setComments(p,q)}});n&&h.push({title:C(_$_f495[436]),onclick:function(){var p=E.getColumnNameFromCoords(f,g);c.setComments(p,_$_f495[3])}});h.push({type:_$_f495[407]})}l.allowExport&&h.push({title:C(_$_f495[437]),icon:_$_f495[438],shortcut:m+_$_f495[439],onclick:function(){c.download()}});l.about&&h.push({title:C(_$_f495[440]),icon:_$_f495[441],
357
- onclick:function(){!0===l.about?alert(K().print()):alert(l.about)}});return h};return k}(),fa=function(){var k=function(c){c.showToolbar=function(){k.show.call(c.parent)};c.hideToolbar=function(){k.hide.call(c.parent)};c.refreshToolbar=function(){k.update.call(c.parent,c)}};k[_$_f495[11]]=function(c){this.toolbar.innerHTML=_$_f495[3];this.config.toolbar=k[_$_f495[51]].call(this,c);k.show.call(this)};k[_$_f495[51]]=function(c){c||(c=this.config.toolbar);c?Array.isArray(c)?c={items:c}:typeof c===_$_f495[85]&&
358
- (c=c({items:k.getDefault()})):c={};typeof c!==_$_f495[84]&&(c={});c.items||(c.items=k.getDefault());typeof c.responsive==_$_f495[13]&&(c.responsive=!0,c.bottom=!1,c.maxWidth=this.element.offsetWidth);return c};k.show=function(){this.toolbar.innerHTML||k.build.call(this);this.toolbar.style.display=_$_f495[3];this.element.classList.add(_$_f495[442])};k.hide=function(){this.toolbar.style.display=_$_f495[40];this.element.classList.remove(_$_f495[442])};k.update=function(c,b){if(b=this.toolbarInstance)if(b.update(c),
359
- b.options.responsive){var a=parseInt(c.content.style.maxWidth);if(!a||this.config.fullscreen)a=c.element.offsetWidth;b.options.maxWidth=a;b.refresh()}};k.build=function(){for(var c=k[_$_f495[51]].call(this),b=0;b<c.items.length;b++)if(c.items[b].type==_$_f495[390]){if(!c.items[b].options&&c.items[b].v){c.items[b].options=[];for(var a=0;a<c.items[b].v.length;a++)c.items[b].options.push(c.items[b].v[a]);c.items[b].k&&(c.items[b].onchange=function(d,e,f,g){t.current.setStyle(t.current.getSelected(),
360
- f.k,g)})}}else c.items[b].type==_$_f495[256]?(c.items[b].type=_$_f495[443],c.items[b].onclick=function(d,e,f){f.color||jSuites.color(f,{onchange:function(g,h){t.current.setStyle(t.current.getSelected(),f.k,h)}}).open()}):!c.items[b].onclick&&c.items[b].k&&(c.items[b].onclick=function(){t.current.setStyle(t.current.getSelected(),this.k,this.v)});(b=na.execute.call(this,_$_f495[87],[c]))&&(c=b[0]);this.toolbarInstance=jSuites.toolbar(this.toolbar,c);this.toolbarInstance.application=this;c=this.element.tabs.getActive();
361
- this.toolbarInstance.update(this.worksheets[c])};k.getDefault=function(){return[{content:_$_f495[444],onclick:function(){t.current&&t.current.undo()}},{content:_$_f495[445],onclick:function(){t.current&&t.current.redo()}},{content:_$_f495[438],onclick:function(){t.current&&t.current.download()}},{type:_$_f495[446]},{type:_$_f495[390],width:_$_f495[447],options:[_$_f495[448],_$_f495[449],_$_f495[450]],render:function(c){return _$_f495[451]+c+_$_f495[226]+c+_$_f495[452]},onchange:function(c,b,a,d){t.current&&
362
- t.current.setStyle(t.current.getSelected(),_$_f495[453],d)}},{type:_$_f495[390],width:_$_f495[454],content:_$_f495[455],options:[_$_f495[456],_$_f495[457],_$_f495[458],_$_f495[459],_$_f495[460]],render:function(c){return _$_f495[461]+c+_$_f495[226]+c+_$_f495[452]},onchange:function(c,b,a,d){t.current&&t.current.setStyle(t.current.getSelected(),_$_f495[462],d)}},{type:_$_f495[390],options:[_$_f495[463],_$_f495[464],_$_f495[465],_$_f495[466]],render:function(c){return _$_f495[467]+c+_$_f495[468]},onchange:function(c,
363
- b,a,d){t.current&&t.current.setStyle(t.current.getSelected(),_$_f495[469],d.split(_$_f495[470])[2])}},{type:_$_f495[443],content:_$_f495[471],k:_$_f495[472],v:_$_f495[473]},{type:_$_f495[256],content:_$_f495[474],k:_$_f495[256]},{type:_$_f495[256],content:_$_f495[475],k:_$_f495[476]},{type:_$_f495[390],content:_$_f495[477],width:_$_f495[478],options:[_$_f495[479],_$_f495[480],_$_f495[481],_$_f495[482]],onchange:function(c,b,a,d,e){c=t.current.table;c.classList.remove(_$_f495[483]);c.classList.remove(_$_f495[484]);
364
- c.classList.remove(_$_f495[485]);1==e?c.classList.add(_$_f495[483]):2==e?c.classList.add(_$_f495[484]):3==e&&c.classList.add(_$_f495[485]);t.current.refreshBorders()}},{content:_$_f495[15],onclick:function(c,b,a){a.children[0].innerText==_$_f495[15]?(t.current.fullscreen(!0),a.children[0].innerText=_$_f495[486]):(t.current.fullscreen(!1),a.children[0].innerText=_$_f495[15])},tooltip:_$_f495[487],updateState:function(c,b,a,d){a.children[0].innerText=1==d.parent.config.fullscreen?_$_f495[486]:_$_f495[15]}},
365
- {type:_$_f495[390],data:[_$_f495[488],_$_f495[489],_$_f495[490],_$_f495[491],_$_f495[492],_$_f495[493],_$_f495[494],_$_f495[495],_$_f495[496],_$_f495[497]],columns:5,render:function(c){return _$_f495[467]+c+_$_f495[468]},right:!0,onchange:function(c,b,a,d,e){if(c=t.current.getHighlighted()){a=b.thickness||1;b=b.color||_$_f495[498];e={};for(var f=c[0],g=c[1],h=c[2],l=c[3],m=c[1];m<=c[3];m++)for(var n=c[0];n<=c[2];n++){var p=E.getColumnNameFromCoords(n,m);e[p]||(e[p]=_$_f495[3]);e[p]=d!=_$_f495[493]&&
366
- d!=_$_f495[489]||n!=f?(d==_$_f495[490]||d==_$_f495[492])&&n>f?e[p]+(_$_f495[499]+a+_$_f495[500]+b+_$_f495[296]):d==_$_f495[488]?e[p]+(_$_f495[499]+a+_$_f495[500]+b+_$_f495[296]):e[p]+_$_f495[501]:e[p]+(_$_f495[499]+a+_$_f495[500]+b+_$_f495[296]);e[p]=d!=_$_f495[488]&&d!=_$_f495[495]&&d!=_$_f495[489]||n!=h?e[p]+_$_f495[503]:e[p]+(_$_f495[502]+a+_$_f495[500]+b+_$_f495[296]);e[p]=d!=_$_f495[494]&&d!=_$_f495[489]||m!=g?(d==_$_f495[490]||d==_$_f495[491])&&m>g?e[p]+(_$_f495[504]+a+_$_f495[500]+b+_$_f495[296]):
367
- d==_$_f495[488]?e[p]+(_$_f495[504]+a+_$_f495[500]+b+_$_f495[296]):e[p]+_$_f495[505]:e[p]+(_$_f495[504]+a+_$_f495[500]+b+_$_f495[296]);e[p]=d!=_$_f495[488]&&d!=_$_f495[496]&&d!=_$_f495[489]||m!=l?e[p]+_$_f495[507]:e[p]+(_$_f495[506]+a+_$_f495[500]+b+_$_f495[296])}Object.keys(e)&&t.current.setStyle(e,null,null,!0)}},onload:function(c,b){var a=document.createElement(_$_f495[20]),d=document.createElement(_$_f495[20]);a.appendChild(d);var e=jSuites.color(d,{closeOnChange:!1,onchange:function(f,g){f.parentNode.children[1].style.color=
368
- g;b.color=g}});d=document.createElement(_$_f495[443]);d.classList.add(_$_f495[508]);d.innerHTML=_$_f495[509];d.onclick=function(){e.open()};a.appendChild(d);c.children[1].appendChild(a);d=document.createElement(_$_f495[20]);jSuites.picker(d,{type:_$_f495[390],data:[1,2,3,4,5],render:function(f){return _$_f495[510]+f+_$_f495[511]},onchange:function(f,g,h,l){b.thickness=l},width:_$_f495[512]});c.children[1].appendChild(d);d=document.createElement(_$_f495[20]);d.style.flex=_$_f495[513];c.children[1].appendChild(d)}},
369
- {content:_$_f495[514],onclick:function(c,b,a){a.children[0].innerText==_$_f495[514]?(qa.show.call(t.current),a.children[0].innerText=_$_f495[515]):(qa.hide.call(t.current),a.children[0].innerText=_$_f495[514])},tooltip:_$_f495[516],updateState:function(c,b,a,d){a.children[0].innerText=1==d.options.search?_$_f495[515]:_$_f495[514]}}]};return k}(),ia=function(){var k=function(c){c.createWorksheet=function(b){return c.parent.createWorksheet(b)};c.deleteWorksheet=function(b){return c.parent.deleteWorksheet(b)};
370
- c.renameWorksheet=function(b,a){return c.parent.renameWorksheet(b,a)};c.moveWorksheet=function(b,a){return c.parent.moveWorksheet(b,a)};c.openWorksheet=function(){return c.parent.openWorksheet(c.parent.getWorksheet(c))};c.getWorksheet=function(b){return c.parent.getWorksheet(b)};c.getWorksheetActive=function(){return c.parent.getWorksheetActive()};c.getWorksheetName=function(){return c.options.worksheetName.toUpperCase()}};k.nextName=function(){var c=1,b,a=t.spreadsheet;if(a.length)for(var d=0;d<
371
- a.length;d++){var e=a[d].worksheets;if(e.length)for(var f=0;f<e.length;f++)e[f].options.worksheetName&&(b=e[f].options.worksheetName.match(/(\d+)/))&&(b=parseInt(b[0])+1,b>c&&(c=b))}return c};k.createWorksheet=function(c){if(!Q.call(this))return!1;c||(c={});var b=this.worksheets.length,a=F.call(this,_$_f495[517],c,b);if(typeof a===_$_f495[84])c=a;else if(!1===a)return!1;c.data||c.minDimensions||(c.minDimensions=[8,8]);c.worksheetId||(c.worksheetId=jSuites.guid().substring(0,8));c.worksheetName||(c.worksheetName=
372
- _$_f495[359]+k.nextName());H(c.worksheetName)?jSuites.notification({error:_$_f495[513],message:_$_f495[518]}):(a=oa.worksheet(this,c),a.onload(),L.call(a,_$_f495[519],[c]),F.call(this,_$_f495[520],a,c,b))};k.deleteWorksheet=function(c){var b=this.worksheets[c];if(!Q.call(this,b))return!1;H(b.options.worksheetName,null);this.element.tabs.deleteElement(c);this.worksheets.splice(c,1);L.call(b,_$_f495[521],[c]);F.call(this,_$_f495[522],b,c)};k.renameWorksheet=function(c,b){var a=this.worksheets[c];if(!Q.call(this,
373
- a))return!1;var d=a.options.worksheetName;if(d.toLowerCase()==b.toLowerCase())return!1;b=b.replace(/[^0-9A-Za-z_\s^]+/gi,_$_f495[3]);Number(b)==b&&(b=_$_f495[359]+Number(b));H(b)?alert(_$_f495[523]):(H(d,null),this.element.tabs.rename(c,b),a.options.worksheetName=b,H(b,a),U.call(this,{worksheet:a,action:_$_f495[80],index:c,oldValue:d,newValue:b}),L.call(a,_$_f495[80],{worksheet:c,newValue:b}),Ha.updateWorksheetName.call(a,d,b),V.updateWorksheetNames.call(a,d,b),F.call(this,_$_f495[524],a,c,b,d))};
374
- k.updateWorksheet=function(c,b){var a=this.worksheets;if(!Q.call(this))return!1;this.worksheets.splice(b,0,a.splice(c,1)[0]);U.call(this,{worksheet:a[b],action:_$_f495[81],f:c,t:b});L.call(a[b],_$_f495[81],{f:c,t:b});F.call(this,_$_f495[525],a[b],c,b)};k.moveWorksheet=function(c,b){this.element.tabs.move(c,b)};k.openWorksheet=function(c){var b=this.worksheets[c];!b||t.current&&t.current==b||(this.element.tabs.getActive()!=c?this.element.tabs.open(c):this.element.tabs.setBorder(c),t.current&&t.current.resetSelection(),
375
- t.current=b,t.current.refreshBorders(),T.call(t.current),k.state.call(this,c),fa.update.call(this,t.current),F.call(this,_$_f495[526],b,c))};k.getWorksheet=function(c){if(c&&typeof c==_$_f495[84]){if(c=this.worksheets.indexOf(c),0<=c)return c}else for(var b=0;b<this.worksheets.length;b++)if(c===this.worksheets[b].options.worksheetId)return b;return!1};k.getWorksheetActive=function(){return this.element.tabs.getActive()};k.getWorksheetInstance=function(c){return c===_$_f495[3]||typeof c==_$_f495[17]?
376
- (c=k.getWorksheet.call(this,c),!1===c?!1:this.worksheets[c]):this.worksheets[c]};k.state=function(c){try{if(typeof localStorage!==_$_f495[13]){var b=this.config.cloud?this.config.cloud:this.element.id;if(b)if(typeof c!==_$_f495[13])localStorage.setItem(_$_f495[527]+b,c);else{var a=parseInt(localStorage.getItem(_$_f495[527]+b));k.openWorksheet.call(this,a)}}}catch(d){}};return k}(),E=function(){var k={getCaretIndex:function(c){var b=0,a=(this.config.root?this.config.root:window).getSelection();a&&
377
- 0!==a.rangeCount&&(b=a.getRangeAt(0),a=b.cloneRange(),a.selectNodeContents(c),a.setEnd(b.endContainer,b.endOffset),b=a.toString().length);return b},invert:function(c){for(var b=[],a=Object.keys(c),d=0;d<a.length;d++)b[c[a[d]]]=a[d];return b},getColumnName:function(c){var b=_$_f495[3];701<c?(b+=String.fromCharCode(64+parseInt(c/676)),b+=String.fromCharCode(64+parseInt(c%676/26))):25<c&&(b+=String.fromCharCode(64+parseInt(c/26)));return b+=String.fromCharCode(65+c%26)},getColumnNameFromCoords:function(c,
378
- b){return k.getColumnName(parseInt(c))+(parseInt(b)+1)},getCoordsFromColumnName:function(c){var b=/^[a-zA-Z]+/.exec(c);if(b){for(var a=0,d=0;d<b[0].length;d++)a+=parseInt(b[0].charCodeAt(d)-64)*Math.pow(26,b[0].length-1-d);a--;0>a&&(a=0);c=parseInt(/[0-9]+$/.exec(c))||null;0<c&&c--;return[a,c]}}};k.shiftFormula=V.shiftFormula;k.createFromTable=function(c,b){if(c.tagName!=_$_f495[528])console.log(_$_f495[529]);else{b||(b={});b.columns=[];b.data=[];var a=c.querySelectorAll(_$_f495[530]);if(a.length)for(var d=
379
- 0;d<a.length;d++){var e=a[d].style.width;e||(e=a[d].getAttribute(_$_f495[152]));e&&(b.columns[d]||(b.columns[d]={}),b.columns[d].width=e)}e=function(x){var y=x.getBoundingClientRect();y=50<y.width?y.width:50;b.columns[d]||(b.columns[d]={});x.getAttribute(_$_f495[531])?b.columns[d].type=x.getAttribute(_$_f495[531]):b.columns[d].type=_$_f495[56];b.columns[d].width=y+_$_f495[44];b.columns[d].title=x.innerHTML;b.columns[d].align=x.style.textAlign||(b.defaultColAlign?b.defaultColAlign:_$_f495[53]);x.classList.contains(_$_f495[532])&&
380
- (b.columns[d].readOnly=!0);if(y=x.getAttribute(_$_f495[533]))b.columns[d].name=y;if(y=x.getAttribute(_$_f495[534]))b.columns[d].id=y};var f=[],g=c.querySelectorAll(_$_f495[535]);if(g.length){for(a=0;a<g.length-1;a++){var h=[];for(d=0;d<g[a].children.length;d++){var l={title:g[a].children[d].innerText,colspan:g[a].children[d].getAttribute(_$_f495[52])||1};h.push(l)}f.push(h)}g=g[g.length-1].children;for(d=0;d<g.length;d++)e(g[d])}l=0;var m={},n={},p={},q={},v=null;h=c.querySelectorAll(_$_f495[536]);
381
- for(a=0;a<h.length;a++)if(b.data[l]=[],1!=b.parseTableFirstRowAsHeader||g.length||0!=a){for(d=0;d<h[a].children.length;d++){var u=h[a].children[d].getAttribute(_$_f495[537]);u?u.substr(0,1)!=_$_f495[12]&&(u=_$_f495[12]+u):u=h[a].children[d].innerHTML;b.data[l].push(u);u=E.getColumnNameFromCoords(d,a);(v=h[a].children[d].getAttribute(_$_f495[538]))&&(q[u]=v);v=parseInt(h[a].children[d].getAttribute(_$_f495[52]))||0;var w=parseInt(h[a].children[d].getAttribute(_$_f495[164]))||0;if(v||w)m[u]=[v||1,w||
382
- 1];if(v=h[a].children[d].style&&h[a].children[d].style.display==_$_f495[40])h[a].children[d].style.display=_$_f495[3];(v=h[a].children[d].getAttribute(_$_f495[98]))&&(p[u]=v);h[a].children[d].classList.contains(_$_f495[539])&&(p[u]=p[u]?p[u]+_$_f495[540]:_$_f495[541])}h[a].style&&h[a].style.height&&(n[a]={height:h[a].style.height});l++}else for(d=0;d<h[a].children.length;d++)e(h[a].children[d]);0<Object.keys(f).length&&(b.nestedHeaders=f);0<Object.keys(p).length&&(b.style=p);0<Object.keys(m).length&&
383
- (b.mergeCells=m);0<Object.keys(n).length&&(b.rows=n);0<Object.keys(q).length&&(b.classes=q);h=c.querySelectorAll(_$_f495[542]);if(h.length){c=[];for(a=0;a<h.length;a++){e=[];for(d=0;d<h[a].children.length;d++)e.push(h[a].children[d].innerText);c.push(e)}0<Object.keys(c).length&&(b.footers=c)}if(1==b.parseTableAutoCellType)for(c=[],d=0;d<b.columns.length;d++){f=e=!0;c[d]=[];for(a=0;a<b.data.length;a++)if(u=b.data[a][d],c[d][u]||(c[d][u]=0),c[d][u]++,25<u.length&&(e=!1),10==u.length){if(u.substr(4,
384
- 1)!=_$_f495[185]||u.substr(7,1)!=_$_f495[185])f=!1}else f=!1;a=Object.keys(c[d]).length;f?b.columns[d].type=_$_f495[184]:1==e&&1<a&&a<=parseInt(.1*b.data.length)&&(b.columns[d].type=_$_f495[58],b.columns[d].source=Object.keys(c[d]))}return b}};k.injectArray=function(c,b,a){return c.slice(0,b).concat(a).concat(c.slice(b))};k.parseCSV=function(c,b){b=b||_$_f495[25];for(var a=0,d=0,e=[[]],f=0,g=null,h=!1,l=!1,m=0;m<c.length;m++)if(e[d]||(e[d]=[]),e[d][a]||(e[d][a]=_$_f495[3]),c[m]!=_$_f495[543])if(c[m]!=
385
- _$_f495[544]&&c[m]!=b||0!=h&&1!=l&&g){c[m]==_$_f495[187]&&(h=!h);if(null===g){if(g=h,1==g)continue}else if(!0===g&&!l&&c[m]==_$_f495[187]){c[m+1]==_$_f495[187]?(h=!0,e[d][a]+=c[m],m++):l=!0;continue}e[d][a]+=c[m]}else{g=null;l=h=!1;if(e[d][a][0]==_$_f495[187]){var n=e[d][a].trim();n[n.length-1]==_$_f495[187]&&(e[d][a]=n.substr(1,n.length-2))}c[m]==_$_f495[544]?(a=0,d++):(a++,a>f&&(f=a))}for(c=0;c<e.length;c++)for(m=0;m<=f;m++)void 0===e[c][m]&&(e[c][m]=_$_f495[3]);return e};k.getTokensFromRange=V.getTokensFromRange;
386
- k.getRangeFromTokens=V.getRangeFromTokens;return k}(),Aa=function(){function k(r){return t.current&&t.current.options.tableOverflow&&r.target.tagName==_$_f495[570]&&r.target.hasAttribute(_$_f495[42])}function c(){y.x1=y.x2;y.y1=y.y2;D=null}function b(r,A){A||(A=1);A*=.1;return 0>r?Math.min(0,Math.ceil(r/(1+A))+1):Math.max(0,Math.ceil(r/(1+A))-1)}function a(){0<Math.abs(y.speeds.vertical)&&(y.speeds.vertical=b(y.speeds.vertical,1),t.current.scrollY.scrollTop+=d(y.speeds.vertical),0==t.current.scrollY.scrollTop||
387
- t.current.scrollY.scrollHeight-t.current.scrollY.scrollTop===t.current.scrollY.clientHeight)&&(y.speeds.vertical=0);0<Math.abs(y.speeds.horizontal)&&(y.speeds.horizontal=b(y.speeds.horizontal,1),t.current.scrollX.scrollLeft+=d(y.speeds.horizontal),0==t.current.scrollX.scrollLeft||t.current.scrollX.scrollWidth-t.current.scrollX.scrollLeft===t.current.scrollX.clientWidth)&&(y.speeds.horizontal=0);0>=Math.abs(y.speeds.vertical)&&0>=Math.abs(y.speeds.horizontal)||requestAnimationFrame(a)}function d(r,
388
- A){A||(A=100);return Math.ceil(A/1E3*r)}var e={},f=null,g=null,h=null,l=!1,m=null,n=null,p=null,q=function(r){function A(ja){ja.className&&(ja.classList.contains(_$_f495[349])&&(I=ja),ja.classList.contains(_$_f495[362])&&(J=ja),ja.classList.contains(_$_f495[545])&&(Y=ja));ja.tagName==_$_f495[546]?z=1:ja.tagName==_$_f495[547]?z=2:ja.tagName==_$_f495[548]&&(z=3);ja.parentNode&&!I&&A(ja.parentNode)}var z=null,B=null,I=null,J=null,Y=null,W=null,wa=null,Ra=null;A(r.target);if(null!==Y)return!1;if(I)if(r.target.classList.contains(_$_f495[331]))B=
389
- _$_f495[549];else if(r.target.classList.contains(_$_f495[340]))B=_$_f495[138];else if(r.target.classList.contains(_$_f495[268]))B=_$_f495[411],W=parseInt(r.target.getAttribute(_$_f495[43]));else if(r.target.parentNode&&r.target.parentNode.classList.contains(_$_f495[177]))W=r.target.getAttribute(_$_f495[181]),wa=r.target.getAttribute(_$_f495[182]),null===W?B=_$_f495[549]:(B=_$_f495[408],W=parseInt(W),wa=parseInt(wa));else if(r.target.parentNode&&r.target.parentNode.classList.contains(_$_f495[146]))B=
390
- _$_f495[550];else if(r.target.classList.contains(_$_f495[150]))B=_$_f495[550];else if(r.target.parentNode&&r.target.parentNode.classList.contains(_$_f495[551]))B=_$_f495[403],W=Array.prototype.indexOf.call(r.target.parentNode.children,r.target);else if(1==z)B=_$_f495[410],W=r.target.clientWidth-r.offsetX,r.target.classList.contains(_$_f495[168])&&3<W&&20>W&&(B=_$_f495[552]),W=r.target.getAttribute(_$_f495[42]);else if(2==z){if(r=v(r,I))B=_$_f495[412],W=r[0],wa=r[1],Ra=r[2]}else if(3==z){if(W=r.target.getAttribute(_$_f495[42]),
391
- wa=r.target.getAttribute(_$_f495[43]),W||wa)B=_$_f495[553]}else z||jSuites.findElement(r.target,_$_f495[554])&&(B=_$_f495[87]);return[I,J,z,B,W,wa,Ra]},v=function(r,A){if(r.changedTouches&&r.changedTouches[0]){var z=r.changedTouches[0].clientX;r=r.changedTouches[0].clientY}else z=r.clientX,r=r.clientY;A=(A.spreadsheet.config.root?A.spreadsheet.config.root:document).elementsFromPoint(z,r);for(var B=0;B<A.length;B++)if(z=A[B].getAttribute(_$_f495[42]),r=A[B].getAttribute(_$_f495[43]),null!=z&&null!=
392
- r)return z=parseInt(z),r=parseInt(r),[z,r,A[B]];return!1},u=function(r){var A=q(r);if(!1===A)return!1;A[0]?A[1]?t.current!=A[1].jexcel&&(t.current&&t.current.resetSelection(),t.current=A[1].jexcel):(r=A[0].tabs.getActive(),0<=r&&(t.current=A[0].spreadsheet.worksheets[r])):t.current&&!jSuites.findElement(r.target,_$_f495[219])&&(t.current.resetSelection(!0),t.current=null);return A};e.input=function(r){if(r.target.tagName==_$_f495[555]&&r.target.classList.contains(_$_f495[92])){var A=null;t.current?
393
- A=t.current:r.target.getAttribute(_$_f495[556])&&(A=H(r.target.getAttribute(_$_f495[556])));A&&la.parse.call(A,r.target)}};e.keydown=function(r){if(t.current){r.target.tagName==_$_f495[555]&&r.target.classList.contains(_$_f495[92])&&la.onkeydown.call(t.current,r);if(27==r.which){if(t.current.edition)return t.current.closeEditor(t.current.edition,!1),r.preventDefault(),!1;if(ra.event)return ra.cancel.call(t.current,r),r.preventDefault(),!1;if(ma.event)return ma.cancel.call(t.current,r),!1;if(1==ca.isVisible())return ca.close.call(t.current,
394
- !1),r.preventDefault(),!1}if(!r.target.classList.contains(_$_f495[219]))if(r.target.classList.contains(_$_f495[381])){var A=r.target;m&&clearTimeout(m);m=setTimeout(function(){ca.search.call(t.current,A.value);m=null},500)}else if(r.target.classList.contains(_$_f495[395]))A=r.target,m&&clearTimeout(m),m=setTimeout(function(){t.current.search(A.value);m=null},400);else if(t.current.edition){var z=t.current.edition.getAttribute(_$_f495[42]);13==r.which?t.current.options.columns[z].type==_$_f495[184]?
395
- t.current.closeEditor(t.current.edition,!0):t.current.options.columns[z].type!=_$_f495[58]&&t.current.options.columns[z].type!=_$_f495[557]&&t.current.options.columns[z].type!=_$_f495[434]&&(r.altKey?t.current.parent.input.classList.contains(_$_f495[558])||document.execCommand(_$_f495[559],!1,_$_f495[560]):(t.current.closeEditor(t.current.edition,!0),t.current.down(),r.preventDefault())):9==r.which&&(t.current.closeEditor(t.current.edition,!0),t.current.right(),r.preventDefault())}else if(t.current.selectedCell)if(33==
396
- r.which)0<t.current.options.pagination?ta.pageUp.call(t.current):G.pageUp.call(t.current);else if(34==r.which)0<t.current.options.pagination?ta.pageDown.call(t.current):G.pageDown.call(t.current);else if(37==r.which)t.current.left(r.shiftKey,r.ctrlKey),r.preventDefault();else if(39==r.which)t.current.right(r.shiftKey,r.ctrlKey),r.preventDefault();else if(38==r.which)t.current.up(r.shiftKey,r.ctrlKey),r.preventDefault();else if(40==r.which)t.current.down(r.shiftKey,r.ctrlKey),r.preventDefault();else if(36==
397
- r.which)t.current.first(r.shiftKey,r.ctrlKey),r.preventDefault();else if(35==r.which)t.current.last(r.shiftKey,r.ctrlKey),r.preventDefault();else if(32==r.which)t.current.setCheckRadioValue(),r.preventDefault();else if(46==r.which||8==r.which)t.current.isEditable()&&t.current.setValue(t.current.getSelected(!1,!0),_$_f495[3]);else if(13==r.which)r.shiftKey?t.current.up():(1==t.current.options.allowManualInsertRow&&t.current.selectedCell[1]==(t.current.results?t.current.results[t.current.results.length-
398
- 1]:t.current.rows.length-1)&&t.current.insertRow(),t.current.selectedCell&&t.current.down()),r.preventDefault();else if(9==r.which)r.shiftKey?t.current.left():(z=t.current.selectedCell[0],t.current.right(),1==t.current.options.allowInsertColumn&&1==t.current.options.allowManualInsertColumn&&t.current.selectedCell[0]==z&&(t.current.insertColumn(),t.current.right())),r.preventDefault();else if((r.ctrlKey||r.metaKey)&&!r.shiftKey)65==r.which?(t.current.selectAll(),r.preventDefault()):83==r.which?(t.current.download(),
399
- r.preventDefault()):89==r.which?(t.current.parent.redo(),r.preventDefault()):90==r.which?(t.current.parent.undo(),r.preventDefault()):67==r.which?(t.current.copy(),r.preventDefault()):88==r.which?(t.current.cut(),r.preventDefault()):86==r.which?e.paste(r):189==r.which&&(1==t.current.options.allowDeleteRow&&h==_$_f495[411]?(t.current.deleteRow(),r.preventDefault()):1==t.current.options.allowDeleteColumn&&h==_$_f495[410]&&(t.current.deleteColumn(),r.preventDefault()));else if(t.current.selectedCell&&
400
- t.current.isEditable()){z=t.current.selectedCell[1];var B=t.current.selectedCell[0];t.current.options.columns[B].type!=_$_f495[18]&&(32==r.keyCode?t.current.options.columns[B].type==_$_f495[251]||t.current.options.columns[B].type==_$_f495[253]?r.preventDefault():t.current.openEditor(t.current.records[z][B].element,!0,r):113==r.keyCode?t.current.openEditor(t.current.records[z][B].element,!1,r):1!=r.key.length&&r.key!=_$_f495[561]||r.altKey||r.ctrlKey||t.current.records[z]&&t.current.openEditor(t.current.records[z][B].element,
401
- !0,r))}}};var w=function(r,A,z,B,I,J){if(1==t.current.parent.input.classList.contains(_$_f495[92])&&la.update.call(t.current,r,A,z,B,I))return!1;if(t.current.edition)t.current.closeEditor(t.current.edition,!0);else if(h&&h!==J)return!1;la.current?la.range.call(t.current,r,A,z,B,I):ya[_$_f495[11]].call(t.current,r,A,z,B,I)};e.mousedown=function(r){r=r||window.event;var A=r.buttons?r.buttons:r.button?r.button:r.which;if(t.current)if(1==ca.isVisible()&&(jSuites.findElement(r.target,_$_f495[385])||ca.close.call(t.current,
402
- !1)),t.current.edition){if(jSuites.findElement(r.target,_$_f495[99]))return!1}else if(jSuites.findElement(r.target,_$_f495[219]))return!1;var z=u(r);if(!1===z)return!1;p=z;if(1<A)if(z[3]==_$_f495[410]){if(t.current.isSelected(z[4],null))return!1}else if(z[3]==_$_f495[411]){if(t.current.isSelected(null,z[4]))return!1}else if(z[3]==_$_f495[412]&&t.current.isSelected(z[4],z[5]))return!1;if(t.current){if(z[3]==_$_f495[138])t.current.isEditable()&&(ma.event=!0);else if(z[3]==_$_f495[552])ca.open.call(t.current,
403
- z[4]);else{if(1==z[2])if(1==t.current.options.columnDrag&&6>r.target.offsetHeight-r.offsetY)ra.start.call(t.current,r);else if(1==t.current.options.columnResize&&6>r.target.offsetWidth-r.offsetX)va.start.call(t.current,r);else{A=t.current.options.columns.length-1;var B=t.current.options.data.length-1;if(z[3]==_$_f495[549])w(0,0,A,B,r,z[3]),g=f=0;else if(z[3]==_$_f495[408]){var I=pa.range.call(t.current,z[5])[z[4]];I[1]>A&&(I[1]=A);w(I[0],0,I[1],B,r,z[3]);f=I[0];g=0}else(r.shiftKey||r.ctrlKey)&&null!=
404
- f&&null!=g?w(f,0,z[4],B,r,z[3]):(z[3]==_$_f495[410]&&f==z[4]&&1==t.current.options.allowRenameColumn&&(n=setTimeout(function(){t.current.setHeader(z[4])},800)),w(z[4],0,z[4],B,r,z[3]),f=z[4],g=0)}if(2==z[2])if(z[3]==_$_f495[411])1==t.current.options.rowDrag&&6>r.target.offsetWidth-r.offsetX?ra.start.call(t.current,r):1==t.current.options.rowResize&&6>r.target.offsetHeight-r.offsetY?va.start.call(t.current,r):(A=t.current.options.columns.length-1,B=parseInt(z[4]),(r.shiftKey||r.ctrlKey)&&null!=f&&
405
- null!=g?w(0,g,A,B,r,z[3]):(w(0,B,A,B,r,z[3]),f=0,g=B));else if(z[3]==_$_f495[412]){A=parseInt(z[4]);B=parseInt(z[5]);if(!t.current.edition&&(I=t.current.options.columns[z[4]].type,r.target.tagName==_$_f495[562]&&(I==_$_f495[254]||I==_$_f495[255])&&r.target.parentNode.classList.contains(_$_f495[124]))){var J=r.target.innerText;I==_$_f495[254]&&(J=_$_f495[563]+J);window.open(J,_$_f495[564])}r.shiftKey||r.ctrlKey?w(t.current.selectedCell[0],t.current.selectedCell[1],A,B,r,z[3]):(w(A,B,A,B,r,z[3]),f=
406
- A,g=B)}}h=z[3];typeof z[3]!==_$_f495[13]&&F.call(t.current.parent,_$_f495[565],t.current,z[3],z[4],z[5]);l=!0}else l=!1};e.mouseup=function(r){t.current&&(ra.event?ra.end.call(t.current,r):va.event?va.end.call(t.current,r):ma.event?ma.end.call(t.current,r):r.target.classList.contains(_$_f495[384])?ca.close.call(t.current,!0):t.current.edition&&r.target.classList.contains(_$_f495[566])&&50>r.target.clientWidth-r.offsetX&&50>r.offsetY?da.close.call(t.current,null,!0):r.target.classList.contains(_$_f495[319])&&
407
- (r=r.target.innerText==_$_f495[215]?0:r.target.innerText==_$_f495[216]?r.target.getAttribute(_$_f495[265])-1:r.target.innerText-1,ta[_$_f495[11]].call(t.current,parseInt(r))));n&&(clearTimeout(n),n=null);l=h=!1;la.current&&la.close.call(t.current)};e.mousemove=function(r){r=r||window.event;if(t.current){var A=r.target.getAttribute(_$_f495[42]),z=r.target.getAttribute(_$_f495[43]);if(1==l)ra.event?ra.update.call(t.current,r):va.event?va.update.call(t.current,r):Oa.event&&Oa.update.call(t.current,r);
408
- else{var B=r.target.getBoundingClientRect();t.current.cursor&&(t.current.cursor.style.cursor=_$_f495[3],t.current.cursor=null);1==t.current.options.editable&&(A||z)&&(1==t.current.options.rowResize&&r.target&&A&&!z&&5>B.width-(r.clientX-B.left)?(t.current.cursor=r.target,t.current.cursor.style.cursor=_$_f495[567]):1==t.current.options.columnResize&&r.target&&!A&&z&&5>B.height-(r.clientY-B.top)?(t.current.cursor=r.target,t.current.cursor.style.cursor=_$_f495[568]):1==t.current.options.rowDrag&&r.target&&
409
- !A&&z&&5>B.width-(r.clientX-B.left)?(t.current.cursor=r.target,t.current.cursor.style.cursor=_$_f495[569]):1==t.current.options.columnDrag&&r.target&&A&&!z&&5>B.height-(r.clientY-B.top)&&(t.current.cursor=r.target,t.current.cursor.style.cursor=_$_f495[569]))}}};e.mouseover=function(r){r=r||window.event;var A=!1;if(t.current&&1==l){var z=q(r);if(z[0]){if(z[1]&&t.current!=z[1].jexcel&&t.current)return!1;if(!ra.event&&!va.event)if(ma.event){var B=r.target.getAttribute(_$_f495[42]),I=r.target.getAttribute(_$_f495[43]);
410
- t.current.isSelected(B,I)||null===B||null===I||(ma.call(t.current,B,I),A=!0)}else null!==f&&null!==g&&(1==z[2]&&(B=f,z[3]==_$_f495[410]&&(B=r.target.getAttribute(_$_f495[42])),I=t.current.options.data.length-1,w(f,0,B,I,r,z[3])),2==z[2]&&(z[3]==_$_f495[411]?(B=t.current.options.columns.length-1,I=parseInt(r.target.getAttribute(_$_f495[43])),w(0,g,B,I,r,z[3])):z[3]==_$_f495[412]&&(B=r.target.getAttribute(_$_f495[42]),I=r.target.getAttribute(_$_f495[43]),B&&I&&(w(f,g,B,I,r,z[3]),A=!0))))}}1==A&&!n&&
411
- G.limited.call(t.current)?n=setTimeout(function(){var J=t.current.content.getBoundingClientRect();if(r.changedTouches&&r.changedTouches[0])var Y=r.changedTouches[0].clientX,W=r.changedTouches[0].clientY;else Y=r.clientX,W=r.clientY;50>J.height-(W-J.top)?G.pageDown.call(t.current,1,null,r):80>W-J.top&&G.pageUp.call(t.current,1,null,r);50>J.width-(Y-J.left)?G.pageRight.call(t.current,1,null,r):80>Y-J.left&&G.pageLeft.call(t.current,1,null,r);n=null},100):n&&(clearTimeout(n),n=null)};e.dblclick=function(r){if(t.current)if(r.target.classList.contains(_$_f495[340]))ma.execute.call(t.current,
412
- !1);else{var A=q(r);1==A[2]?1==t.current.options.columnSorting&&(r=r.target.getAttribute(_$_f495[42]))&&t.current.orderBy(r):2==A[2]&&t.current.isEditable()&&!t.current.edition&&A[6]&&t.current.openEditor(A[6])}};e.paste=function(r){if(t.current&&t.current.selectedCell&&!t.current.edition){var A=r.clipboardData||window.clipboardData;A&&(t.current.paste(t.current.selectedCell[0],t.current.selectedCell[1],A.getData(_$_f495[56])),r&&r.preventDefault())}};e.contextmenu=function(r){var A=u(r);!1!==A&&
413
- (A[1]||(A=p),t.current&&!t.current.edition&&(A=Array.prototype.slice.call(A,3),Qa.open.call(t.current,r,A)))};var x=Date.now(),y={},D=null,R=null,O=null;e.touchstart=function(r){var A=q(r);A[0]?A[1]&&t.current!=A[1].jexcel&&(t.current&&t.current.resetSelection(),t.current=A[1].jexcel):t.current&&(t.current.resetSelection(),t.current=null);if(t.current&&!t.current.edition){var z=A[4];A=A[5];k(r)&&(O=r.touches[0],R=r.touches.length,x=Date.now(),y.x1=r.touches[0].screenX,y.y1=r.touches[0].screenY,y.x2=
414
- r.touches[0].screenX,y.y2=r.touches[0].screenY,D=setTimeout(c,250),null!=y.speeds&&(y.speeds.vertical=0,y.speeds.horizontal=0));if(null!==z&&null!==A){t.current.updateSelectionFromCoords(z,A,z,A);var B=r.target;n=setTimeout(function(){t.current.openEditor(B,!1,r);n=null},300)}}};e.touchmove=function(r){n&&(clearTimeout(n),n=null);if(k(r)&&1==R){var A=r.changedTouches[0];O&&(t.current.scrollY.scrollTop+=-1*(A.clientY-O.clientY),t.current.scrollX.scrollLeft+=-1*(A.clientX-O.clientX));O=A;y.x2=r.touches[0].screenX;
415
- y.y2=r.touches[0].screenY;null!=y.speeds&&(y.speeds.vertical=0,y.speeds.horizontal=0);null==D&&(D=setTimeout(c,250));r.cancelable&&t.current.options.tableOverflow&&r.preventDefault()}};e.touchend=function(r){n&&(clearTimeout(n),n=null);D&&(clearTimeout(D),D=null);O=R=null;if(k(r)){r=Date.now()-x;var A=y.x1,z=y.y1,B=y.x2,I=y.y2,J=A==A&&z==I?0:Math.sqrt(Math.pow(A-A,2)+Math.pow(z-I,2));I>z&&(J=-J);10>Math.abs(I-z)&&(J=0);I=0>=r?-1:Math.ceil(J/(r/1E3));z=A==B&&z==z?0:Math.sqrt(Math.pow(A-B,2)+Math.pow(z-
416
- z,2));B>A&&(z=-z);10>Math.abs(B-A)&&(z=0);y.speeds={vertical:I,horizontal:0>=r?-1:Math.ceil(z/(r/1E3))};(250>r&&200<Math.abs(y.speeds.vertical)||250>r&&200<Math.abs(y.speeds.horizontal))&&requestAnimationFrame(a)}};e.resize=function(){t.current&&1==t.current.parent.config.fullscreen&&G.refresh.call(t.current)};return e}(),t=function(k,c,b){c||(c={});if(c.cloud&&!b)typeof c.plugins.cloud==_$_f495[85]?c.plugins.cloud.load(c,function(f){t(k,f,!0)}):console.error(_$_f495[571]);else{if(k.spreadsheet)a=
417
- k.spreadsheet,Ca[_$_f495[11]].call(a,c);else var a=oa.spreadsheet(k,c);a.processing=!0;1==a.config.loadingSpin&&jSuites.loading.show();jSuites.ajax.oncomplete[a.name]=function(){for(var f=0;f<a.worksheets.length;f++)a.worksheets[f].onload();a.processing=!1;if(Array.isArray(a.queue)&&0<a.queue.length)for(;f=a.queue.shift();)f[0].updateCell(f[1],f[2],N.call(f[0],f[1],f[2]),!0);a.config.toolbar&&fa.show.call(a);for(f=0;f<a.worksheets.length;f++)aa.refresh.call(a.worksheets[f]);if(typeof a.config.onload==
418
- _$_f495[85])a.config.onload(a);ia.state.call(a);jSuites.loading.hide()};Array.isArray(c.worksheets)&&(c=c.worksheets);if(Array.isArray(c)){b=null;for(var d=[],e=0;e<c.length;e++)b=oa.worksheet(a,c[e]),d.push(b)}else d=oa.worksheet(a,c);jSuites.ajax.pending(a.name)||(jSuites.ajax.oncomplete[a.name](),jSuites.ajax.oncomplete[a.name]=null);return d}};t.license=null;t.setLicense=function(k){t.license=k};t.spreadsheet=[];t.picker=la;t.setDictionary=function(k){jSuites.setDictionary(k)};t.extensions={};
419
- t.setExtensions=function(k){for(var c=Object.keys(k),b=0;b<c.length;b++)typeof k[c[b]]===_$_f495[85]&&(t[c[b]]=k[c[b]],t.extensions[c[b]]=k[c[b]],t.license&&typeof t[c[b]].license==_$_f495[85]&&t[c[b]].license.call(t,t.license))};t.destroy=function(k,c){k.spreadsheet&&(c&&oa.unbind(k),c=t.spreadsheet.indexOf(k.spreadsheet),t.spreadsheet.splice(c,1),k.spreadsheet=null,k.jexcel=null,k.innerHTML=_$_f495[3],k.classList.remove(_$_f495[572]),k.classList.remove(_$_f495[349]))};t.version=K;t.helpers=E;t.events=
420
- Aa;typeof formula!==_$_f495[13]&&(t.formula=formula);t.editors=function(){var k={},c=function(b,a){return 1==b[a]||b.options&&1==b.options[a]?!0:b[a]==_$_f495[229]||b.options&&b.options[a]==_$_f495[229]?!0:!1};k.createEditor=function(b,a,d,e){e.parent.input.setAttribute(_$_f495[100],!1);b==_$_f495[220]?(b=document.createElement(_$_f495[220]),b.type=_$_f495[56],b.value=d):b=document.createElement(_$_f495[20]);b.style.width=a.offsetWidth-2+_$_f495[44];b.style.height=a.offsetHeight-1+_$_f495[44];e.parent.input.appendChild(b);
421
- return b};k.createDialog=function(b,a,d,e,f,g){b=k.createEditor(_$_f495[20],b,a,f);b.classList.add(_$_f495[573]);b.classList.add(_$_f495[566]);800>window.innerWidth?(f.parent.input.style.top=_$_f495[144],f.parent.input.style.left=_$_f495[144]):(a=f.parent.input.getBoundingClientRect(),window.innerHeight<a.bottom&&(f.parent.input.style.marginTop=-f.parent.input.offsetHeight));return b};k.general=function(){var b={},a=function(e){e=(_$_f495[3]+e)[0];return e==_$_f495[12]||e==_$_f495[574]?!0:!1},d=function(e){if(e.format||
422
- e.mask||e.locale){var f={};e.mask?f.mask=e.mask:e.format?f.mask=e.format:(f.locale=e.locale,f.options=e.options);e.decimal&&(f.options||(f.options={}),f.options={decimal:e.decimal});return f}return null};b.updateCell=function(e,f,g,h,l,m){g=parseInt(g);h=parseInt(h);if(e){var n=d(m),p=null;f===_$_f495[3]||a(f)||typeof f===_$_f495[14]||(n?(n=jSuites.mask.extract(f,n,!0))&&n.value!==_$_f495[3]&&(p=n.value):1==(!1===l.parent.config.autoCasting||!1===m.autoCasting?!1:!0)&&(m.type==_$_f495[14]||m.type==
423
- _$_f495[308]||m.type==_$_f495[307]?(n=jSuites.mask.extract(f,m,!0))&&n.value!==_$_f495[3]&&(p=n.value):jSuites.isNumeric(Number(f))&&(p=Number(f))));null!==p&&(f=p);f=b.parseValue(g,h,f,l,m,e);f instanceof Element||f instanceof HTMLDocument?(e.innerHTML=_$_f495[3],e.appendChild(f)):1==l.parent.config.stripHTML?e.innerText=f:e.innerHTML=f;if(null!==p)return p}};b.createCell=b.updateCell;b.openEditor=function(e,f,g,h,l,m){var n=l.parent.input;n.onblur=function(){n.classList.contains(_$_f495[92])||l.closeEditor(e,
424
- !0)};if(m.type==_$_f495[14]||m.type==_$_f495[308]||m.type==_$_f495[307])n.classList.add(_$_f495[558]),a(f)||m.inputmode||(m.inputmode=_$_f495[575]);g=null;a(f)||(m.inputmode&&n.setAttribute(_$_f495[96],m.inputmode),(g=d(m))?(m.disabledMaskOnEdition||(m.mask?(m=m.mask.split(_$_f495[264]),n.setAttribute(_$_f495[94],m[0])):m.locale&&n.setAttribute(_$_f495[576],m.locale)),g.input=l.parent.input,l.parent.input.mask=g,jSuites.mask.render(f,g,!1)):f&&m.type==_$_f495[307]&&(f*=100));g||(n.innerText=f,jSuites.focus(l.parent.input))};
425
- b.closeEditor=function(e,f,g,h,l,m){e=l.parent.input;f=f?e.innerText:_$_f495[3];a(f)?f=f.replace(/(\r\n|\n|\r)/gm,_$_f495[3]):m.type==_$_f495[307]&&(f+=_$_f495[577],e.classList.remove(_$_f495[578]));return f};b.parseValue=function(e,f,g,h,l,m){a(g)&&1==h.parent.config.parseFormulas&&(g=h.executeFormula(g,e,f));g instanceof Element||g instanceof HTMLDocument||!l||a(g)||!(f=d(l))||(e=jSuites.mask.render(g,f,!0),m&&f.mask&&(f=f.mask.split(_$_f495[264]),f[1]&&(f[1].match(new RegExp(_$_f495[579],_$_f495[377]))&&
426
- (0>g?m.classList.add(_$_f495[580]):m.classList.remove(_$_f495[580])),f[1].match(new RegExp(_$_f495[581],_$_f495[377]))&&0>g&&(e=_$_f495[212]+e+_$_f495[232]))),e&&(g=e));return g};b[_$_f495[51]]=function(e,f){var g;return(g=d(e))?jSuites.mask.render(f,g,!0):e.type==_$_f495[307]?100*parseFloat(f):f};return b}();k.text=k.general;k.number=k.general;k.numeric=k.general;k.percent=k.general;k.notes=function(){var b={},a=null;b.updateCell=function(d,e,f,g,h,l){d&&(f=document.createElement(_$_f495[20]),f.classList.add(_$_f495[582]),
427
- 1==h.parent.config.stripHTML?f.innerText=e:f.innerHTML=e,d.innerHTML=_$_f495[3],d.appendChild(f))};b.createCell=b.updateCell;b.openEditor=function(d,e,f,g,h,l){var m=l&&l.options?l.options:{};m.focus=!0;m.value=e;m.border=!1;m.height=_$_f495[583];m.toolbar=!1;a=k.createDialog(d,e,f,g,h,l);a=jSuites.editor(a,m)};b.closeEditor=function(d,e,f,g,h,l){return e?a.getData():_$_f495[3]};return b}();k.dropdown=function(){var b={createCell:function(a,d,e,f,g,h){h.render==_$_f495[584]?a.classList.add(_$_f495[585]):
428
- a.classList.add(_$_f495[586]);if(a=b.updateCell(a,d,e,f,g,h))return a},destroyCell:function(a){a.classList.remove(_$_f495[586])},updateCell:function(a,d,e,f,g,h){if(a){var l=b.getItem(a,d,e,f,g,h);l?a.innerHTML=l:d?(d=b.fromLabel(a,d,e,f,g,h),d.length?(l=b.getItem(a,d,e,f,g,h),a.innerHTML=l):a.innerHTML=_$_f495[3]):a.innerHTML=_$_f495[3];return d}},openEditor:function(a,d,e,f,g,h){var l=k.createEditor(_$_f495[20],a,d,g),m=h.delimiter||_$_f495[264];h=Object.create(h);h.options||(h.options={});typeof h.filter==
429
- _$_f495[85]&&(h.source=h.filter(g.el,a,e,f,h.source));typeof h.filterOptions==_$_f495[85]&&(h=h.filterOptions(g,a,e,f,d,h));e=h.options;h.source&&(e.data=JSON.parse(JSON.stringify(h.source)));c(h,_$_f495[587])&&(e.multiple=!0);c(h,_$_f495[57])&&(e.autocomplete=!0);e.format=!0;e.opened=!0;e.width=a.offsetWidth-2;e.onclose=function(){g.closeEditor(a,!0)};c(h,_$_f495[587])?d&&(e.value=(_$_f495[3]+d).split(m)):e.value=d;jSuites.dropdown(l,e)},closeEditor:function(a,d,e,f,g,h){for(var l=g.parent.input.children[0],
430
- m=h.delimiter||_$_f495[264],n=l.dropdown.getText(!0),p=l.dropdown.getValue(!0),q=0;q<p.length;q++)!1===b.getItem(a,p[q],e,f,g,h)&&h.source.push({id:p[q],name:n[q]});l.dropdown.close(!0);if(d)return p.join(m)},fromLabel:function(a,d,e,f,g,h){a=h.delimiter||_$_f495[264];e=[];f=[];Array.isArray(d)||(d=(_$_f495[3]+d).split(a));for(g=0;g<d.length;g++)f[d[g].trim()]=!0;d=Object.keys(f);!c(h,_$_f495[587])&&1<Object.keys(d).length&&(f=[],f[d[0]]=!0);for(d=0;d<h.source.length;d++)f[h.source[d].name]&&e.push(h.source[d].id);
431
- return e.join(a)},getItem:function(a,d,e,f,g,h){f=h.delimiter||_$_f495[264];a=[];e=[];Array.isArray(d)||(d=(_$_f495[3]+d).split(f));for(f=0;f<d.length;f++)e[d[f].trim()]=!0;f=Object.keys(e);!c(h,_$_f495[587])&&1<Object.keys(f).length&&(d=[],d[f[0]]=!0,e=d);if(h.source&&typeof h.source[0]!==_$_f495[84])for(d=0;d<h.source.length;d++)f=h.source[d],h.source[d]={id:f,name:f};for(d=0;d<h.source.length;d++)typeof e[h.source[d].id]!==_$_f495[13]&&a.push(h.render==_$_f495[256]?h.source[d].color:h.render==
432
- _$_f495[588]?h.source[d].image:h.source[d].name);if(a.length){if(typeof h.render!==_$_f495[13]){for(d=0;d<a.length;d++)e=d,f=a[d],f=h.render==_$_f495[256]?_$_f495[589]+f+_$_f495[590]:h.render==_$_f495[588]?_$_f495[589]+f+_$_f495[590]:h.render==_$_f495[584]?_$_f495[592]+(h.source[d].color||_$_f495[591])+_$_f495[593]+f+_$_f495[594]:void 0,a[e]=f;return a.join(_$_f495[3])}for(d=0;d<a.length;d++)a[d]=(_$_f495[3]+a[d]).replace(_$_f495[215],_$_f495[595]);return a.join(_$_f495[296])}return!1}};b[_$_f495[51]]=
433
- function(a,d){for(var e=0;e<a.source.length;e++)if(a.source[e].id==d)return a.render==_$_f495[256]?a.source[e].color:a.render==_$_f495[588]?a.source[e].image:a.source[e].name};return b}();k.autocomplete=k.dropdown;k.calendar=function(){var b={},a=null;b.updateCell=function(d,e,f,g,h,l){if(d){f=e;l=b.getFormat(l);0<e&&Number(e)==e&&(f=jSuites.calendar.numToDate(e));g=_$_f495[3]+e;g.substr(4,1)==_$_f495[185]&&g.substr(7,1)==_$_f495[185]?g=!0:(g=g.split(_$_f495[185]),g=4==g[0].length&&g[0]==Number(g[0])&&
434
- 2==g[1].length&&g[1]==Number(g[1])?!0:!1);g||(g=jSuites.calendar.extractDateFromString(e,l))&&(f=g);if(f=jSuites.calendar.getDateString(f,l))return d.innerText=f,e;d.innerText=_$_f495[3];return _$_f495[3]}};b.createCell=b.updateCell;b.openEditor=function(d,e,f,g,h,l){l=Object.create(l);typeof l.filterOptions==_$_f495[85]&&(l=l.filterOptions(h,d,f,g,e,l));f=l.options||{};f.opened=!0;f.onclose=function(m,n){h.closeEditor(d,!0)};typeof l.timepicker!==_$_f495[13]&&(f.time=c(l,_$_f495[596])?!0:!1);typeof f.readonly!==
435
- _$_f495[13]&&(f.readonly=f.readonly);f.value=e||null;f.placeholder=f.format;a=k.createEditor(_$_f495[220],d,e,h);jSuites.calendar(a,f);!1===a.calendar.options.readonly&&a.focus()};b.closeEditor=function(d,e,f,g,h){d=a.calendar.close(!0,a.value?!0:!1);d=a.value?d:_$_f495[3];if(e)return d};b.getFormat=function(d){return d&&d.format?d.format:d&&d.options&&d.options.format?d.options.format:_$_f495[597]};b[_$_f495[51]]=function(d,e){d=b.getFormat(d);return jSuites.calendar.getDateString(e,d)};return b}();
436
- k.color=function(){var b={},a=null;b.updateCell=function(d,e,f,g,h,l){d&&(l.render==_$_f495[598]?(f=document.createElement(_$_f495[20]),f.className=_$_f495[256],f.style.backgroundColor=e,d.innerText=_$_f495[3],d.appendChild(f)):(d.style.color=e,d.innerText=e))};b.createCell=b.updateCell;b.openEditor=function(d,e,f,g,h,l){l=Object.create(l);typeof l.filterOptions==_$_f495[85]&&(l=l.filterOptions(h,d,f,g,e,l));l.value=e;l.onclose=function(m,n){h.closeEditor(d,!0)};a=k.createEditor(_$_f495[220],d,e,
437
- h);a=jSuites.color(a,l);a.open()};b.closeEditor=function(d,e,f,g,h,l){d=a.close(!0);if(e)return d};b[_$_f495[51]]=function(d,e){d=document.createElement(_$_f495[20]);d.style.width=_$_f495[599];d.style.height=_$_f495[22];d.style.backgroundColor=e;return d.outerHTML};return b}();k.checkbox=function(){var b={createCell:function(a,d,e,f,g,h){d=d&&d!=_$_f495[600]&&d!=_$_f495[601]?!0:!1;e=document.createElement(_$_f495[220]);e.type=_$_f495[251];e.checked=d;e.onclick=function(){g.setValue(a,this.checked)};
438
- (h&&1==h.readOnly||!g.isEditable())&&e.setAttribute(_$_f495[602],_$_f495[602]);a.innerHTML=_$_f495[3];a.appendChild(e);return d},updateCell:function(a,d){d=d&&d!=_$_f495[600]&&d!=_$_f495[601]?!0:!1;a&&(a.children[0].checked=d);return d},openEditor:function(a,d,e,f,g){d=a.children[0].checked?!1:!0;g.setValue(a,d);return!1},closeEditor:function(a,d){return!1}};b[_$_f495[51]]=function(a,d){return 1==d||1==d||d==_$_f495[229]?jSuites.translate(_$_f495[229]):jSuites.translate(_$_f495[600])};return b}();
439
- k.radio=function(){var b={createCell:function(a,d,e,f,g,h){a.getAttribute(_$_f495[42]);e=document.createElement(_$_f495[220]);e.type=_$_f495[253];e.checked=1==d||1==d||d==_$_f495[229]?!0:!1;e.onclick=function(){g.setValue(a,!0)};(h&&1==h.readOnly||!g.isEditable())&&e.setAttribute(_$_f495[602],_$_f495[602]);a.innerHTML=_$_f495[3];a.appendChild(e)},updateCell:function(a,d,e,f,g){d=1==d||1==d||d==_$_f495[229]||d==_$_f495[603]?!0:!1;a&&(a.children[0].checked=d);if(1==d){a=[];for(var h=0;h<g.options.data.length;h++)f!=
440
- h&&g.options.data[h][e]&&a.push({x:e,y:h,value:0});a.length&&g.setValue(a)}return d},openEditor:function(a,d,e,f,g){return!1},closeEditor:function(a,d){return!1}};b[_$_f495[51]]=function(a,d){return 1==d||1==d||d==_$_f495[229]?_$_f495[229]:_$_f495[600]};return b}();k.autonumber=function(){var b={},a=null;b.createCell=function(d,e,f,g,h,l){(e=parseInt(e))||0<parseInt(d.innerText)&&(e=parseInt(d.innerText));l.sequence||(l.sequence=0);e?b.isValid(e,f,g,h)||(e=_$_f495[244]):e=l.sequence+1;e>l.sequence&&
441
- (l.sequence=e);return d.innerText=e};b.updateCell=b.createCell;b.openEditor=function(d,e,f,g,h,l){a=k.createEditor(_$_f495[220],d,e,h);a.onblur=function(){h.closeEditor(d,!0)};a.focus();a.value=e};b.closeEditor=function(d,e,f,g,h){return e?a.value:_$_f495[3]};b.isValid=function(d,e,f,g){for(var h,l=0;l<g.options.data.length;l++)if(h=g.value(e,l),h==d&&l!=f)return!1;return!0};return b}();k.progressbar=function(){var b={},a=null;b.createCell=function(d,e){e=parseInt(e);if(100<e)e=100;else if(!e||0>
442
- e)e=0;if(d.children[0]&&d.children[0].tagName==_$_f495[555])var f=d.children[0];else f=document.createElement(_$_f495[20]),f.classList.add(_$_f495[257]),d.innerText=_$_f495[3],d.classList.add(_$_f495[604]),d.appendChild(f);f.style.width=parseInt(e)+_$_f495[577];f.setAttribute(_$_f495[265],parseInt(e)+_$_f495[577])};b.destroyCell=function(d){d.classList.remove(_$_f495[604])};b.updateCell=b.createCell;b.openEditor=function(d,e,f,g,h,l){a=k.createEditor(_$_f495[220],d,e,h);a.type=_$_f495[14];a.setAttribute(_$_f495[605],
443
- 0);a.setAttribute(_$_f495[606],100);a.onblur=function(){h.closeEditor(d,!0)};a.focus();a.value=e};b.closeEditor=function(d,e,f,g,h){return e?a.value:_$_f495[3]};return b}();k.rating=function(){var b={},a=null;b.createCell=function(d,e,f,g,h,l){return b.setCell(d,e,l)};b.destroyCell=function(d){d.classList.remove(_$_f495[607])};b.updateCell=b.createCell;b.openEditor=function(d,e,f,g,h,l){a=k.createEditor(_$_f495[220],d,e,h);a.type=_$_f495[14];a.setAttribute(_$_f495[605],0);a.setAttribute(_$_f495[606],
444
- 5);a.onblur=function(){h.closeEditor(d,!0)};a.focus();a.value=e};b.closeEditor=function(d,e,f,g,h,l){return e?a.value:_$_f495[3]};b.setCell=function(d,e,f){e=parseInt(e);if(5<e)e=5;else if(!e||0>e)e=0;if(d){f=f&&f.color?f.color:_$_f495[580];var g=document.createElement(_$_f495[20]);g.setAttribute(_$_f495[265],parseInt(e)+_$_f495[608]);g.classList.add(_$_f495[258]);for(var h=0;h<e;h++){var l=document.createElement(_$_f495[443]);l.className=_$_f495[508];l.style.color=f;l.innerHTML=_$_f495[609];g.appendChild(l)}d.innerHTML=
445
- _$_f495[3];d.className=_$_f495[607];d.appendChild(g)}return e};return b}();k.email=function(){var b={createCell:function(a,d,e,f,g,h){a&&(a.children&&a.children[0]&&a.children[0].tagName==_$_f495[562]?e=a.children[0]:(e=document.createElement(_$_f495[201]),a.innerText=_$_f495[3],a.appendChild(e),h.options&&h.options.url&&e.setAttribute(_$_f495[610],h.options.url)),e.innerText=d)}};b.updateCell=b.createCell;b.openEditor=function(a,d,e,f,g,h){g.parent.input.classList.add(_$_f495[558]);g.parent.input.onblur=
446
- function(){g.closeEditor(a,!0)};g.parent.input.innerText=d;jSuites.focus(g.parent.input)};b.closeEditor=function(a,d,e,f,g){g.parent.input.classList.remove(_$_f495[558]);return d?g.parent.input.innerText.replace(new RegExp(/\n/,_$_f495[188]),_$_f495[3]):_$_f495[3]};return b}();k.url=k.email;k.image=function(){var b={},a=null;b.createCell=function(d,e,f,g,h,l){if(d)if(e)if(d.children&&d.children[0]&&d.children[0].tagName==_$_f495[611])d.children[0].src=e;else{var m=document.createElement(_$_f495[37]);
447
- l.render==_$_f495[612]&&m.classList.add(_$_f495[612]);l.options&&(m.style.maxWidth=_$_f495[613],l.options.absolute&&(m.setAttribute(_$_f495[614],-1),m.classList.add(_$_f495[615]),m.classList.add(_$_f495[219]),m.classList.add(_$_f495[616]),m.settings=function(){h.openEditor(d,e,f,g,h,l)},m.refresh=function(){}),l.options.width&&(m.style.width=parseInt(l.options.width)+_$_f495[44]),l.options.height&&(m.style.height=parseInt(l.options.height)+_$_f495[44]));m.src=e;d.innerHTML=_$_f495[3];d.appendChild(m)}else d.innerHTML=
448
- _$_f495[3]};b.updateCell=b.createCell;b.openEditor=function(d,e,f,g,h,l){(l&&l.options?l.options:{}).value=e;a=k.createDialog(d,e,f,g,h,l);e&&(d=document.createElement(_$_f495[37]),d.src=e,d.classList.add(_$_f495[617]),d.style.width=_$_f495[613],a.appendChild(d));jSuites.image(a,l)};b.closeEditor=function(d,e,f,g,h,l){if(e&&(d=a.children[0]))return d.tagName==_$_f495[611]?d.src:_$_f495[3]};b[_$_f495[51]]=function(d,e){return _$_f495[618]+e+_$_f495[619]};return b}();k.html=function(){var b={},a=null;
449
- b.createCell=function(d,e){d.classList.add(_$_f495[620]);var f=document.createElement(_$_f495[20]);f.innerHTML=e;d.appendChild(f)};b.updateCell=function(d,e){d&&(d.firstChild.innerHTML=e)};b.destroyCell=function(d){d.classList.remove(_$_f495[620])};b.openEditor=function(d,e,f,g,h,l){var m=l&&l.options?l.options:{};m.focus=!0;m.value=e;m.border=!1;m.height=_$_f495[583];e=k.createDialog(d,e,f,g,h,l);a=jSuites.editor(e,m);a.close=function(){h.closeEditor(d,!0)};jSuites.tracking(a,!0)};b.closeEditor=
450
- function(d,e,f,g,h,l){jSuites.tracking(a,!1);d=a.getData();if(e)return d};return b}();k.hidden=function(){return{createCell:function(b,a,d,e,f){b.style.display=_$_f495[40];b.innerText=a},updateCell:function(b,a,d,e,f){b&&(b.innerText=a)},openEditor:function(b,a,d,e,f){return!1},closeEditor:function(b,a){return!1}}}();k.tags=function(){var b={},a=null;b.createCell=function(d,e){d.classList.add(_$_f495[621]);b.updateCell(d,e)};b.updateCell=function(d,e){d&&(d.innerHTML=e)};b.destroyCell=function(d){d.classList.remove(_$_f495[621])};
451
- b.openEditor=function(d,e,f,g,h,l){var m=l&&l.options?l.options:{};m.value=e;a=k.createDialog(d,e,f,g,h,l);d=document.createElement(_$_f495[20]);d.style.margin=_$_f495[22];d.style.marginRight=_$_f495[622];a.appendChild(d);a=jSuites.tags(d,m);d.focus();jSuites.focus(d)};b.closeEditor=function(d,e,f,g,h,l){d=a.getValue();if(e)return d};return b}();k.record=function(){var b={},a=null;b.createCell=function(d,e,f,g,h,l){d.classList.add(_$_f495[586]);var m;(m=h.parent.getWorksheetInstance(l.worksheetId))?
452
- m.rows?b.updateCell(d,e,f,g,h,l):(d.innerText=_$_f495[244],h.parent.queue.push([h,f,g])):(d.innerText=_$_f495[244],h.parent.queue.push([h,f,g]))};b.destroyCell=function(d){d.classList.remove(_$_f495[586])};b.updateCell=function(d,e,f,g,h,l){d&&(typeof l.worksheetId==_$_f495[13]?d.innerText=_$_f495[244]:d.innerHTML=b.getValue(d,e,f,g,h,l))};b.openEditor=function(d,e,f,g,h,l){var m=l.delimiter||_$_f495[264];l=Object.create(l);l.options||(l.options={});typeof l.filter==_$_f495[85]&&(l.source=l.filter(h.el,
453
- d,f,g,l.source));typeof l.filterOptions==_$_f495[85]&&(l=l.filterOptions(h,d,f,g,e,l));f=l.options;f.data=b.getSource(h,l);c(l,_$_f495[587])&&(f.multiple=!0);c(l,_$_f495[57])&&(f.autocomplete=!0);f.opened=!0;f.width=d.offsetWidth-2;f.onclose=function(){h.closeEditor(d,!0)};c(l,_$_f495[587])?e&&(f.value=(_$_f495[3]+e).split(m)):f.value=e;a=k.createEditor(_$_f495[20],d,e,h);a=jSuites.dropdown(a,f)};b.closeEditor=function(d,e,f,g,h,l){d=l.delimiter||_$_f495[264];f=a.getValue(!0);a.close(!0);if(e)return f.join(d)};
454
- b.getValue=function(d,e,f,g,h,l){d=[];if(typeof l.worksheetId==_$_f495[17]&&(h=h.parent.getWorksheetInstance(l.worksheetId))){f=l.worksheetColumn?l.worksheetColumn:0;0<=l.worksheetImage&&(f=l.worksheetImage);if(e==_$_f495[3]||0==e||null==e||void 0==e)return _$_f495[3];e=(_$_f495[3]+e).split(_$_f495[264]);for(g=0;g<e.length;g++){var m=e[g].trim();var n=h.name(f);m=h.getRowById(m);n=!1===m?_$_f495[623]:m[n];0<=l.worksheetImage&&(n=_$_f495[624]+n+_$_f495[625]);d.push(n)}return 0<=l.worksheetImage?d.join(_$_f495[3]):
455
- d.join(_$_f495[296])}return _$_f495[244]};b.getSource=function(d,e){var f=e.worksheetColumn?e.worksheetColumn:0,g=null;typeof e.worksheetId==_$_f495[17]&&(g=d.parent.getWorksheetInstance(e.worksheetId));if(g){var h,l=[];for(d=0;d<g.rows.length;d++)if(h=g.value(f,d))h={id:g.getRowId(d),name:h},void 0!=e.worksheetImage&&(h.image=g.value(e.worksheetImage,d)),l.push(h)}else console.error(_$_f495[626]+e.worksheetId);return l};b[_$_f495[51]]=function(d,e){for(var f=0;f<d.source.length;f++)if(d.source[f].id==
456
- e)return d.render==_$_f495[256]?d.source[f].color:d.render==_$_f495[588]?d.source[f].image:d.source[f].name};return b}();return k}();typeof jQuery!==_$_f495[13]&&function(k){k.fn.jspreadsheet=k.fn.jexcel=function(c){var b=k(this)[_$_f495[51]](0);if(b.jspreadsheet){if(typeof arguments[0]==_$_f495[14])var a=arguments[0],d=2;else a=0,d=1;return b.jspreadsheet[a][c].apply(b.jspreadsheet[a],Array.prototype.slice.call(arguments,d))}return t(k(this)[_$_f495[51]](0),arguments[0])}}(jQuery);return t});
41
+ "data-current","html","jss_nowrap","insertHTML","<br/>\n","Process","A","mailto:","_blank","onclick","jclose","col-resize","row-resize","move","TD","Cloud plugin not loaded.","jtabs","jss_dialog","#","jss_number","decimal","data-locale","%","jss_percent","\\[Red\\]","red","\\(","jss_notes","145px","tag","jss_dropdown_tags","jss_dropdown","multiple","image","<div class='jss_dropdown_icon' style='background-color: ","'></div>","orange","<div class='jss_dropdown_tag' style='background-color: ","'>",
42
+ "</div>","&lt;","timepicker","YYYY-MM-DD","square","100px","false","FALSE","disabled","TRUE","jss_progressbar","min","max","jss_rating"," stars","star","href","IMG","round","100%","jss_image","tabindex","jpanel","delete","jfile",'<img src="','" alt="">',"jss_richtext","jss_tags","40px","#NOTFOUND","<img src='","' class='round small' />","Jspreadsheet: worksheet not found "];
43
+ (function(B,I){typeof exports===_$_c0e3[83]&&typeof module!==_$_c0e3[13]?module.exports=I():typeof define===_$_c0e3[84]&&define.amd?define(I):B.jspreadsheet=B.jexcel=I()})(this,function(){_$_c0e3[0];var B=function(k,b){k=jSuites.translate(k);if(b&&b.length)for(var c=0;c<b.length;c++)k=k.replace(_$_c0e3[1]+c+_$_c0e3[2],b[c]);return k},I=function(k,b){Array.isArray(k)&&(k=k[0]);k=k.replace(new RegExp(/'/g),_$_c0e3[3]).toUpperCase();if(void 0===b)return window[k]?window[k]:null;window[k]=b},J=function(){var k=
44
+ {version:_$_c0e3[4],edition:_$_c0e3[5],host:_$_c0e3[6],license:_$_c0e3[7],print:function(){return[_$_c0e3[8]+this.edition+_$_c0e3[9]+this.version+_$_c0e3[10]+this.host+_$_c0e3[10]+this.license]}};return function(){return k}}(),T=function(k){var b=parseInt(k.y);if(k.id)var c=parseInt(k.id);else k.value&&(c=parseInt(k.value));0<c&&(this.rows[b].id=c,sa[_$_c0e3[11]].call(this,c))},O=function(k){return(_$_c0e3[3]+k).substr(0,1)===_$_c0e3[12]},Z=function(k){var b=this.options.columns;return b[k]&&b[k].name?
45
+ b[k].name:k},M=function(k,b,c){var a;if(a=this.options.data[b]){var d=0<=k?Z.call(this,k):k;typeof c===_$_c0e3[13]?c=typeof d===_$_c0e3[14]?a[k]:jSuites.path.call(a,_$_c0e3[3]+d):(typeof d===_$_c0e3[14]?a[k]=c:jSuites.path.call(a,_$_c0e3[3]+d,c),!O(c)&&this.records[b][k]&&(this.records[b][k].v=c))}else c=null;return c},R=function(k){return 0==this.config.editable||k&&0==k.options.editable?!1:(k=Ja.call(this))?7<=k?!0:!1:!0},Ka=function(k){var b=_$_c0e3[15];if(this.parent)var c=this.parent.config,
46
+ a=this.parent.element,d=this;else c=this.config,a=this.element,d=t.current?t.current:null;typeof k===_$_c0e3[13]&&(k=!a.classList.contains(b));k?(a.classList.add(b),c.fullscreen=!0):(a.classList.remove(b),c.fullscreen=!1);d&&(d.tbody.innerHTML=_$_c0e3[3],H.call(d),U.refresh.call(d),fa.update.call(d.parent,d))},La=function(k){var b=this.loading;null===k&&(k=b.style.display==_$_c0e3[16]?!0:!1);b.style.display=k?_$_c0e3[16]:_$_c0e3[3];setTimeout(function(){b.style.display=_$_c0e3[3]},1E3)},Ga=function(k,
47
+ b){if(typeof k===_$_c0e3[17]){var c=E.getCoordsFromColumnName(k);c=this.records[c[1]][c[0]];if(c.element)k=c.element;else return typeof b===_$_c0e3[13]?c.readonly:c.readonly=b?!0:!1}c=_$_c0e3[18];k=k.classList;if(typeof b===_$_c0e3[13])return k.contains(c)?!0:!1;b?k.add(c):k.remove(c)},xa=function(k){var b=_$_c0e3[19],c=this.table.classList;if(typeof k==_$_c0e3[13])return c.contains(b)?!1:!0;k?c.remove(b):c.add(b);0<this.options.freezeColumns&&ka[_$_c0e3[11]].call(this,this.options.freezeColumns);
48
+ this.refreshBorders()},Ja=function(k){if(void 0===k)return this.status;var b=document.createElement(_$_c0e3[20]);b.style.textAlign=_$_c0e3[21];b.style.fontSize=_$_c0e3[22];b.style.cursor=_$_c0e3[23];b.onclick=function(){window.location.href=J().host+_$_c0e3[24]};var c=null,a=[74,50,48,50,48,33].join(_$_c0e3[3]);(function(e){c=1;try{if(e){var f=window.atob(e);f=f.split(_$_c0e3[25]);if(f[1]){f[1]=window.atob(f[1]);var h=f[0];e=a;var g=f[1],l=jSuites.sha512,m=_$_c0e3[3],p=_$_c0e3[3];128<e.length&&(e=
49
+ l(e));for(var n=0;128>n;n++){var q=e[n]?e[n].charCodeAt(0):0;m+=String.fromCharCode(54^q);p+=String.fromCharCode(92^q)}var v=l(p+l(m+g));if(h!=v)c=3;else if(f[1]=JSON.parse(f[1]),f[1].date){var u=window.location.hostname||_$_c0e3[26],y=u.split(_$_c0e3[27]);u=u.split(_$_c0e3[27]);2<u.length&&!jSuites.isNumeric(u[u.length-1])&&y.shift();y=y.join(_$_c0e3[27]);u=u.join(_$_c0e3[27]);if(-1==f[1].domain.indexOf(y)&&-1==f[1].domain.indexOf(u))c=4;else if(f[1].scope&&0<=f[1].scope.indexOf(_$_c0e3[28])){u=
50
+ new Date;y=parseInt(u.getTime()/1E3);var w=J();f[1].date<y?(c=f[1].date+2592E3<y&&!f[1].plan||f[1].date+15552E3<y?6:7,w.license=f[1].name+_$_c0e3[29]):(c=8,w.license=_$_c0e3[30]+f[1].name,w.edition=3==f[1].plan||6==f[1].plan?_$_c0e3[31]:_$_c0e3[5])}else c=5}else c=4}else c=2}}catch(C){}})(k);k=_$_c0e3[3];if(1==c)k=_$_c0e3[32];else if(2==c||3==c||4==c)k=_$_c0e3[33];else if(5==c)k=_$_c0e3[34];else if(6==c||7==c)k=_$_c0e3[35];b.appendChild(document.createTextNode(k));if(8>c)try{if(typeof sessionStorage!==
51
+ _$_c0e3[13]&&!sessionStorage.getItem(_$_c0e3[36])){sessionStorage.setItem(_$_c0e3[36],!0);var d=document.createElement(_$_c0e3[37]);d.src=J().host+_$_c0e3[38]+_$_c0e3[39];d.style.display=_$_c0e3[40];b.appendChild(d)}}catch(e){}Object.defineProperty(this,_$_c0e3[41],{value:c,writable:!1,configurable:!1,enumerable:!1,extensible:!1});J().edition===_$_c0e3[31]&&(this.edition=1);return b},U=function(){var k=function(){if(this.edition){var d=this.edition.getAttribute(_$_c0e3[42]),e=this.edition.getAttribute(_$_c0e3[43]);
52
+ da.position.call(this,d,e)}},b=function(){this.scrollX.scrollWidth<this.scrollX.scrollLeft+this.scrollX.offsetWidth+25?(this.content.scrollLeft=this.content.scrollWidth,0<this.options.freezeColumns&&ha.refresh.call(this)):this.content.scrollLeft=0;k.call(this)},c=function(){var d=this.tbody.lastChild.getAttribute(_$_c0e3[43]),e=this.scrollY.scrollHeight-this.content.offsetHeight-this.scrollY.scrollTop;this.content.scrollTop=d!=(this.results?this.rows[this.results[this.results.length-1]].y:this.rows[this.rows.length-
53
+ 1].y)&&e?0:this.content.scrollHeight;k.call(this)},a=function(){if(H.limited.call(this)){var d=ka.getWidth.call(this);if(1==this.parent.config.fullscreen)var e=this.content.offsetWidth,f=this.content.offsetHeight;else 1==this.options.tableOverflow&&(e=parseInt(this.options.tableWidth),f=parseInt(this.options.tableHeight));this.width=a.width.call(this)+(d?d:1);this.height=a.height.call(this);this.tfoot.offsetHeight&&(this.height+=this.tfoot.offsetHeight+26);this.scrollX.firstChild.style.width=this.width+
54
+ _$_c0e3[44];this.scrollY.firstChild.style.height=this.height+_$_c0e3[44];this.scrollX.style.width=e+_$_c0e3[44];this.scrollY.style.height=f+_$_c0e3[44];this.scrollX.style.display=this.width>e?_$_c0e3[3]:_$_c0e3[40];this.scrollY.style.display=this.height>f?_$_c0e3[3]:_$_c0e3[40]}else this.scrollX.style.display=_$_c0e3[40],this.scrollY.style.display=_$_c0e3[40]};a.refresh=function(){this.scrollY.scrollTop=0;this.scrollX.scrollLeft=0;a.call(this)};a.updateX=function(){if(a.event)return!1;var d=parseInt(this.thead.lastChild.children[(this.options.freezeColumns||
55
+ 0)+1].getAttribute(_$_c0e3[42]));a.setX.call(this,a.width.call(this,d));b.call(this)};a.updateY=function(){if(a.event)return!1;if(this.tbody.firstChild){var d=parseInt(this.tbody.firstChild.getAttribute(_$_c0e3[43]));a.setY.call(this,a.height.call(this,d));c.call(this)}};a.setX=function(d){a.ignore=!0;this.scrollX.scrollLeft=d};a.setY=function(d){a.ignore=!0;this.scrollY.scrollTop=d};a.update=function(d,e){e==_$_c0e3[45]?(d=a.width.call(this,null,d.target.scrollLeft/(d.target.scrollWidth-this.content.offsetWidth)*
56
+ this.width),H.reset.call(this),H[_$_c0e3[46]].call(this,null,d),b.call(this)):(d=a.height.call(this,null,d.target.scrollTop/(d.target.scrollHeight-this.content.offsetHeight)*(this.height-(this.tbody.offsetHeight-5))),this.tbody.textContent=_$_c0e3[3],H[_$_c0e3[46]].call(this,d),c.call(this))};a.build=function(d){var e=this,f=document.createElement(_$_c0e3[20]),h=document.createElement(_$_c0e3[20]);f.className=_$_c0e3[47]+d;h.className=_$_c0e3[48]+d;f.appendChild(h);d==_$_c0e3[45]?f.style.height=_$_c0e3[22]:
57
+ f.style.width=_$_c0e3[22];f.onscroll=function(g){if(a.ignore)return a.ignore=!1;a.event=!0;a.update.call(e,g,d);a.event=!1};return f};a.width=function(d,e){for(var f=this.options.columns,h=0,g=this.options.freezeColumns||0;g<this.options.columns.length;g++){if(d===g)return h;!1!==f[g].visible&&f[g].type!==_$_c0e3[49]&&(h+=parseInt(f[g].width));if(h>=e)return g}return e?g:h};a.height=function(d,e){var f=0,h=0;this.options.defaultRowHeight||(this.options.defaultRowHeight=23);for(var g=this.results?
58
+ this.results:this.rows,l=0;l<g.length;l++){h=l;this.results&&(h=g[l]);if(d===h)return f;this.rows[h]&&!1!==this.rows[h].visible&&(f=this.rows[h].height?f+parseInt(this.rows[h].height):this.rows[h].element&&this.rows[h].element.offsetHeight?f+parseInt(this.rows[h].element.offsetHeight):f+parseInt(this.options.defaultRowHeight));if(f>=e)return h}return e?h:f};return a}(),H=function(){var k=function(c,a){var d=this.thead.clientHeight;a||(a=1);var e=!1,f=!1,h=c.getAttribute(_$_c0e3[42]),g=c.getAttribute(_$_c0e3[43]);
59
+ var l=this.records[g][h];l.merged&&(h-=l.merged[0],g-=l.merged[1],c=this.records[g][h].element);g=this.content.getBoundingClientRect();l=c.getBoundingClientRect();var m=ka.getWidth.call(this),p=g.left+m,n=g.left+g.width;h=g.top+d;var q=g.top+g.height;var v=0;g=l.top;g>=h&&g<=q||(v++,e=!0);g=l.top+l.height;g>=h&&g<=q||v++;if(v>=a)return 2>a&&(a=this.content.scrollTop,0==e?q-h>l.height&&(this.content.scrollTop+=g-q+3,U.ignore=!0,this.scrollY.scrollTop+=g-q+3):(this.content.scrollTop=c.offsetTop-d,U.ignore=
60
+ !0,this.scrollY.scrollTop-=a-this.content.scrollTop)),!1;if(!m||!c.classList.contains(_$_c0e3[50]))if(v=0,h=l.left,h>=p&&h<=n||(v++,f=!0),h=l.left+l.width,h>=p&&h<n||v++,v>=a)return 2>a&&(a=this.content.scrollLeft,0==f?n-p>l.width&&(this.content.scrollLeft+=h-n+3,U.ignore=!0,this.scrollX.scrollLeft+=h-n+3):(this.content.scrollLeft=c.offsetLeft-p-50,U.ignore=!0,this.scrollX.scrollLeft-=a-this.content.scrollLeft)),!1;return!0},b=function(){var c=0;this.results&&(c=this.results[0]);b.reset.call(this,
61
+ !0);b.renderX.call(this,0);b.renderY.call(this,c);ka.headers.call(this);0<this.options.pagination&&ta.update.call(this);this.refreshBorders();U.call(this)};b.limited=function(){return 1==this.options.tableOverflow||1==this.parent.config.fullscreen};b.refresh=function(){if(!this.tbody.lastChild)return!1;var c=parseInt(this.thead.lastChild.lastChild.getAttribute(_$_c0e3[42]))+1,a=parseInt(this.tbody.lastChild.getAttribute(_$_c0e3[43]));this.results?(a=this.results.indexOf(a),a<this.results.length-1&&
62
+ a++,a=this.results[a]):a++;b.renderX.call(this,c);b.renderY.call(this,a);this.content.scrollTop=0;this.content.scrollLeft=0;b.adjustX.call(this,!1,!0);b.adjustY.call(this,!1,!0);U.call(this)};b.renderX=function(c,a,d){var e=this.options.columns,f=0,h=[],g=(this.options.freezeColumns||0)+1;1==this.parent.config.fullscreen?f=this.content.offsetWidth:1==this.options.tableOverflow&&(f=parseInt(this.options.tableWidth));var l=this.headerContainer.offsetWidth||0;for(d||(d=0);e[c]&&(!f||l<f||0<d);){!1!==
63
+ e[c].visible&&e[c].type!==_$_c0e3[49]&&(l+=parseInt(e[c].width));0<d&&d--;var m=ba.getWidth.call(this,c,h);m>d&&(d=m);a?(b.renderColumn.call(this,c,g),c--):(b.renderColumn.call(this,c),c++)}ba.batch.call(this,h)};b.renderY=function(c,a,d){var e=0,f=[];1==this.parent.config.fullscreen?e=this.content.offsetHeight:1==this.options.tableOverflow&&(e=parseInt(this.options.tableHeight));e&&(e-=this.thead.offsetHeight+4,this.tfoot.offsetHeight&&(e-=this.tfoot.offsetHeight+14));var h=this.tbody.offsetHeight;
64
+ var g=this.options.freezeColumns||0,l=parseInt(this.headerContainer.lastChild.getAttribute(_$_c0e3[42]));g=this.headerContainer.children[g+1]?parseInt(this.headerContainer.children[g+1].getAttribute(_$_c0e3[42])):l;var m=this.results?this.results.indexOf(c):c,p=parseInt(this.options.pagination)||0,n=this.tbody.children.length||0,q=!1;for(d||(d=0);this.options.data&&this.options.data[c]&&(!p||n<p||0<d)&&(!e||h<=e||0<d);){var v=b.renderRow.call(this,c,g,l);a?(this.tbody.insertBefore(v,this.tbody.firstChild),
65
+ m--):(this.tbody.appendChild(v),m++);this.rows[c].height?(v.offsetHeight!==this.rows[c].height&&(this.rows[c].height=v.offsetHeight,q=!0),h+=this.rows[c].height):(h+=this.rows[c].height=v.offsetHeight,q=!0);0<d&&d--;c=ba.getHeight.call(this,c,f);c>d&&(d=c);c=this.results?this.results[m]:m;n++}ba.batch.call(this,f);q&&U.call(this)};b.renderColumn=function(c,a,d){this.headers[c]||Ca.create.call(this,c);if(this.options.nestedHeaders)for(d=0;d<this.options.nestedHeaders.length;d++){var e=oa.getColumns.call(this,
66
+ d);void 0!==e[c]&&oa.renderCell.call(this,e[c],d,a)}if(this.options.footers)for(d=0;d<this.options.footers.length;d++)e=aa.create.call(this,c,d),null===a?this.tfoot.children[d].appendChild(e):this.tfoot.children[d].insertBefore(e,this.tfoot.children[d].children[a]);null===a?(this.headerContainer.appendChild(this.headers[c]),this.colgroupContainer.appendChild(this.colgroup[c])):(this.headerContainer.insertBefore(this.headers[c],this.headerContainer.children[a]),this.colgroupContainer.insertBefore(this.colgroup[c],
67
+ this.colgroupContainer.children[a]));if(this.tbody.children.length)for(d=0;d<this.tbody.children.length;d++)e=parseInt(this.tbody.children[d].getAttribute(_$_c0e3[43])),(e=L[_$_c0e3[51]].call(this,c,e))&&(null===a?this.tbody.children[d].appendChild(e):this.tbody.children[d].insertBefore(e,this.tbody.children[d].children[a]))};b.renderRow=function(c,a,d,e){var f=this.options.freezeColumns||0;null==a&&(a=parseInt(this.headerContainer.children[f+1].getAttribute(_$_c0e3[42])));null==d&&(d=parseInt(this.headerContainer.lastChild.getAttribute(_$_c0e3[42])));
68
+ var h=Aa.create.call(this,c,e);if(h.children.length)for(;h.children[f+1];)h.removeChild(h.lastChild);if(0<f){for(var g=0;g<f;g++)h.appendChild(L[_$_c0e3[51]].call(this,g,c));ka.update.call(this,c)}for(g=a;g<=d;g++)a=L[_$_c0e3[51]].call(this,g,c,e),h.appendChild(a);return h};b.resetY=function(){if(this.options.pagination){this.pageNumber||(this.pageNumber=0);var c=this.options.pagination*this.pageNumber}else c=0;var a=0;if(this.merged.rows[c]){for(a=this.options.pagination;this.merged.rows[c]&&0<=
69
+ c;)c--;c++}this.tbody.textContent=_$_c0e3[3];this.results&&this.results.length&&(c=this.results[c]);(!this.results||0<this.results.length)&&H.renderY.call(this,c,0,a);0<this.options.pagination&&ta.update.call(this);U.call(this);this.refreshBorders()};b[_$_c0e3[46]]=function(c,a){if(null!==c&&0<=c)if(0<this.options.pagination)this.page(this.whichPage(c));else if(this.rows[c]||(c=this.options.data.length-1),!Aa.attached.call(this,c)){if(this.merged.rows[c]){for(;this.merged.rows[c]&&0<=c;)c--;c++}this.tbody.textContent=
70
+ _$_c0e3[3];b.renderY.call(this,c);var d=this.results?this.results.indexOf(c):c;0<d&&(this.results?d=this.results[d-1]:d--,b.renderY.call(this,d,!0));U.updateY.call(this)}if(null!==a&&0<=a&&(this.options.columns[a]||(a=this.options.columns.length-1),c||(c=b.getY.call(this)),!L.attached.call(this,a,c))){if(this.merged.cols[a]){for(d=c=0;d<this.rows.length;d++)this.records[d][a].merged&&(c=this.records[d][a].merged[0]);a-=c}b.reset.call(this);b.renderX.call(this,a);0<a&&b.renderX.call(this,a-1,!0);U.updateX.call(this)}this.refreshBorders()};
71
+ b.pageUp=function(c,a,d){var e=parseInt(this.tbody.firstChild.getAttribute(_$_c0e3[43]));if(a){c=null;var f=this.results?this.results[0]:0}else this.results?(f=this.results.indexOf(e),0<f&&f--,f=this.results[f]):(f=e,0<f&&f--);if(f<e){if(null==c)this.tbody.textContent=_$_c0e3[3];else{e=c;if(this.options.mergeCells){var h=parseInt(this.tbody.lastChild.getAttribute(_$_c0e3[43]));e+=ba.getHeight.call(this,h)}for(h=0;h<e;h++)this.tbody.removeChild(this.tbody.lastChild)}b.renderY.call(this,f,!a,c);b.adjustY.call(this,
72
+ !1);d&&d.preventDefault();U.updateY.call(this)}this.refreshBorders()};b.pageDown=function(c,a,d){var e=parseInt(this.tbody.lastChild.getAttribute(_$_c0e3[43]));if(a){c=null;var f=this.results?this.results[this.results.length-1]:this.rows.length-1}else this.results?(f=this.results.indexOf(e),f<this.results.length-1&&f++,f=this.results[f]):(f=e,e<this.options.data.length-1&&f++);if(f>e){if(null==c)this.tbody.textContent=_$_c0e3[3];else{e=c;if(this.options.mergeCells){var h=parseInt(this.tbody.firstChild.getAttribute(_$_c0e3[43]));
73
+ e+=ba.getHeight.call(this,h)}for(h=0;h<e;h++)this.tbody.removeChild(this.tbody.firstChild)}b.renderY.call(this,f,a,c);b.adjustY.call(this,!0);d&&d.preventDefault();U.updateY.call(this)}this.refreshBorders()};b.removeColumns=function(c,a){var d=null===a?this.headerContainer.lastChild:this.headerContainer.children[a];if(d)d=parseInt(d.getAttribute(_$_c0e3[42]));else return!1;if(this.options.mergeCells){for(var e=0,f=d,h=0;h<c;h++){var g=ba.getWidth.call(this,f);g>e&&(e=g);null===a?f--:f++}c+=e}c>=this.headerContainer.children.length&&
74
+ (c=this.headerContainer.children.length-1);if((e=this.options.nestedHeaders)&&e.length)for(f=0;f<e.length;f++)for(g=oa.getColumns.call(this,f),h=0;h<c;h++)if(void 0!==g[d+h]&&this.nested.content[f][g[d+h]]){var l=this.nested.content[f][g[d+h]].element,m=l.getAttribute(_$_c0e3[52]);0<m&&m--;0<m?l.setAttribute(_$_c0e3[52],m):l.parentNode&&this.thead.children[f].removeChild(l)}for(h=0;h<c;h++)null===a?(this.headerContainer.removeChild(this.headerContainer.lastChild),this.colgroupContainer.removeChild(this.colgroupContainer.lastChild)):
75
+ this.headerContainer.children[a]&&(this.headerContainer.removeChild(this.headerContainer.children[a]),this.colgroupContainer.removeChild(this.colgroupContainer.children[a]));for(f=0;f<this.tbody.children.length;f++)for(h=0;h<c;h++)null===a?this.tbody.children[f].removeChild(this.tbody.children[f].lastChild):this.tbody.children[f].children[a]&&this.tbody.children[f].removeChild(this.tbody.children[f].children[a]);for(f=0;f<this.tfoot.children.length;f++)for(h=0;h<c;h++)null===a?this.tfoot.children[f].removeChild(this.tfoot.children[f].lastChild):
76
+ this.tfoot.children[f].removeChild(this.tfoot.children[f].children[a])};b.pageLeft=function(c,a){var d=this.options.freezeColumns||0;if(a){c=null;var e=d}else e=parseInt(this.thead.lastChild.children[d+1].getAttribute(_$_c0e3[42]))-1;e>=d&&(null==c?b.reset.call(this):b.removeColumns.call(this,c,null),b.renderX.call(this,e,!a,c),b.adjustX.call(this,!1),U.updateX.call(this));this.refreshBorders()};b.pageRight=function(c,a){var d=this.options.freezeColumns||0;if(a){c=null;var e=this.options.columns.length-
77
+ 1}else e=parseInt(this.thead.lastChild.lastChild.getAttribute(_$_c0e3[42]))+1;e<this.options.columns.length&&(null==c?b.reset.call(this):b.removeColumns.call(this,c,d+1),b.renderX.call(this,e,a,c),b.adjustX.call(this,!0),U.updateX.call(this));this.refreshBorders()};b.reset=function(c){1<this.headerContainer.children.length&&(c=c?0:this.options.freezeColumns||0,b.removeColumns.call(this,this.headerContainer.children.length-(c+1),c+1))};b.getX=function(){if(this.thead.lastChild)return parseInt(this.thead.lastChild.children[1].getAttribute(_$_c0e3[42]))};
78
+ b.getY=function(){if(this.tbody.firstChild)return parseInt(this.tbody.firstChild.getAttribute(_$_c0e3[43]))};b.adjustX=function(c,a){var d=this.options.freezeColumns||0;if(c)var e=this.options.columns.length-1,f=parseInt(this.tbody.firstChild.lastChild.getAttribute(_$_c0e3[42])),h=parseInt(this.tbody.firstChild.children[d+1].getAttribute(_$_c0e3[42]));else e=d,f=parseInt(this.tbody.firstChild.children[d+1].getAttribute(_$_c0e3[42])),h=parseInt(this.tbody.firstChild.lastChild.getAttribute(_$_c0e3[42]));
79
+ f===e&&(c?h--:h++,b.renderX.call(this,h,c));if(!0===a){for(c=0;c<this.tbody.children.length&&this.tbody.children[c].style.display===_$_c0e3[40];c++);a=[];for(d+=1;d<this.thead.lastChild.children.length;d++)k.call(this,this.tbody.children[c].children[d],2)||a.push(d);a.length&&b.removeColumns.call(this,a.length,a[0])}};b.adjustY=function(c,a){if(c)var d=this.rows.length-1,e=parseInt(this.tbody.lastChild.getAttribute(_$_c0e3[43])),f=parseInt(this.tbody.firstChild.getAttribute(_$_c0e3[43]));else d=0,
80
+ e=parseInt(this.tbody.firstChild.getAttribute(_$_c0e3[43])),f=parseInt(this.tbody.lastChild.getAttribute(_$_c0e3[43]));e==d&&(this.results?(d=this.results.indexOf(f),f=c?this.results[d-1]:this.results[d+1]):c?f--:f++,b.renderY.call(this,f,c));if(!0===a){c=[];for(a=0;a<this.tbody.children.length;a++)this.tbody.children[a].style.display!==_$_c0e3[40]&&this.tbody.children[a].children[1]&&(k.call(this,this.tbody.children[a].children[1],2)||c.push(this.tbody.children[a].firstChild.getAttribute(_$_c0e3[43])));
81
+ if(c.length)for(a=0;a<c.length;a++)this.rows[c[a]].element.remove()}};b.isVisible=k;return b}(),Ma=function(k,b,c,a){for(var d=this.options.columns,e=k,f,h=null;k<d.length-1;)if(k++,!1!==d[k].visible&&d[k].type!==_$_c0e3[49]){f=this.records[b]&&this.records[b][k].v===_$_c0e3[3]?!1:!0;null===h&&(h=f);if(this.records[b]&&this.records[b][k].element&&this.records[b][k].element.style.display==_$_c0e3[40]){if(this.records[b][k].merged){if(k==k+this.records[b][k].merged[0]&&(e=k,!c))break;f=!1}}else{if(c&&
82
+ f!==h&&!a)break;if(c)e=k;else return k}h=f}return e},Na=function(k,b,c,a){for(var d=this.options.columns,e=k,f,h=null;0<k;)if(k--,!1!==d[k].visible&&d[k].type!==_$_c0e3[49]){f=this.records[b]&&this.records[b][k].v===_$_c0e3[3]?!1:!0;null===h&&(h=f);if(this.records[b]&&this.records[b][k].element&&this.records[b][k].element.style.display==_$_c0e3[40]){if(this.records[b][k].merged){e=k-this.records[b][k].merged[0];if(!c)break;f=!0}}else{if(c&&f!==h&&!a)break;if(c)e=k;else return k}h=f}return e},Ta=function(){var k=
83
+ function(c,a,d,e){1==c||3==c?Aa.attached.call(this,d)||(0<this.options.pagination?this.page(this.whichPage(d)):(1==c?H.pageUp.call(this,1,e):H.pageDown.call(this,1,e),Aa.attached.call(this,d)||H[_$_c0e3[46]].call(this,d))):L.attached.call(this,a,d)||(0==c?H.pageLeft.call(this,1,e):H.pageRight.call(this,1,e),L.attached.call(this,a,d)||H[_$_c0e3[46]].call(this,d,a))},b=function(c){c.up=b.up;c.down=b.down;c.right=b.right;c.left=b.left;c.last=b.last;c.first=b.first};b.up=function(c,a,d){if(c)var e=parseInt(this.selectedCell[2]),
84
+ f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);a:{var h=e,g=f,l=g,m=null;if(this.results&&(g=this.results.indexOf(g),-1==g)){d=l;break a}for(;0<g;){g--;var p=this.results?this.results[g]:g;if(!1!==this.rows[p].visible){var n=this.records[p][h].v===_$_c0e3[3]?!1:!0;null===m&&(m=n);if(this.records[p][h].element&&this.records[p][h].element.style.display==_$_c0e3[40]){if(this.records[p][h].merged){l=p-this.records[p][h].merged[1];if(!a)break;n=
85
+ !0}}else if(a&&n!==m&&!d){d=l;break a}else if(a)l=this.records[p][h].merged?p-this.records[p][h].merged[1]:p;else{d=p;break a}m=n}}d=l}d!=f&&(f=d,c?(c=this.selectedCell[0],d=this.selectedCell[1]):(c=e,d=f,e=c,f=d),k.call(this,1,e,f,a),this.updateSelectionFromCoords(c,d,e,f))};b.down=function(c,a,d){if(c)var e=parseInt(this.selectedCell[2]),f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);a:{var h=e,g=f,l=g,m=null;if(this.results){g=this.results.indexOf(g);
86
+ if(-1==g){d=l;break a}var p=this.results.length-1}else p=this.rows.length-1;for(;g<p;){g++;var n=this.results?this.results[g]:g;if(!1!==this.rows[n].visible){var q=this.records[n][h].v===_$_c0e3[3]?!1:!0;null===m&&(m=q);if(this.records[n][h].element&&this.records[n][h].element.style.display==_$_c0e3[40]){if(this.records[n][h].merged){if(!this.records[n][h].merged[1]&&(l=n,!a))break;q=!0}}else if(a&&q!==m&&!d){d=l;break a}else if(a)l=n;else{d=n;break a}m=q}}d=l}d!=f&&(f=d,c?(c=this.selectedCell[0],
87
+ d=this.selectedCell[1]):(c=e,d=f,e=c,f=d),k.call(this,3,e,f,a),this.updateSelectionFromCoords(c,d,e,f))};b.right=function(c,a,d){if(c)var e=parseInt(this.selectedCell[2]),f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);d=Ma.call(this,e,f,a,d);d!=e&&(e=d,c?(c=this.selectedCell[0],d=this.selectedCell[1]):(c=e,d=f,e=c,f=d),k.call(this,2,e,f,a),this.updateSelectionFromCoords(c,d,e,f))};b.left=function(c,a,d){if(c)var e=parseInt(this.selectedCell[2]),
88
+ f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);d=Na.call(this,e,f,a,d);d!=e&&(e=d,c?(c=this.selectedCell[0],d=this.selectedCell[1]):(c=e,d=f,e=c,f=d),k.call(this,0,e,f,a),this.updateSelectionFromCoords(c,d,e,f))};b.first=function(c,a){a?b.up.call(this,c,!0,!0):b.left.call(this,c,!0,!0)};b.last=function(c,a){a?b.down.call(this,c,!0,!0):b.right.call(this,c,!0,!0)};return b}(),Ua=function(){return function(k){k.save=Oa;k.fullscreen=Ka;k.setReadOnly=
89
+ Ga;k.getReadOnly=Ga;k.isReadOnly=Ga;k.setPlugins=function(b){pa.call(this.parent,b)};k.showIndex=function(){xa.call(this,!0)};k.hideIndex=function(){xa.call(this,!1)};k[_$_c0e3[46]]=H[_$_c0e3[46]];k.undo=function(){V.undo.call(k.parent)};k.redo=function(){V.redo.call(k.parent)};k.isEditable=function(){return R.call(k.parent,k)};k.dispatch=function(){return F.apply(this.parent,arguments)};k.setViewport=function(b,c){this.options.tableOverflow=!0;b=parseInt(b);c=parseInt(c);this.content.style.overflow=
90
+ _$_c0e3[49];100<b&&(this.options.tableWidth=b+_$_c0e3[44],this.content.style.maxWidth=this.options.tableWidth);100<c&&(this.options.tableHeight=parseInt(c)+_$_c0e3[44],this.content.style.maxHeight=this.options.tableHeight);this.tbody.innerHTML=_$_c0e3[3];H.call(this);U.refresh.call(this);fa.update.call(this.parent,this)}}}(),Da=function(){var k={logo:null,url:null,persistence:!1,sequence:!0,data:null,json:null,rows:[],columns:[],cells:{},role:null,nestedHeaders:null,defaultColWidth:100,defaultRowHeight:0,
91
+ defaultColAlign:null,minSpareRows:0,minSpareCols:0,minDimensions:[0,0],csv:null,csvFileName:_$_c0e3[36],csvHeaders:!0,csvDelimiter:_$_c0e3[25],columnSorting:!0,columnDrag:!0,columnResize:!0,rowResize:!0,rowDrag:!0,editable:!0,allowInsertRow:!0,allowManualInsertRow:!0,allowInsertColumn:!0,allowManualInsertColumn:!0,allowDeleteRow:!0,allowDeletingAllRows:!1,allowDeleteColumn:!0,allowRenameColumn:!0,allowComments:!0,selectionCopy:!0,mergeCells:{},search:!1,pagination:!1,paginationOptions:null,textOverflow:!1,
92
+ tableOverflow:!1,tableHeight:_$_c0e3[53],tableWidth:null,comments:null,meta:null,style:{},freezeColumns:0,orderBy:null,worksheetId:_$_c0e3[3],worksheetName:null,worksheetState:null,filters:!1,footers:null,validations:null,formify:null,applyMaskOnFooters:!1,pluginOptions:null,locked:!1,selectUnLockedCells:!0,selectLockedCells:!0},b={application:_$_c0e3[54],cloud:null,root:null,definedNames:{},sorting:null,server:null,toolbar:null,editable:!0,allowExport:!0,includeHeadersOnDownload:!1,forceUpdateOnPaste:!1,
93
+ loadingSpin:!1,fullscreen:!1,secureFormulas:!0,parseFormulas:!0,debugFormulas:!1,editorFormulas:!0,autoIncrement:!0,autoCasting:!0,stripHTML:!1,tabs:!1,allowDeleteWorksheet:!0,allowRenameWorksheet:!0,allowMoveWorksheet:!0,onevent:null,onclick:null,onload:null,onundo:null,onredo:null,onbeforesave:null,onsave:null,onbeforechange:null,onchange:null,onafterchanges:null,oncopy:null,onbeforepaste:null,onpaste:null,onbeforeinsertrow:null,oninsertrow:null,onbeforedeleterow:null,ondeleterow:null,onbeforeinsertcolumn:null,
94
+ oninsertcolumn:null,onbeforedeletecolumn:null,ondeletecolumn:null,onmoverow:null,onmovecolumn:null,onresizerow:null,onresizecolumn:null,onselection:null,onbeforecomments:null,oncomments:null,onbeforesort:null,onsort:null,onfocus:null,onblur:null,onmerge:null,onchangeheader:null,onchangefooter:null,onchangefootervalue:null,onchangenested:null,onchangenestedcell:null,oncreateeditor:null,oneditionstart:null,oneditionend:null,onchangestyle:null,onchangemeta:null,onbeforechangepage:null,onchangepage:null,
95
+ onbeforecreateworksheet:null,oncreateworksheet:null,onrenameworksheet:null,ondeleteworksheet:null,onmoveworksheet:null,onopenworksheet:null,onchangerowid:null,onbeforesearch:null,onsearch:null,onbeforefilter:null,onfilter:null,oncreatecell:null,oncreaterow:null,onbeforeformula:null,updateTable:null,contextMenu:null,parseTableFirstRowAsHeader:!1,parseTableAutoCellType:!1,plugins:null,wordWrap:!0,about:!0,license:null,worksheets:null},c=function(e,f){f=JSON.parse(JSON.stringify(f));var h={},g;for(g in f)e&&
96
+ e.hasOwnProperty(g)?h[g]=e[g]:h[g]=f[g];return h},a=function(e){e&&(typeof e==_$_c0e3[17]&&(e=JSON.parse(e)),this.options.data=e);this.options.json&&(this.options.data=this.options.json);this.options.data||(this.options.data=[]);e=this.options.columns.length;if(this.options.data&&typeof this.options.data[0]!==_$_c0e3[13]){var f=this.options.data[0].data&&0<Object.keys(this.options.data[0].data).length?Object.keys(this.options.data[0].data):Object.keys(this.options.data[0]);f.length>e&&(e=f.length)}this.options.minDimensions[0]>
97
+ e&&(e=this.options.minDimensions[0]);e||(e=8);for(var h=0;h<e;h++)this.options.columns[h]?this.options.columns[h].type||(this.options.columns[h].type=_$_c0e3[55]):this.options.columns[h]={type:_$_c0e3[55]},this.options.columns[h].type==_$_c0e3[56]&&(this.options.columns[h].type=_$_c0e3[57],this.options.columns[h].autocomplete=!0),!this.options.columns[h].name&&f&&f[h]&&Number(f[h])!=f[h]&&(this.options.columns[h].name=f[h]),this.options.columns[h].width||(this.options.columns[h].width=this.options.defaultColWidth),
98
+ this.options.columns[h].type!=_$_c0e3[57]||this.options.columns[h].source||(this.options.columns[h].source=[]),this.options.columns[h].type==_$_c0e3[57]&&this.options.columns[h].url&&jSuites.ajax({url:this.options.columns[h].url,index:h,method:_$_c0e3[58],dataType:_$_c0e3[59],worksheet:this,group:this.parent.name,success:function(g){this.worksheet.options.columns[this.index].source=g}})},d=function(e){e.getConfig=d[_$_c0e3[51]];e.setConfig=d[_$_c0e3[11]]};d.spreadsheet=function(e){this.config=c(e,
99
+ b);1!=this.config.secureFormulas&&console.log(_$_c0e3[60])};d.worksheet=function(e){var f=this;f.options=c(e,k);f.options.csv?jSuites.ajax({url:f.options.csv,method:_$_c0e3[58],dataType:_$_c0e3[55],group:f.parent.name,success:function(h){h=E.parseCSV(h,f.options.csvDelimiter);if(1==f.options.csvHeaders&&0<h.length)for(var g=h.shift(),l=0;l<g.length;l++)f.options.columns[l]||(f.options.columns[l]={type:_$_c0e3[55],width:f.options.defaultColWidth}),typeof f.options.columns[l].title===_$_c0e3[13]&&(f.options.columns[l].title=
100
+ g[l]);a.call(f,h)}}):f.options.url?jSuites.ajax({url:f.options.url,method:_$_c0e3[58],dataType:_$_c0e3[59],group:f.parent.name,success:function(h){a.call(f,h)}}):a.call(f)};d[_$_c0e3[51]]=function(){return this.options};d[_$_c0e3[11]]=function(e){typeof e==_$_c0e3[17]&&(e=JSON.parse(e));if(this.parent){f=Object.keys(e);for(h=0;h<f.length;h++)typeof k[f[h]]!==_$_c0e3[13]&&(this.options[f[h]]=e[f[h]]);!0===e.filters?ca.show.call(this):!1===e.filters&&ca.hide.call(this);!0===e.search?qa.show.call(this):
101
+ !1===e.search&&qa.hide.call(this);!0===e.toolbar?fa.show.call(this.parent):!1===e.toolbar&&fa.hide.call(this.parent);e.minDimensions&&e.minDimensions[0]&&(f=parseInt(e.minDimensions[0])-this.headers.length,0<f&&this.insertColumn(f),f=parseInt(e.minDimensions[1])-this.rows.length,0<f&&this.insertRow(f));K.call(this,_$_c0e3[61],{data:JSON.stringify(e)})}else for(var f=Object.keys(e),h=0;h<f.length;h++)typeof b[f[h]]!==_$_c0e3[13]&&(this.config[f[h]]=e[f[h]])};return d}(),V=function(k){k=function(b){if(1!=
102
+ this.ignoreHistory){var c=++this.historyIndex;this.history=this.history.slice(0,c+1);this.history[c]=b}};k.undo=function(){if(0<=this.historyIndex)var b=this.history[this.historyIndex--];if(b){this.ignoreHistory=!0;var c=b.worksheet;c.openWorksheet();var a=[];if(b.action==_$_c0e3[62])c.deleteRow(b.insertBefore?b.rowNumber:b.rowNumber+1,b.numOfRows);else if(b.action==_$_c0e3[63])c.insertRow(b.numOfRows,b.rowNumber,1,b.data),L.setAttributes.call(c,b.attributes);else if(b.action==_$_c0e3[64])c.deleteColumn(b.insertBefore?
103
+ b.columnNumber:b.columnNumber+1,b.numOfColumns);else if(b.action==_$_c0e3[65])c.insertColumn(b.numOfColumns,b.columnNumber,1,b.properties,b.data,b.extra),L.setAttributes.call(c,b.attributes);else if(b.action==_$_c0e3[66])c.moveRow(b.newValue,b.oldValue);else if(b.action==_$_c0e3[67])c.moveColumn(b.newValue,b.oldValue);else if(b.action==_$_c0e3[68])c.removeMerge(b.newValue,!0),c.setMerge(b.oldValue);else if(b.action==_$_c0e3[69])c.setMerge(b.oldValue);else if(b.action==_$_c0e3[70])c.setStyle(b.oldValue,
104
+ null,null,1);else if(b.action==_$_c0e3[71])c.setStyle(b.oldValue);else if(b.action==_$_c0e3[72])c.setWidth(b.column,b.oldValue);else if(b.action==_$_c0e3[73])c.setHeight(b.row,b.oldValue);else if(b.action==_$_c0e3[74])c.setHeader(b.column,b.oldValue);else if(b.action==_$_c0e3[75])c.setComments(b.oldValue);else if(b.action==_$_c0e3[76])c.orderBy(b.column,b.direction?0:1,b.oldValue);else if(b.action==_$_c0e3[77]||b.action==_$_c0e3[78]){for(var d=0;d<b.records.length;d++){var e=JSON.parse(JSON.stringify(b.records[d]));
105
+ e.value=b.records[d].oldValue;b.records[d].oldStyle&&(e.style=b.records[d].oldStyle);a.push(e)}c[b.action](a)}else b.action==_$_c0e3[79]?c.renameWorksheet(b.index,b.oldValue):b.action==_$_c0e3[80]&&c.moveWorksheet(b.t,b.f);b.selection&&c.updateSelectionFromCoords(b.selection);this.ignoreHistory=!1;F.call(this,_$_c0e3[81],c,b)}};k.redo=function(){if(this.historyIndex<this.history.length-1)var b=this.history[++this.historyIndex];if(b){this.ignoreHistory=!0;var c=b.worksheet;c.openWorksheet();if(b.action==
106
+ _$_c0e3[62])c.insertRow(b.numOfRows,b.rowNumber,b.insertBefore,b.data);else if(b.action==_$_c0e3[63])c.deleteRow(b.rowNumber,b.numOfRows);else if(b.action==_$_c0e3[64])c.insertColumn(b.numOfColumns,b.columnNumber,b.insertBefore,b.properties,b.data);else if(b.action==_$_c0e3[65])c.deleteColumn(b.columnNumber,b.numOfColumns);else if(b.action==_$_c0e3[66])c.moveRow(b.oldValue,b.newValue);else if(b.action==_$_c0e3[67])c.moveColumn(b.oldValue,b.newValue);else if(b.action==_$_c0e3[68])c.setMerge(b.newValue);
107
+ else if(b.action==_$_c0e3[69])c.removeMerge(b.newValue);else if(b.action==_$_c0e3[70])c.setStyle(b.newValue,null,null,1);else if(b.action==_$_c0e3[71])c.resetStyle(b.cells);else if(b.action==_$_c0e3[72])c.setWidth(b.column,b.newValue);else if(b.action==_$_c0e3[73])c.setHeight(b.row,b.newValue);else if(b.action==_$_c0e3[74])c.setHeader(b.column,b.newValue);else if(b.action==_$_c0e3[75])c.setComments(b.newValue);else if(b.action==_$_c0e3[76])c.orderBy(b.column,b.direction,b.newValue);else if(b.action==
108
+ _$_c0e3[77]||b.action==_$_c0e3[78])c[b.action](b.records);else b.action==_$_c0e3[79]?c.renameWorksheet(b.index,b.newValue):b.action==_$_c0e3[80]&&c.moveWorksheet(b.f,b.t);b.selection&&c.updateSelectionFromCoords(b.selection);this.ignoreHistory=!1;F.call(this,_$_c0e3[82],c,b)}};return k}(),pa=function(){var k=function(b){var c=null;if(Array.isArray(b))c=b;else if(typeof b==_$_c0e3[83]){c=[];var a=Object.keys(b);for(var d=0;d<a.length;d++)c.push({name:a[d],plugin:b[a[d]],options:{}})}if(c&&c.length)for(d=
109
+ 0;d<c.length;d++){if(c[d].name&&c[d].plugin){var e=c[d].name;var f=c[d].plugin;var h=c[d].options}typeof f===_$_c0e3[84]&&(this.plugins[e]=f.call(t,this,h,this.config),typeof f.license==_$_c0e3[84]&&t.license&&f.license(t.license))}};k.execute=function(b,c){if(this.plugins){var a=Object.keys(this.plugins);if(a.length)for(var d=0;d<a.length;d++)if(typeof this.plugins[a[d]][b]==_$_c0e3[84]){var e=this.plugins[a[d]][b].apply(this.plugins[a[d]],c);e&&(b==_$_c0e3[85]&&(c[4]=e),b==_$_c0e3[86]&&(c[0]=e))}return c}};
110
+ k.onevent=function(b){return function(){var c,a,d=this.plugins;if(d){var e=Object.keys(d);if(e.length)for(a=0;a<e.length;a++)if(typeof d[e[a]][b]==_$_c0e3[84]){var f=d[e[a]][b].apply(d[e[a]],arguments);typeof f!==_$_c0e3[13]&&(c=f)}}return c}}(_$_c0e3[87]);return k}(),da=function(){var k=function(b){b.getEditor=k[_$_c0e3[51]];b.openEditor=k.open;b.closeEditor=k.close};k[_$_c0e3[51]]=function(b,c){b=Ha[_$_c0e3[51]].call(this,b,c);return[b.type&&typeof b.type==_$_c0e3[83]?b.type:t.editors[b.type],b]};
111
+ k.open=function(b,c,a){if(!R.call(this.parent,this))return!1;if(1!=b.classList.contains(_$_c0e3[18])){var d=parseInt(b.getAttribute(_$_c0e3[42])),e=parseInt(b.getAttribute(_$_c0e3[43]));if(!0===this.options.locked){var f=E.getColumnNameFromCoords(d,e);if(!this.options.cells||!this.options.cells[f]||!1!==this.options.cells[f].locked)return!1}if(f=this.records[e][d].merged)d-=f[0],e-=f[1],b=this.records[e][d].element;if(!L.attached.call(this,d,e)){if(this.results&&0<this.results.length)return console.error(_$_c0e3[88]),
112
+ !1;H[_$_c0e3[46]].call(this,e,d)}k.position.call(this,d,e);f=this.parent.input;f.innerText=_$_c0e3[3];F.call(this.parent,_$_c0e3[89],this,b,d,e);c=1==c?_$_c0e3[3]:M.call(this,d,e);var h=k[_$_c0e3[51]].call(this,d,e),g=!0;typeof h[0].openEditor==_$_c0e3[84]&&(!1===h[0].openEditor(b,c,d,e,this,h[1],a)?g=!1:F.call(this.parent,_$_c0e3[90],this,b,d,e,f,h[1]));g&&(1==this.options.textOverflow&&(this.records[e][d].element.style.overflow=_$_c0e3[49],0<d&&(this.records[e][d-1].element.style.overflow=_$_c0e3[49])),
113
+ this.edition=b,f.classList.add(_$_c0e3[91]),1==this.parent.config.editorFormulas&&O(c)&&(f.classList.add(_$_c0e3[92]),la.parse.call(this,f),b=document.createTextNode(_$_c0e3[3]),f.appendChild(b),jSuites.focus(f)))}};k.close=function(b,c){null===b&&(b=this.edition);this.parent.input.classList.contains(_$_c0e3[92])&&la.close.call(this,this.parent.input);var a,d=parseInt(b.getAttribute(_$_c0e3[42])),e=parseInt(b.getAttribute(_$_c0e3[43]));1==this.options.textOverflow&&(a=this.records[e][d+1])&&a.element&&
114
+ a.element.innerText==_$_c0e3[3]&&(this.records[e][d].element.style.overflow=_$_c0e3[3]);a=k[_$_c0e3[51]].call(this,d,e);if(1==c){var f=null;typeof a[0].closeEditor==_$_c0e3[84]&&(a=a[0].closeEditor(b,!0,d,e,this,a[1]),void 0!==a&&(f=a));null!==f&&M.call(this,d,e)!=f&&this.setValue(b,f)}else a[0].closeEditor(b,!1,d,e,this,a[1]);F.call(this.parent,_$_c0e3[93],this,b,d,e,f,c);a=this.parent.input;a.onblur&&(a.onblur=null);a.children[0]&&a.children[0].onblur&&(a.children[0].onblur=null);a.update&&(a.update=
115
+ null);da.build(this.parent);a.removeAttribute(_$_c0e3[94]);a.removeAttribute(_$_c0e3[95]);a.removeAttribute(_$_c0e3[96]);this.edition=a.mask=null;this.refreshBorders()};k.position=function(b,c){var a=null;if(a=this.records[c][b].element){var d=this.parent.element.getBoundingClientRect();a=a.getBoundingClientRect();var e=this.parent.input;e.x=b;e.y=c;0==a.width&&0==a.height?e.style.opacity=_$_c0e3[97]:(e.setAttribute(_$_c0e3[98],_$_c0e3[3]),b=a.top-d.top+1,c=a.left-d.left+1,e.style.top=b+_$_c0e3[44],
116
+ e.style.left=c+_$_c0e3[44],e.style.minWidth=a.width-1+_$_c0e3[44],e.style.minHeight=a.height-1+_$_c0e3[44],setTimeout(function(){e.focus()},0))}};k.build=function(b){b.input||(b.input=document.createElement(_$_c0e3[20]));b.input.className=_$_c0e3[99];b.input.setAttribute(_$_c0e3[100],!0);b.input.innerText=_$_c0e3[3];b.input.oninput=function(c){1==t.current.parent.config.editorFormulas&&(O(c.target.innerText)?c.target.classList.add(_$_c0e3[92]):c.target.classList.contains(_$_c0e3[92])&&la.close.call(t.current,
117
+ this))};return b.input};return k}(),F=function(k){var b;if(!this.ignoreEvents){if(typeof this.config.onevent==_$_c0e3[84]){var c=this.config.onevent.apply(this,arguments);typeof c!==_$_c0e3[13]&&(b=c)}typeof this.config[k]==_$_c0e3[84]&&(c=this.config[k].apply(this,Array.prototype.slice.call(arguments,1)),typeof c!==_$_c0e3[13]&&(b=c));c=pa.onevent.apply(this,arguments);typeof c!==_$_c0e3[13]&&(b=c)}return b},sa=function(){var k=function(b){b.sequence=0;b.getNextSequence=k.next;b.getRowId=k.getId;
118
+ b.setRowId=k.setId;b.getRowById=k.getRowById};k[_$_c0e3[51]]=function(){return this.sequence};k[_$_c0e3[11]]=function(b,c){if(b>this.sequence||c)this.sequence=b};k.next=function(){return 1==this.options.sequence?++this.sequence:null};k.reset=function(){this.sequence=0};k.getId=function(b){if(this.rows[b]&&this.rows[b].id)return this.rows[b].id;var c=this.getPrimaryKey();if(!1!==c)return M.call(this,c,b)};k.setId=function(b,c){if(void 0!==c&&0<=parseInt(b)){var a={};a[b]=c}else a=b;b=Object.keys(a);
119
+ if(b.length){for(var d=0;d<b.length;d++)c=a[b[d]],this.rows[b[d]].id=c,k[_$_c0e3[11]].call(this,c);K.call(this,_$_c0e3[101],[a]);F.call(this.parent,_$_c0e3[102],this,a)}};k.getRowById=function(b,c){for(var a=0;a<this.rows.length;a++)if(k.getId.call(this,a)==b)return!0===c?this.rows[a]:this.options.data[a];return!1};return k}(),Oa=function(){var k=function(c){for(var a=[],d={},e=0;e<c.length;e++){var f=c[e].x,h=c[e].y,g=sa.getId.call(this,h);if(!g)if(d[h])g=d[h];else if(g=sa.next.call(this))d[h]=g;
120
+ a[h]||(a[h]={id:g,row:h,data:{}});f=Z.call(this,f);a[h].data[f]=c[e].value}sa.setId.call(this,d);return a.filter(function(l){return null!=l})},b=function(c){var a=c[0];if(0<=[_$_c0e3[103],_$_c0e3[104],_$_c0e3[101],_$_c0e3[105]].indexOf(a))return!1;var d={};a==_$_c0e3[77]||a==_$_c0e3[106]?(a=_$_c0e3[107],d[a]=k.call(this,c[1].data)):Array.isArray(c[1])&&1==c[1].length?d[a]=c[1][0]:d[a]=c[1];return d};return function(c,a,d,e){var f=this.parent,h=this;d=null;var g=b.call(this,a);if(g)a=g;else if(!1===
121
+ g)return!1;if(g=F.call(f,_$_c0e3[108],f,h,a))a=g;else if(!1===g)return!1;La.call(f,!0);jSuites.ajax({url:c,method:_$_c0e3[109],dataType:_$_c0e3[59],data:{data:JSON.stringify(a)},queue:!0,beforeSend:function(l){d&&l.setRequestHeader(_$_c0e3[110],_$_c0e3[111]+d)},success:function(l){f.element.classList.contains(_$_c0e3[112])&&f.element.classList.remove(_$_c0e3[112]);l&&(l.message&&(l.name=f.config.application,jSuites.notification.isVisible()?console.log(l.name+_$_c0e3[113]+l.message):jSuites.notification(l)),
122
+ l.success?typeof e===_$_c0e3[84]?e(l):l.data&&Array.isArray(l.data)&&L.updateAll.call(h,l.data):l.error&&(alert(_$_c0e3[114]),window.open(window.location.href,_$_c0e3[115])));F.call(f,_$_c0e3[116],f,h,a,l)},error:function(){f.element.classList.add(_$_c0e3[112])}})}}(),K=function(){return function(){pa.execute.call(this.parent,_$_c0e3[117],[this,arguments[0],arguments[1]]);if(!this.parent.ignorePersistence){var k=null;if(this.parent.config.server){var b=this.parent.worksheets.indexOf(this);k=this.parent.config.server;
123
+ k=-1==k.indexOf(_$_c0e3[118])?k+(_$_c0e3[119]+b):k+(_$_c0e3[120]+b)}else this.options.persistence&&(k=typeof this.options.persistence==_$_c0e3[17]?this.options.persistence:this.options.url);k&&Oa.call(this,k,arguments)}}}(),Ea=function(k){if(this.selectedCell){var b=this.selectedCell[0],c=this.selectedCell[1];this.records&&this.records[c]&&this.records[c][b]&&this.records[c][b].element||(this.selectedCell=this.getHighlighted(),b=this.selectedCell[0],c=this.selectedCell[1]);var a=this.getHighlighted(),
124
+ d=a[0],e=a[1],f=a[2];a=a[3];var h=k?_$_c0e3[121]:_$_c0e3[122];this.records[c]&&this.records[c][b]&&this.records[c][b].element&&(this.records[c][b].element.classList[h](_$_c0e3[123]),this.cursor=k?this.records[c][b].element:null);for(k=d;k<=f;k++)if(this.headers[k])this.headers[k].classList[h](_$_c0e3[124]);for(;e<=a;e++)if(this.rows[e]&&this.rows[e].element)this.rows[e].element.classList[h](_$_c0e3[124])}},ya=function(){var k=function(b){b.resetSelection=k.reset;b.updateSelection=k.fromElements;b.updateSelectionFromCoords=
125
+ k[_$_c0e3[11]];b.selectAll=k.all;b.isSelected=k.isSelected;b.getHighlighted=k.getHighlighted;b.getRange=k.getRange};k.getHighlighted=function(){var b=this.borders;return(b=b.main)?[b.x1,b.y1,b.x2,b.y2]:null};k.isSelected=function(b,c,a){if(!a&&(a=this.getHighlighted(),!a))return!1;var d=a[0],e=a[1],f=a[2];a=a[3];f||(f=d);a||(a=e);return null==b?c>=e&&c<=a:null==c?b>=d&&b<=f:b>=d&&b<=f&&c>=e&&c<=a};k.reset=function(){if(this.selectedCell)b=1,this.edition&&da.close.call(this,this.edition,!0),this.resetBorders(_$_c0e3[125],
126
+ !0),this.resetBorders(_$_c0e3[126],!0),this.selectedCell=null,1==b&&F.call(this.parent,_$_c0e3[127],this);else var b=0;return b};k.refresh=function(){this.selectedCell&&k[_$_c0e3[11]].call(this,this.selectedCell)};k.isValid=function(b,c,a,d){return!(b>=this.options.columns.length||c>=this.rows.length||a>=this.options.columns.length||d>=this.rows.length)};k[_$_c0e3[11]]=function(b,c,a,d,e,f,h){f||(f=_$_c0e3[125]);Array.isArray(b)&&(d=b[3],a=b[2],c=b[1],b=b[0]);null==a&&(a=b);null==d&&(d=c);if(!k.isValid.call(this,
127
+ b,c,a,d))return!1;if(null!=b){if(parseInt(b)<parseInt(a))var g=parseInt(b),l=parseInt(a);else g=parseInt(a),l=parseInt(b);if(parseInt(c)<parseInt(d))var m=parseInt(c),p=parseInt(d);else m=parseInt(d),p=parseInt(c);var n;var q={};if(this.options.mergeCells){for(var v=m;v<=p;v++)for(var u=g;u<=l;u++)if(n=this.records[v][u].merged)n=E.getColumnNameFromCoords(u-n[0],v-n[1]),q[n]=!0;v=Object.keys(q);if(v.length)for(u=0;u<v.length;u++)n=E.getCoordsFromColumnName(v[u]),q=this.options.mergeCells[v[u]],n[0]<
128
+ g&&(g=n[0]),n[0]+q[0]-1>l&&(l=n[0]+q[0]-1),n[1]<m&&(m=n[1]),n[1]+q[1]-1>p&&(p=n[1]+q[1]-1)}}f==_$_c0e3[125]&&(this.selectedCell?(Ea.call(this,!1),n=1):n=0,this.selectedCell=[b,c,a,d],this.records[d][a].element&&H.isVisible.call(this,this.records[d][a].element),da.position.call(this,b,c),0==n&&F.call(this.parent,_$_c0e3[128],this));ha[_$_c0e3[11]].call(this,g,m,l,p,f,h);f==_$_c0e3[125]&&(F.call(this.parent,_$_c0e3[129],this,g,m,l,p,e),fa.update.call(this.parent,t.current,this.selectedCell))};k.fromElements=
129
+ function(b,c,a){var d=b.getAttribute(_$_c0e3[42]);b=b.getAttribute(_$_c0e3[43]);if(c){var e=c.getAttribute(_$_c0e3[42]);c=c.getAttribute(_$_c0e3[43])}else e=d,c=b;this.updateSelectionFromCoords(d,b,e,c,a)};k.all=function(){k[_$_c0e3[11]].call(this,0,0,this.options.columns.length-1,this.records.length-1)};k.getRange=function(){var b=this.selectedCell;if(!b)return _$_c0e3[3];var c=E.getColumnNameFromCoords(b[0],b[1]);b=E.getColumnNameFromCoords(b[2],b[3]);var a=this.options.worksheetName;a=-1!=a.indexOf(_$_c0e3[130])?
130
+ _$_c0e3[131]+a+_$_c0e3[132]:a+_$_c0e3[133];return c==b?a+c:a+t.helpers.getRangeFromTokens(t.helpers.getTokensFromRange(c+_$_c0e3[134]+b))};return k}(),ha=function(){var k=function(a){a.borders=[];a.setBorder=k[_$_c0e3[11]];a.getBorder=k[_$_c0e3[51]];a.resetBorders=k.reset;a.refreshBorders=k.refresh};k[_$_c0e3[51]]=function(a){return this.borders[a]};var b=function(a,d,e,f,h,g){h||(h=0);if(!ya.isValid.call(this,a,d,e,f))return!1;if(this.borders[h])l=this.borders[h];else{var l={};l.element=document.createElement(_$_c0e3[20]);
131
+ l.element.classList.add(_$_c0e3[135]);h==_$_c0e3[126]||h==_$_c0e3[136]||h==_$_c0e3[125]?l.element.classList.add(_$_c0e3[137]+h):(g=g?g:jSuites.randomColor(!0),l.color=g,l.element.style.backgroundColor=g+_$_c0e3[138],l.element.style.borderColor=g);this.content.appendChild(l.element)}l.x1=a;l.y1=d;l.x2=e;l.y2=f;g=this.headers[a]?this.headers[a].offsetLeft:0;var m=this.headers[e]?this.headers[e].offsetLeft:0,p=this.rows[d].element?this.rows[d].element.offsetTop:0,n=this.rows[f].element?this.rows[f].element.offsetTop:
132
+ 0;l.element.style.top=_$_c0e3[139];l.element.style.left=_$_c0e3[139];l.active=0;var q=this.options.freezeColumns||0,v=!1,u=null,y=null,w=null,C=null;this.tbody.firstChild&&(y=parseInt(this.tbody.firstChild.getAttribute(_$_c0e3[43])),C=parseInt(this.tbody.lastChild.getAttribute(_$_c0e3[43])));this.thead.lastChild&&(u=parseInt(this.thead.lastChild.children[q+1].getAttribute(_$_c0e3[42])),w=parseInt(this.thead.lastChild.lastChild.getAttribute(_$_c0e3[42])),this.thead.lastChild.children[1].style.display==
133
+ _$_c0e3[40]&&(u=Ma.call(this,u,y)),this.thead.lastChild.lastChild.style.display==_$_c0e3[40]&&(w=Na.call(this,w,C)));null==u||e<u&&a>=q||a>w||f<y||d>C||(g?l.element.style.borderLeftColor=l.color?l.color:_$_c0e3[3]:(g=this.thead.lastChild.children[q+1].offsetLeft,l.element.style.borderLeftColor=h==_$_c0e3[126]?_$_c0e3[140]:_$_c0e3[141]),m?(m+=this.headers[e].offsetWidth,l.element.style.borderRightColor=l.color?l.color:_$_c0e3[3]):(e>w?(m=this.headers[w].offsetLeft+this.headers[w].offsetWidth,v=!0):
134
+ m=this.thead.lastChild.children[q].offsetLeft+this.thead.lastChild.children[q].offsetWidth,l.element.style.borderRightColor=h==_$_c0e3[126]?_$_c0e3[140]:_$_c0e3[141]),m=m-g-1,p?l.element.style.borderTopColor=l.color?l.color:_$_c0e3[3]:(p=this.tbody.firstChild.offsetTop,l.element.style.borderTopColor=h==_$_c0e3[126]?_$_c0e3[140]:_$_c0e3[141]),n?(n+=this.rows[f].element.offsetHeight,l.element.style.borderBottomColor=l.color?l.color:_$_c0e3[3]):(n=this.rows[C].element.offsetTop+this.rows[C].element.offsetHeight,
135
+ l.element.style.borderBottomColor=h==_$_c0e3[126]?_$_c0e3[140]:_$_c0e3[141],v=!0),n=n-p-1,this.options.freezeColumns&&(l.element.style.borderLeftWidth=_$_c0e3[3],l.element.style.borderRightWidth=_$_c0e3[3],d=0<this.content.scrollLeft?ka.getWidth.call(this):0)&&(a=a<this.options.freezeColumns,e=e<this.options.freezeColumns,a&&e||!a&&e||(a&&!e?(e=d+this.content.scrollLeft,e>g+m&&(l.element.style.borderRightWidth=_$_c0e3[142],m+=e-(g+m))):(e=d+this.content.scrollLeft,e>g&&(e-=g,e>m?g=p=-2E3:(g=g+e+1,
136
+ m-=e,l.element.style.borderLeftWidth=_$_c0e3[142]))))),l.element.style.top=p+_$_c0e3[44],l.element.style.left=g+_$_c0e3[44],l.element.style.width=m+_$_c0e3[44],l.element.style.height=n+_$_c0e3[44],l.t=p,l.l=g,l.w=m,l.h=n,l.active=1);h==_$_c0e3[125]&&(l.active&&1!=v?(this.corner.style.top=p+n-2+_$_c0e3[44],this.corner.style.left=g+m-2+_$_c0e3[44]):(this.corner.style.top=_$_c0e3[139],this.corner.style.left=_$_c0e3[139]));this.borders[h]=l},c=function(a,d){a.element.style.top=_$_c0e3[139];a.element.style.left=
137
+ _$_c0e3[139];a.active=0;d&&(a.x1=null,a.y1=null,a.x2=null,a.y2=null)};k[_$_c0e3[11]]=function(a,d,e,f,h,g){b.call(this,a,d,e,f,h,g);h==_$_c0e3[125]&&(Ea.call(this,!0),K.call(this,_$_c0e3[103],{x1:a,y1:d,x2:e,y2:f}))};k.reset=function(a,d){a&&a!=_$_c0e3[125]||(this.corner.style.top=_$_c0e3[139],this.corner.style.left=_$_c0e3[139],Ea.call(this,!1));if(a)this.borders[a]&&c(this.borders[a],d);else{d=Object.keys(this.borders);for(var e=0;e<d.length;e++)c(this.borders[d[e]])}a&&a!=_$_c0e3[125]||K.call(this,
138
+ _$_c0e3[104])};k.refresh=function(a){var d=this.borders;if(a)d[a]&&null!=d[a].x1&&b.call(this,d[a].x1,d[a].y1,d[a].x2,d[a].y2,a);else{a=Object.keys(d);for(var e=0;e<a.length;e++)d[a[e]]&&null!=d[a[e]].x1&&b.call(this,d[a[e]].x1,d[a[e]].y1,d[a[e]].x2,d[a[e]].y2,a[e])}this.edition&&(d=this.parent.input,da.position.call(this,d.x,d.y))};k.destroy=function(a){var d;if(d=this.borders[a])d.element.remove(),delete this.borders[a]};return k}(),Va=function(){var k=function(b){b.setGroup=k[_$_c0e3[11]];b.unsetGroup=
139
+ k.unset};k[_$_c0e3[11]]=function(b,c,a){0==b&&(a=document.createElement(_$_c0e3[143]),a.classList.add(_$_c0e3[144]),this.thead.insertBefore(a,this.thead.firstChild),b=document.createElement(_$_c0e3[145]),b.innerHTML=_$_c0e3[146],a.appendChild(b),b=document.createElement(_$_c0e3[145]),a.appendChild(b),c=this.headers[c])&&(c=c.querySelector(_$_c0e3[147]),c||(c=document.createElement(_$_c0e3[20]),c.classList.add(_$_c0e3[148]),c.innerText=_$_c0e3[149],b.appendChild(c)))};k.unset=function(b,c){};return k}(),
140
+ va=function(){var k={start:function(b){if(!R.call(this.parent,this))return!1;if(null!==b.target.getAttribute(_$_c0e3[43])){var c=b.target.getAttribute(_$_c0e3[43]);k.event={y:parseInt(c),h:b.target.offsetHeight,p:b.pageY}}else null!==b.target.getAttribute(_$_c0e3[42])&&(c=b.target.getAttribute(_$_c0e3[42]),k.event={x:parseInt(c),w:b.target.offsetWidth,p:b.pageX})},end:function(b){var c=[];if(null!=k.event.y){var a=parseInt(this.rows[k.event.y].element.offsetHeight);var d=this.getSelectedRows(!0);
141
+ b=d.indexOf(parseInt(k.event.y));if(d.length&&-1<b)for(var e=0;e<d.length;e++)c.push(parseInt(this.rows[d[e]].element.offsetHeight));else d=[];-1==b?(d.push(k.event.y),c.push(k.event.h)):c[b]=k.event.h;this.setHeight(d,a,c)}else if(null!=k.event.x){a=parseInt(this.colgroup[k.event.x].getAttribute(_$_c0e3[150]));d=this.getSelectedColumns();b=d.indexOf(parseInt(k.event.x));if(d.length&&-1<b)for(e=0;e<d.length;e++)c.push(parseInt(this.options.columns[d[e]].width));else d=[];-1==b?(d.push(k.event.x),
142
+ c.push(k.event.w)):c[b]=k.event.w;this.setWidth(d,a,c)}k.event=null},update:function(b){null!=k.event.y?(b=b.pageY-k.event.p,0<k.event.h+b&&(this.rows[k.event.y].element.style.height=k.event.h+b+_$_c0e3[44],this.refreshBorders())):null!=k.event.x&&(b=b.pageX-k.event.p,0<k.event.w+b&&(this.colgroup[k.event.x].setAttribute(_$_c0e3[150],k.event.w+b),this.options.columns[k.event.x].width=k.event.w+b,0<this.options.freezeColumns&&ka.width.call(this),this.refreshBorders()))},cancel:function(){k.end.call(this)}};
143
+ return k}(),Pa=function(){var k={start:function(b){var c=this.parent.helper;b=parseInt(b.target.getAttribute(_$_c0e3[42]));if(this.merged.cols[b])console.error(_$_c0e3[151]);else{k.event={x:b,d:b};this.headers[b].classList.add(_$_c0e3[152]);for(var a=0;a<this.tbody.children.length;a++){var d=this.tbody.children[a].getAttribute(_$_c0e3[43]);this.records[d][b].element.classList.add(_$_c0e3[152])}a=this.parent.element.getBoundingClientRect();b=this.headers[b].getBoundingClientRect();d=this.content.getBoundingClientRect();
144
+ c.style.display=_$_c0e3[16];c.style.top=d.top-a.top+_$_c0e3[44];c.style.left=b.left-d.left+_$_c0e3[44];c.style.width=_$_c0e3[153];c.style.height=d.height+_$_c0e3[44];c.classList.add(_$_c0e3[154])}},end:function(){this.headers[k.event.x].classList.remove(_$_c0e3[152]);for(var b=0;b<this.tbody.children.length;b++){var c=this.tbody.children[b].getAttribute(_$_c0e3[43]);this.records[c][k.event.x].element.classList.remove(_$_c0e3[152])}null!=k.event.d&&k.event.x!=k.event.d&&(this.moveColumn(k.event.x,
145
+ k.event.d),this.refreshBorders());this.parent.helper.classList.remove(_$_c0e3[154]);this.parent.helper.style.display=_$_c0e3[3];k.event=null},cancel:function(){k.event.d=null;k.end.call(this)},update:function(b){var c=b.target.getAttribute(_$_c0e3[42]);if(null!=c)if(c=parseInt(c),this.merged.cols[c])console.error(_$_c0e3[151]);else{b=b.target.clientWidth/2>b.offsetX;k.event.d=b?k.event.x<c?parseInt(c)-1:parseInt(c):k.event.x>c?parseInt(c)+1:parseInt(c);c=this.headers[c].getBoundingClientRect();var a=
146
+ this.content.getBoundingClientRect();this.parent.helper.style.left=(b?c.left:c.right)-a.left+_$_c0e3[44]}}};return k}(),ra=function(){var k={start:function(b){if(R.call(this.parent,this)){this.resetSelection();var c=this.parent.helper;if(null!==b.target.getAttribute(_$_c0e3[43])){var a=parseInt(b.target.getAttribute(_$_c0e3[43]));this.merged.rows[a]?console.error(_$_c0e3[155]):this.results?console.error(_$_c0e3[156]):(k.event={y:a,d:a},this.rows[a].element.classList.add(_$_c0e3[152]),b=this.parent.element.getBoundingClientRect(),
147
+ a=this.rows[a].element.getBoundingClientRect(),c.style.display=_$_c0e3[16],c.style.top=a.top-b.top+_$_c0e3[44],c.style.left=_$_c0e3[157],c.style.width=this.content.offsetWidth-50+_$_c0e3[44],c.style.height=_$_c0e3[153],c.classList.add(_$_c0e3[158]))}else if(null!==b.target.getAttribute(_$_c0e3[42]))if(a=parseInt(b.target.getAttribute(_$_c0e3[42])),this.merged.cols[a])console.error(_$_c0e3[151]);else{k.event={x:a,d:a};this.headers[a].classList.add(_$_c0e3[152]);for(b=0;b<this.tbody.children.length;b++){var d=
148
+ this.tbody.children[b].getAttribute(_$_c0e3[43]);this.records[d][a].element.classList.add(_$_c0e3[152])}b=this.parent.element.getBoundingClientRect();a=this.headers[a].getBoundingClientRect();d=this.content.getBoundingClientRect();c.style.display=_$_c0e3[16];c.style.top=d.top-b.top+_$_c0e3[44];c.style.left=a.left-d.left+_$_c0e3[44];c.style.width=_$_c0e3[153];c.style.height=d.height+_$_c0e3[44];c.classList.add(_$_c0e3[154])}}else return!1},end:function(){if(null!=k.event.y)this.rows[k.event.y].element.classList.remove(_$_c0e3[152]),
149
+ null!=k.event.d&&k.event.y!=k.event.d&&(this.moveRow(k.event.y,k.event.d),this.updateSelectionFromCoords(0,k.event.d,this.options.columns.length-1,k.event.d)),this.parent.helper.classList.remove(_$_c0e3[158]);else if(null!=k.event.x){this.headers[k.event.x].classList.remove(_$_c0e3[152]);for(var b=0;b<this.tbody.children.length;b++){var c=this.tbody.children[b].getAttribute(_$_c0e3[43]);this.records[c][k.event.x].element.classList.remove(_$_c0e3[152])}null!=k.event.d&&k.event.x!=k.event.d&&(this.moveColumn(k.event.x,
150
+ k.event.d),this.refreshBorders());this.parent.helper.classList.remove(_$_c0e3[154])}this.parent.helper.style.display=_$_c0e3[3];k.event=null},cancel:function(){k.event.d=null;k.end.call(this)},update:function(b){if(null!=k.event.y){var c=b.target.getAttribute(_$_c0e3[43]);if(null!=c){var a=c=parseInt(c),d=b.target.clientHeight/2>b.offsetY;d?k.event.y<c&&(a=c-1):k.event.y>c&&(a=c+1);b=!1;this.merged.rows[a]&&(k.event.y>a?this.merged.rows[a-1]&&(b=!0):this.merged.rows[a+1]&&(b=!0));b||(k.event.d=a,
151
+ a=this.parent.element.getBoundingClientRect(),c=this.rows[c].element.getBoundingClientRect(),this.parent.helper.style.top=(d?c.top:c.bottom)-a.top+_$_c0e3[44])}}else d=b.target.getAttribute(_$_c0e3[42]),null!=d&&(a=d=parseInt(d),(c=b.target.clientWidth/2>b.offsetX)?k.event.x<d&&(a=d-1):k.event.x>d&&(a=d+1),b=!1,this.merged.cols[a]&&(k.event.x>a?this.merged.cols[a-1]&&(b=!0):this.merged.cols[a+1]&&(b=!0)),b||(k.event.d=a,a=this.headers[d].getBoundingClientRect(),d=this.content.getBoundingClientRect(),
152
+ this.parent.helper.style.left=(c?a.left:a.right)-d.left+_$_c0e3[44]))}};return k}(),ba=function(){var k=function(b){b.getMerge=k[_$_c0e3[51]];b.setMerge=k[_$_c0e3[11]];b.updateMerge=k.update;b.removeMerge=k.remove;b.destroyMerged=b.destroyMerge=k.destroy};k.getHeight=function(b,c){var a,d=1;if(this.merged.rows[b])for(var e=0;e<this.options.columns.length;e++){var f=E.getColumnNameFromCoords(e,b);if(f=this.merged.cells[f])if(a=this.options.mergeCells[f])c&&void 0!==c[f]||(a[1]>d&&(d=a[1]),c&&(c[f]=
153
+ this.records[b][e].element&&!this.records[b][e].merged?!0:!1))}return d-1};k.getWidth=function(b,c){var a,d=1;if(this.merged.cols[b])for(var e=0;e<this.options.data.length;e++){var f=E.getColumnNameFromCoords(b,e);if(f=this.merged.cells[f])if(a=this.options.mergeCells[f])c&&void 0!==c[f]||(a[0]>d&&(d=a[0]),c&&(c[f]=this.records[e][b].element&&!this.records[e][b].merged?!0:!1))}return d-1};k[_$_c0e3[51]]=function(b){return b?this.options.mergeCells[b]:this.options.mergeCells};k[_$_c0e3[11]]=function(b,
154
+ c,a){if(!R.call(this.parent,this))return!1;this.options.mergeCells||(this.options.mergeCells={});var d,e=null,f={},h={},g={},l=!1;typeof b==_$_c0e3[17]?g[b]=[c,a]:typeof b==_$_c0e3[83]?g=b:((e=this.getHighlighted())?e=[E.getColumnNameFromCoords(e[0],e[1]),e[2]-e[0]+1,e[3]-e[1]+1]:(jSuites.notification({message:B(_$_c0e3[159])}),e=!1),e&&(g[e[0]]=[e[1],e[2]]));c=Object.keys(g);if(c.length){for(a=0;a<c.length;a++){var m=c[a],p=g[c[a]][0],n=g[c[a]][1];p=parseInt(p);n=parseInt(n);if((!p||2>p)&&(!n||2>
155
+ n))console.log(B(_$_c0e3[160])+_$_c0e3[134]+m);else if(this.options.mergeCells[m])h[m]=[p,n],f[m]=this.options.mergeCells[m],k.update.call(this,m,p,n);else{e=E.getCoordsFromColumnName(m);for(var q=e[1];q<e[1]+n;q++)for(var v=e[0];v<e[0]+p;v++)b=E.getColumnNameFromCoords(v,q),(d=this.merged.cells[b])&&this.options.mergeCells[d]&&(f[d]=this.options.mergeCells[d],k.applyDestroy.call(this,d));h[m]=this.options.mergeCells[m]=[p,n];k.applyCreate.call(this,m);L.attached.call(this,e[0],e[1])||(l=e)}}Object.keys(h).length&&
156
+ (l&&H[_$_c0e3[46]].call(this,e[1],e[0]),V.call(this.parent,{worksheet:this,action:_$_c0e3[68],newValue:h,oldValue:f}),K.call(this,_$_c0e3[68],[h]),k.build.call(this),ya.refresh.call(this),ha.refresh.call(this),F.call(this.parent,_$_c0e3[161],this,h,f))}};k.update=function(b,c,a){var d=this.options.mergeCells;if(d[b]){var e=d[b][1];if(c!==d[b][0]||e!==a)k.applyDestroy.call(this,b),c&&a&&(d[b]=[c,a],k.applyCreate.call(this,b))}};k.remove=function(b,c){if(!R.call(this.parent,this))return!1;c={};var a=
157
+ {},d={};typeof b==_$_c0e3[17]?d[b]=!0:typeof b==_$_c0e3[83]&&(d=b);b=Object.keys(d);for(d=0;d<b.length;d++)this.options.mergeCells[b[d]]&&(c[b[d]]=this.options.mergeCells[b[d]],a[b[d]]=!0,k.applyDestroy.call(this,b[d],!0));V.call(this.parent,{worksheet:this,action:_$_c0e3[69],newValue:a,oldValue:c});K.call(this,_$_c0e3[69],{data:a})};k.destroy=function(){k.remove.call(this,this.options.mergeCells,!0)};k.applyCreate=function(b,c){var a=this.options.mergeCells;if(a[b]){var d=a[b][0]||1,e=a[b][1]||1;
158
+ b=E.getCoordsFromColumnName(b);if(!this.records[b[1]][b[0]].merged||1==c)if(a=L[_$_c0e3[51]].call(this,b[0],b[1])){a.style.display=_$_c0e3[3];1<d?a.setAttribute(_$_c0e3[52],d):a.removeAttribute(_$_c0e3[52]);1<e?a.setAttribute(_$_c0e3[162],e):a.removeAttribute(_$_c0e3[162]);1==this.options.textOverflow&&(a.style.overflow=_$_c0e3[49]);for(var f=0;f<e;f++)for(var h=0;h<d;h++){c=b[0]+h;var g=b[1]+f;if(a=this.records[g][c])if(a.merged=[h,f,a.v,a.v],0!=h||0!=f)a.element||L[_$_c0e3[51]].call(this,c,g),a.element.style.display=
159
+ _$_c0e3[40],a.merged[3]=a.element.innerText,a.element.innerText=_$_c0e3[3],M.call(this,c,g,_$_c0e3[3])}}}};k.applyDestroy=function(b,c){var a=this.options.mergeCells;if(a[b]){var d=E.getCoordsFromColumnName(b),e=d[0];d=d[1];var f=a[b][0],h=a[b][1];delete this.options.mergeCells[b];for(b=0;b<h;b++)for(var g=0;g<f;g++)if(a=this.records[d+b][e+g])a.element&&(0==g&&0==b?(a.element.removeAttribute(_$_c0e3[52]),a.element.removeAttribute(_$_c0e3[162])):(a.element.style.display=_$_c0e3[3],1==c&&(M.call(this,
160
+ e+g,d+b,a.merged[2]),a.element.innerHTML=a.merged[3]))),a.merged&&delete a.merged}};k.updateConfig=function(b,c,a,d){if(1==c)var e=[a];else{e=[];for(var f=a;f<a+d;f++)e.push(f)}var h=this.options.mergeCells,g=Object.keys(h),l={};for(f=0;f<g.length;f++){a=E.getCoordsFromColumnName(g[f]);for(var m=a[b];m<a[b]+h[g[f]][b];m++)-1!==e.indexOf(m)&&(l[g[f]]||(l[g[f]]=[h[g[f]][0],h[g[f]][1]],1==c&&(l[g[f]][b]+=d)),0==c&&l[g[f]][b]--)}g=Object.keys(l);for(f=0;f<g.length;f++)k.update.call(this,g[f],l[g[f]][0],
161
+ l[g[f]][1]);k.build.call(this)};k.build=function(){var b=this.options.mergeCells;this.merged={cols:[],rows:[],cells:[]};if(b)for(var c=Object.keys(b),a=0;a<c.length;a++){for(var d=E.getCoordsFromColumnName(c[a]),e=parseInt(b[c[a]][0]),f=parseInt(b[c[a]][1]),h=0;h<e;h++)this.merged.cols[d[0]+h]=!0;for(var g=0;g<f;g++)this.merged.rows[d[1]+g]=!0;for(g=0;g<f;g++)for(h=0;h<e;h++){var l=E.getColumnNameFromCoords(d[0]+h,d[1]+g);this.merged.cells[l]=c[a]}}};k.batch=function(b){var c=Object.keys(b);if(c.length)for(var a=
162
+ 0;a<c.length;a++)!1===b[c[a]]&&k.applyCreate.call(this,c[a])};return k}(),Ca=function(){var k=function(b){b.getHeader=k[_$_c0e3[51]];b.setHeader=k[_$_c0e3[11]];b.getHeaders=k.all};k[_$_c0e3[51]]=function(b){var c;if(c=this.options.columns)return c[b].title||E.getColumnName(b)};k.all=function(b){for(var c=[],a=0;a<this.options.columns.length;a++)c.push(k[_$_c0e3[51]].call(this,a));return b?c:c.join(this.options.csvDelimiter)};k[_$_c0e3[11]]=function(b,c){if(!R.call(this.parent,this))return!1;var a;
163
+ if(a=this.options.columns[b]){var d=k[_$_c0e3[51]].call(this,b);if(!c&&(c=prompt(B(_$_c0e3[163]),d),!c))return!1;a.title=c;if(a=this.headers[b])a.innerHTML=c,a.setAttribute(_$_c0e3[164],c);V.call(this.parent,{worksheet:this,action:_$_c0e3[74],column:b,oldValue:d,newValue:c});K.call(this,_$_c0e3[74],{column:b,title:c});F.call(this.parent,_$_c0e3[165],this,b,c,d)}};k.create=function(b){var c=this.options.columns[b],a=c.width||this.options.defaultColWidth,d=c.title||E.getColumnName(b),e=document.createElement(_$_c0e3[145]);
164
+ this.parent.config.stripHTML?e.innerText=d:e.innerHTML=d;e.setAttribute(_$_c0e3[42],b);c.align&&(e.style.textAlign=c.align);c.title&&e.setAttribute(_$_c0e3[164],e.innerText);c.tooltip&&(e.title=c.tooltip);d=this.options.filters;!0===c.filter&&(d=!0);!1===c.filter&&(d=!1);!0===d&&e.classList.add(_$_c0e3[166]);!1===c.visible&&(a=_$_c0e3[97]);d=document.createElement(_$_c0e3[167]);d.setAttribute(_$_c0e3[150],a);c.type==_$_c0e3[49]&&(e.style.display=_$_c0e3[40],d.style.display=_$_c0e3[40]);this.headers[b]=
165
+ e;this.colgroup[b]=d};return k}(),aa=function(){var k=function(c,a,d){var e=this.footers.content,f;e&&e[a]&&e[a][c]&&(f=e[a][c].element)&&(void 0===d&&(e=this.options.footers,d=e[a]&&e[a][c]?e[a][c]:_$_c0e3[3]),O(d)&&1==this.parent.config.parseFormulas&&(d=W.execute.call(this,d,c,null,!1)),this.options.applyMaskOnFooters&&(e=da[_$_c0e3[51]].call(this,c),d=t.editors.general.parseValue(c,a,d,this,e[1],f)),d instanceof Element||d instanceof HTMLDocument?(f.innerHTML=_$_c0e3[3],f.appendChild(d)):1==this.parent.config.stripHTML?
166
+ f.innerText=d:f.innerHTML=d)},b=function(c){c.getFooter=b[_$_c0e3[51]];c.setFooter=b[_$_c0e3[11]];c.resetFooter=b.reset;c.refreshFooter=b.refresh;c.getFooterValue=b.value;c.setFooterValue=b.value};b[_$_c0e3[51]]=function(){return this.options.footers};b[_$_c0e3[11]]=function(c){if(c){var a=this.options.footers;this.options.footers=c}this.options.footers!=a&&(aa.build.call(this),b.render.call(this),H.limited.call(this)&&(this.scrollY.style.display=_$_c0e3[40],H.resetY.call(this)),K.call(this,_$_c0e3[168],
167
+ {data:this.options.footers}),F.call(this.parent,_$_c0e3[169],this,this.options.footers,a))};b.refresh=function(){var c=this.options.footers;if(c&&c.length)for(var a=0;a<c.length;a++)for(var d=0;d<c[a].length;d++)k.call(this,d,a,c[a][d])};b.value=function(c,a,d){if(void 0===d)return this.options.footers[a][c];k.call(this,c,a,d);K.call(this,_$_c0e3[170],{x:c,y:a,value:d});F.call(this.parent,_$_c0e3[171],this,c,a,d)};b.reset=function(){var c=this.options.footers;this.options.footers=null;this.footers.content=
168
+ null;this.tfoot.innerHTML=_$_c0e3[3];K.call(this,_$_c0e3[172],{});F.call(this.parent,_$_c0e3[169],this,null,c)};b.create=function(c,a){var d=this.footers.content[a][c];if(d&&d.element)return d.element;d=this.footers.content[a][c]={};var e=this.options.columns[c].align;d.element=document.createElement(_$_c0e3[145]);d.element.setAttribute(_$_c0e3[42],c);d.element.setAttribute(_$_c0e3[43],a);e&&(d.element.style.textAlign=e);k.call(this,c,a);this.options.columns[c].type==_$_c0e3[49]&&(d.element.style.display=
169
+ _$_c0e3[40]);return d.element};b.build=function(){this.footers={element:this.tfoot,content:[]};if(this.options.footers){this.tfoot.innerHTML=_$_c0e3[3];for(var c=0;c<this.options.footers.length;c++){if(!this.footers.content[c]){this.footers.content[c]=[];var a=document.createElement(_$_c0e3[143]),d=document.createElement(_$_c0e3[145]);d.innerHTML=_$_c0e3[146];a.appendChild(d);this.footers.element.appendChild(a)}for(a=0;a<this.options.columns.length;a++)this.options.footers[c][a]||(this.options.footers[c][a]=
170
+ _$_c0e3[3]),this.footers.content[c][a]||(this.footers.content[c][a]={})}}};b.render=function(){for(var c=this.options.footers,a=0;a<c.length;a++)for(var d=0;d<c[a].length;d++){var e=aa.create.call(this,d,a);this.tfoot.children[a].appendChild(e)}};b.adjust=function(c,a,d){var e=[],f=this.options.footers,h=this.footers.content;if(f)if(1==d){if(this.headers[c]&&this.headers[c].parentNode)var g=this.headers[c]==this.thead.lastChild.lastChild?!0:!1,l=!0;for(d=0;d<f.length;d++){for(var m=f[d].splice(c),
171
+ p=c;p<c+a;p++)f[d][p]=_$_c0e3[3];f[d]=f[d].concat(m);m=h[d].splice(c);for(p=c;p<c+a;p++)h[d][p]={element:b.create.call(this,p,d)},l&&(1==g?this.tfoot.children[d].appendChild(h[d][p].element):this.tfoot.children[d].insertBefore(h[d][p].element,this.tfoot.children[d].children[c].nextSibling));h[d]=h[d].concat(m)}}else for(d=0;d<f.length;d++){for(p=c;p<c+a;p++)(g=this.footers.content[d][p].element)&&g.parentNode&&g.parentNode.removeChild(g);h[d].splice(c,a);e[d]=f[d].splice(c,a)}return e};return b}(),
172
+ oa=function(){var k=function(b){b.setNestedCell=k.cell;b.getNestedCell=k.cell;b.setNestedHeaders=k[_$_c0e3[11]];b.getNestedHeaders=k[_$_c0e3[51]];b.resetNestedHeaders=k.reset};k[_$_c0e3[51]]=function(){return this.options.nestedHeaders};k[_$_c0e3[11]]=function(b){k.reset.call(this);this.options.nestedHeaders=b;k.build.call(this);k.render.call(this);ha.refresh.call(this);U.call(this);K.call(this,_$_c0e3[173],{data:b});F.call(this.parent,_$_c0e3[174],this,b)};k.reset=function(){var b=[],c=this.thead.children;
173
+ this.options.nestedHeaders=null;for(var a=0;a<c.length;a++)c[a].classList.contains(_$_c0e3[175])&&b.push(c[a]);if(b.length)for(;c=b.shift();)c.remove();this.nested=null;ha.refresh.call(this);U.call(this);K.call(this,_$_c0e3[176]);F.call(this.parent,_$_c0e3[174],this,[])};k.cell=function(b,c,a){if(a){if(!R.call(this.parent,this))return!1;var d=this.options.nestedHeaders[c][b],e=this.nested.content[c][b].element;void 0!==a.title&&(e.innerText=a.title);void 0!==a.tooltip&&(e.title=a.tooltip);void 0!==
174
+ a.colspan&&(d.colspan=a.colspan,e.setAttribute(_$_c0e3[52],a.colspan),e.style.display=0==d.colspan?_$_c0e3[40]:_$_c0e3[3]);K.call(this,_$_c0e3[177],{x:b,y:c,properties:a});F.call(this.parent,_$_c0e3[178],this,b,c,a)}else return this.nested.content[c][b].element};k.range=function(b){b=this.options.nestedHeaders[b];for(var c=[],a=0,d=0;d<b.length;d++){var e=parseInt(b[d].colspan);c[d]=[a,a+e-1];a+=e}return c};k.getColumns=function(b){b=this.options.nestedHeaders[b];for(var c=[],a=0;a<b.length;a++)for(var d=
175
+ b[a].colspan,e=0;e<d;e++)c.push(a);return c};k.create=function(b,c){if(this.nested.content[c][b])return this.nested.content[c][b].element;var a=this.options.nestedHeaders[c][b]||{},d=this.nested.content[c][b]={};a.colspan||(a.colspan=1);a.align||(a.align=_$_c0e3[179]);a.title||(a.title=_$_c0e3[3]);var e=document.createElement(_$_c0e3[145]);e.setAttribute(_$_c0e3[180],b);e.setAttribute(_$_c0e3[181],c);e.setAttribute(_$_c0e3[52],a.colspan);e.setAttribute(_$_c0e3[182],a.align);e.innerHTML=a.title;a.tooltip&&
176
+ (e.title=a.tooltip);return d.element=e};k.build=function(){this.nested||(this.nested={content:[]});if(this.options.nestedHeaders)for(var b=0;b<this.options.nestedHeaders.length;b++){this.nested.content[b]=[];var c=document.createElement(_$_c0e3[145]);c.innerHTML=_$_c0e3[146];var a=document.createElement(_$_c0e3[143]);a.classList.add(_$_c0e3[175]);a.appendChild(c);this.thead.insertBefore(a,this.thead.lastChild)}};k.render=function(){for(var b,c=this.options.nestedHeaders,a=0;a<c.length;a++)for(var d=
177
+ 0;d<this.thead.lastChild.children.length;d++){b=this.thead.lastChild.children[d].getAttribute(_$_c0e3[42]);var e=k.getColumns.call(this,a);void 0!==e[b]&&k.renderCell.call(this,e[b],a)}};k.renderCell=function(b,c,a){var d=oa.create.call(this,b,c);d.parentNode?(b=d.getAttribute(_$_c0e3[52]),b++,d.setAttribute(_$_c0e3[52],b)):(d.setAttribute(_$_c0e3[52],1),a?this.thead.children[c].insertBefore(d,this.thead.children[c].children[a]):this.thead.children[c].appendChild(d),0==b&&0<this.options.freezeColumns&&
178
+ (d.classList.add(_$_c0e3[50]),d.style.left=xa.call(this)?_$_c0e3[157]:_$_c0e3[153]))};k.adjust=function(b,c,a,d){var e=this.options.nestedHeaders;if(e)if(1==a)if(d&&d.nested)for(a=0;a<e.length;a++)for(var f=0;f<e[a].length;f++)k.cell.call(this,f,a,{colspan:d.nested[a][f]});else for(a=0;a<e.length;a++){if(f=k.getColumns.call(this,a)){f=f[b];var h=parseInt(e[a][f].colspan)+c;k.cell.call(this,f,a,{colspan:h})}}else{d=[];for(a=0;a<e.length;a++)if(h=k.getColumns.call(this,a)){d[a]=[];for(f=0;f<c;f++){var g=
179
+ h[b+f];typeof d[a][g]==_$_c0e3[13]&&(d[a][g]=e[a][g].colspan);e[a][g].colspan--}h=Object.keys(d[a]);for(f=0;f<h.length;f++)k.cell.call(this,h[f],a,{colspan:e[a][h[f]].colspan})}return d}};return k}(),ma=function(){var k=function(b,c){var a=function(p){var n;(n=this.results)?p=n.indexOf(p):n=this.rows;p--;for(var q=p;0<=q;q--)if(p=this.results?n[q]:q,this.rows[p]&&this.rows[p].element)return p;return 0},d=function(p){var n;(n=this.results)?p=n.indexOf(p):n=this.rows;p++;for(var q=p;q<n.length;q++)if(p=
180
+ this.results?n[q]:q,this.rows[p]&&this.rows[p].element)return p;return n[n.length-1]},e=function(p,n){for(;0<=p;p--)if(this.records[n][p].element&&this.records[n][p].element.style.display!=_$_c0e3[40])return p;return 0},f=function(p,n){for(;p<this.options.columns.length;p++)if(this.records[n][p].element&&this.records[n][p].element.style.display!=_$_c0e3[40])return p;return this.options.columns-1},h=this.getHighlighted(),g=h[0],l=h[1],m=h[2];h=h[3];b=parseInt(b);c=parseInt(c);null!=b&&null!=c&&(0<
181
+ b-m?(f=f.call(this,parseInt(m)+1,c),b=parseInt(b)):(f=parseInt(b),b=e.call(this,parseInt(g)-1,c)),0<c-h?(d=d.call(this,parseInt(h)),c=parseInt(c)):(d=parseInt(c),c=a.call(this,parseInt(l))),b-f<=c-d?(f=parseInt(g),b=parseInt(m)):(d=parseInt(l),c=parseInt(h)),this.setBorder(f,d,b,c,_$_c0e3[136]))};k.execute=function(b){if(!R.call(this.parent,this))return!1;var c=this.borders.cloning;if(b)if(c&&c.active){b=c.x1;var a=c.y1,d=c.x2,e=c.y2}else return!1;else if(d=this.getSelected(),d.length)b=d[0].x,a=
182
+ parseInt(d[d.length-1].y)+1,d=d[d.length-1].x,e=this.options.data.length-1;else return!1;var f,h=0,g=[],l=[],m=!1,p=this.getHighlighted(),n=Fa[_$_c0e3[51]].call(this,p,!1,!1),q=this.getSelected();if(f=this.getStyle(q,!0)){var v=Object.keys(f);if(v.length)for(var u=0;u<v.length;u++)g.push(f[v[u]])}if(p[0]==b)var y=a<p[1]?a-p[1]:1,w=0;else w=b<p[0]?b-p[0]:1,y=0;v=0;b=parseInt(b);d=parseInt(d);a=parseInt(a);e=parseInt(e);for(var C=a;C<=e;C++)if(!this.results||-1!=this.results.indexOf(C)){void 0==n[h]&&
183
+ (h=0);f=0;p[0]!=b&&(w=b<p[0]?b-p[0]:1);for(u=b;u<=d;u++){if(!(0!=m||this.records[C][u].element&&this.records[C][u].element.classList.contains(_$_c0e3[18]))){if((!c||1!=c.active)&&M.call(this,u,C)){m=!0;continue}void 0==n[h]?f=0:void 0==n[h][f]&&(f=0);var A=n[h][f];A&&!n[1]&&1==this.parent.config.autoIncrement&&(this.options.columns[u].type==_$_c0e3[55]||this.options.columns[u].type==_$_c0e3[14]||1==this.options.columns[u].shiftFormulas?O(A)?A=W.shiftFormula(A,w,C-p[1]):A==Number(A)&&(A=Number(A)+
184
+ y):this.options.columns[u].type==_$_c0e3[183]&&(A=new Date(A),A.setDate(A.getDate()+y),A=A.getFullYear()+_$_c0e3[184]+jSuites.two(parseInt(A.getMonth()+1))+_$_c0e3[184]+jSuites.two(A.getDate())+_$_c0e3[130]+_$_c0e3[185]));A={x:u,y:C,value:A};g&&null!=g[v]&&(A.style=g[v],v++,v>=g.length&&(v=0));l.push(A)}f++;p[0]!=b&&w++}h++;y++}l.length&&(q[0].x<b&&(b=q[0].x),q[0].y<a&&(a=q[0].y),q[q.length-1].x>d&&(d=q[q.length-1].x),q[q.length-1].y>e&&(e=q[q.length-1].y),this.setValue(l),this.resetBorders(_$_c0e3[136],
185
+ !0),this.updateSelectionFromCoords(b,a,d,e))};k.end=function(b){ma.event=!1;ma.execute.call(this,!0)};k.cancel=function(b){ma.event=!1;this.resetBorders(_$_c0e3[136],!0)};return k}(),Fa=function(){var k=function(b){b.getData=k[_$_c0e3[51]];b.getJson=k[_$_c0e3[51]];b.setData=k[_$_c0e3[11]];b.loadData=k.load;b.getRowData=k.getRowData;b.setRowData=k.setRowData;b.getColumnData=k.getColumnData;b.setColumnData=k.setColumnData;b.updateData=k.update;b.refresh=k.refresh;b.data=k[_$_c0e3[51]];b.download=k.download;
186
+ b.copy=k.copy;b.paste=k.paste;b.cut=function(){return b.copy(!0)}};k[_$_c0e3[51]]=function(b,c,a,d){!0===b&&(b=this.getHighlighted());var e=b?!0:!1,f=[],h=this.options.columns.length,g=this.options.data.length;void 0===d&&(d=this.dataType&&typeof a==_$_c0e3[13]?1:0);for(var l=0;l<g;l++){var m=null;var p=d?{}:[];for(var n=0;n<h;n++){var q;if(!(q=!e)){q=b[1];var v=b[2],u=b[3];q=n>=b[0]&&n<=v&&l>=q&&l<=u?!0:!1}if(q&&(!e||!this.results||-1!=this.results.indexOf(l))){q=M.call(this,n,l);if(c){if(e&&!1===
187
+ this.rows[l].visible)continue;m=ea.processed.call(this,n,l);void 0!==m&&(q=m)}a&&q.match&&(q.match(a)||q.match(/\n/)||q.match(/"/))&&(q=q.replace(new RegExp(_$_c0e3[186],_$_c0e3[187]),_$_c0e3[188]),q=_$_c0e3[186]+q+_$_c0e3[186]);d?jSuites.path.call(p,_$_c0e3[3]+Z.call(this,n),q):p.push(q);m=!0}}m&&(a?f.push(p.join(a)):f.push(p))}return a?f.join(_$_c0e3[10])+_$_c0e3[10]:f};k.parse=function(){for(var b,c={},a=0,d,e=[],f=this.options.data,h=0;h<f.length;h++)b=null,d=h,f[h].data&&(Array.isArray(f[h].data)||
188
+ typeof f[h].data==_$_c0e3[83])&&(typeof f[h].id==_$_c0e3[14]&&(b=parseInt(f[h].id)),typeof f[h].row==_$_c0e3[14]&&(d=f[h].row),e[d]=f[h].data,f[h]=[]),d>a&&(a=d),b&&(c[d]=b);if(Object.keys(e).length)for(h=0;h<=a;h++)e[h]&&(f[h]=e[h]);a=this.getPrimaryKey();if(!1!==a)for(a=Z.call(this,a),h=0;h<f.length;h++)c[h]||!1===a||(b=parseInt(f[h][a]),0<b&&(c[h]=b));return c};k.type=function(){for(var b=this.dataType=0;b<this.options.columns.length;b++)typeof this.options.columns[b].name!==_$_c0e3[13]&&(this.dataType=
189
+ 1)};k[_$_c0e3[11]]=function(b){b=k.standardize(b);var c={},a=[],d={};var e=Object.keys(b[0]).length-this.options.columns.length;0<e&&this.insertRow(e);var f=b.length-this.options.data.length;0<f&&this.insertRow(f);for(var h=0;h<this.options.data.length;h++){void 0===b[h]&&(b[h]={row:h,data:[]});for(var g=0;g<this.options.columns.length;g++)b[h].data[g]||(b[h].data[g]=_$_c0e3[3])}for(g=0;g<this.options.columns.length;g++){var l=Z.call(this,g);d[l]=g}for(h=0;h<b.length;h++){f=b[h].row;l=Object.keys(b[h].data);
190
+ for(g=0;g<l.length;g++)e=null,void 0!==d[l[g]]?e=d[l[g]]:-1<l[g]&&(e=parseInt(l[g])),null!==e&&a.push({x:e,y:f,value:b[h].data[l[g]]});b[h].id&&(c[f]=b[h].id)}sa.setId.call(this,c);ea[_$_c0e3[11]].call(this,a,null,!0)};k.build=function(){this.results=null;this.rows=[];this.records=[];this.sequence=0;k.type.call(this);if(this.options.data){var b=k.parse.call(this),c=this.options.data.length;this.options.minDimensions[1]>c&&(c=this.options.minDimensions[1]);for(var a=0;a<c;a++){var d=b[a]?b[a]:null;
191
+ na.row.call(this,a,d)}}};k.load=function(b){this.resetBorders();this.resetSelection();this.tbody.innerText=_$_c0e3[3];this.options.data=b;k.build.call(this);H.call(this);Y.update.call(this)};k.refresh=function(b){if(typeof b!==_$_c0e3[13])for(var c=0;c<this.options.columns.length;c++){var a=this.records[b]&&this.records[b][c].element?this.records[b][c].element:null,d=da[_$_c0e3[51]].call(this,c,b);typeof d[0].updateCell==_$_c0e3[84]&&d[0].updateCell(a,M.call(this,c,b),c,b,this,d[1]);a&&L.applyOverflow.call(this,
192
+ a,c,b)}else if(this.options.url){var e=this;1==this.parent.config.loadingSpin&&jSuites.loading.show();jSuites.ajax({url:this.options.url,method:_$_c0e3[58],dataType:_$_c0e3[59],success:function(f){e.setData(f);jSuites.loading.hide()}})}};k.getRowData=function(b,c){if(typeof this.options.data[b]===_$_c0e3[13])return!1;if(c){if(this.dataType){c={};for(var a=0;a<this.options.columns.length;a++){var d=_$_c0e3[3]+Z.call(this,a),e=_$_c0e3[3]+ea.processed.call(this,a,b,!0);jSuites.path.call(c,d,e)}}else for(c=
193
+ [],a=0;a<this.options.columns.length;a++)c.push(ea.processed.call(this,a,b,!0));return c}return JSON.parse(JSON.stringify(this.options.data[b]))};k.setRowData=function(b,c,a){for(var d=[],e=0;e<this.options.columns.length;e++)typeof c[e]===_$_c0e3[13]&&(c[e]=_$_c0e3[3]),d.push({x:e,y:b,value:c[e]});d.length&&this.setValue(d,null,a)};k.getColumnData=function(b,c){if(typeof this.options.columns[b]===_$_c0e3[13])return!1;for(var a=[],d=0;d<this.options.data.length;d++){var e=c?ea.processed.call(this,
194
+ b,d,!0):M.call(this,b,d);a.push(e)}return a};k.setColumnData=function(b,c,a){for(var d=[],e=0;e<this.rows.length;e++)typeof c[e]===_$_c0e3[13]&&(c[e]=_$_c0e3[3]),d.push({x:b,y:e,value:c[e]});d.length&&this.setValue(d,null,a)};k.copy=function(b){var c=this,a=this.getHighlighted(),d=function(){c.setBorder(a[0],a[1],a[2],a[3],_$_c0e3[126]);c.borders.copying.clear=1==b?!0:!1},e=k[_$_c0e3[51]].call(this,a,!0,_$_c0e3[189]),f=F.call(this.parent,_$_c0e3[190],this,a,e);if(f)e=f;else if(!1===f)return!1;navigator.clipboard?
195
+ navigator.clipboard.writeText(e).then(d):(this.parent.textarea.value=e,this.parent.textarea.select(),document.execCommand(_$_c0e3[191]),d());return e};k.paste=function(b,c,a){if(!R.call(this.parent,this))return!1;var d=this,e=function(){d.borders.copying&&(d.resetBorders(_$_c0e3[126],!0),d.borders.copying.clear=!1)},f=a,h=null,g=this.options.style,l=null,m=null,p=[];if(this.borders.copying){var n=[this.borders.copying.x1,this.borders.copying.y1,this.borders.copying.x2,this.borders.copying.y2];l=n[0];
196
+ m=n[1];var q=jSuites.hash(a),v=jSuites.hash(k[_$_c0e3[51]].call(this,n,!0,_$_c0e3[189]));if(q!=v)e();else{var u=0,y=0;a=k[_$_c0e3[51]].call(this,n,!1,!1);for(q=n[1];q<=n[3];q++)if(!this.results||-1!=this.results.indexOf(q)){p[y]=[];u=0;for(v=n[0];v<=n[2];v++)h=E.getColumnNameFromCoords(v,q),p[y][u]=g&&g[h]?g[h]:_$_c0e3[192],u++;y++}}}b=parseInt(b);c=parseInt(c);100<f.length&&!this.options.pagination&&!H.limited.call(this)&&console.log(_$_c0e3[193]);if(q=F.call(this.parent,_$_c0e3[194],this,a,b,c,
197
+ p,f))a=q;else if(!1===q)return!1;if(a){Array.isArray(a)||(a=E.parseCSV(a,_$_c0e3[189]));if(f=this.getHighlighted()){h=[];u=[];y=[];g=[];var w=0,C=0;for(q=f[1];q<=f[3];q++)if(!this.results||-1!=this.results.indexOf(q)){h=[];u=[];for(v=f[0];v<=f[2];v++)h.push(a[C][w]),p&&p[C]&&p[C][w]?u.push(p[C][w]):u.push(_$_c0e3[3]),w++,w>=a[0].length&&(w=0);y.push(h);g.push(u);C++;C>=a.length&&(C=0)}0==y.length%a.length&&0==y[0].length%a[0].length&&(a=y,p=g)}g=null;f=[];if(this.borders.copying&&!0===this.borders.copying.clear){for(q=
198
+ n[1];q<=n[3];q++)for(v=n[0];v<=n[2];v++)(!this.results||this.results&&0<=this.results.indexOf(q))&&f.push({x:v,y:q,value:_$_c0e3[3],style:_$_c0e3[3]});e()}q=b+a[0].length-this.options.columns.length;0<q&&this.insertColumn(q);q=c+a.length-this.rows.length;0<q&&this.insertRow(q);u=h=b;w=y=c;C=null;this.results&&(g=this.results.indexOf(c));for(q=0;q<a.length;q++)for(v=0;v<a[q].length;v++){null!==l&&null!==m&&a[q][v][0]==_$_c0e3[12]&&(a[q][v]=W.shiftFormula(a[q][v],b-l,c-m));u=b+v;w=c+q;this.results&&
199
+ (w=this.results[g+q]);var A={x:u,y:w,value:a[q][v]};p&&p[q]&&p[q][v]&&(A.style=p[q][v]);f.push(A);null===C&&ya.isSelected.call(this,u,w,n)&&(C=!0)}C&&e();f.length&&(ea[_$_c0e3[11]].call(this,f,null,this.parent.config.forceUpdateOnPaste?!0:!1),F.call(this.parent,_$_c0e3[195],this,f),this.updateSelectionFromCoords(h,y,u,w))}};k.download=function(b,c){if(this.parent.config.allowExport){void 0===c&&(c=!0);var a=_$_c0e3[3];if(1==b||1==this.parent.config.includeHeadersOnDownload)a+=this.getHeaders().replace(/\s+/gm,
200
+ _$_c0e3[130])+_$_c0e3[10];a+=k[_$_c0e3[51]].call(this,null,c,this.options.csvDelimiter);c=new Blob([_$_c0e3[197]+a],{type:_$_c0e3[198]});window.navigator&&window.navigator.msSaveOrOpenBlob?window.navigator.msSaveOrOpenBlob(c,this.options.csvFileName+_$_c0e3[199]):(b=document.createElement(_$_c0e3[200]),c=URL.createObjectURL(c),b.href=c,b.setAttribute(_$_c0e3[201],this.options.csvFileName+_$_c0e3[199]),document.body.appendChild(b),b.click(),b.parentNode.removeChild(b))}else console.error(_$_c0e3[196])};
201
+ k.standardize=function(b){b||(b=[]);Array.isArray(b)||(b=[b]);void 0==b[0]||Array.isArray(b[0])||typeof b[0]==_$_c0e3[83]||(b=[b]);for(var c=0;c<b.length;c++){var a={};Array.isArray(b[c])||void 0==b[c].data?a.data=b[c]:a=b[c];a.row=void 0==b[c].row?c:b[c].row;b[c]=a}return b};return k}(),Wa=function(){var k=function(b){b.getLabel=k[_$_c0e3[51]];b.getLabelFromCoords=k[_$_c0e3[51]]};k[_$_c0e3[51]]=function(b,c,a){if(typeof b==_$_c0e3[17]){b=E.getCoordsFromColumnName(b);var d=b[0];c=b[1]}else d=b;return this.getProcessed(d,
202
+ c,a)};return k}(),Ia=function(){var k=function(b){b.getDefinedNames=k[_$_c0e3[51]];b.setDefinedNames=k[_$_c0e3[11]]};k[_$_c0e3[11]]=function(b){var c=Object.keys(b);if(c.length){for(var a=0;a<c.length;a++)this.parent.config.definedNames[c[a]]=b[c[a]];K.call(this,_$_c0e3[202],[b])}};k[_$_c0e3[51]]=function(b){var c=this.parent.config.definedNames;return b?c[b]:c};k.updateAll=function(b,c){var a,d={};if(a=this.parent.config.definedNames){var e=Object.keys(a);if(e.length){for(var f=this.getWorksheetName(),
203
+ h=0;h<e.length;h++){var g=W.update.call(this,a[e[h]],b,c,f);g!==a[e[h]]&&(d[e[h]]=g)}k[_$_c0e3[11]].call(this,d)}}};k.updateWorksheetName=function(b,c){var a,d={};if(a=this.parent.config.definedNames){var e=Object.keys(a);if(e.length){for(var f=0;f<e.length;f++){var h=W.updateWorksheetName(a[e[f]],b,c);h!==a[e[f]]&&(d[e[f]]=h)}k[_$_c0e3[11]].call(this,d)}}};return k}(),la=function(){var k=[_$_c0e3[203],_$_c0e3[204],_$_c0e3[205],_$_c0e3[206],_$_c0e3[207]],b=[_$_c0e3[184],_$_c0e3[149],_$_c0e3[208],
204
+ _$_c0e3[209],_$_c0e3[210],_$_c0e3[211],_$_c0e3[1],_$_c0e3[212],_$_c0e3[25],_$_c0e3[213],_$_c0e3[12],_$_c0e3[214],_$_c0e3[215],_$_c0e3[216]],c=[],a=function(){if(0<c.length){for(var f=0;f<c.length;f++)ha.destroy.call(this,c[f]);c=[]}},d=function(f){a.call(this);for(var h=0,g=[],l,m=0;m<f.children.length;m++)if(l=f.children[m].getAttribute(_$_c0e3[217])){g[l]||(g[l]=k[h++],4<h&&(h=0));f.children[m].style.color=g[l];if(-1===l.indexOf(_$_c0e3[133])){if(0<=l.indexOf(_$_c0e3[134])){var p=l.split(_$_c0e3[134]),
205
+ n=E.getCoordsFromColumnName(p[0]);p=E.getCoordsFromColumnName(p[1])}else p=n=E.getCoordsFromColumnName(l);ya[_$_c0e3[11]].call(this,n[0],n[1],p[0],p[1],null,l,g[l])}c.push(l)}},e=function(f,h){f.classList.add(_$_c0e3[92]);f.classList.add(_$_c0e3[218]);f.classList.add(_$_c0e3[219]);f.classList.add(_$_c0e3[220]);f.setAttribute(_$_c0e3[221],!0);f.onclick=function(g){g=g.changedTouches&&g.changedTouches[0]?g.changedTouches[0].clientX:g.clientX;var l=this.getBoundingClientRect();24>l.width-(g-l.left)&&
206
+ (e.current=f,f.classList.add(_$_c0e3[222]))};f.onblur=function(){f.worksheet&&(a.call(f.worksheet),typeof f.onchange==_$_c0e3[84]&&f.onchange.call(f),f.worksheet=null)};f.val=function(g){if(void 0===g)return f.innerText;f.innerText=g};f.onchange=h};e.current=null;e.parse=function(f){for(var h=_$_c0e3[3],g=_$_c0e3[3],l=window.getSelection(),m=document.createRange(),p=E.getCaretIndex.call(this.parent,f),n=W.tokenize(f.innerText.replace(/(\r\n|\n|\r)/gm,_$_c0e3[3])),q=0;q<n.length;q++)n[q]&&W.tokenIdentifier.test(n[q].trim())?
207
+ (q==n.length-1&&(g=_$_c0e3[223]),h+=_$_c0e3[224]+g+_$_c0e3[225]+n[q].trim().replace(/\$/g,_$_c0e3[3])+_$_c0e3[226]+n[q]+_$_c0e3[227]):h+=n[q];f.innerHTML=h;h=null;for(q=0;q<f.childNodes.length&&!(h=f.childNodes[q],g=h.tagName?h.innerText.length:h.length,0>=p-g);q++)p-=g;h&&(h.tagName?m.setStart(h.firstChild,p):m.setStart(h,p),l.removeAllRanges(),l.addRange(m));d.call(this,f)};e.close=function(f){a.call(this);f?f.classList.remove(_$_c0e3[92]):e.current&&(typeof e.current.onchange==_$_c0e3[84]&&e.current.onchange.call(e.current),
208
+ e.current.classList.remove(_$_c0e3[222]),e.current.worksheet=null,e.current=null)};e.getName=function(f,h,g,l,m){f=E.getColumnNameFromCoords(f,h);g=E.getColumnNameFromCoords(g,l);m.ctrlKey&&(f=g);return f!==g?(m=f+_$_c0e3[134]+g,m=W.getTokensFromRange.call(this,m),W.getRangeFromTokens.call(this,m)):f};e.range=function(f,h,g,l,m){e.current.getAttribute(_$_c0e3[228])==_$_c0e3[229]&&(f=g,h=l);f=e.getName.call(this,f,h,g,l,m);h=document.createElement(_$_c0e3[230]);h.innerText=f;h.setAttribute(_$_c0e3[217],
209
+ f);e.current.innerText=_$_c0e3[3];e.current.appendChild(h);d.call(this,e.current);jSuites.focus(h);m.preventDefault()};e.update=function(f,h,g,l,m){var p=this,n=jSuites.getNode();if(n){var q=e.getName.call(this,f,h,g,l,m);f=function(v){var u=document.createElement(_$_c0e3[230]);u.innerText=q;u.setAttribute(_$_c0e3[217],q);n.parentNode===p.parent.input&&!1===v?n.parentNode.insertBefore(u,n.nextSibling):p.parent.input.appendChild(u);n=u};if(n.getAttribute(_$_c0e3[217]))m.ctrlKey?(p.parent.input.appendChild(document.createTextNode(_$_c0e3[25])),
210
+ f(!0)):(n.innerText=q,n.setAttribute(_$_c0e3[217],q));else{if(n.innerText!==_$_c0e3[3]&&-1==b.indexOf(n.innerText.slice(-1))||n.nextElementSibling&&n.nextElementSibling.getAttribute(_$_c0e3[217]))return!1;f(!1)}jSuites.focus(n);d.call(p,p.parent.input);m.preventDefault();return!0}return!1};e.onkeydown=function(f){f.target.worksheet=this;if(f.ctrlKey){if(67==f.which||88==f.which)f=window.getSelection().toString().replace(/(\r\n|\n|\r)/gm,_$_c0e3[3]),navigator.clipboard?navigator.clipboard.writeText(f):
211
+ (this.parent.textarea.value=f,this.parent.textarea.select(),document.execCommand(_$_c0e3[191]))}else if(36==f.which){var h=window.getSelection(),g=document.createRange();g.setStart(f.target,0);h.removeAllRanges();h.addRange(g)}else 35==f.which?jSuites.focus(f.target):187==f.which&&!f.target.innerText.replace(/(\r\n|\n|\r)/gm,_$_c0e3[3])&&f.target.getAttribute(_$_c0e3[94])&&f.target.removeAttribute(_$_c0e3[94])};return e}(),W=function(){var k=new RegExp(/^(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]+)(:\$?[A-Z]+\$?[0-9]+)?$/i),
212
+ b=function(g){g=c(g);for(var l=[_$_c0e3[184],_$_c0e3[149],_$_c0e3[208],_$_c0e3[209],_$_c0e3[210],_$_c0e3[231]],m=[_$_c0e3[211],_$_c0e3[232],_$_c0e3[1],_$_c0e3[2],_$_c0e3[212],_$_c0e3[233],_$_c0e3[25],_$_c0e3[213],_$_c0e3[12],_$_c0e3[214],_$_c0e3[215],_$_c0e3[216]],p=_$_c0e3[3],n=[],q=0,v=0;v<g.length;v++){if(g[v]==_$_c0e3[186]||g[v]==_$_c0e3[131])q=0==q?1:0;0==q&&(-1<l.indexOf(g[v])||-1<m.indexOf(g[v]))?(p&&(n.push(p),p=_$_c0e3[3]),n.push(g[v])):p+=g[v]}p&&n.push(p);for(v=0;v<n.length;v++)-1==n[v].indexOf(_$_c0e3[186])&&
213
+ -1==n[v].indexOf(_$_c0e3[131])&&(n[v]=n[v].replace(/\s/g,_$_c0e3[3]));return n},c=function(g,l){for(var m=_$_c0e3[3],p=0,n=[_$_c0e3[12],_$_c0e3[133],_$_c0e3[215],_$_c0e3[214]],q=0;q<g.length;q++)g[q]==_$_c0e3[186]&&(p=0==p?1:0),1==p?m+=g[q]:(m+=g[q].toUpperCase(),1==l&&0<q&&g[q]==_$_c0e3[12]&&-1==n.indexOf(g[q-1])&&-1==n.indexOf(g[q+1])&&(m+=_$_c0e3[12]));return m},a=function(g){g.setFormula=a[_$_c0e3[11]];g.executeFormula=a.execute;g.formula=[]};a.run=function(g,l){var m=_$_c0e3[3],p=Object.keys(l);
214
+ if(p.length){for(var n={},q=0;q<p.length;q++){var v=p[q].replace(/!/g,_$_c0e3[27]);0<v.indexOf(_$_c0e3[27])&&(v=v.split(_$_c0e3[27]),n[v[0]]=!0)}v=Object.keys(n);for(q=0;q<v.length;q++)m+=_$_c0e3[234]+v[q]+_$_c0e3[235];for(q=0;q<p.length;q++)v=p[q].replace(/!/g,_$_c0e3[27]),jSuites.isNumeric(l[p[q]])||(n=l[p[q]].match(/(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&n.length&&(l[p[q]]=e(n,l[p[q]])),m=0<v.indexOf(_$_c0e3[27])?m+(v+_$_c0e3[236]+l[p[q]]+_$_c0e3[237]):m+(_$_c0e3[234]+
215
+ v+_$_c0e3[236]+l[p[q]]+_$_c0e3[237])}g=g.replace(/\$/g,_$_c0e3[3]);(n=g.match(/(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&n.length&&(g=e(n,g));g=g.replace(/!/g,_$_c0e3[27]);return(new Function(m+_$_c0e3[238]+g))()};a[_$_c0e3[11]]=function(){};var d=function(g){g=c(g,!0);return g.replace(/\$/g,_$_c0e3[3])},e=function(g,l){for(var m=0;m<g.length;m++){var p=a.getTokensFromRange.call(this,g[m]);l=l.replace(g[m],_$_c0e3[212]+p.join(_$_c0e3[25])+_$_c0e3[233])}return l},f=function(g,
216
+ l,m){for(var p=this.config.definedNames,n=0;n<g.length;n++)g[n]&&p&&p[g[n]]&&(l=l.replace(g[n],p[g[n]]),m&&(m[g[n]]=p[g[n]]));return d(l)},h=function(g,l){var m;if(m=this.records[l][g].a)for(var p=0;p<m.length;p++)for(var n=0;n<m[p].length;n++)m[p][n]&&(m[p][n].innerText=_$_c0e3[3],this.records[l+p][g+n].v=_$_c0e3[3]);this.records[l][g].a=[]};a.execute=function(g,l,m,p,n){if(1==this.parent.processing)return null!==l&&null!==m&&this.parent.queue.push([this,l,m]),_$_c0e3[3];if(typeof this.parent.config.onbeforeformula==
217
+ _$_c0e3[84]){var q=F.call(this.parent,_$_c0e3[239],this,g,l,m);if(!1===q)return g;q&&(g=q)}var v=[],u=function(N,S,P,r){if(void 0!=S&&void 0!=P){var z=E.getColumnNameFromCoords(S,P);P=r.getWorksheetName()+_$_c0e3[27]+z;v[P]||(v[P]=0);v[P]++;if(3<v[P])throw{error:_$_c0e3[240],message:_$_c0e3[241],reference:P};}else z=null;n||(N=d(N));var x=N,D=x.match(/[A-Z_]+[A-Z0-9_\.]*/g);D&&D.length&&(x=f.call(r.parent,D,x,y));(D=x.match(/(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&D.length&&
218
+ (x=e.call(r,D,x));D=[];x=b(x);for(var G=0;G<x.length;G++)x[G]&&k.test(x[G])&&D.push(x[G]);if(D){if(-1<D.indexOf(z))throw{error:_$_c0e3[242],message:_$_c0e3[243]};for(x=0;x<D.length;x++){G=D[x].split(_$_c0e3[133]);G[1]?(S=G[1],G=I(G[0]),P=r.getWorksheetName()+_$_c0e3[27]+z):(S=G[0],G=r,P=z);if(typeof G==_$_c0e3[13]||typeof G.formula==_$_c0e3[13])throw{error:_$_c0e3[244],message:_$_c0e3[245]};P&&(G.formula[S]||(G.formula[S]=[]),0>G.formula[S].indexOf(P)&&G.formula[S].push(P));if(!y[D[x]]){P=E.getCoordsFromColumnName(S);
219
+ S=P[0];P=P[1];var Q=void 0!==G.records[P][S].v?G.records[P][S].v:M.call(G,S,P);y[D[x]]||((_$_c0e3[3]+Q).substr(0,1)==_$_c0e3[12]?y[D[x]]=u(Q,S,P,G):(Q?Q!=Number(Q)&&(Q=_$_c0e3[186]+Q+_$_c0e3[186]):Q=0,y[D[x]]=Q))}}}return N.substr(1)},y={};try{g=u(g,l,m,this);if(g==_$_c0e3[3])return _$_c0e3[3];0==g.indexOf(_$_c0e3[246])&&(n=!0);var w=n?a.run(g,y):t.formula(g,y,l,m,this);if(!1!==p&&void 0!=l&&void 0!=m)if(w instanceof Date)this.records[m][l].v=jSuites.calendar.dateToNum(w);else if(Array.isArray(w)){h.call(this,
220
+ l,m);p=[];q=null;for(var C=0;C<w.length;C++)for(var A=0;A<w[C].length;A++)null===q&&(0<C&&C>A&&this.options.data[m+C][l+A]?q=_$_c0e3[247]:(this.records[m+C][l+A].v=w[C][A],this.records[m+C][l+A].element&&(p[C]||(p[C]=[]),p[C][A]=this.records[m+C][l+A].element,this.records[m+C][l+A].element.innerText=w[C][A])));null===q?(q=w[0][0],this.records[m][l].a=p):h.call(this,l,m);w=this.records[m][l].v=q}else this.records[m][l].v=w;return w}catch(N){return 1==this.parent.config.debugFormulas&&console.log(g,
221
+ y,N),N&&N.error?N.error:_$_c0e3[244]}};a.update=function(g,l,m,p){var n=null,q=null,v=function(w){m&&m[w]&&(w=_$_c0e3[248]);l[w]&&(w=l[w]);return w};g=c(g,!0);g=b(g);for(var u=0;u<g.length;u++)if(g[u]&&k.test(g[u])){if(-1==g[u].indexOf(_$_c0e3[133])){if(q=g[u],n=_$_c0e3[3],p)continue}else if(q=g[u].split(_$_c0e3[133]),n=q[0],q=q[1],p!=n)continue;if(0<=q.indexOf(_$_c0e3[134])){q=a.getTokensFromRange.call(this,q);for(var y=0;y<q.length;y++)q[y]=v(q[y]);q=a.getRangeFromTokens.call(this,q)}else-1==q.indexOf(_$_c0e3[249])?
222
+ q=v(q):(q=v(q.replace(/\$/g,_$_c0e3[3])),q=_$_c0e3[249]+q.match(/[A-Z]+/g)+_$_c0e3[249]+q.match(/[0-9]+/g));n&&(q=n+_$_c0e3[133]+q);g[u]=q}return g.join(_$_c0e3[3])};a.getChain=function(g){if(void 0===g)return[];var l=[],m=[],p=[],n=function(u){if(0<=u.indexOf(_$_c0e3[27])){var y=u.split(_$_c0e3[27]),w=y[0],C=y[1];y=I(y[0])}else y=this,w=y.getWorksheetName(),C=u;if(y.formula[C]&&!p[u]){var A=!1;p[u]=!0;for(u=0;u<y.formula[C].length;u++){var N=y.formula[C][u];-1==N.indexOf(_$_c0e3[27])&&(N=w+_$_c0e3[27]+
223
+ N);if(!m[N]){var S=y.getValue(N);O(S)?l.push([N,S,a.getTokens.call(y,S,w)]):(A=!0,y.formula[C][u]=null);n.call(y,N);m[N]=!0}}1==A&&(y.formula[C]=y.formula[C].filter(function(P){return null!=P}))}},q=Object.keys(g);for(g=0;g<q.length;g++)n.call(this,q[g]);q=0;for(g=l.length-1;0<=g;g--){for(var v=0;v<g;v++)if(0<=l[v][2].indexOf(l[g][0])){l.splice(v,0,l.splice(g,1)[0]);g=l.length;break}q++;if(1E6<q){console.error(_$_c0e3[250]);break}}m=[];for(g=0;g<l.length;g++)m[l[g][0]]=l[g][1];return m};a.updateAll=
224
+ function(g,l){var m,p;Ia.updateAll.call(this,g,l);var n=Object.keys(this.formula);var q=[];var v=[];for(m=0;m<n.length;m++){var u=n[m];var y=this.formula[u];if(l&&l[u])for(var w=0;w<y.length;w++)g[y[w]]&&(y[w]=g[y[w]]),v[y[w]]=!0;else{var C=[];for(w=0;w<y.length;w++)l&&l[y[w]]||(g[y[w]]&&(y[w]=g[y[w]]),v[y[w]]=!0,C.push(y[w]));C.length&&(g[u]&&(u=g[u]),q[u]=C)}}this.formula=q;C=this.getWorksheetName();for(var A=0;A<t.spreadsheet.length;A++)for(var N=t.spreadsheet[A].worksheets,S=0;S<N.length;S++)if(N[S].getWorksheetName()!==
225
+ C)for(n=Object.keys(N[S].formula),m=0;m<n.length;m++){q=[];y=N[S].formula[n[m]];for(w=0;w<y.length;w++)u=y[w].split(_$_c0e3[27]),u[0]==C&&u[1]?l&&l[u[1]]||(g[u[1]]&&(u[1]=g[u[1]]),q.push(u[0]+_$_c0e3[27]+u[1])):q.push(y[w]);N[S].formula[n[m]]=q}n=[];u=Object.keys(v);for(w=0;w<u.length;w++)0<=u[w].indexOf(_$_c0e3[27])?(y=u[w].split(_$_c0e3[27]),q=I(y[0]),m=y[1],C=this.getWorksheetName(),y=y[0]):(q=this,m=u[w],C=null,y=this.getWorksheetName()),(p=q.getValue(m))&&O(p)&&(q=a.update.call(q,p,g,l,C),q!=
226
+ p&&(v[u[w]]=q,m=E.getCoordsFromColumnName(m),n[y]||(n[y]=[]),n[y].push({x:m[0],y:m[1],value:q,force:!0})));u=Object.keys(n);for(g=0;g<u.length;g++)q=I(u[g]),n[u[g]]=ea.applyValues.call(q,n[u[g]]),ea.setValueChained.call(q,n[u[g]]),K.call(q,_$_c0e3[106],{data:n[u[g]]})};a.updateWorksheetName=function(g,l,m){for(var p=b(g),n=0;n<p.length;n++)g=p[n].split(_$_c0e3[133]),g[1]&&(g[0]=g[0].replace(new RegExp(_$_c0e3[131],_$_c0e3[187]),_$_c0e3[3]),g[0].toUpperCase()==l.toUpperCase()&&(g[0]=m,0<=g[0].indexOf(_$_c0e3[130])&&
227
+ (g[0]=_$_c0e3[131]+g[0]+_$_c0e3[131]),p[n]=g.join(_$_c0e3[133])));return p.join(_$_c0e3[3])};a.updateWorksheetNames=function(g,l){for(var m,p,n=0;n<t.spreadsheet.length;n++)for(var q=[],v=t.spreadsheet[n].worksheets,u=0;u<v.length;u++){for(var y=0;y<v[u].options.data.length;y++)for(var w=0;w<v[u].options.data[y].length;w++)(m=v[u].options.data[y][w])&&O(m)&&(p=a.updateWorksheetName(m,g,l),p!=m&&q.push({x:w,y,value:p,force:!0}));q.length&&(q=ea.applyValues.call(v[u],q),K.call(v[u],_$_c0e3[106],{data:q}))}};
228
+ a.shiftFormula=function(g,l,m){var p=b(g,!0);g=function(u){if(-1==u.indexOf(_$_c0e3[133])){u=E.getCoordsFromColumnName(u);var y=_$_c0e3[3]}else y=p[n].split(_$_c0e3[133]),u=E.getCoordsFromColumnName(y[1]),y=y[0]+_$_c0e3[133];var w=u[0]+l;u=u[1]+m;return u=0>w||0>u?_$_c0e3[248]:y+E.getColumnNameFromCoords(w,u)};for(var n=0;n<p.length;n++)if(k.test(p[n])&&-1==p[n].indexOf(_$_c0e3[249])){var q=-1==p[n].indexOf(_$_c0e3[133])?[_$_c0e3[3],p[n]]:p[n].split(_$_c0e3[133]);if(-1==q[1].indexOf(_$_c0e3[134]))q[1]=
229
+ g(q[1]);else{var v=q[1].split(_$_c0e3[134]);q[1]=g(v[0])+_$_c0e3[134]+g(v[1])}p[n]=q[0]?q.join(_$_c0e3[133]):q[1]}return p.join(_$_c0e3[3])};a.getTokensFromRange=function(g){var l=this,m=_$_c0e3[3],p=_$_c0e3[3];0<=g.indexOf(_$_c0e3[27])?p=_$_c0e3[27]:0<=g.indexOf(_$_c0e3[133])&&(p=_$_c0e3[133]);g=g.replace(/\$/g,_$_c0e3[3]);p&&(m=g.split(p),l=I(m[0]),g=m[1],m=m[0]+p);p=[];g=g.split(_$_c0e3[134]);var n=E.getCoordsFromColumnName(g[0]),q=E.getCoordsFromColumnName(g[1]);if(n[0]<=q[0]){g=n[0];var v=q[0]}else g=
230
+ q[0],v=n[0];if(null===n[1]&&null==q[1]){var u=0;n=0;l.options&&l.options.data&&(n=l.options.data.length-1)}else n[1]<=q[1]?(u=n[1],n=q[1]):(u=q[1],n=n[1]);for(l=u;l<=n;l++)for(u=g;u<=v;u++)p.push(m+E.getColumnNameFromCoords(u,l));return p};a.getRangeFromTokens=function(g){g=g.filter(function(p){return p!=_$_c0e3[248]});for(var l=_$_c0e3[3],m=0;m<g.length;m++)0<=g[m].indexOf(_$_c0e3[27])&&(l=g[m].split(_$_c0e3[27]),g[m]=l[1],l=l[0]);l&&(l+=_$_c0e3[27]);g.sort(function(p,n){p=E.getCoordsFromColumnName(p);
231
+ n=E.getCoordsFromColumnName(n);return p[1]>n[1]?1:p[1]<n[1]?-1:p[0]>n[0]?1:p[0]<n[0]?-1:0});return g.length?l+(g[0]+_$_c0e3[134]+g[g.length-1]):_$_c0e3[248]};a.getTokens=function(g,l){var m=d(g);g.replace(/!/g,_$_c0e3[27]);(g=m.match(/[A-Z_]+[A-Z0-9_\.]*/g))&&g.length&&(m=f.call(this.parent,g,m));(g=m.match(/('.*?'?|\w*\.)?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&g.length&&(m=e.call(this,g,m));g=m.match(/('.*?'?|\w*\.)?(\$?[A-Z]+\$?[0-9]+)(:\$?[A-Z]+\$?[0-9]+)?/g);for(m=0;m<g.length;m++)-1==
232
+ g[m].indexOf(_$_c0e3[27])&&l&&(g[m]=l+_$_c0e3[27]+g[m]);return g};a.tokenIdentifier=k;a.tokenize=b;return a}(),ea=function(){var k=function(b){b.name=Z;b.value=M;b.getValue=k[_$_c0e3[51]];b.getValueFromCoords=k.getFromCoords;b.setValue=k[_$_c0e3[11]];b.setValueFromCoords=k.setFromCoords;b.setCheckRadioValue=k.setCheckRadio;b.getProcessed=k.processed};k[_$_c0e3[51]]=function(b,c){var a=this;if(typeof b==_$_c0e3[83]){var d=b.x;b=b.y}else 0<=b.indexOf(_$_c0e3[27])&&(a=b.split(_$_c0e3[27]),b=a[1],a=I(a[0])),
233
+ b=E.getCoordsFromColumnName(b),d=b[0],b=b[1];return k.getFromCoords.call(a,d,b,c)};k.getFromCoords=function(b,c,a){var d=null;null!=b&&null!=c&&(d=a?k.processed.call(this,b,c):M.call(this,b,c));return d};k[_$_c0e3[11]]=function(b,c,a){if(!R.call(this.parent,this))return!1;var d=null,e=null,f=null,h=[];a=a?!0:!1;var g=function(p,n){var q=null;typeof p==_$_c0e3[17]?(f=E.getCoordsFromColumnName(p),d=f[0],e=f[1]):p.tagName?(d=p.getAttribute(_$_c0e3[42]),e=p.getAttribute(_$_c0e3[43])):p.element&&p.element.tagName?
234
+ (d=p.element.getAttribute(_$_c0e3[42]),e=p.element.getAttribute(_$_c0e3[43])):(d=p.x,e=p.y,void 0!==p.value&&(n=p.value),void 0!==p.style&&(q=p.style));p={x:d,y:e,value:n,force:a};null!==q&&(p.style=q);h.push(p)};if(b&&Array.isArray(b))for(var l=0;l<b.length;l++)g(b[l],c);else if(typeof b==_$_c0e3[83]&&void 0==b.x&&void 0==b.tagName)for(c=Object.keys(b),l=0;l<c.length;l++)g(c[l],b[c[l]]);else g(b,c);if(h.length){h=k.applyValues.call(this,h);this.parent.config.parseFormulas&&k.setValueChained.call(this,
235
+ h);Y.update.call(this,!0);this.refreshBorders();var m=this;setTimeout(function(){ha.refresh.call(m)},250);if(h.length){V.call(this.parent,{worksheet:m,action:_$_c0e3[77],records:h,selection:this.selectedCell});b=this.getPrimaryKey();if(!1!==b)for(l=0;l<h.length;l++)h[l].x===b&&h[l].value&&T.call(this,h[l]);K.call(this,_$_c0e3[77],{data:h});F.call(this.parent,_$_c0e3[251],this,h)}}};k.setFromCoords=function(b,c,a,d){var e=[];e.push({x:b,y:c,value:a});k[_$_c0e3[11]].call(this,e,null,d)};k.setCheckRadio=
236
+ function(){for(var b=[],c=this.getSelected(),a=0;a<c.length;a++){var d=c[a].x,e=c[a].y;if(!this.options.columns[d].readOnly&&this.options.columns[d].type==_$_c0e3[252]){var f=M.call(this,d,e)?!1:!0;b.push({x:d,y:e,value:f})}}b.length&&k[_$_c0e3[11]].call(this,b)};k.applyValues=function(b){for(var c,a,d=this.options.style||{},e=[],f={},h=0;h<b.length;h++)if(c=b[h],a=this.updateCell(c.x,c.y,c.value,c.force),void 0!==a.value){if(void 0!==c.style){var g=E.getColumnNameFromCoords(c.x,c.y);a.style=f[g]=
237
+ c.style;a.oldStyle=d&&d[g]?d[g]:_$_c0e3[192]}e.push(a)}0<Object.keys(f).length&&Qa.update.call(this,f);return e};k.processed=function(b,c,a){var d=M.call(this,b,c);if(null===d)return null;var e=da[_$_c0e3[51]].call(this,b,c),f=e[1];f.type!=_$_c0e3[49]&&f.type!=_$_c0e3[253]&&f.type!=_$_c0e3[254]&&f.type!=_$_c0e3[255]&&f.type!=_$_c0e3[256]&&0!=f.process&&(!0===a||f.type!=_$_c0e3[257]&&f.type!=_$_c0e3[258]&&f.type!=_$_c0e3[259])&&(f.type==_$_c0e3[252]?d=e[0][_$_c0e3[51]](f,d,a):this.records[c][b].element?
238
+ d=1==this.parent.config.stripHTML?this.records[c][b].element.innerText:this.records[c][b].element.innerHTML:((_$_c0e3[3]+d).substr(0,1)==_$_c0e3[12]&&(d=this.executeFormula(d,b,c,!1)),e[0]&&typeof e[0][_$_c0e3[51]]==_$_c0e3[84]&&(d=e[0][_$_c0e3[51]](f,d,a))));return d};k.setValueChained=function(b){for(var c,a=[],d,e=0;e<b.length;e++)c=b[e],d=E.getColumnNameFromCoords(c.x,c.y),a[d]=c.value;a=W.getChain.call(this,a);b=Object.keys(a);for(e=0;e<b.length;e++)0<=b[e].indexOf(_$_c0e3[27])?(c=b[e].split(_$_c0e3[27]),
239
+ d=c[1],c=I(c[0])):(d=b[e],c=this),d=E.getCoordsFromColumnName(d),L.update.call(c,d[0],d[1],a[b[e]],!0)};return k}(),L=function(){var k=function(b){b.getCell=k[_$_c0e3[51]];b.getCellFromCoords=k[_$_c0e3[51]];b.updateCell=k.update;b.updateCells=k.updateAll;b.getSelected=k.selected;b.isAttached=k.attached};k.attached=function(b,c){return this.records[c]&&this.records[c][b]&&this.records[c][b].element&&this.records[c][b].element.parentNode&&this.records[c][b].element.parentNode.parentNode?!0:!1};k[_$_c0e3[51]]=
240
+ function(b,c,a){typeof b==_$_c0e3[17]&&(c=E.getCoordsFromColumnName(b),b=c[0],c=c[1]);b=parseInt(b);c=parseInt(c);if(this.records[c]&&this.records[c][b]&&this.records[c][b].element)return this.records[c][b].element;var d=M.call(this,b,c);null===d&&(d=_$_c0e3[3]);return L.create.call(this,b,c,d,a)};k.getFromCoords=function(b,c,a){if(!b)return null;var d=[],e=b[0],f=b[1],h=b[2];b=b[3];for(a&&(a=this.results?E.invert(this.results):null);f<=b;f++)for(var g=e;g<=h;g++)if(!a||a[f])c?d.push(E.getColumnNameFromCoords(g,
241
+ f)):d.push(this.records[f][g]);return d};k.selected=function(b,c){return k.getFromCoords.call(this,this.getHighlighted(),b,c)};k.getSelectedColumns=function(){var b=[],c=this.getHighlighted();if(c)for(var a=c[0];a<=c[2];a++)b.push(a);return b};k.updateAll=function(b){for(var c=this.getPrimaryKey(),a=[],d=0;d<b.length;d++)void 0!==b[d].id?(T.call(this,b[d]),a.push({id:b[d].id,y:b[d].y}),!1!==c&&k.update.call(this,c,b[d].y,b[d].id,!0)):a.push(k.update.call(this,b[d].x,b[d].y,b[d].value,b[d].force));
242
+ K.call(this,_$_c0e3[105],[a])};k.update=function(b,c,a,d){var e=this.records[c];if(e=e&&e[b]?e[b]:null)if(e=e.element,!d&&e&&1==e.classList.contains(_$_c0e3[18]))var f={x:b,y:c};else{f=F.call(this.parent,_$_c0e3[260],this,e,b,c,a);void 0!==f&&(a=f);d=da[_$_c0e3[51]].call(this,b,c);typeof d[0].updateCell==_$_c0e3[84]&&(f=d[0].updateCell(e,a,b,c,this,d[1]),void 0!==f&&(a=f));f={x:b,y:c};var h=M.call(this,b,c);if(h!==a){var g=M.call(this,b,c,a);f.oldValue=h;f.value=g;e&&k.applyOverflow.call(this,e,b,
243
+ c);d[1]&&typeof d[1].render==_$_c0e3[84]&&d[1].render(e,a,b,c,this,d[1]);F.call(this.parent,_$_c0e3[261],this,e,b,c,f.value,f.oldValue)}}else return!1;return f};k.create=function(b,c,a,d){var e=document.createElement(_$_c0e3[145]);e.setAttribute(_$_c0e3[42],b);e.setAttribute(_$_c0e3[43],c);var f=da[_$_c0e3[51]].call(this,b,c);f[0]&&typeof f[0].createCell==_$_c0e3[84]&&(f=f[0].createCell(e,a,b,c,this,f[1]),void 0!==f&&(a=f));M.call(this,b,c,a);this.records[c][b]||na.cell.call(this,b,c,a);this.records[c][b].element=
244
+ e;!a&&this.records[c][b].v&&(e.innerText=this.records[c][b].v);k.applyProperties.call(this,e,b,c,d);k.applyOverflow.call(this,e,b,c);F.call(this.parent,_$_c0e3[262],this,e,b,c,a);return e};k.getAttributes=function(b,c,a){a[b]||(a[b]={});b==_$_c0e3[263]?a[b][c]=this.getValue(c):b==_$_c0e3[264]?this.merged.cells&&(c=this.merged.cells[c])&&(a[b][c]=this.options.mergeCells[c]):this.options[b]&&this.options[b][c]&&(a[b][c]=this.options[b][c])};k.setAttributes=function(b){b&&b.style&&this.setStyle(b.style);
245
+ b&&b.comments&&this.setComments(b.comments);b&&b.meta&&this.setMeta(b.meta);b&&b.cells&&this.setCells(b.cells);b&&b.mergeCells&&this.setMerge(b.mergeCells);b&&b.values&&k.batch.call(this,b.values);b&&b.formulas&&k.batch.call(this,b.formulas,!0)};k.applyProperties=function(b,c,a,d){if(!d){var e=E.getColumnNameFromCoords(c,a),f=this.options.style;d=this.options.comments;var h=this.options.cells,g=this.options.rows;if(f&&f[e]){var l=(l=b.getAttribute(_$_c0e3[98]))?l+(_$_c0e3[216]+f[e]):f[e];b.setAttribute(_$_c0e3[98],
246
+ l)}d&&d[e]&&b.setAttribute(_$_c0e3[265],d[e]);h&&h[e]&&(1==h[e].readOnly&&b.classList.add(_$_c0e3[18]),!1===h[e].locked&&!0===this.options.selectUnLockedCells&&b.classList.add(_$_c0e3[266]));g&&g[a]&&1==g[a].readOnly&&b.classList.add(_$_c0e3[18])}d=this.options.columns[c];!b.style.textAlign&&(l=d.align?d.align:this.options.defaultColAlign)&&(b.style.textAlign=l);!1===this.records[a][c].readonly||1!=this.records[a][c].readonly&&1!=d.readOnly&&1!=d.readonly||b.classList.add(_$_c0e3[18])};k.applyOverflow=
247
+ function(b,c,a){1==this.options.textOverflow&&0<c&&(c==this.options.columns.length-1&&(b.style.overflow=_$_c0e3[49]),this.records[a][c-1]&&this.records[a][c-1].element&&(this.records[a][c-1].element.style.overflow=!b.innerText&&this.headers[c-1]&&this.headers[c-1].offsetWidth?_$_c0e3[3]:_$_c0e3[49]))};k.batch=function(b,c){var a=[],d=Object.keys(b);if(d.length)for(var e=0;e<d.length;e++){if(0<=d[e].indexOf(_$_c0e3[27])){var f=d[e].split(_$_c0e3[27]);var h=I(f[0]);var g=f[1];f=f[0]}else h=this,g=d[e],
248
+ f=this.getWorksheetName();g=E.getCoordsFromColumnName(g);g=h.updateCell(g[0],g[1],b[d[e]],!0);a[f]||(a[f]=[]);a[f].push(g)}if(1==c&&(d=Object.keys(a),d.length))for(e=0;e<d.length;e++)h=I(d[e]),K.call(h,_$_c0e3[106],a[d[e]])};return k}(),Ha=function(){var k=function(b){b.getColumnOptions=k[_$_c0e3[51]];b.setColumnOptions=k[_$_c0e3[11]];b.getCells=k.getCells;b.setCells=k.setCells;b.getProperties=k[_$_c0e3[51]];b.setProperties=k[_$_c0e3[11]];b.getProperty=k[_$_c0e3[51]];b.setProperty=k[_$_c0e3[11]];
249
+ b.resetProperty=k[_$_c0e3[11]];b.getOptions=k[_$_c0e3[51]]};k.getCells=function(b){return b?this.options.cells[b]:this.options.cells};k.setCells=function(b,c){if(!R.call(this.parent,this))return!1;if(typeof b==_$_c0e3[17])this.options.cells[b]=c;else{c=Object.keys(b);for(var a=0;a<c.length;a++)this.options.cells[c[a]]=b[c[a]]}};k[_$_c0e3[51]]=function(b,c){var a=null;void 0!==c&&(c=E.getColumnNameFromCoords(b,c),this.options.cells&&this.options.cells[c]&&(a=this.options.cells[c]));null===a&&(a=this.options.columns[b]);
250
+ if(!a)a={type:_$_c0e3[55]};else if(!a.type||typeof a.type==_$_c0e3[17]&&!t.editors[a.type])a.type=_$_c0e3[55];return a};k[_$_c0e3[11]]=function(b,c,a){if(!R.call(this.parent,this))return!1;this.edition&&this.closeEditor(this.edition,!1);var d=[];Array.isArray(b)?d=b:jSuites.isNumeric(b)&&jSuites.isNumeric(c)?(b={x:b,y:c},typeof a==_$_c0e3[83]&&(b.value=a),d.push(b)):typeof c===_$_c0e3[83]&&(b={x:b,value:c},d.push(b));if(Array.isArray(d))for(a=0;a<d.length;a++){var e=d[a];b=e.x;var f=e.y,h=k[_$_c0e3[51]].call(this,
251
+ b,f);c=e.value;e.oldValue=h;e=t.editors[h.type];if(c&&c.type)var g=t.editors[c.type];if(typeof f===_$_c0e3[13]){if(e&&typeof e.destroyCell==_$_c0e3[84])for(f=0;f<this.records.length;f++)this.records[f][b].element&&e.destroyCell(this.records[f][b].element,b,f);parseInt(c.width)||(c.width=this.options.defaultColWidth||100);c.type&&t.editors[c.type]||(c.type=_$_c0e3[55]);this.options.columns[b]=c;c.width&&this.colgroup[b]&&this.colgroup[b].setAttribute(_$_c0e3[150],parseInt(c.width));typeof c.title!==
252
+ _$_c0e3[13]&&this.headers[b]&&(c.title?(this.headers[b].innerText=c.title,this.headers[b].setAttribute(_$_c0e3[164],c.title)):(this.headers[b].innerText=E.getColumnName(b),this.headers[b].removeAttribute(_$_c0e3[164])));c.tooltip&&this.headers[b]&&(this.headers[b].title=c.tooltip);if(g&&typeof g.createCell==_$_c0e3[84])for(f=0;f<this.records.length;f++)this.records[f]&&this.records[f][b]&&(L.applyProperties.call(this,this.records[f][b].element,b,f),g.createCell(this.records[f][b].element,M.call(this,
253
+ b,f),b,f,this,c))}else e&&typeof e.destroyCell==_$_c0e3[84]&&this.records[f][b].element&&e.destroyCell(this.records[f][b].element,b,f,this),e=E.getColumnNameFromCoords(b,f),c?(this.options.cells||(this.options.cells={}),this.options.cells[e]=c,g&&typeof g.createCell==_$_c0e3[84]&&this.records[f]&&this.records[f][b]&&(L.applyProperties.call(this,this.records[f][b].element,b,f,this),g.createCell(this.records[f][b].element,M.call(this,b,f),b,f,this,c))):delete this.options.cells[e]}else return console.error(_$_c0e3[250]),
254
+ !1;this.refreshBorders();V.call(this.parent,{worksheet:this,action:_$_c0e3[78],records:d});K.call(this,_$_c0e3[78],{data:d});return!0};return k}(),Aa=function(){var k=function(c,a){Array.isArray(a)||(a=[a]);for(var d,e=c?_$_c0e3[3]:_$_c0e3[40],f=Object.keys(a),h=0;h<f.length;h++)if(d=this.rows[a[f[h]]])d.element&&(d.element.style.display=e),d.visible=c;this.resetBorders();H.refresh.call(this)},b=function(c){c.getRow=b[_$_c0e3[51]];c.moveRow=b.move;c.insertRow=b.add;c.deleteRow=b.del;c.getSelectedRows=
255
+ b.selected;c.showRow=k.bind(c,!0);c.hideRow=k.bind(c,!1)};b[_$_c0e3[51]]=function(c){return this.rows[c]};b.attached=function(c){return this.rows[c]&&this.rows[c].element&&this.rows[c].element.parentNode?!0:!1};b.selected=function(c){var a=[],d=this.getHighlighted();if(d)for(var e=d[1];e<=d[3];e++)c?a.push(e):a.push(this.rows[e].element);return a};b.create=function(c,a){if(this.rows[c]&&this.rows[c].element)return this.rows[c].element;this.rows[c]||na.row.call(this,c);var d=document.createElement(_$_c0e3[143]);
256
+ d.setAttribute(_$_c0e3[43],c);this.rows[c].element=d;var e=null;this.options.rows[c]&&!a&&(this.options.rows[c].style&&d.setAttribute(_$_c0e3[98],this.options.rows[c].style),this.options.rows[c].height&&(d.style.height=parseInt(this.options.rows[c].height)+_$_c0e3[44]),this.options.rows[c].title&&(e=this.options.rows[c].title),0==this.options.rows[c].visible&&(this.rows[c].visible=!1),this.options.rows[c].id&&(this.rows[c].id=this.options.rows[c].id));F.call(this.parent,_$_c0e3[267],this,c,d);0==
257
+ this.rows[c].visible&&(d.style.display=_$_c0e3[40]);e||(e=parseInt(c+1));a=document.createElement(_$_c0e3[145]);a.innerHTML=e;a.setAttribute(_$_c0e3[43],c);a.className=_$_c0e3[268];d.appendChild(a);return d};b.move=function(c,a){if(!R.call(this.parent,this))return!1;c=parseInt(c);a=parseInt(a);if(!this.rows[a]||!this.rows[c])return console.error(_$_c0e3[269]),!1;if(0<Object.keys(this.getMerge()).length){var d=null;this.merged.rows[c]?d=!0:this.merged.rows[a]&&(c>a?this.merged.rows[a-1]&&(d=!0):this.merged.rows[a+
258
+ 1]&&(d=!0));d&&this.destroyMerged()}this.resetBorders();0<=Array.prototype.indexOf.call(this.tbody.children,this.rows[a].element)?(d=H.renderRow.call(this,c),c>a?this.tbody.insertBefore(d,this.rows[a].element):this.tbody.insertBefore(d,this.rows[a].element.nextSibling)):this.rows[c].element&&(this.tbody.removeChild(this.rows[c].element),H.refresh.call(this));this.rows.splice(a,0,this.rows.splice(c,1)[0]);this.records.splice(a,0,this.records.splice(c,1)[0]);this.options.data.splice(a,0,this.options.data.splice(c,
259
+ 1)[0]);0<this.options.pagination&&this.tbody.children.length!=this.options.pagination&&this.page(this.pageNumber);K.call(this,_$_c0e3[66],{f:c,t:a});Y.references.call(this);Y.update.call(this);V.call(this.parent,{worksheet:this,action:_$_c0e3[66],oldValue:c,newValue:a});F.call(this.parent,_$_c0e3[270],this,c,a)};b.add=function(c,a,d,e){if(!R.call(this.parent,this))return!1;if(!this.options.allowInsertRow)return console.error(_$_c0e3[271]),!1;var f=[];if(0<c)var h=parseInt(c);else h=1,Array.isArray(c)&&
260
+ !e&&(Array.isArray(c[0])?e=c:(e=[],e.push(c)));e=Fa.standardize(e);d=d?!0:!1;var g=this.options.data?this.options.data.length-1:0;if(void 0==a||a>g||0>a)a=g,d=!1;h||(h=1);if(!1===F.call(this.parent,_$_c0e3[272],this,a,h,d))return console.log(_$_c0e3[273]),!1;this.resetBorders();var l=d?a:a+1,m=0;c=[];for(var p=[],n=this.rows.splice(l),q=this.options.data?this.options.data.splice(l):[],v=this.records.splice(l),u=l;u<h+l;u++){var y=e[m]&&e[m].id?e[m].id:sa.next.call(this);na.row.call(this,u,y);var w=
261
+ this.dataType?{}:[];for(var C=0;C<this.options.columns.length;C++){var A=Z.call(this,C);w[A]=_$_c0e3[3];e&&e[m]&&e[m].data&&(typeof e[m].data[A]!==_$_c0e3[13]?w[A]=e[m].data[A]:typeof e[m].data[C]!==_$_c0e3[13]&&(w[A]=e[m].data[C]));f.push({x:C,y:u,value:w[A],force:!0})}p.push({id:y,data:w});m++}this.rows=this.rows.concat(n);this.records=this.records.concat(v);this.options.data=this.options.data.concat(q);this.results&&0<this.results.length&&(g=this.results[this.results.length-1]);e=!1;n[0]?0<=Array.prototype.indexOf.call(this.tbody.children,
262
+ n[0].element)&&(e=!0):this.rows[g]?this.rows[g].element&&0<=Array.prototype.indexOf.call(this.tbody.children,this.rows[g].element)&&(e=!0):e=!0;for(u=l;u<h+l;u++)this.results&&(this.rows[u].results=!0),1==e&&(g=n[0]?n[0].element:null,A=H.renderRow.call(this,u,null,null,!0),g?this.tbody.insertBefore(A,g):this.tbody.appendChild(A),0<this.options.pagination?Array.prototype.indexOf.call(this.tbody.children,A)>=this.options.pagination&&(e=!1):H.limited.call(this)&&(H.isVisible.call(this,A.children[1])||
263
+ (e=!1))),c.push(this.records[u]);this.merged.rows[l]&&ba.updateConfig.call(this,1,1,l-1,h);K.call(this,_$_c0e3[62],{numOfRows:h,rowNumber:a,insertBefore:d?1:0,data:p});l=this.tbody.firstChild.getAttribute(_$_c0e3[43]);this.results&&(l=this.results.indexOf(parseInt(l)),this.results=ua.refresh.call(this));Y.references.call(this);f.length&&ea.applyValues.call(this,f);0<this.options.pagination?ta[_$_c0e3[11]].call(this,this.pageNumber):(this.results&&(l=this.results[l]),this.tbody.textContent=_$_c0e3[3],
264
+ H[_$_c0e3[46]].call(this,l));Y.update.call(this);U.call(this);ha.refresh.call(this);V.call(this.parent,{worksheet:this,action:_$_c0e3[62],rowNumber:a,numOfRows:h,insertBefore:d,data:p});F.call(this.parent,_$_c0e3[274],this,a,h,c,d)};b.del=function(c,a){if(!R.call(this.parent,this))return!1;if(!this.options.allowDeleteRow)return console.error(_$_c0e3[275]),!1;var d=null,e={},f=[],h=0;void 0==c&&(a=this.getSelectedRows(),a[0]?(c=parseInt(a[0].getAttribute(_$_c0e3[43])),a=a.length):(c=this.options.data.length-
265
+ 1,a=1));var g=this.options.data.length-1;if(void 0==c||c>g||0>c)c=g;a||(a=1);c+a>=this.options.data.length&&(a=this.options.data.length-c,a>=this.options.data.length&&(a=this.options.data.length,this.resetSelection()));if(!1===F.call(this.parent,_$_c0e3[276],this,c,a))return console.log(_$_c0e3[277]),!1;if(-1<parseInt(c)&&0<parseInt(a)){g=parseInt(this.thead.lastChild.children[1].getAttribute(_$_c0e3[42]));var l=parseInt(this.tbody.firstChild.getAttribute(_$_c0e3[43]));this.resetBorders();for(var m=
266
+ c;m<c+a;m++)for(var p=0;p<this.options.columns.length;p++)d=E.getColumnNameFromCoords(p,m),L.getAttributes.call(this,_$_c0e3[278],d,e),L.getAttributes.call(this,_$_c0e3[98],d,e),L.getAttributes.call(this,_$_c0e3[279],d,e),L.getAttributes.call(this,_$_c0e3[280],d,e),L.getAttributes.call(this,_$_c0e3[264],d,e),L.getAttributes.call(this,_$_c0e3[263],d,e),f[d]=!0;if(d=W.getChain.call(this,e.values))e.formulas=d;for(m=c;m<c+a;m++)0<=Array.prototype.indexOf.call(this.tbody.children,this.rows[m].element)&&
267
+ (this.rows[m].element.parentNode.removeChild(this.rows[m].element),h++);d=[];for(m=c;m<c+a;m++)d.push({id:this.getRowId(m),row:m,data:this.getRowData(m)});this.rows.splice(c,a);m=this.records.splice(c,a);this.options.data.splice(c,a);ba.updateConfig.call(this,1,0,c,a);K.call(this,_$_c0e3[63],{rowNumber:c,numOfRows:a,data:d});Y.references.call(this,f);this.results&&(this.results=ua.refresh.call(this));0<this.options.pagination?this.page(this.pageNumber,function(){if(0==this.tbody.children.length){var n=
268
+ this.whichPage(this.options.data.length-1);this.page(n)}}):H.limited.call(this)&&0<h&&(this.tbody.textContent=_$_c0e3[3],H.call(this),H[_$_c0e3[46]].call(this,l,g));Y.update.call(this,!0);V.call(this.parent,{worksheet:this,action:_$_c0e3[63],rowNumber:c,numOfRows:a,insertBefore:1,data:d,attributes:e});F.call(this.parent,_$_c0e3[281],this,c,a,m,d,e)}};return b}(),Xa=function(){var k=function(c,a){Array.isArray(a)||(a=[a]);for(var d,e,f=Object.keys(a),h=0;h<f.length;h++)if(d=a[f[h]],e=this.options.columns[d])this.colgroup[d]&&
269
+ (this.colgroup[d].style.width=c?parseInt(e.width||this.options.defaultColWidth)+_$_c0e3[44]:_$_c0e3[142]),e.visible=c;H.refresh.call(this);0<this.options.freezeColumns&&ka[_$_c0e3[11]].call(this,this.options.freezeColumns);this.resetBorders()},b=function(c){c.getColumn=b[_$_c0e3[51]];c.getColumnIdByName=b.getByName;c.getPrimaryKey=b.getPrimaryKey;c.getSelectedColumns=b.selected;c.moveColumn=b.move;c.insertColumn=b.add;c.deleteColumn=b.del;c.showColumn=k.bind(c,!0);c.hideColumn=k.bind(c,!1)};b[_$_c0e3[51]]=
270
+ function(c){return this.options.columns[c]||!1};b.getByName=function(c){for(var a=this.options.columns,d=0;d<a.length;d++)if(a[d].name==c)return d;return!1};b.getPrimaryKey=function(){for(var c=0;c<this.options.columns.length;c++)if(1==this.options.columns[c].primaryKey)return c;return!1};b.selected=function(c){c=[];var a=this.getHighlighted();if(a)for(var d=a[0];d<=a[2];d++)c.push(d);return c};b.move=function(c,a){if(!R.call(this.parent,this))return!1;c=parseInt(c);a=parseInt(a);if(!this.options.columns[c])return console.error(_$_c0e3[282]),
271
+ !1;if(!this.options.columns[a])return console.error(_$_c0e3[283]),!1;if(0<Object.keys(this.getMerge()).length){var d=null;this.merged.cols[c]?d=!0:this.merged.cols[a]&&(c>a?this.merged.cols[a-1]&&(d=!0):this.merged.cols[a+1]&&(d=!0));d&&this.destroyMerged()}this.resetBorders();d=this.options.freezeColumns;0<d&&(c<d||a<d)?ka.reset.call(this):d=null;if(this.headers[a]&&this.headers[a].parentNode){this.headers[c]||Ca.create.call(this,c);var e=(c>a?this.headers[a]:this.headers[a].nextSibling)||null;this.headerContainer.insertBefore(this.headers[c],
272
+ e);e=(c>a?this.colgroup[a]:this.colgroup[a].nextSibling)||null;this.colgroupContainer.insertBefore(this.colgroup[c],e);for(var f=0;f<this.tbody.children.length;f++){var h=this.tbody.children[f].getAttribute(_$_c0e3[43]);e=(c>a?this.records[h][a].element:this.records[h][a].element.nextSibling)||null;this.tbody.children[f].insertBefore(L[_$_c0e3[51]].call(this,c,h),e)}if(this.options.footers)for(f=0;f<this.tfoot.children.length;f++)e=(c>a?this.footers.content[f][a].element:this.footers.content[f][a].element.nextSibling)||
273
+ null,this.tfoot.children[f].insertBefore(aa.create.call(this,c,f),e)}else if(this.headers[c]&&this.headers[c].parentNode){this.headerContainer.removeChild(this.headers[c]);this.colgroupContainer.removeChild(this.colgroup[c]);for(f=0;f<this.tbody.children.length;f++)h=parseInt(this.tbody.children[f].getAttribute(_$_c0e3[43])),this.tbody.children[f].removeChild(this.records[h][c].element);if(this.options.footers)for(f=0;f<this.tfoot.children.length;f++)this.tfoot.children[f].removeChild(this.footers.content[f][c].element)}this.options.columns.splice(a,
274
+ 0,this.options.columns.splice(c,1)[0]);this.headers.splice(a,0,this.headers.splice(c,1)[0]);this.colgroup.splice(a,0,this.colgroup.splice(c,1)[0]);for(f=0;f<this.rows.length;f++)this.dataType||this.options.data[f].splice(a,0,this.options.data[f].splice(c,1)[0]),this.records[f].splice(a,0,this.records[f].splice(c,1)[0]);if(this.options.footers)for(f=0;f<this.options.footers.length;f++)this.options.footers[f].splice(a,0,this.options.footers[f].splice(c,1)[0]),this.footers.content[f].splice(a,0,this.footers.content[f].splice(c,
275
+ 1)[0]);K.call(this,_$_c0e3[67],{f:c,t:a});Y.references.call(this);Y.update.call(this);0<d&&(c<=d||d<=d)&&ka[_$_c0e3[11]].call(this,d);V.call(this.parent,{worksheet:this,action:_$_c0e3[67],oldValue:c,newValue:a});F.call(this.parent,_$_c0e3[284],this,c,a)};b.add=function(c,a,d,e,f,h){if(!R.call(this.parent,this))return!1;if(!this.options.allowInsertColumn)return console.error(_$_c0e3[285]),!1;var g=[];if(0<c)var l=parseInt(c);else if(l=1,Array.isArray(c)&&!f)if(Array.isArray(c[0]))f=c;else{f=[];for(var m=
276
+ 0;m<c.length;m++)f[m]=[c[m]]}f||(f=[]);d=d?!0:!1;c=this.options.columns.length-1;if(void 0==a||a>c||0>a)a=c,d=!1;l||(l=1);if(!1===F.call(this.parent,_$_c0e3[286],this,a,l,d))return console.log(_$_c0e3[287]),!1;ha.reset.call(this);if(1==this.dataType)var p=parseInt((_$_c0e3[3]+Date.now()).substr(-8));e||(e=[]);for(m=0;m<l;m++)e[m]||(e[m]={type:_$_c0e3[55],source:[],options:[],width:this.options.defaultColWidth}),1==this.dataType&&typeof e[m].name==_$_c0e3[13]&&(e[m].name=_$_c0e3[288]+(p+m));var n=
277
+ d?a:a+1;this.options.columns=E.injectArray(this.options.columns,n,e);p=function(w,C){for(var A=n;A<l+n;A++)Ca.create.call(this,A),w?(this.headerContainer.insertBefore(this.headers[A],w),this.colgroupContainer.insertBefore(this.colgroup[A],C)):(this.headerContainer.appendChild(this.headers[A]),this.colgroupContainer.appendChild(this.colgroup[A]))};m=function(w,C){if(C)for(var A=n;A<l+n;A++)this.rows[w].element.insertBefore(L[_$_c0e3[51]].call(this,A,w,!0),C);else for(A=n;A<l+n;A++)this.rows[w].element.appendChild(L[_$_c0e3[51]].call(this,
278
+ A,w,!0))};var q=this.headers.splice(n),v=this.colgroup.splice(n);q[0]?0<=Array.prototype.indexOf.call(this.headerContainer.children,q[0])&&p.call(this,q[0],v[0]):this.headers[c]&&0<=Array.prototype.indexOf.call(this.headerContainer.children,this.headers[c])&&p.call(this);this.headers=this.headers.concat(q);this.colgroup=this.colgroup.concat(v);aa.adjust.call(this,n,l,1);oa.adjust.call(this,a,l,1,h);h=0;v=q=p=null;for(var u=0;u<this.options.data.length;u++){this.dataType||(q=this.options.data[u].splice(n));
279
+ v=this.records[u].splice(n);h=0;for(var y=n;y<l+n;y++)p=f[u]&&f[u][h]?f[u][h]:_$_c0e3[3],M.call(this,y,u,p),g.push({x:y,y:u,value:p}),na.cell.call(this,y,u),h++;this.rows[u].element&&this.rows[u].element.parentNode&&(v[0]?0<=Array.prototype.indexOf.call(this.rows[u].element.children,v[0].element)&&m.call(this,u,v[0].element):this.records[u][c].element&&0<=Array.prototype.indexOf.call(this.rows[u].element.children,this.records[u][c].element)&&m.call(this,u));this.dataType||(this.options.data[u]=this.options.data[u].concat(q));
280
+ this.records[u]=this.records[u].concat(v)}this.merged.cols[n]&&ba.updateConfig.call(this,0,1,n-1,l);K.call(this,_$_c0e3[64],{numOfColumns:l,columnNumber:a,insertBefore:d?1:0,properties:e,data:f});Y.references.call(this);g.length&&ea.applyValues.call(this,g);Y.update.call(this);this.refreshBorders();V.call(this.parent,{worksheet:this,action:_$_c0e3[64],columnNumber:a,numOfColumns:l,insertBefore:d,properties:e,data:f});F.call(this.parent,_$_c0e3[289],this,a,l,[],d)};b.del=function(c,a){if(!R.call(this.parent,
281
+ this))return!1;if(!this.options.allowDeleteColumn)return console.error(_$_c0e3[290]),!1;var d={},e=[],f=0;if(1<this.options.columns.length){void 0==c&&(a=this.getSelectedColumns(!0),a.length?(c=parseInt(a[0]),a=parseInt(a.length)):(c=this.options.columns.length-1,a=1));var h=this.options.columns.length-1;if(void 0==c||c>h||0>c)c=h;a||(a=1);c+a>=this.options.columns.length&&(a=this.options.columns.length-c,a>=this.options.columns.length&&(a--,console.error(_$_c0e3[291])));if(!1===F.call(this.parent,
282
+ _$_c0e3[292],this,c,a))return console.log(_$_c0e3[293]),!1;if(-1<parseInt(c)&&0<parseInt(a)){h=parseInt(this.thead.lastChild.children[1].getAttribute(_$_c0e3[42]));var g=0;this.tbody.firstChild&&(g=parseInt(this.tbody.firstChild.getAttribute(_$_c0e3[43])));this.resetBorders();var l=null,m=[],p=[],n=[];var q=0;for(var v=c;v<c+a;v++)0<=Array.prototype.indexOf.call(this.headerContainer.children,this.headers[v])&&(this.colgroup[v].parentNode.removeChild(this.colgroup[v]),this.headers[v].parentNode.removeChild(this.headers[v]),
283
+ f++),n[q]=this.options.columns[v],q++;for(var u=0;u<this.options.data.length;u++)for(v=c;v<c+a;v++)q=E.getColumnNameFromCoords(v,u),L.getAttributes.call(this,_$_c0e3[278],q,d),L.getAttributes.call(this,_$_c0e3[98],q,d),L.getAttributes.call(this,_$_c0e3[279],q,d),L.getAttributes.call(this,_$_c0e3[280],q,d),L.getAttributes.call(this,_$_c0e3[264],q,d),L.getAttributes.call(this,_$_c0e3[263],q,d),e[q]=!0,this.records[u][v].element&&0<=Array.prototype.indexOf.call(this.rows[u].element.children,this.records[u][v].element)&&
284
+ this.records[u][v].element.parentNode.removeChild(this.records[u][v].element);if(v=W.getChain.call(this,d.values))d.formulas=v;this.options.columns.splice(c,a);this.headers.splice(c,a);this.colgroup.splice(c,a);for(u=0;u<this.options.data.length;u++)this.dataType||(p[u]=this.options.data[u].splice(c,a)),m[u]=this.records[u].splice(c,a);aa.adjust.call(this,c,a,0);(v=oa.adjust.call(this,c,a,0))&&(l={nested:v});ba.updateConfig.call(this,0,0,c,a);K.call(this,_$_c0e3[65],{columnNumber:c,numOfColumns:a});
285
+ Y.references.call(this,e);H.limited.call(this)&&0<f&&(this.tbody.textContent=_$_c0e3[3],H.call(this),H[_$_c0e3[46]].call(this,g,h));Y.update.call(this,!0);V.call(this.parent,{worksheet:this,action:_$_c0e3[65],columnNumber:c,numOfColumns:a,insertBefore:1,data:p,properties:n,attributes:d,extra:l});F.call(this.parent,_$_c0e3[294],this,c,a,m,n,d)}}};return b}(),Qa=function(){var k={},b={},c=function(d){if(typeof d==_$_c0e3[17]){var e=d;d=E.getCoordsFromColumnName(d);var f=d[0];d=d[1]}else f=d.x,d=d.y,
286
+ e=E.getColumnNameFromCoords(f,d);this.records[d]&&this.records[d][f]&&this.records[d][f].element&&(b[e]=this.options.style[e],this.records[d][f].element.setAttribute(_$_c0e3[98],_$_c0e3[3]));this.options.style&&this.options.style[e]&&delete this.options.style[e]},a=function(d){d.getStyle=a[_$_c0e3[51]];d.setStyle=a[_$_c0e3[11]];d.resetStyle=a.reset};a[_$_c0e3[51]]=function(d){var e=this.options.style;if(!e)return!1;if(d){if(typeof d==_$_c0e3[17])return e[d];var f=[],h=Object.keys(d);if(0<h.length)for(var g=
287
+ 0;g<h.length;g++){if(typeof d[g]==_$_c0e3[17])var l=e&&e[d[g]]?e[d[g]]:_$_c0e3[3];else l=E.getColumnNameFromCoords(d[g].x,d[g].y),l=e&&e[l]?e[l]:_$_c0e3[3];f.push(l)}return f}return this.options.style};a[_$_c0e3[11]]=function(d,e,f,h){if(!R.call(this.parent,this))return!1;this.options.style||(this.options.style={});var g=this.options.style,l=null,m=[],p=[],n={};p=function(u,y,w){if(!n[u]&&(g[u]?m=g[u].split(_$_c0e3[216]):(g[u]=_$_c0e3[3],m=[]),n[u]={},m.length))for(var C=0;C<m.length;C++)m[C]&&m[C].trim()&&
288
+ (l=m[C].split(_$_c0e3[134]),n[u][l[0].trim()]=l[1].trim());b[u]||(b[u]=[]);k[u]||(k[u]=[]);n[u][y]||(n[u][y]=_$_c0e3[3]);b[u].push([y+_$_c0e3[134]+n[u][y]]);n[u][y]=n[u][y]&&n[u][y]==w&&!h?_$_c0e3[3]:w;k[u].push([y+_$_c0e3[134]+n[u][y]]);w=E.getCoordsFromColumnName(u);this.records[w[1]]&&this.records[w[1]][w[0]]&&this.records[w[1]][w[0]].element&&(this.records[w[1]][w[0]].element.style[y]=n[u][y]);n[u][y]||delete n[u][y]};k={};b={};if(e)if(typeof d==_$_c0e3[17])p.call(this,d,e,f);else{if(d&&d.length)for(var q=
289
+ 0;q<d.length;q++){var v=E.getColumnNameFromCoords(d[q].x,d[q].y);p.call(this,v,e,f)}}else for(f=Object.keys(d),q=0;q<f.length;q++)if(v=d[f[q]])for(typeof v==_$_c0e3[17]&&(v=v.split(_$_c0e3[216])),e=0;e<v.length;e++)v[e]&&(typeof v[e]==_$_c0e3[17]&&(v[e]=v[e].split(_$_c0e3[134])),v[e][0].trim()&&p.call(this,f[q],v[e][0].trim(),v[e][1].trim()));m={};p=Object.keys(n);if(p.length){for(q=0;q<p.length;q++){m[p[q]]||(m[p[q]]=[]);d=Object.keys(n[p[q]]);for(e=0;e<d.length;e++)m[p[q]].push(d[e]+_$_c0e3[113]+
290
+ n[p[q]][d[e]]);this.options.style[p[q]]=m[p[q]].join(_$_c0e3[295])}p=Object.keys(k);for(q=0;q<p.length;q++)k[p[q]]=k[p[q]].join(_$_c0e3[216]);p=Object.keys(b);for(q=0;q<p.length;q++)b[p[q]]=b[p[q]].join(_$_c0e3[216]);this.refreshBorders();V.call(this.parent,{worksheet:this,action:_$_c0e3[70],oldValue:b,newValue:k});K.call(this,_$_c0e3[70],[k]);F.call(this.parent,_$_c0e3[296],this,k,b)}};a.reset=function(d){if(!R.call(this.parent,this))return!1;if(d){b={};if(Array.isArray(d))for(var e=0;e<d.length;e++)c.call(this,
291
+ d[e]);else c.call(this,d);this.refreshBorders();V.call(this.parent,{worksheet:this,action:_$_c0e3[71],cells:d,oldValue:b});K.call(this,_$_c0e3[71],[d]);F.call(this.parent,_$_c0e3[298],this,d)}else console.error(_$_c0e3[297])};a.update=function(d){k={};b={};for(var e,f=Object.keys(d),h=0;h<f.length;h++){b[f[h]]=this.options.style[f[h]]||_$_c0e3[3];k[f[h]]=this.options.style[f[h]]=d[f[h]];e=E.getCoordsFromColumnName(f[h]);var g=e[0],l=e[1];this.records[l]&&this.records[l][g]&&this.records[l][g].element&&
292
+ (this.records[l][g].element.setAttribute(_$_c0e3[98],d[f[h]]),!this.records[l][g].element.style.textAlign&&(e=this.options.columns[g].align?this.options.columns[g].align:this.options.defaultColAlign))&&(this.records[l][g].element.style.textAlign=e)}K.call(this,_$_c0e3[71],[f]);K.call(this,_$_c0e3[70],[k]);F.call(this.parent,_$_c0e3[296],this,k,b)};return a}(),Ya=function(){var k=function(b){b.getComments=k[_$_c0e3[51]];b.setComments=k[_$_c0e3[11]]};k[_$_c0e3[51]]=function(b){return b&&typeof b==_$_c0e3[17]?
293
+ this.options.comments&&this.options.comments[b]?this.options.comments[b]:!1:this.options.comments};k[_$_c0e3[11]]=function(b,c){if(!R.call(this.parent,this))return!1;if(typeof b==_$_c0e3[17]){var a={};a[b]=c}else a=b;if(c=F.call(this.parent,_$_c0e3[299],this,a))a=c;else if(!1===c)return!1;this.options.comments||(this.options.comments={});b={};var d=Object.keys(a);if(d.length){for(var e=0;e<d.length;e++){var f=E.getCoordsFromColumnName(d[e]);this.records[f[1]]&&this.records[f[1]][f[0]]&&(b[d[e]]=this.options.comments[d[e]]||
294
+ _$_c0e3[3],(c=a[d[e]])?this.options.comments[d[e]]=c:delete this.options.comments[d[e]],this.records[f[1]][f[0]].element&&(c?this.records[f[1]][f[0]].element.setAttribute(_$_c0e3[265],c):this.records[f[1]][f[0]].element.removeAttribute(_$_c0e3[265])))}V.call(this.parent,{worksheet:this,action:_$_c0e3[75],newValue:a,oldValue:b});K.call(this,_$_c0e3[75],[a]);F.call(this.parent,_$_c0e3[300],this,a,b)}};return k}(),Za=function(){var k=function(b){b.getMeta=k[_$_c0e3[51]];b.setMeta=k[_$_c0e3[11]];b.resetMeta=
295
+ k.reset};k[_$_c0e3[51]]=function(b,c){if(b){if(this.options.meta[b])return c?this.options.meta[b][c]:this.options.meta[b]}else return this.options.meta};k[_$_c0e3[11]]=function(b,c,a){if(!R.call(this.parent,this))return!1;this.options.meta||(this.options.meta={});if(typeof b==_$_c0e3[17]&&c){a||(a=_$_c0e3[3]);var d={};d[b]={};d[b][c]=a;b=d}c=Object.keys(b);if(c.length){a={};for(d=0;d<c.length;d++){this.options.meta[c[d]]||(this.options.meta[c[d]]={});a[c[d]]||(a[c[d]]={});for(var e=Object.keys(b[c[d]]),
296
+ f=0;f<e.length;f++)this.options.meta[c[d]][e[f]]=b[c[d]][e[f]],a[c[d]][e[f]]=b[c[d]][e[f]]}Object.keys(a).length&&(K.call(this,_$_c0e3[301],[a]),F.call(this.parent,_$_c0e3[302],this,a))}};k.reset=function(){this.options.meta={};K.call(this,_$_c0e3[303],{});F.call(this.parent,_$_c0e3[304],this,{})};return k}(),$a=function(){var k=function(b){b.orderBy=k.execute};k.handler=function(b,c){return function(a,d){a=a[1];d=d[1];return b?a===_$_c0e3[3]&&d!==_$_c0e3[3]?1:a!==_$_c0e3[3]&&d===_$_c0e3[3]?-1:a>
297
+ d?-1:a<d?1:0:a===_$_c0e3[3]&&d!==_$_c0e3[3]?1:a!==_$_c0e3[3]&&d===_$_c0e3[3]?-1:a>d?1:a<d?-1:0}};k.execute=function(b,c,a){if(0<=b){c=null==c?this.headers[b].classList.contains(_$_c0e3[305])?1:0:c?1:0;for(var d,e,f=[],h=0;h<this.options.data.length;h++)d=Ha[_$_c0e3[51]].call(this,b,h),e=this.records[h][b].v,e=d.type==_$_c0e3[253]||d.type==_$_c0e3[258]||d.type==_$_c0e3[259]||d.type==_$_c0e3[306]||d.type==_$_c0e3[14]||d.type==_$_c0e3[307]?Number(e):jSuites.isNumeric(e)?Number(e):e.toLowerCase(),f[h]=
298
+ [h,e];h=typeof this.parent.config.sorting===_$_c0e3[84]?this.parent.config.sorting(c,b):k.handler(c,b);f.sort(h);d=a?!0:!1;if(!a)for(a=[],h=0;h<f.length;h++)a[h]=f[h][0];if(h=F.call(this.parent,_$_c0e3[308],this,b,c,a))a=h;else if(!1===h)return!1;if(d)this.destroyMerged();else if(0<Object.keys(this.getMerge()).length)if(confirm(B(_$_c0e3[309])))this.destroyMerged();else return!1;if(a.length<f.length)for(h=0;h<f.length;h++)-1==a.indexOf(f[h][0])&&a.push(f[h][0]);f=[];for(h=0;h<a.length;h++)f[a[h]]=
299
+ h;Ea.call(this,!1);ha.reset.call(this);K.call(this,_$_c0e3[76],{column:b,direction:c,order:a});k.update.call(this,a);k.arrow.call(this,b,c);ha.refresh.call(this);V.call(this.parent,{worksheet:this,action:_$_c0e3[76],column:b,newValue:a,oldValue:f,direction:c});F.call(this.parent,_$_c0e3[310],this,b,c,a);return!0}};k.update=function(b){for(var c=[],a=0;a<b.length;a++)c[a]=this.options.data[b[a]];for(a=0;a<b.length;a++)this.options.data[a]=c[a];c=[];for(a=0;a<b.length;a++)c[a]=this.records[b[a]];this.records=
300
+ c;c=[];for(a=0;a<b.length;a++)c[a]=this.rows[b[a]];this.rows=c;Y.references.call(this);this.searchInput&&this.searchInput.value?qa.update.call(this,null):ca.update.call(this)};k.arrow=function(b,c){for(var a=0;a<this.headers.length;a++)this.headers[a].classList.remove(_$_c0e3[311]),this.headers[a].classList.remove(_$_c0e3[305]);c?this.headers[b].classList.add(_$_c0e3[311]):this.headers[b].classList.add(_$_c0e3[305])};return k}(),ta=function(){var k=function(b){b.whichPage=k.whichPage;b.quantityOfPages=
301
+ k.quantityOfPages;b.page=k[_$_c0e3[11]];b.updatePagination=k.update};k.build=function(){this.pageNumber=0;var b=document.createElement(_$_c0e3[20]),c=document.createElement(_$_c0e3[20]);this.pagination=document.createElement(_$_c0e3[20]);this.pagination.classList.add(_$_c0e3[312]);this.pagination.appendChild(b);this.pagination.appendChild(c);this.options.pagination||(this.pagination.style.display=_$_c0e3[40]);this.element.appendChild(this.pagination)};k.pageUp=function(){0<this.pageNumber&&(this.pageNumber--,
302
+ k[_$_c0e3[11]].call(this,this.pageNumber))};k.pageDown=function(){this.pageNumber<k.quantityOfPages.call(this)-1&&(this.pageNumber++,k[_$_c0e3[11]].call(this,this.pageNumber))};k.whichPage=function(b){if(0<this.options.pagination)return this.rows[b]?(this.results&&(b=this.results.indexOf(parseInt(b))),Math.ceil((parseInt(b)+1)/parseInt(this.options.pagination))-1):null;console.log(_$_c0e3[313]);return!1};k.quantityOfPages=function(){if(0<this.options.pagination)return Math.ceil((this.results?this.results.length:
303
+ this.rows.length)/parseInt(this.options.pagination));console.log(_$_c0e3[313]);return!1};k[_$_c0e3[11]]=function(b,c){var a=this.pageNumber,d=parseInt(this.options.pagination);if(d){if(null==b||-1==b)b=Math.ceil((this.results?this.results:this.rows).length/d)-1;if(!1===F.call(this.parent,_$_c0e3[315],this,b,a,d))return!1;this.pageNumber=b;H.resetY.call(this);aa.refresh.call(this);typeof c==_$_c0e3[84]&&c.call(this);F.call(this.parent,_$_c0e3[316],this,b,a,d)}else console.error(_$_c0e3[314])};k.update=
304
+ function(){this.pagination.children[0].innerHTML=_$_c0e3[3];this.pagination.children[1].innerHTML=_$_c0e3[3];if(this.options.pagination){var b=this.results?this.results.length:this.rows.length;if(b){b=Math.ceil(b/this.options.pagination);if(6>this.pageNumber)var c=1,a=10>b?b:10;else 5>b-this.pageNumber?(c=b-9,a=b,1>c&&(c=1)):(c=this.pageNumber-4,a=this.pageNumber+5);if(1<c){var d=document.createElement(_$_c0e3[20]);d.className=_$_c0e3[318];d.innerHTML=_$_c0e3[214];d.title=1;this.pagination.children[1].appendChild(d)}for(;c<=
305
+ a;c++)d=document.createElement(_$_c0e3[20]),d.className=_$_c0e3[318],d.innerHTML=c,this.pagination.children[1].appendChild(d),this.pageNumber==c-1&&d.classList.add(_$_c0e3[319]);a<b&&(d=document.createElement(_$_c0e3[20]),d.className=_$_c0e3[318],d.innerHTML=_$_c0e3[215],d.title=b,this.pagination.children[1].appendChild(d));this.pagination.children[0].innerHTML=B(_$_c0e3[320],[this.pageNumber+1,b])}else this.pagination.children[0].innerHTML=B(_$_c0e3[317])}};return k}(),ka=function(){var k=function(b){b.setFreezeColumns=
306
+ k[_$_c0e3[11]];b.resetFreezeColumns=k.reset};k.width=function(){if(this.options.freezeColumns){k.headers.call(this);for(var b=0;b<this.rows.length;b++)this.rows[b].element&&k.update.call(this,b)}};k.update=function(b){var c,a;if(a=this.options.freezeColumns){var d=xa.call(this)?50:0;if(this.rows[b].element)for(var e=0;e<a;e++){if(c=this.records[b][e].element)c.classList.add(_$_c0e3[50]),c.style.left=d+1+_$_c0e3[44];!1!==this.options.columns[e].visible&&(d+=this.options.columns[e].width)}}};k.headers=
307
+ function(){var b=xa.call(this)?50:0,c;if(c=this.options.freezeColumns)for(var a=0;a<c;a++){if(this.headers[a]){this.headers[a].classList.add(_$_c0e3[50]);this.headers[a].style.left=b+1+_$_c0e3[44];if(this.options.footers)for(var d=0;d<this.options.footers.length;d++)this.footers.content[d][a].element.classList.add(_$_c0e3[50]),this.footers.content[d][a].element.style.left=b+1+_$_c0e3[44];!1!==this.options.columns[a].visible&&(b+=this.options.columns[a].width)}}else k.reset.call(this)};k[_$_c0e3[11]]=
308
+ function(b){k.reset.call(this);this.options.freezeColumns=b;k.width.call(this);H.limited.call(this)&&U.call(this)};k.reset=function(){H[_$_c0e3[46]].call(this,null,this.options.freezeColumns);for(var b,c=1;c<=this.options.freezeColumns;c++){if(b=this.thead.lastChild)b.children[c].classList.remove(_$_c0e3[50]),b.children[c].style.left=_$_c0e3[3];for(var a=0;a<this.rows.length;a++)if(b=this.rows[a].element)b.children[c].classList.remove(_$_c0e3[50]),b.children[c].style.left=_$_c0e3[3];if(this.options.footers)for(a=
309
+ 0;a<this.options.footers.length;a++)this.tfoot.children[a].children[c].classList.remove(_$_c0e3[50]),this.tfoot.children[a].children[c].style.left=_$_c0e3[3]}this.options.freezeColumns=0};k.getWidth=function(){var b=xa.call(this)?50:0;if(0<this.options.freezeColumns)for(var c=0;c<=this.options.freezeColumns;c++)b=this.thead.lastChild.children[c]?b+this.thead.lastChild.children[c].offsetWidth:b+this.options.columns[c].width;return b};return k}(),Y=function(){var k=function(a,d){if(this.options[a]){for(var e=
310
+ {},f=Object.keys(this.options[a]),h=0;h<f.length;h++)e[d&&void 0!=d[f[h]]?d[f[h]]:f[h]]=this.options[a][f[h]];this.options[a]=e}},b=function(){if(0<this.options.minSpareRows){for(var a=0,d=this.rows.length-1;0<=d;d--){for(var e=!1,f=0;f<this.options.columns.length;f++)M.call(this,f,d)&&(e=!0);if(e)break;else a++}0<this.options.minSpareRows-a&&this.insertRow(this.options.minSpareRows-a)}if(0<this.options.minSpareCols){a=0;for(f=this.options.columns.length-1;0<=f;f--){e=!1;for(d=0;d<this.rows.length;d++)M.call(this,
311
+ f,d)&&(e=!0);if(e)break;else a++}0<this.options.minSpareCols-a&&this.insertColumn(this.options.minSpareCols-a)}},c=function(){};c.build=function(){var a=this;this.content=document.createElement(_$_c0e3[20]);this.content.classList.add(_$_c0e3[321]);this.content.addEventListener(_$_c0e3[322],function(f){if(H.limited.call(a)&&!a.options.pagination){var h=Math.abs(f.deltaX),g=Math.abs(f.deltaY);f.shiftKey||h>g?0>f.deltaX||0>f.deltaY?H.pageLeft.call(a,1,null,f):H.pageRight.call(a,1,null,f):0>f.deltaY?
312
+ H.pageUp.call(a,1,null,f):H.pageDown.call(a,1,null,f)}});this.content.addEventListener(_$_c0e3[323],function(f){if(!a.edition)return f.preventDefault(),!1});this.table=document.createElement(_$_c0e3[324]);this.thead=document.createElement(_$_c0e3[325]);this.tbody=document.createElement(_$_c0e3[326]);this.tfoot=document.createElement(_$_c0e3[327]);this.headers=[];this.colgroup=[];this.colgroupContainer=document.createElement(_$_c0e3[328]);var d=document.createElement(_$_c0e3[167]);d.setAttribute(_$_c0e3[150],
313
+ _$_c0e3[329]);this.colgroupContainer.appendChild(d);this.headerContainer=document.createElement(_$_c0e3[143]);d=document.createElement(_$_c0e3[145]);d.classList.add(_$_c0e3[330]);this.headerContainer.appendChild(d);this.thead.appendChild(this.headerContainer);this.table.classList.add(_$_c0e3[331]);this.table.setAttribute(_$_c0e3[332],_$_c0e3[97]);this.table.setAttribute(_$_c0e3[333],_$_c0e3[97]);this.table.setAttribute(_$_c0e3[334],_$_c0e3[335]);this.table.appendChild(this.colgroupContainer);this.table.appendChild(this.thead);
314
+ this.table.appendChild(this.tbody);this.table.appendChild(this.tfoot);this.parent.config.wordWrap&&this.table.classList.add(_$_c0e3[336]);this.options.textOverflow||this.table.classList.add(_$_c0e3[337]);!1===this.options.selectLockedCells&&this.table.classList.add(_$_c0e3[338]);this.corner=document.createElement(_$_c0e3[20]);this.corner.className=_$_c0e3[339];this.corner.setAttribute(_$_c0e3[334],_$_c0e3[340]);this.corner.setAttribute(_$_c0e3[341],_$_c0e3[342]);0==this.options.selectionCopy&&(this.corner.style.display=
315
+ _$_c0e3[40]);this.scrollX=U.build.call(a,_$_c0e3[45]);this.scrollY=U.build.call(a,_$_c0e3[343]);d=document.createElement(_$_c0e3[20]);d.appendChild(this.content);d.appendChild(this.scrollY);d.classList.add(_$_c0e3[344]);var e=document.createElement(_$_c0e3[20]);e.appendChild(d);e.appendChild(this.scrollX);e.classList.add(_$_c0e3[345]);this.content.appendChild(this.table);this.content.appendChild(this.corner);this.element.appendChild(e);1==this.options.tableOverflow&&(this.options.tableHeight||(this.options.tableHeight=
316
+ 300),this.options.tableWidth||(this.options.tableWidth=document.body.offsetWidth-8),this.content.style.overflow=_$_c0e3[49],this.content.style.maxHeight=parseInt(this.options.tableHeight)+_$_c0e3[44],this.content.style.maxWidth=parseInt(this.options.tableWidth)+_$_c0e3[44]);this.options.freezeColumns>this.options.columns.length&&console.error(_$_c0e3[346]);qa.build.call(this);oa.build.call(this);ta.build.call(this);Fa.build.call(this);ba.build.call(this);aa.build.call(this);H.call(this);ca.onload.call(this);
317
+ b.call(this)};c.references=function(a){var d=[],e=[],f=null,h=null,g=null,l=null;for(f=0;f<this.options.columns.length;f++)if(h=this.headers[f])g=h.getAttribute(_$_c0e3[42]),g!=f&&(h.setAttribute(_$_c0e3[42],f),h.getAttribute(_$_c0e3[164])||(h.innerHTML=E.getColumnName(f)));for(var m=0;m<this.rows.length;m++)h=this.rows[m],l=h.y,l!=m&&(h.y=m,d[l]=m,h.element&&(h.element.setAttribute(_$_c0e3[43],m),h.element.children[0].setAttribute(_$_c0e3[43],m),f=this.options.rows&&this.options.rows[l]&&this.options.rows[l].title?
318
+ this.options.rows[l].title:m+1,h.element.children[0].innerHTML=f));var p=function(q,v){h=this.records[v][q];g=h.x;l=h.y;g!=q&&(h.x=q,h.element&&h.element.setAttribute(_$_c0e3[42],q));l!=v&&(h.y=v,h.element&&h.element.setAttribute(_$_c0e3[43],v));if(g!=q||l!=v){var u=E.getColumnNameFromCoords(g,l);q=E.getColumnNameFromCoords(q,v);e[u]=q}};if(a){m=function(q,v){q&&q[v]&&delete q[v]};var n=Object.keys(a);for(f=0;f<n.length;f++)m(this,n[f]),m(this.options.meta,n[f]),m(this.options.cells,n[f]),m(this.options.style,
319
+ n[f]),m(this.options.comments,n[f])}for(m=0;m<this.rows.length;m++)for(f=0;f<this.options.columns.length;f++)p.call(this,f,m);k.call(this,_$_c0e3[347],d);k.call(this,_$_c0e3[278],e);k.call(this,_$_c0e3[279],e);k.call(this,_$_c0e3[98],e);k.call(this,_$_c0e3[280],e);k.call(this,_$_c0e3[264],e);this.options.mergeCells&&ba.build.call(this);W.updateAll.call(this,e,a);return e};c.update=function(a){a&&b.call(this);if(typeof this.parent.config.updateTable==_$_c0e3[84])for(var d=0;d<this.rows.length;d++)for(var e=
320
+ 0;e<this.options.columns.length;e++)a=this.records[d][e],this.parent.config.updateTable.call(this,this,a.element,e,d,M.call(this,e,d),a.r?a.r:a.v);U.call(this);aa.refresh.call(this)};return c}(),na=function(){var k={spreadsheet:function(b,c){var a={name:null,config:{},el:b,element:b,plugins:[],worksheets:[],history:[],historyIndex:-1,queue:[],ignoreEvents:!1,ignoreHistory:!1,ignorePersistence:!1};Da.spreadsheet.call(a,c);a.config.license&&(t.license=a.config.license);b.spreadsheet=a;b.jspreadsheet=
321
+ b.jexcel=a.worksheets;t.spreadsheet.push(a);a.name||(a.name=jSuites.guid());k.bind(a.config.root?a.config.root:document);var d=a.config.tabs;typeof d!==_$_c0e3[83]&&(d={allowCreate:d?!0:!1,hideHeaders:d?!1:!0,allowChangePosition:a.config.allowMoveWorksheet?!0:!1});d.maxWidth||(d.maxWidth=b.offsetWidth-50+_$_c0e3[44]);d.animation=void 0==d.animation?!0:d.animation;d.onbeforecreate=function(){a.createWorksheet();return!1};d.onclick=function(f,h,g,l,m){0<=g&&a.openWorksheet(g)};d.onchangeposition=function(f,
322
+ h,g){a.updateWorksheet(h,g)};jSuites.tabs(b,d);b.classList.add(_$_c0e3[348]);1==c.fullscreen&&b.classList.add(_$_c0e3[15]);var e=document.createElement(_$_c0e3[20]);a.toolbar=document.createElement(_$_c0e3[20]);a.toolbar.className=_$_c0e3[349];e.appendChild(a.toolbar);a.filter=ca.build.call(a);e.appendChild(a.filter);a.helper=document.createElement(_$_c0e3[20]);a.helper.className=_$_c0e3[350];e.appendChild(a.helper);a.loading=document.createElement(_$_c0e3[20]);a.loading.classList.add(_$_c0e3[351]);
323
+ e.appendChild(a.loading);e.appendChild(da.build(a));e.appendChild(Ra(a));a.textarea=document.createElement(_$_c0e3[352]);a.textarea.className=_$_c0e3[353];a.textarea.tabIndex=_$_c0e3[354];e.appendChild(a.textarea);d.position===_$_c0e3[355]?b.insertBefore(e,b.children[0]):b.insertBefore(e,b.children[1]);b.appendChild(Ja.call(a,t.license));a.createWorksheet=ia.createWorksheet;a.deleteWorksheet=ia.deleteWorksheet;a.renameWorksheet=ia.renameWorksheet;a.updateWorksheet=ia.updateWorksheet;a.openWorksheet=
324
+ ia.openWorksheet;a.moveWorksheet=ia.moveWorksheet;a.getWorksheet=ia.getWorksheet;a.getWorksheetActive=ia.getWorksheetActive;a.getWorksheetInstance=ia.getWorksheetInstance;a.getConfig=function(){var f=a.config;f.worksheets=[];for(var h=0;h<a.worksheets.length;h++)f.worksheets.push(a.worksheets[h].getConfig());return f};a.fullscreen=Ka;a.progress=La;a.undo=V.undo;a.redo=V.redo;a.setToolbar=fa[_$_c0e3[11]];a.getToolbar=fa[_$_c0e3[51]];a.showToolbar=fa.show;a.hideToolbar=fa.hide;a.tools=e;1!==a.edition&&
325
+ (b=Object.keys(a.config.definedNames))&&b.length&&(a.config.definedNames={},console.log(_$_c0e3[356]));c.plugins&&pa.call(a,c.plugins);a.setPlugins=function(f){pa.call(a,f)};b=Object.keys(t.extensions);if(b.length)for(d=0;d<b.length;d++)if(typeof t.extensions[b[d]].oninit==_$_c0e3[84])t.extensions[b[d]].oninit(a,c);return a},worksheet:function(b,c){var a={};b.worksheets.push(a);a.parent=b;Da(a);Ta(a);ya(a);ha(a);da(a);Fa(a);Va(a);ba(a);Qa(a);Wa(a);ea(a);W(a);L(a);Aa(a);Xa(a);Za(a);Ya(a);Ca(a);aa(a);
326
+ oa(a);qa(a);ca(a);fa(a);sa(a);ab(a);bb(a);ta(a);ia(a);ka(a);Ua(a);$a(a);Ia(a);Ha(a);Da.worksheet.call(a,c);!t.license&&a.options.license&&(t.license=a.options.license);b.element.jexcel=b.worksheets?b.worksheets:a;pa.execute.call(a.parent,_$_c0e3[357],[a]);a.onload=function(){this.options.worksheetName||(this.options.worksheetName=_$_c0e3[358]+ia.nextName());var d=this.options.worksheetName;I(d)&&console.log(_$_c0e3[359]+d+_$_c0e3[360]);I(d,a);this.element=b.element.tabs.appendElement(this.options.worksheetName,
327
+ function(e,f){a.options.worksheetState===_$_c0e3[49]&&(f.style.display=_$_c0e3[40])});this.element.classList.add(_$_c0e3[361]);this.element.jexcel=this;Y.build.call(this);pa.execute.call(this.parent,_$_c0e3[362],[this]);this.options.data&&500<this.options.data.length&&!H.limited.call(this)&&!this.options.pagination&&console.error(_$_c0e3[363])};return a},row:function(b,c){this.rows[b]||(this.rows[b]={element:null,y:b});c&&(this.rows[b].id=c,sa[_$_c0e3[11]].call(this,c));this.options.rows&&this.options.rows[b]&&
328
+ this.options.rows[b].height&&(this.rows[b].height=this.options.rows[b].height);this.records[b]||(this.records[b]=[]);this.options.data[b]||(this.options.data[b]=this.dataType?{}:[]);for(c=0;c<this.options.columns.length;c++)k.cell.call(this,c,b)},cell:function(b,c,a){typeof a==_$_c0e3[13]&&(a=M.call(this,b,c),null===a||void 0===a)&&(a=_$_c0e3[3],M.call(this,b,c,a));this.records[c][b]||(this.records[c][b]={element:null,x:b,y:c,v:a})},bind:function(b){for(var c=Object.keys(Ba),a=0;a<c.length;a++)(c[a]==
329
+ _$_c0e3[364]?window:b).addEventListener(c[a],Ba[c[a]],c[a]==_$_c0e3[365]||c[a]==_$_c0e3[366]||c[a]==_$_c0e3[367]?{passive:!1}:{})},unbind:function(b){for(var c=Object.keys(Ba),a=0;a<c.length;a++)(c[a]==_$_c0e3[364]?window:b).removeEventListener(c[a],Ba[c[a]])}};return k}(),ab=function(){var k=function(b){b.getWidth=k[_$_c0e3[51]];b.setWidth=k[_$_c0e3[11]]};k[_$_c0e3[51]]=function(b){var c=this.options.columns;if(typeof b===_$_c0e3[13]){b=[];for(var a=0;a<c.length;a++)b.push(c[a].width)}else b=c[b].width;
330
+ return b};k[_$_c0e3[11]]=function(b,c,a){if(!R.call(this.parent,this))return!1;if(c){if(Array.isArray(b)){a||(a=[]);for(var d=0;d<b.length;d++){a[d]||(a[d]=this.options.columns[b[d]].width);var e=Array.isArray(c)&&c[d]?c[d]:c;this.options.columns[b[d]].width=e;this.colgroup[b[d]]&&this.colgroup[b[d]].setAttribute(_$_c0e3[150],e)}}else a||(a=this.options.columns[b].width),this.options.columns[b].width=c,this.colgroup[b]&&this.colgroup[b].setAttribute(_$_c0e3[150],c);this.refreshBorders();V.call(this.parent,
331
+ {worksheet:this,action:_$_c0e3[72],column:b,oldValue:a,newValue:c});K.call(this,_$_c0e3[72],{column:b,width:c,oldWidth:a});F.call(this.parent,_$_c0e3[368],this,b,c,a)}H.refresh.call(this)};return k}(),bb=function(){var k=function(c){c.getHeight=k[_$_c0e3[51]];c.setHeight=k[_$_c0e3[11]]};k[_$_c0e3[51]]=function(c){if(c)c=this.rows[c].element.style.height;else{c=[];for(var a=0;a<this.rows.length;a++){var d=this.rows[a].element.style.height;d&&(c[a]=d)}}return c};var b=function(c,a){a=parseInt(a);var d=
332
+ this.rows[c].height?this.rows[c].height:this.rows[c].element.offsetHeight||this.options.defaultRowHeight;this.rows[c].element.style.height=a+_$_c0e3[44];this.options.rows[c]||(this.options.rows[c]={});this.options.rows[c].height=a+_$_c0e3[44];this.rows[c].height=a;return d};k[_$_c0e3[11]]=function(c,a,d){if(!R.call(this.parent,this))return!1;var e,f=typeof d==_$_c0e3[13]?!0:!1;if(a){if(Array.isArray(c))for(!0===f&&(d=[]),e=0;e<c.length;e++){var h=Array.isArray(a)&&a[e]?a[e]:a;b.call(this,c[e],h);
333
+ 1==f&&d.push(f)}else e=b.call(this,c,a),1==f&&(d=e);this.refreshBorders();V.call(this.parent,{worksheet:this,action:_$_c0e3[73],row:c,oldValue:d,newValue:a});K.call(this,_$_c0e3[73],{row:c,height:a,oldHeight:d});F.call(this.parent,_$_c0e3[369],this,c,a,d)}H.refresh.call(this)};return k}(),ca=function(){var k=function(h){var g=e[h];h=a[e[h]];if(!h.element){h.element=document.createElement(_$_c0e3[370]);h.element.innerHTML=h.value;var l=document.createElement(_$_c0e3[220]);l.type=_$_c0e3[252];l.value=
334
+ g;l.o=h;h.element.insertBefore(l,h.element.firstChild)}h.element.firstChild.checked=h.selected;return h.element},b=null,c=null,a=[],d=0,e=null,f=function(h){h.setFilter=f[_$_c0e3[11]];h.getFilter=f[_$_c0e3[51]];h.openFilter=f.open;h.closeFilter=f.close;h.resetFilters=f.reset;h.showFilter=f.show;h.hideFilter=f.hide};f.isVisible=function(){return c};f[_$_c0e3[11]]=function(h,g){var l=this.headers[h];h=this.options.columns[h];Array.isArray(g)&&0<g.length?(l&&l.classList.add(_$_c0e3[371]),h.filters=g):
335
+ (l&&l.classList.remove(_$_c0e3[371]),h.filters=null);f.update.call(this)};f[_$_c0e3[51]]=function(h){if(h)return this.options.columns[h].filters||null;h={};for(var g=0;g<this.options.columns.length;g++)h[g]=this.options.columns[g].filters||null;return h};f.open=function(h){b=parseInt(h);if(this.headers[b].classList.contains(_$_c0e3[166])){c=!0;var g=this.parent.element.getBoundingClientRect(),l=this.headers[b].getBoundingClientRect();h=l.left-g.left;l=l.top-g.top+l.height;g=this.parent.filter;g.style.display=
336
+ _$_c0e3[16];g.style.top=l+_$_c0e3[44];g.style.left=h+_$_c0e3[44];g.children[0].focus();h=g.children[1].selectAll;g.children[1].textContent=_$_c0e3[3];g.children[1].appendChild(h);this.options.columns[b].filters||(h.children[0].checked=!0);h=qa.execute.call(this,null,b);h=E.invert(h);g=[];for(l=0;l<this.rows.length;l++)if(h[l]){var m=_$_c0e3[3]+M.call(this,b,l),p=_$_c0e3[3]+ea.processed.call(this,b,l,!0);m.substr(0,1)==_$_c0e3[12]&&(m=p);g.push([m,p])}g.sort(function(n,q){return n[0]>q[0]?1:n[0]<q[0]?
337
+ -1:0});a=[];for(l=0;l<g.length;l++)a[g[l][0]]={value:g[l][1],element:null};void 0!==a[_$_c0e3[3]]&&(delete a[_$_c0e3[3]],a[_$_c0e3[3]]={value:_$_c0e3[211]+B(_$_c0e3[373])+_$_c0e3[232],element:null});f.search.call(this,_$_c0e3[3])}else console.log(_$_c0e3[372])};f.close=function(h){if(h){h=this.parent.filter.children[1];if(1==h.selectAll.firstChild.checked&&e.length==Object.keys(a).length)h=null;else{h=1==h.currentSelection.firstChild.checked?this.options.columns[b].filters||[]:[];for(var g=0;g<e.length;g++)a[e[g]].selected&&
338
+ h.push(e[g])}f[_$_c0e3[11]].call(this,b,h)}this.parent.filter.style.display=_$_c0e3[3];this.parent.filter.children[0].value=_$_c0e3[3];b=null;c=!1;a=null;d=0;e=null};f.reset=function(h){f.updateDOM.call(this,h,!1);ua.reset.call(this);f.update.call(this)};f.execute=function(h){for(var g=this.options.columns,l=[],m=0;m<this.options.data.length;m++){for(var p=!0,n=0;n<g.length;n++)if(g[n].filters&&h!==n){var q=_$_c0e3[3]+M.call(this,n,m),v=_$_c0e3[3]+this.getLabelFromCoords(n,m,!0);-1==g[n].filters.indexOf(q)&&
339
+ -1==g[n].filters.indexOf(v)&&(p=!1)}p&&l.push(m)}return l};f.update=function(){ua.reset.call(this);this.resetSelection();this.resetBorders();var h=qa.execute.call(this,null);if(typeof this.parent.config.onbeforefilter==_$_c0e3[84]){var g=f[_$_c0e3[51]].call(this),l=F.call(this.parent,_$_c0e3[374],this,g,h);if(l)h=l;else if(!1===l)return!1}this.pageNumber=0;h&&h.length<this.rows.length&&ua[_$_c0e3[11]].call(this,h);H.resetY.call(this);aa.refresh.call(this);F.call(this.parent,_$_c0e3[375],this,g,h)};
340
+ f.show=function(h){f.updateDOM.call(this,h,!0)};f.hide=function(h){f.updateDOM.call(this,h,!1,!0);f.update.call(this)};f.search=function(h){for(var g=this.parent.filter.children[1];g.children[1];)g.removeChild(g.lastChild);g.currentSelection.firstChild.checked=!1;if(h){e=[];h=new RegExp(h,_$_c0e3[376]);for(var l=Object.keys(a),m=0;m<l.length;m++)(_$_c0e3[3]+l[m]).match(h)||(_$_c0e3[3]+a[l[m]]).match(h)?(e.push(l[m]),a[l[m]].selected=!0):a[l[m]].selected=!1;g.firstChild.checked=!0;this.options.columns[b].filters&&
341
+ g.appendChild(g.currentSelection)}else{e=Object.keys(a);if(h=this.options.columns[b].filters)for(m=0;m<e.length;m++)a[e[m]].selected=!1,0<=h.indexOf(e[m])&&(a[e[m]].selected=!0);else for(m=0;m<e.length;m++)a[e[m]].selected=!0;g.firstChild.checked=h?!1:!0}for(m=d=0;m<e.length;m++)200>m&&(h=d++,g.appendChild(k(h)))};f.build=function(){var h=document.createElement(_$_c0e3[20]);h.className=_$_c0e3[377];h.onclick=function(p){p.target.tagName==_$_c0e3[378]&&p.target.o&&(p.target.o.selected=p.target.checked);
342
+ p=!0;for(var n=1;n<this.children.length;n++)this.children[n].children[0].checked||(p=!1);this.children[0].children[0].checked=p};var g=document.createElement(_$_c0e3[220]);g.type=_$_c0e3[55];g.placeholder=B(_$_c0e3[379]);g.className=_$_c0e3[380];var l=document.createElement(_$_c0e3[220]);l.type=_$_c0e3[381];l.value=_$_c0e3[382];l.className=_$_c0e3[383];var m=document.createElement(_$_c0e3[20]);m.className=_$_c0e3[384];m.appendChild(g);m.appendChild(h);m.appendChild(l);h.currentSelection=document.createElement(_$_c0e3[370]);
343
+ h.currentSelection.innerHTML=_$_c0e3[385]+B(_$_c0e3[386]);h.selectAll=document.createElement(_$_c0e3[370]);h.selectAll.innerHTML=_$_c0e3[387]+B(_$_c0e3[388])+_$_c0e3[232];h.selectAll.onclick=function(){for(var p=this.children[0].checked,n=1;n<this.parentNode.children.length;n++)this.parentNode.children[n].children[0].checked=p;if(1==p)for(n=0;n<e.length;n++)a[e[n]].selected=!0;else for(p=Object.keys(a),n=0;n<p.length;n++)a[p[n]].selected=!1};jSuites.lazyLoading(h,{loadDown:function(p){for(p=0;d<e.length-
344
+ 1&&10>p;){var n=d++;h.appendChild(k(n));p++}}});return m};f.updateDOM=function(h,g,l){var m=this.headers,p=function(n){1==g?m[n].classList.add(_$_c0e3[166]):(this.options.columns[n].filters=null,m[n].classList.remove(_$_c0e3[371]),1==l&&m[n].classList.remove(_$_c0e3[166]))};if(h)p.call(this,h);else for(h=0;h<m.length;h++)p.call(this,h)};f.onload=function(){var h,g=!1;if(h=this.options.columns)for(var l=0;l<h.length;l++)Array.isArray(h[l].filters)&&0<h[l].filters.length&&this.headers[l]&&(this.headers[l].classList.add(_$_c0e3[371]),
345
+ g=!0);1==g&&f.update.call(this)};return f}(),ua=function(){var k={};k[_$_c0e3[11]]=function(b){for(var c=0;c<b.length;c++)this.rows[b[c]].results=!0;this.results=b};k.reset=function(){for(var b=0;b<this.rows.length;b++)!0===this.rows[b].results&&delete this.rows[b].results;this.results=null};k.refresh=function(){for(var b=[],c=0;c<this.rows.length;c++)!0===this.rows[c].results&&b.push(c);return b};return k}(),qa=function(){var k=function(a){var d=document.createElement(_$_c0e3[20]);if(0<a.options.pagination&&
346
+ a.options.paginationOptions&&0<a.options.paginationOptions.length){a.paginationDropdown=document.createElement(_$_c0e3[389]);a.paginationDropdown.classList.add(_$_c0e3[390]);a.paginationDropdown.onchange=function(){a.options.pagination=parseInt(this.value);a.page(0)};for(var e=0;e<a.options.paginationOptions.length;e++){var f=document.createElement(_$_c0e3[391]);f.value=a.options.paginationOptions[e];f.innerHTML=a.options.paginationOptions[e];a.paginationDropdown.appendChild(f)}a.paginationDropdown.value=
347
+ a.options.pagination;d.appendChild(document.createTextNode(B(_$_c0e3[392])));d.appendChild(a.paginationDropdown);d.appendChild(document.createTextNode(B(_$_c0e3[393])))}return d},b=function(a,d){var e=this.merged.rows;if(e[d]){for(;0<d&&e[d-1];)d--;for(;e[d];)a.push(d++)}else a.push(d)},c=function(a){a.search=c.update;a.resetSearch=c.reset;a.updateSearch=c.refresh;a.showSearch=c.show;a.hideSearch=c.hide};c.execute=function(a,d){null===a?a=this.searchInput.value||_$_c0e3[3]:a!==this.searchInput.value&&
348
+ (this.searchInput.value=a);this.pageNumber=0;var e=[],f=null;d=ca.execute.call(this,d);if(a)try{a=new RegExp(a,_$_c0e3[376]);for(var h=0;h<this.rows.length;h++){f=!1;if(!d||0<=d.indexOf(h))for(var g=0;g<this.options.columns.length;g++){var l=_$_c0e3[3]+M.call(this,g,h),m=_$_c0e3[3]+this.getLabelFromCoords(g,h);if(l.match(a)||m.match(a))f=!0}1==f&&b.call(this,e,h)}}catch(p){}else e=d;if(e.length){for(h=0;h<this.rows.length;h++)!0===this.rows[h].results&&e.push(h);e.sort(function(p,n){return p-n})}return e};
349
+ c.update=function(a){ua.reset.call(this);this.resetSelection();this.resetBorders();var d=c.execute.call(this,a);if(typeof this.parent.config.onbeforesearch==_$_c0e3[84]){var e=F.call(this.parent,_$_c0e3[395],this,a,d);if(e)d=e;else if(!1===e)return!1}this.pageNumber=0;d&&d.length<this.rows.length&&ua[_$_c0e3[11]].call(this,d);H.resetY.call(this);aa.refresh.call(this);F.call(this.parent,_$_c0e3[396],this,a,d)};c.refresh=function(){H.resetY.call(this);aa.refresh.call(this)};c.reset=function(){this.searchInput.value=
350
+ _$_c0e3[3];ua.reset.call(this);H.resetY.call(this);aa.refresh.call(this)};c.show=function(){this.options.search=!0;this.searchContainer.style.display=_$_c0e3[3]};c.hide=function(){this.options.search=!1;this.searchContainer.style.display=_$_c0e3[40]};c.build=function(){this.searchContainer=document.createElement(_$_c0e3[20]);this.searchContainer.classList.add(_$_c0e3[397]);this.searchContainer.appendChild(k(this));var a=this.searchContainer,d=a.appendChild,e=document.createElement(_$_c0e3[20]);e.innerHTML=
351
+ B(_$_c0e3[379])+_$_c0e3[113];this.searchInput=document.createElement(_$_c0e3[220]);this.searchInput.classList.add(_$_c0e3[394]);e.appendChild(this.searchInput);d.call(a,e);0==this.options.search&&(this.searchContainer.style.display=_$_c0e3[40]);this.element.insertBefore(this.searchContainer,this.element.firstChild)};return c}(),Ra=function(){var k=function(b){b.contextmenu=document.createElement(_$_c0e3[20]);b.contextmenu.className=_$_c0e3[398];jSuites.contextmenu(b.contextmenu,{onclick:function(c,
352
+ a,d){c.close()}});return b.contextmenu};k.open=function(b,c){var a=b.target.getAttribute(_$_c0e3[42]),d=b.target.getAttribute(_$_c0e3[43]),e=k[_$_c0e3[51]](this,a,d,b,c[0],c[1],c[2]);if(typeof this.parent.config.contextMenu==_$_c0e3[84]){var f=this.parent.config.contextMenu(this,a,d,b,e,c[0],c[1],c[2]);if(f)e=f;else if(!1===f)return!1}b.preventDefault();f=pa.execute.call(this.parent,_$_c0e3[85],[this,a,d,b,e,c[0],c[1],c[2]]);e=f[4];this.parent.contextmenu.contextmenu.open(b,e)};k[_$_c0e3[51]]=function(b,
353
+ c,a,d,e,f,h){var g=[],l=b.parent.config,m=-1!=navigator.userAgent.indexOf(_$_c0e3[399])?_$_c0e3[400]:_$_c0e3[401];e==_$_c0e3[402]&&(1==l.allowRenameWorksheet&&g.push({title:B(_$_c0e3[403]),onclick:function(){var n=prompt(B(_$_c0e3[403]),d.target.innerText);n&&b.parent.renameWorksheet(f,n)}}),1==l.allowDeleteWorksheet&&g.push({title:B(_$_c0e3[404]),onclick:function(){confirm(B(_$_c0e3[405]),d.target.innerText)&&b.parent.deleteWorksheet(f)}}),g.push({type:_$_c0e3[406]}));e==_$_c0e3[407]&&(g.push({title:B(_$_c0e3[408]),
354
+ onclick:function(){var n=prompt(B(_$_c0e3[408]),d.target.innerText);b.setNestedCell(f,h,{title:n})}}),g.push({type:_$_c0e3[406]}));if(e==_$_c0e3[409]||e==_$_c0e3[410]||e==_$_c0e3[411]||e==_$_c0e3[407])g.push({title:B(_$_c0e3[412]),icon:_$_c0e3[413],shortcut:m+_$_c0e3[414],onclick:function(){b.cut()}}),g.push({title:B(_$_c0e3[415]),icon:_$_c0e3[416],shortcut:m+_$_c0e3[417],onclick:function(){b.copy()}}),navigator&&navigator.clipboard&&navigator.clipboard.readText&&g.push({title:B(_$_c0e3[418]),icon:_$_c0e3[419],
355
+ shortcut:m+_$_c0e3[420],onclick:function(){b.selectedCell&&navigator.clipboard.readText().then(function(n){n&&b.paste(b.selectedCell[0],b.selectedCell[1],n)})}}),g.push({type:_$_c0e3[406]});e==_$_c0e3[409]&&(1==b.options.allowInsertColumn&&g.push({title:B(_$_c0e3[421]),onclick:function(){b.insertColumn(1,parseInt(f),1)}}),1==b.options.allowInsertColumn&&g.push({title:B(_$_c0e3[422]),onclick:function(){b.insertColumn(1,parseInt(f),0)}}),1==b.options.allowDeleteColumn&&g.push({title:B(_$_c0e3[423]),
356
+ onclick:function(){b.deleteColumn(b.getSelectedColumns().length?void 0:parseInt(c))}}),1==b.options.allowRenameColumn&&g.push({title:B(_$_c0e3[424]),onclick:function(){b.setHeader(f)}}),b.options.data.length||(g.push({type:_$_c0e3[406]}),g.push({title:B(_$_c0e3[425]),onclick:function(){b.insertRow(0)}})),1==b.options.columnSorting&&(g.push({type:_$_c0e3[406]}),g.push({title:B(_$_c0e3[426]),onclick:function(){b.orderBy(f,0)}}),g.push({title:B(_$_c0e3[427]),onclick:function(){b.orderBy(f,1)}}),g.push({type:_$_c0e3[406]})));
357
+ if(e==_$_c0e3[411]||e==_$_c0e3[410])1==b.options.allowInsertRow&&(g.push({title:B(_$_c0e3[428]),onclick:function(){b.insertRow(1,parseInt(a),1)}}),g.push({title:B(_$_c0e3[429]),onclick:function(){b.insertRow(1,parseInt(a))}})),1==b.options.allowDeleteRow&&g.push({title:B(_$_c0e3[430]),onclick:function(){b.deleteRow(b.getSelectedRows().length?void 0:parseInt(a))}}),g.push({type:_$_c0e3[406]});if(e==_$_c0e3[411]&&1==b.options.allowComments){var p=b.records[h][f].element.getAttribute(_$_c0e3[265])||
358
+ _$_c0e3[3];g.push({title:p?B(_$_c0e3[431]):B(_$_c0e3[432]),icon:_$_c0e3[433],onclick:function(){var n=E.getColumnNameFromCoords(f,h),q=prompt(B(_$_c0e3[434]),p);q&&b.setComments(n,q)}});p&&g.push({title:B(_$_c0e3[435]),onclick:function(){var n=E.getColumnNameFromCoords(f,h);b.setComments(n,_$_c0e3[3])}});g.push({type:_$_c0e3[406]})}l.allowExport&&g.push({title:B(_$_c0e3[436]),icon:_$_c0e3[437],shortcut:m+_$_c0e3[438],onclick:function(){b.download()}});l.about&&g.push({title:B(_$_c0e3[439]),icon:_$_c0e3[440],
359
+ onclick:function(){!0===l.about?alert(J().print()):alert(l.about)}});return g};return k}(),fa=function(){var k=function(b){b.showToolbar=function(){k.show.call(b.parent)};b.hideToolbar=function(){k.hide.call(b.parent)};b.refreshToolbar=function(){k.update.call(b.parent,b)}};k[_$_c0e3[11]]=function(b){this.toolbar.innerHTML=_$_c0e3[3];this.config.toolbar=k[_$_c0e3[51]].call(this,b);k.show.call(this)};k[_$_c0e3[51]]=function(b){b||(b=this.config.toolbar);b?Array.isArray(b)?b={items:b}:typeof b===_$_c0e3[84]&&
360
+ (b=b({items:k.getDefault()})):b={};typeof b!==_$_c0e3[83]&&(b={});b.items||(b.items=k.getDefault());typeof b.responsive==_$_c0e3[13]&&(b.responsive=!0,b.bottom=!1,b.maxWidth=this.element.offsetWidth);return b};k.show=function(){this.toolbar.innerHTML||k.build.call(this);this.toolbar.style.display=_$_c0e3[3];this.element.classList.add(_$_c0e3[441])};k.hide=function(){this.toolbar.style.display=_$_c0e3[40];this.element.classList.remove(_$_c0e3[441])};k.update=function(b,c){if(c=this.toolbarInstance)if(c.update(b),
361
+ c.options.responsive){var a=parseInt(b.content.style.maxWidth);if(!a||this.config.fullscreen)a=b.element.offsetWidth;c.options.maxWidth=a;c.refresh()}};k.build=function(){for(var b=k[_$_c0e3[51]].call(this),c=0;c<b.items.length;c++)if(b.items[c].type==_$_c0e3[389]){if(!b.items[c].options&&b.items[c].v){b.items[c].options=[];for(var a=0;a<b.items[c].v.length;a++)b.items[c].options.push(b.items[c].v[a]);b.items[c].k&&(b.items[c].onchange=function(d,e,f,h){t.current.setStyle(t.current.getSelected(),
362
+ f.k,h)})}}else b.items[c].type==_$_c0e3[257]?(b.items[c].type=_$_c0e3[442],b.items[c].onclick=function(d,e,f){if(!f.color){var h=null;jSuites.color(f,{onchange:function(g,l){(h=t.current.getSelected())&&t.current.setStyle(h,f.k,l)},onopen:function(g){var l;t.current.cursor?(l=t.current.cursor.style[f.k])?g.color.select(g.color.toHex(l)):g.color.select(_$_c0e3[3]):g.color.select(_$_c0e3[3])}});f.color.open()}}):!b.items[c].onclick&&b.items[c].k&&(b.items[c].onclick=function(){t.current.setStyle(t.current.getSelected(),
363
+ this.k,this.v)});(c=pa.execute.call(this,_$_c0e3[86],[b]))&&(b=c[0]);this.toolbarInstance=jSuites.toolbar(this.toolbar,b);this.toolbarInstance.application=this;b=this.element.tabs.getActive();this.toolbarInstance.update(this.worksheets[b])};k.getDefault=function(){return[{content:_$_c0e3[443],onclick:function(){t.current&&t.current.undo()}},{content:_$_c0e3[444],onclick:function(){t.current&&t.current.redo()}},{content:_$_c0e3[437],onclick:function(){t.current&&t.current.download()}},{type:_$_c0e3[445]},
364
+ {type:_$_c0e3[389],width:_$_c0e3[446],options:[_$_c0e3[447],_$_c0e3[448],_$_c0e3[449]],render:function(b){return _$_c0e3[450]+b+_$_c0e3[226]+b+_$_c0e3[451]},onchange:function(b,c,a,d){t.current&&t.current.setStyle(t.current.getSelected(),_$_c0e3[452],d)}},{type:_$_c0e3[389],width:_$_c0e3[453],content:_$_c0e3[454],options:[_$_c0e3[455],_$_c0e3[456],_$_c0e3[457],_$_c0e3[458],_$_c0e3[459]],render:function(b){return _$_c0e3[460]+b+_$_c0e3[226]+b+_$_c0e3[451]},onchange:function(b,c,a,d){t.current&&t.current.setStyle(t.current.getSelected(),
365
+ _$_c0e3[461],d)}},{type:_$_c0e3[389],options:[_$_c0e3[462],_$_c0e3[463],_$_c0e3[464],_$_c0e3[465]],render:function(b){return _$_c0e3[466]+b+_$_c0e3[467]},onchange:function(b,c,a,d){t.current&&t.current.setStyle(t.current.getSelected(),_$_c0e3[468],d.split(_$_c0e3[469])[2])}},{type:_$_c0e3[442],content:_$_c0e3[470],k:_$_c0e3[471],v:_$_c0e3[472]},{type:_$_c0e3[257],content:_$_c0e3[473],k:_$_c0e3[257]},{type:_$_c0e3[257],content:_$_c0e3[474],k:_$_c0e3[475]},{type:_$_c0e3[389],content:_$_c0e3[476],width:_$_c0e3[477],
366
+ options:[_$_c0e3[478],_$_c0e3[479],_$_c0e3[480],_$_c0e3[481]],onchange:function(b,c,a,d,e){b=t.current.table;b.classList.remove(_$_c0e3[482]);b.classList.remove(_$_c0e3[483]);b.classList.remove(_$_c0e3[484]);1==e?b.classList.add(_$_c0e3[482]):2==e?b.classList.add(_$_c0e3[483]):3==e&&b.classList.add(_$_c0e3[484]);t.current.refreshBorders()}},{content:_$_c0e3[15],onclick:function(b,c,a){a.children[0].innerText==_$_c0e3[15]?(t.current.fullscreen(!0),a.children[0].innerText=_$_c0e3[485]):(t.current.fullscreen(!1),
367
+ a.children[0].innerText=_$_c0e3[15])},tooltip:_$_c0e3[486],updateState:function(b,c,a,d){a.children[0].innerText=1==d.parent.config.fullscreen?_$_c0e3[485]:_$_c0e3[15]}},{type:_$_c0e3[389],data:[_$_c0e3[487],_$_c0e3[488],_$_c0e3[489],_$_c0e3[490],_$_c0e3[491],_$_c0e3[492],_$_c0e3[493],_$_c0e3[494],_$_c0e3[495],_$_c0e3[496]],columns:5,render:function(b){return _$_c0e3[466]+b+_$_c0e3[467]},right:!0,onchange:function(b,c,a,d,e){if(b=t.current.getHighlighted()){a=c.thickness||1;c=c.color||_$_c0e3[497];
368
+ e={};for(var f=b[0],h=b[1],g=b[2],l=b[3],m=b[1];m<=b[3];m++)for(var p=b[0];p<=b[2];p++){var n=E.getColumnNameFromCoords(p,m);e[n]||(e[n]=_$_c0e3[3]);e[n]=d!=_$_c0e3[492]&&d!=_$_c0e3[488]||p!=f?(d==_$_c0e3[489]||d==_$_c0e3[491])&&p>f?e[n]+(_$_c0e3[498]+a+_$_c0e3[499]+c+_$_c0e3[295]):d==_$_c0e3[487]?e[n]+(_$_c0e3[498]+a+_$_c0e3[499]+c+_$_c0e3[295]):e[n]+_$_c0e3[500]:e[n]+(_$_c0e3[498]+a+_$_c0e3[499]+c+_$_c0e3[295]);e[n]=d!=_$_c0e3[487]&&d!=_$_c0e3[494]&&d!=_$_c0e3[488]||p!=g?e[n]+_$_c0e3[502]:e[n]+
369
+ (_$_c0e3[501]+a+_$_c0e3[499]+c+_$_c0e3[295]);e[n]=d!=_$_c0e3[493]&&d!=_$_c0e3[488]||m!=h?(d==_$_c0e3[489]||d==_$_c0e3[490])&&m>h?e[n]+(_$_c0e3[503]+a+_$_c0e3[499]+c+_$_c0e3[295]):d==_$_c0e3[487]?e[n]+(_$_c0e3[503]+a+_$_c0e3[499]+c+_$_c0e3[295]):e[n]+_$_c0e3[504]:e[n]+(_$_c0e3[503]+a+_$_c0e3[499]+c+_$_c0e3[295]);e[n]=d!=_$_c0e3[487]&&d!=_$_c0e3[495]&&d!=_$_c0e3[488]||m!=l?e[n]+_$_c0e3[506]:e[n]+(_$_c0e3[505]+a+_$_c0e3[499]+c+_$_c0e3[295])}Object.keys(e)&&t.current.setStyle(e,null,null,!0)}},onload:function(b,
370
+ c){var a=document.createElement(_$_c0e3[20]),d=document.createElement(_$_c0e3[20]);a.appendChild(d);var e=jSuites.color(d,{closeOnChange:!1,onchange:function(f,h){f.parentNode.children[1].style.color=h;c.color=h}});d=document.createElement(_$_c0e3[442]);d.classList.add(_$_c0e3[507]);d.innerHTML=_$_c0e3[508];d.onclick=function(){e.open()};a.appendChild(d);b.children[1].appendChild(a);d=document.createElement(_$_c0e3[20]);jSuites.picker(d,{type:_$_c0e3[389],data:[1,2,3,4,5],render:function(f){return _$_c0e3[509]+
371
+ f+_$_c0e3[510]},onchange:function(f,h,g,l){c.thickness=l},width:_$_c0e3[511]});b.children[1].appendChild(d);d=document.createElement(_$_c0e3[20]);d.style.flex=_$_c0e3[512];b.children[1].appendChild(d)}},{content:_$_c0e3[513],onclick:function(b,c,a){a.children[0].innerText==_$_c0e3[513]?(qa.show.call(t.current),a.children[0].innerText=_$_c0e3[514]):(qa.hide.call(t.current),a.children[0].innerText=_$_c0e3[513])},tooltip:_$_c0e3[515],updateState:function(b,c,a,d){a.children[0].innerText=1==d.options.search?
372
+ _$_c0e3[514]:_$_c0e3[513]}}]};return k}(),ia=function(){var k=function(b){b.createWorksheet=function(c){return b.parent.createWorksheet(c)};b.deleteWorksheet=function(c){return b.parent.deleteWorksheet(c)};b.renameWorksheet=function(c,a){return b.parent.renameWorksheet(c,a)};b.moveWorksheet=function(c,a){return b.parent.moveWorksheet(c,a)};b.openWorksheet=function(){return b.parent.openWorksheet(b.parent.getWorksheet(b))};b.getWorksheet=function(c){return b.parent.getWorksheet(c)};b.getWorksheetActive=
373
+ function(){return b.parent.getWorksheetActive()};b.getWorksheetName=function(){return b.options.worksheetName.toUpperCase()}};k.nextName=function(){var b=1,c,a=t.spreadsheet;if(a.length)for(var d=0;d<a.length;d++){var e=a[d].worksheets;if(e.length)for(var f=0;f<e.length;f++)e[f].options.worksheetName&&(c=e[f].options.worksheetName.match(/(\d+)/))&&(c=parseInt(c[0])+1,c>b&&(b=c))}return b};k.createWorksheet=function(b){if(!R.call(this))return!1;b||(b={});var c=this.worksheets.length,a=F.call(this,
374
+ _$_c0e3[516],b,c);if(typeof a===_$_c0e3[83])b=a;else if(!1===a)return!1;b.data||b.minDimensions||(b.minDimensions=[8,8]);b.worksheetId||(b.worksheetId=jSuites.guid().substring(0,8));b.worksheetName||(b.worksheetName=_$_c0e3[358]+k.nextName());if(I(b.worksheetName))jSuites.notification({error:_$_c0e3[512],message:_$_c0e3[517]});else return a=na.worksheet(this,b),a.onload(),K.call(a,_$_c0e3[518],[b]),F.call(this,_$_c0e3[519],a,b,c),a};k.deleteWorksheet=function(b){var c=this.worksheets[b];if(!R.call(this,
375
+ c))return!1;I(c.options.worksheetName,null);this.element.tabs.deleteElement(b);this.worksheets.splice(b,1);K.call(c,_$_c0e3[520],[b]);F.call(this,_$_c0e3[521],c,b)};k.renameWorksheet=function(b,c){var a=this.worksheets[b];if(!R.call(this,a))return!1;var d=a.options.worksheetName;if(d.toLowerCase()==c.toLowerCase())return!1;c=c.replace(/[^0-9A-Za-z_\s^]+/gi,_$_c0e3[3]);Number(c)==c&&(c=_$_c0e3[358]+Number(c));I(c)?alert(_$_c0e3[522]):(I(d,null),this.element.tabs.rename(b,c),a.options.worksheetName=
376
+ c,I(c,a),V.call(this,{worksheet:a,action:_$_c0e3[79],index:b,oldValue:d,newValue:c}),K.call(a,_$_c0e3[79],{worksheet:b,newValue:c}),Ia.updateWorksheetName.call(a,d,c),W.updateWorksheetNames.call(a,d,c),F.call(this,_$_c0e3[523],a,b,c,d))};k.updateWorksheet=function(b,c){var a=this.worksheets;if(!R.call(this))return!1;this.worksheets.splice(c,0,a.splice(b,1)[0]);V.call(this,{worksheet:a[c],action:_$_c0e3[80],f:b,t:c});K.call(a[c],_$_c0e3[80],{f:b,t:c});F.call(this,_$_c0e3[524],a[c],b,c)};k.moveWorksheet=
377
+ function(b,c){this.element.tabs.move(b,c)};k.openWorksheet=function(b){var c=this.worksheets[b];!c||t.current&&t.current==c||(this.element.tabs.getActive()!=b?this.element.tabs.open(b):this.element.tabs.setBorder(b),t.current&&t.current.resetSelection(),t.current=c,t.current.refreshBorders(),U.call(t.current),k.state.call(this,b),fa.update.call(this,t.current),F.call(this,_$_c0e3[525],c,b))};k.getWorksheet=function(b){if(b&&typeof b==_$_c0e3[83]){if(b=this.worksheets.indexOf(b),0<=b)return b}else for(var c=
378
+ 0;c<this.worksheets.length;c++)if(b===this.worksheets[c].options.worksheetId)return c;return!1};k.getWorksheetActive=function(){return this.element.tabs.getActive()};k.getWorksheetInstance=function(b){return b===_$_c0e3[3]||typeof b==_$_c0e3[17]?(b=k.getWorksheet.call(this,b),!1===b?!1:this.worksheets[b]):this.worksheets[b]};k.state=function(b){try{if(typeof localStorage!==_$_c0e3[13]){var c=this.config.cloud?this.config.cloud:this.element.id;if(c)if(typeof b!==_$_c0e3[13])localStorage.setItem(_$_c0e3[526]+
379
+ c,b);else{var a=parseInt(localStorage.getItem(_$_c0e3[526]+c));k.openWorksheet.call(this,a)}}}catch(d){}};return k}(),E=function(){var k={getCaretIndex:function(b){var c=0,a=(this.config.root?this.config.root:window).getSelection();a&&0!==a.rangeCount&&(c=a.getRangeAt(0),a=c.cloneRange(),a.selectNodeContents(b),a.setEnd(c.endContainer,c.endOffset),c=a.toString().length);return c},invert:function(b){for(var c=[],a=Object.keys(b),d=0;d<a.length;d++)c[b[a[d]]]=a[d];return c},getColumnName:function(b){var c=
380
+ _$_c0e3[3];701<b?(c+=String.fromCharCode(64+parseInt(b/676)),c+=String.fromCharCode(64+parseInt(b%676/26))):25<b&&(c+=String.fromCharCode(64+parseInt(b/26)));return c+=String.fromCharCode(65+b%26)},getColumnNameFromCoords:function(b,c){return k.getColumnName(parseInt(b))+(parseInt(c)+1)},getCoordsFromColumnName:function(b){var c=/^[a-zA-Z]+/.exec(b);if(c){for(var a=0,d=0;d<c[0].length;d++)a+=parseInt(c[0].charCodeAt(d)-64)*Math.pow(26,c[0].length-1-d);a--;0>a&&(a=0);b=parseInt(/[0-9]+$/.exec(b))||
381
+ null;0<b&&b--;return[a,b]}}};k.shiftFormula=W.shiftFormula;k.createFromTable=function(b,c){if(b.tagName!=_$_c0e3[527])console.log(_$_c0e3[528]);else{c||(c={});c.columns=[];c.data=[];var a=b.querySelectorAll(_$_c0e3[529]);if(a.length)for(var d=0;d<a.length;d++){var e=a[d].style.width;e||(e=a[d].getAttribute(_$_c0e3[150]));e&&(c.columns[d]||(c.columns[d]={}),c.columns[d].width=e)}e=function(w){var C=w.getBoundingClientRect();C=50<C.width?C.width:50;c.columns[d]||(c.columns[d]={});w.getAttribute(_$_c0e3[530])?
382
+ c.columns[d].type=w.getAttribute(_$_c0e3[530]):c.columns[d].type=_$_c0e3[55];c.columns[d].width=C+_$_c0e3[44];c.columns[d].title=w.innerHTML;w.style.textAlign&&(c.columns[d].align=w.style.textAlign);w.classList.contains(_$_c0e3[531])&&(c.columns[d].readOnly=!0);if(C=w.getAttribute(_$_c0e3[532]))c.columns[d].name=C;if(C=w.getAttribute(_$_c0e3[533]))c.columns[d].id=C};var f=[],h=b.querySelectorAll(_$_c0e3[534]);if(h.length){for(a=0;a<h.length-1;a++){var g=[];for(d=0;d<h[a].children.length;d++){var l=
383
+ {title:h[a].children[d].innerText,colspan:h[a].children[d].getAttribute(_$_c0e3[52])||1};g.push(l)}f.push(g)}h=h[h.length-1].children;for(d=0;d<h.length;d++)e(h[d])}l=0;var m={},p={},n={},q={},v=null;g=b.querySelectorAll(_$_c0e3[535]);for(a=0;a<g.length;a++)if(c.data[l]=[],1!=c.parseTableFirstRowAsHeader||h.length||0!=a){for(d=0;d<g[a].children.length;d++){var u=g[a].children[d].getAttribute(_$_c0e3[536]);u?u.substr(0,1)!=_$_c0e3[12]&&(u=_$_c0e3[12]+u):u=g[a].children[d].innerHTML;c.data[l].push(u);
384
+ u=E.getColumnNameFromCoords(d,a);(v=g[a].children[d].getAttribute(_$_c0e3[537]))&&(q[u]=v);v=parseInt(g[a].children[d].getAttribute(_$_c0e3[52]))||0;var y=parseInt(g[a].children[d].getAttribute(_$_c0e3[162]))||0;if(v||y)m[u]=[v||1,y||1];if(v=g[a].children[d].style&&g[a].children[d].style.display==_$_c0e3[40])g[a].children[d].style.display=_$_c0e3[3];(v=g[a].children[d].getAttribute(_$_c0e3[98]))&&(n[u]=v);g[a].children[d].classList.contains(_$_c0e3[538])&&(n[u]=n[u]?n[u]+_$_c0e3[539]:_$_c0e3[540])}g[a].style&&
385
+ g[a].style.height&&(p[a]={height:g[a].style.height});l++}else for(d=0;d<g[a].children.length;d++)e(g[a].children[d]);0<Object.keys(f).length&&(c.nestedHeaders=f);0<Object.keys(n).length&&(c.style=n);0<Object.keys(m).length&&(c.mergeCells=m);0<Object.keys(p).length&&(c.rows=p);0<Object.keys(q).length&&(c.classes=q);g=b.querySelectorAll(_$_c0e3[541]);if(g.length){b=[];for(a=0;a<g.length;a++){e=[];for(d=0;d<g[a].children.length;d++)e.push(g[a].children[d].innerText);b.push(e)}0<Object.keys(b).length&&
386
+ (c.footers=b)}if(1==c.parseTableAutoCellType)for(b=[],d=0;d<c.columns.length;d++){f=e=!0;b[d]=[];for(a=0;a<c.data.length;a++)if(u=c.data[a][d],b[d][u]||(b[d][u]=0),b[d][u]++,25<u.length&&(e=!1),10==u.length){if(u.substr(4,1)!=_$_c0e3[184]||u.substr(7,1)!=_$_c0e3[184])f=!1}else f=!1;a=Object.keys(b[d]).length;f?c.columns[d].type=_$_c0e3[183]:1==e&&1<a&&a<=parseInt(.1*c.data.length)&&(c.columns[d].type=_$_c0e3[57],c.columns[d].source=Object.keys(b[d]))}return c}};k.injectArray=function(b,c,a){return b.slice(0,
387
+ c).concat(a).concat(b.slice(c))};k.parseCSV=function(b,c){c=c||_$_c0e3[25];for(var a=0,d=0,e=[[]],f=0,h=null,g=!1,l=!1,m=0;m<b.length;m++)if(e[d]||(e[d]=[]),e[d][a]||(e[d][a]=_$_c0e3[3]),b[m]!=_$_c0e3[542])if(b[m]!=_$_c0e3[543]&&b[m]!=c||0!=g&&1!=l&&h){b[m]==_$_c0e3[186]&&(g=!g);if(null===h){if(h=g,1==h)continue}else if(!0===h&&!l&&b[m]==_$_c0e3[186]){b[m+1]==_$_c0e3[186]?(g=!0,e[d][a]+=b[m],m++):l=!0;continue}e[d][a]+=b[m]}else{h=null;l=g=!1;if(e[d][a][0]==_$_c0e3[186]){var p=e[d][a].trim();p[p.length-
388
+ 1]==_$_c0e3[186]&&(e[d][a]=p.substr(1,p.length-2))}b[m]==_$_c0e3[543]?(a=0,d++):(a++,a>f&&(f=a))}for(b=0;b<e.length;b++)for(m=0;m<=f;m++)void 0===e[b][m]&&(e[b][m]=_$_c0e3[3]);return e};k.getTokensFromRange=W.getTokensFromRange;k.getRangeFromTokens=W.getRangeFromTokens;return k}(),Ba=function(){function k(r){return t.current&&t.current.options.tableOverflow&&r.target.tagName==_$_c0e3[569]&&r.target.hasAttribute(_$_c0e3[42])}function b(){A.x1=A.x2;A.y1=A.y2;N=null}function c(r,z){z||(z=1);z*=.1;return 0>
389
+ r?Math.min(0,Math.ceil(r/(1+z))+1):Math.max(0,Math.ceil(r/(1+z))-1)}function a(){0<Math.abs(A.speeds.vertical)&&(A.speeds.vertical=c(A.speeds.vertical,1),t.current.scrollY.scrollTop+=d(A.speeds.vertical),0==t.current.scrollY.scrollTop||t.current.scrollY.scrollHeight-t.current.scrollY.scrollTop===t.current.scrollY.clientHeight)&&(A.speeds.vertical=0);0<Math.abs(A.speeds.horizontal)&&(A.speeds.horizontal=c(A.speeds.horizontal,1),t.current.scrollX.scrollLeft+=d(A.speeds.horizontal),0==t.current.scrollX.scrollLeft||
390
+ t.current.scrollX.scrollWidth-t.current.scrollX.scrollLeft===t.current.scrollX.clientWidth)&&(A.speeds.horizontal=0);0>=Math.abs(A.speeds.vertical)&&0>=Math.abs(A.speeds.horizontal)||requestAnimationFrame(a)}function d(r,z){z||(z=100);return Math.ceil(z/1E3*r)}var e={},f=null,h=null,g=null,l=null,m=!1,p=null,n=null,q=null,v=function(r){function z(ja){ja.className&&(ja.classList.contains(_$_c0e3[348])&&(G=ja),ja.classList.contains(_$_c0e3[361])&&(Q=ja),ja.classList.contains(_$_c0e3[544])&&(za=ja));
391
+ ja.tagName==_$_c0e3[545]?x=1:ja.tagName==_$_c0e3[546]?x=2:ja.tagName==_$_c0e3[547]&&(x=3);ja.parentNode&&!G&&z(ja.parentNode)}var x=null,D=null,G=null,Q=null,za=null,X=null,wa=null,Sa=null;z(r.target);if(null!==za)return!1;if(G)if(r.target.classList.contains(_$_c0e3[330]))D=_$_c0e3[548];else if(r.target.classList.contains(_$_c0e3[339]))D=_$_c0e3[136];else if(r.target.classList.contains(_$_c0e3[268]))D=_$_c0e3[410],X=parseInt(r.target.getAttribute(_$_c0e3[43]));else if(r.target.parentNode&&r.target.parentNode.classList&&
392
+ r.target.parentNode.classList.contains(_$_c0e3[175]))X=r.target.getAttribute(_$_c0e3[180]),wa=r.target.getAttribute(_$_c0e3[181]),null===X?D=_$_c0e3[548]:(D=_$_c0e3[407],X=parseInt(X),wa=parseInt(wa));else if(r.target.parentNode&&r.target.parentNode.classList&&r.target.parentNode.classList.contains(_$_c0e3[144]))D=_$_c0e3[549];else if(r.target.classList.contains(_$_c0e3[148]))D=_$_c0e3[549];else if(r.target.parentNode&&r.target.parentNode.classList&&r.target.parentNode.classList.contains(_$_c0e3[550]))D=
393
+ _$_c0e3[402],X=Array.prototype.indexOf.call(r.target.parentNode.children,r.target);else if(1==x)D=_$_c0e3[409],X=r.target.clientWidth-r.offsetX,r.target.classList.contains(_$_c0e3[166])&&3<X&&20>X&&(D=_$_c0e3[551]),X=r.target.getAttribute(_$_c0e3[42]);else if(2==x){if(r=u(r,G))D=_$_c0e3[411],X=r[0],wa=r[1],Sa=r[2]}else if(3==x){if(X=r.target.getAttribute(_$_c0e3[42]),wa=r.target.getAttribute(_$_c0e3[43]),X||wa)D=_$_c0e3[552]}else x||jSuites.findElement(r.target,_$_c0e3[553])&&(D=_$_c0e3[86]);return[G,
394
+ Q,x,D,X,wa,Sa]},u=function(r,z){if(r.changedTouches&&r.changedTouches[0]){var x=r.changedTouches[0].clientX;r=r.changedTouches[0].clientY}else x=r.clientX,r=r.clientY;z=(z.spreadsheet.config.root?z.spreadsheet.config.root:document).elementsFromPoint(x,r);for(var D=0;D<z.length;D++)if(x=z[D].getAttribute(_$_c0e3[42]),r=z[D].getAttribute(_$_c0e3[43]),null!=x&&null!=r)return x=parseInt(x),r=parseInt(r),[x,r,z[D]];return!1},y=function(r){var z=v(r);if(!1===z)return!1;z[0]?z[1]?t.current!=z[1].jexcel&&
395
+ (t.current&&t.current.resetSelection(),t.current=z[1].jexcel):(r=z[0].tabs.getActive(),0<=r&&(t.current=z[0].spreadsheet.worksheets[r])):t.current&&!jSuites.findElement(r.target,_$_c0e3[219])&&(t.current.resetSelection(!0),t.current=null);return z};e.input=function(r){if(r.target.tagName==_$_c0e3[554]&&r.target.classList.contains(_$_c0e3[92])){var z=null;t.current?z=t.current:r.target.getAttribute(_$_c0e3[555])&&(z=I(r.target.getAttribute(_$_c0e3[555])));z&&la.parse.call(z,r.target)}};e.keydown=function(r){if(t.current){r.target.tagName==
396
+ _$_c0e3[554]&&r.target.classList.contains(_$_c0e3[92])&&la.onkeydown.call(t.current,r);if(27==r.which){if(t.current.edition)return t.current.closeEditor(t.current.edition,!1),r.preventDefault(),!1;if(ra.event)return ra.cancel.call(t.current,r),r.preventDefault(),!1;if(ma.event)return ma.cancel.call(t.current,r),!1;if(1==ca.isVisible())return ca.close.call(t.current,!1),r.preventDefault(),!1}if(!r.target.classList.contains(_$_c0e3[219]))if(r.target.classList.contains(_$_c0e3[380])){var z=r.target;
397
+ p&&clearTimeout(p);p=setTimeout(function(){ca.search.call(t.current,z.value);p=null},500)}else if(r.target.classList.contains(_$_c0e3[394]))z=r.target,p&&clearTimeout(p),p=setTimeout(function(){t.current.search(z.value);p=null},400);else if(t.current.edition){var x=t.current.edition.getAttribute(_$_c0e3[42]);13==r.which?t.current.options.columns[x].type==_$_c0e3[183]?t.current.closeEditor(t.current.edition,!0):t.current.options.columns[x].type!=_$_c0e3[57]&&t.current.options.columns[x].type!=_$_c0e3[556]&&
398
+ t.current.options.columns[x].type!=_$_c0e3[433]&&(r.altKey?t.current.parent.input.classList.contains(_$_c0e3[557])||document.execCommand(_$_c0e3[558],!1,_$_c0e3[559]):(t.current.closeEditor(t.current.edition,!0),t.current.down(),r.preventDefault())):9==r.which&&(t.current.closeEditor(t.current.edition,!0),t.current.right(),r.preventDefault())}else if(t.current.selectedCell)if(33==r.which)0<t.current.options.pagination?ta.pageUp.call(t.current):H.pageUp.call(t.current);else if(34==r.which)0<t.current.options.pagination?
399
+ ta.pageDown.call(t.current):H.pageDown.call(t.current);else if(37==r.which)t.current.left(r.shiftKey,r.ctrlKey),r.preventDefault();else if(39==r.which)t.current.right(r.shiftKey,r.ctrlKey),r.preventDefault();else if(38==r.which)t.current.up(r.shiftKey,r.ctrlKey),r.preventDefault();else if(40==r.which)t.current.down(r.shiftKey,r.ctrlKey),r.preventDefault();else if(36==r.which)t.current.first(r.shiftKey,r.ctrlKey),r.preventDefault();else if(35==r.which)t.current.last(r.shiftKey,r.ctrlKey),r.preventDefault();
400
+ else if(32==r.which)t.current.setCheckRadioValue(),r.preventDefault();else if(46==r.which||8==r.which)t.current.isEditable()&&t.current.setValue(t.current.getSelected(!1,!0),_$_c0e3[3]);else if(13==r.which)r.shiftKey?t.current.up():(1==t.current.options.allowManualInsertRow&&t.current.selectedCell[1]==(t.current.results?t.current.results[t.current.results.length-1]:t.current.rows.length-1)&&t.current.insertRow(),t.current.selectedCell&&t.current.down()),r.preventDefault();else if(9==r.which)r.shiftKey?
401
+ t.current.left():(x=t.current.selectedCell[0],t.current.right(),1==t.current.options.allowInsertColumn&&1==t.current.options.allowManualInsertColumn&&t.current.selectedCell[0]==x&&(t.current.insertColumn(),t.current.right())),r.preventDefault();else if((r.ctrlKey||r.metaKey)&&!r.shiftKey)65==r.which?(t.current.selectAll(),r.preventDefault()):83==r.which?(t.current.download(),r.preventDefault()):89==r.which?(t.current.parent.redo(),r.preventDefault()):90==r.which?(t.current.parent.undo(),r.preventDefault()):
402
+ 67==r.which?(t.current.copy(),r.preventDefault()):88==r.which?(t.current.cut(),r.preventDefault()):86==r.which?e.paste(r):189==r.which&&(1==t.current.options.allowDeleteRow&&l==_$_c0e3[410]?(t.current.deleteRow(),r.preventDefault()):1==t.current.options.allowDeleteColumn&&l==_$_c0e3[409]&&(t.current.deleteColumn(),r.preventDefault()));else if(t.current.selectedCell&&t.current.isEditable()){x=t.current.selectedCell[1];var D=t.current.selectedCell[0];t.current.options.columns[D].type!=_$_c0e3[18]&&
403
+ (32==r.keyCode?t.current.options.columns[D].type==_$_c0e3[252]||t.current.options.columns[D].type==_$_c0e3[254]?r.preventDefault():t.current.openEditor(t.current.records[x][D].element,!0,r):113==r.keyCode?t.current.openEditor(t.current.records[x][D].element,!1,r):1!=r.key.length&&r.key!=_$_c0e3[560]||r.altKey||r.ctrlKey||t.current.records[x]&&t.current.openEditor(t.current.records[x][D].element,!0,r))}}};var w=function(r,z,x,D,G,Q){if(1==t.current.parent.input.classList.contains(_$_c0e3[92])&&la.update.call(t.current,
404
+ r,z,x,D,G))return!1;if(t.current.edition)t.current.closeEditor(t.current.edition,!0);else if(l&&l!==Q)return!1;la.current?la.range.call(t.current,r,z,x,D,G):ya[_$_c0e3[11]].call(t.current,r,z,x,D,G)};e.mousedown=function(r){r=r||window.event;var z=r.buttons?r.buttons:r.button?r.button:r.which;if(t.current)if(1==ca.isVisible()&&(jSuites.findElement(r.target,_$_c0e3[384])||ca.close.call(t.current,!1)),t.current.edition){if(jSuites.findElement(r.target,_$_c0e3[99]))return!1}else if(jSuites.findElement(r.target,
405
+ _$_c0e3[219]))return!1;var x=y(r);if(!1===x)return!1;q=x;if(1<z)if(x[3]==_$_c0e3[409]){if(t.current.isSelected(x[4],null))return!1}else if(x[3]==_$_c0e3[410]){if(t.current.isSelected(null,x[4]))return!1}else if(x[3]==_$_c0e3[411]&&t.current.isSelected(x[4],x[5]))return!1;if(t.current){if(x[3]==_$_c0e3[136])t.current.isEditable()&&(ma.event=!0);else if(x[3]==_$_c0e3[551])ca.open.call(t.current,x[4]);else{if(1==x[2])if(1==t.current.options.columnDrag&&6>r.target.offsetHeight-r.offsetY)ra.start.call(t.current,
406
+ r);else if(1==t.current.options.columnResize&&6>r.target.offsetWidth-r.offsetX)va.start.call(t.current,r);else{z=t.current.options.columns.length-1;var D=t.current.options.data.length-1;if(x[3]==_$_c0e3[548])w(0,0,z,D,r,x[3]),g=h=0;else if(x[3]==_$_c0e3[407]){var G=oa.range.call(t.current,x[5])[x[4]];G[1]>z&&(G[1]=z);w(G[0],0,G[1],D,r,x[3]);h=G[0];g=0}else(r.shiftKey||r.ctrlKey)&&null!=h&&null!=g?w(h,0,x[4],D,r,x[3]):(x[3]==_$_c0e3[409]&&h==x[4]&&1==t.current.options.allowRenameColumn&&(n=setTimeout(function(){t.current.setHeader(x[4])},
407
+ 800)),w(x[4],0,x[4],D,r,x[3]),h=x[4],g=0)}if(2==x[2])if(x[3]==_$_c0e3[410])1==t.current.options.rowDrag&&6>r.target.offsetWidth-r.offsetX?ra.start.call(t.current,r):1==t.current.options.rowResize&&6>r.target.offsetHeight-r.offsetY?va.start.call(t.current,r):(z=t.current.options.columns.length-1,D=parseInt(x[4]),(r.shiftKey||r.ctrlKey)&&null!=h&&null!=g?w(0,g,z,D,r,x[3]):(w(0,D,z,D,r,x[3]),h=0,g=D));else if(x[3]==_$_c0e3[411]){z=parseInt(x[4]);D=parseInt(x[5]);if(!t.current.edition&&(G=t.current.options.columns[x[4]].type,
408
+ r.target.tagName==_$_c0e3[561]&&(G==_$_c0e3[255]||G==_$_c0e3[256])&&r.target.parentNode.classList.contains(_$_c0e3[123]))){var Q=r.target.innerText;G==_$_c0e3[255]&&(Q=_$_c0e3[562]+Q);window.open(Q,_$_c0e3[563])}r.shiftKey||r.ctrlKey?w(t.current.selectedCell[0],t.current.selectedCell[1],z,D,r,x[3]):(w(z,D,z,D,r,x[3]),h=z,g=D)}}l=x[3];typeof x[3]!==_$_c0e3[13]&&F.call(t.current.parent,_$_c0e3[564],t.current,x[3],x[4],x[5]);m=!0}else m=!1};e.mouseup=function(r){t.current&&(ra.event?ra.end.call(t.current,
409
+ r):va.event?va.end.call(t.current,r):ma.event?ma.end.call(t.current,r):r.target.classList.contains(_$_c0e3[383])?ca.close.call(t.current,!0):t.current.edition&&r.target.classList.contains(_$_c0e3[565])&&50>r.target.clientWidth-r.offsetX&&50>r.offsetY?da.close.call(t.current,null,!0):r.target.classList.contains(_$_c0e3[318])&&(r=r.target.innerText==_$_c0e3[214]?0:r.target.innerText==_$_c0e3[215]?r.target.getAttribute(_$_c0e3[265])-1:r.target.innerText-1,ta[_$_c0e3[11]].call(t.current,parseInt(r))));
410
+ n&&(clearTimeout(n),n=null);m=l=!1;la.current&&la.close.call(t.current)};e.mousemove=function(r){r=r||window.event;if(t.current){var z=r.target.getAttribute(_$_c0e3[42]),x=r.target.getAttribute(_$_c0e3[43]);if(1==m)ra.event?ra.update.call(t.current,r):va.event?va.update.call(t.current,r):Pa.event&&Pa.update.call(t.current,r);else{var D=r.target.getBoundingClientRect();f&&(f.style.cursor=_$_c0e3[3],f=null);1==t.current.options.editable&&(z||x)&&(1==t.current.options.rowResize&&r.target&&z&&!x&&5>D.width-
411
+ (r.clientX-D.left)?(f=r.target,f.style.cursor=_$_c0e3[566]):1==t.current.options.columnResize&&r.target&&!z&&x&&5>D.height-(r.clientY-D.top)?(f=r.target,f.style.cursor=_$_c0e3[567]):1==t.current.options.rowDrag&&r.target&&!z&&x&&5>D.width-(r.clientX-D.left)?(f=r.target,f.style.cursor=_$_c0e3[568]):1==t.current.options.columnDrag&&r.target&&z&&!x&&5>D.height-(r.clientY-D.top)&&(f=r.target,f.style.cursor=_$_c0e3[568]))}}};e.mouseover=function(r){r=r||window.event;var z=!1;if(t.current&&1==m){var x=
412
+ v(r);if(x[0]){if(x[1]&&t.current!=x[1].jexcel&&t.current)return!1;if(!ra.event&&!va.event)if(ma.event){var D=r.target.getAttribute(_$_c0e3[42]),G=r.target.getAttribute(_$_c0e3[43]);t.current.isSelected(D,G)||null===D||null===G||(ma.call(t.current,D,G),z=!0)}else null!==h&&null!==g&&(1==x[2]&&(D=h,x[3]==_$_c0e3[409]&&(D=r.target.getAttribute(_$_c0e3[42])),G=t.current.options.data.length-1,w(h,0,D,G,r,x[3])),2==x[2]&&(x[3]==_$_c0e3[410]?(D=t.current.options.columns.length-1,G=parseInt(r.target.getAttribute(_$_c0e3[43])),
413
+ w(0,g,D,G,r,x[3])):x[3]==_$_c0e3[411]&&(D=r.target.getAttribute(_$_c0e3[42]),G=r.target.getAttribute(_$_c0e3[43]),D&&G&&(w(h,g,D,G,r,x[3]),z=!0))))}}1==z&&!n&&H.limited.call(t.current)?n=setTimeout(function(){var Q=t.current.content.getBoundingClientRect();if(r.changedTouches&&r.changedTouches[0])var za=r.changedTouches[0].clientX,X=r.changedTouches[0].clientY;else za=r.clientX,X=r.clientY;50>Q.height-(X-Q.top)?H.pageDown.call(t.current,1,null,r):80>X-Q.top&&H.pageUp.call(t.current,1,null,r);50>Q.width-
414
+ (za-Q.left)?H.pageRight.call(t.current,1,null,r):80>za-Q.left&&H.pageLeft.call(t.current,1,null,r);n=null},100):n&&(clearTimeout(n),n=null)};e.dblclick=function(r){if(t.current)if(r.target.classList.contains(_$_c0e3[339]))ma.execute.call(t.current,!1);else{var z=v(r);1==z[2]?1==t.current.options.columnSorting&&(r=r.target.getAttribute(_$_c0e3[42]))&&t.current.orderBy(r):2==z[2]&&t.current.isEditable()&&!t.current.edition&&z[6]&&t.current.openEditor(z[6])}};e.paste=function(r){if(t.current&&t.current.selectedCell&&
415
+ !t.current.edition){var z=r.clipboardData||window.clipboardData;z&&(t.current.paste(t.current.selectedCell[0],t.current.selectedCell[1],z.getData(_$_c0e3[55])),r&&r.preventDefault())}};e.contextmenu=function(r){var z=y(r);!1!==z&&(z[1]||(z=q),t.current&&!t.current.edition&&(z=Array.prototype.slice.call(z,3),Ra.open.call(t.current,r,z)))};var C=Date.now(),A={},N=null,S=null,P=null;e.touchstart=function(r){var z=v(r);z[0]?z[1]&&t.current!=z[1].jexcel&&(t.current&&t.current.resetSelection(),t.current=
416
+ z[1].jexcel):t.current&&(t.current.resetSelection(),t.current=null);if(t.current&&!t.current.edition){var x=z[4];z=z[5];k(r)&&(P=r.touches[0],S=r.touches.length,C=Date.now(),A.x1=r.touches[0].screenX,A.y1=r.touches[0].screenY,A.x2=r.touches[0].screenX,A.y2=r.touches[0].screenY,N=setTimeout(b,250),null!=A.speeds&&(A.speeds.vertical=0,A.speeds.horizontal=0));if(null!==x&&null!==z){t.current.updateSelectionFromCoords(x,z,x,z);var D=r.target;n=setTimeout(function(){t.current.openEditor(D,!1,r);n=null;
417
+ r.preventDefault();r.stopPropagation();r.stopImmediatePropagation()},750)}}};e.touchmove=function(r){n&&(clearTimeout(n),n=null);if(k(r)&&1==S){var z=r.changedTouches[0];P&&(t.current.scrollY.scrollTop+=-1*(z.clientY-P.clientY),t.current.scrollX.scrollLeft+=-1*(z.clientX-P.clientX));P=z;A.x2=r.touches[0].screenX;A.y2=r.touches[0].screenY;null!=A.speeds&&(A.speeds.vertical=0,A.speeds.horizontal=0);null==N&&(N=setTimeout(b,250));r.cancelable&&t.current.options.tableOverflow&&r.preventDefault()}};e.touchend=
418
+ function(r){n&&(clearTimeout(n),n=null);N&&(clearTimeout(N),N=null);P=S=null;if(k(r)){r=Date.now()-C;var z=A.x1,x=A.y1,D=A.x2,G=A.y2,Q=z==z&&x==G?0:Math.sqrt(Math.pow(z-z,2)+Math.pow(x-G,2));G>x&&(Q=-Q);10>Math.abs(G-x)&&(Q=0);G=0>=r?-1:Math.ceil(Q/(r/1E3));x=z==D&&x==x?0:Math.sqrt(Math.pow(z-D,2)+Math.pow(x-x,2));D>z&&(x=-x);10>Math.abs(D-z)&&(x=0);A.speeds={vertical:G,horizontal:0>=r?-1:Math.ceil(x/(r/1E3))};(250>r&&200<Math.abs(A.speeds.vertical)||250>r&&200<Math.abs(A.speeds.horizontal))&&requestAnimationFrame(a)}};
419
+ e.resize=function(){t.current&&1==t.current.parent.config.fullscreen&&H.refresh.call(t.current)};return e}(),t=function(k,b,c){b||(b={});if(b.cloud&&!c)typeof b.plugins.cloud==_$_c0e3[84]?b.plugins.cloud.load(b,function(d){t(k,d,!0)}):console.error(_$_c0e3[570]);else{if(k.spreadsheet)a=k.spreadsheet,Da[_$_c0e3[11]].call(a,b);else var a=na.spreadsheet(k,b);a.processing=!0;1==a.config.loadingSpin&&jSuites.loading.show();jSuites.ajax.oncomplete[a.name]=function(){for(var d=0;d<a.worksheets.length;d++)a.worksheets[d].onload();
420
+ a.processing=!1;if(Array.isArray(a.queue)&&0<a.queue.length)for(;d=a.queue.shift();)d[0].updateCell(d[1],d[2],M.call(d[0],d[1],d[2]),!0);a.config.toolbar&&fa.show.call(a);for(d=0;d<a.worksheets.length;d++)aa.refresh.call(a.worksheets[d]);if(typeof a.config.onload==_$_c0e3[84])a.config.onload(a);ia.state.call(a);for(d=0;d<a.worksheets.length;d++)Y.update.call(a.worksheets[d]);jSuites.loading.hide()};Array.isArray(b.worksheets)&&(b=b.worksheets);if(Array.isArray(b))for(c=0;c<b.length;c++)na.worksheet(a,
421
+ b[c]);else na.worksheet(a,b);jSuites.ajax.pending(a.name)||(jSuites.ajax.oncomplete[a.name](),jSuites.ajax.oncomplete[a.name]=null);return a.worksheets}};t.license=null;t.setLicense=function(k){t.license=k};t.spreadsheet=[];t.picker=la;t.setDictionary=function(k){jSuites.setDictionary(k)};t.extensions={};t.setExtensions=function(k){for(var b=Object.keys(k),c=0;c<b.length;c++)typeof k[b[c]]===_$_c0e3[84]&&(t[b[c]]=k[b[c]],t.extensions[b[c]]=k[b[c]],t.license&&typeof t[b[c]].license==_$_c0e3[84]&&t[b[c]].license.call(t,
422
+ t.license))};t.destroy=function(k,b){k.spreadsheet&&(b&&na.unbind(k),b=t.spreadsheet.indexOf(k.spreadsheet),t.spreadsheet.splice(b,1),k.spreadsheet=null,k.jexcel=null,k.innerHTML=_$_c0e3[3],k.classList.remove(_$_c0e3[571]),k.classList.remove(_$_c0e3[348]))};t.version=J;t.helpers=E;t.events=Ba;typeof formula!==_$_c0e3[13]&&(t.formula=formula);t.editors=function(){var k={},b=function(c,a){return 1==c[a]||c.options&&1==c.options[a]?!0:c[a]==_$_c0e3[229]||c.options&&c.options[a]==_$_c0e3[229]?!0:!1};
423
+ k.createEditor=function(c,a,d,e){e.parent.input.setAttribute(_$_c0e3[100],!1);c==_$_c0e3[220]?(c=document.createElement(_$_c0e3[220]),c.type=_$_c0e3[55],c.value=d):c=document.createElement(_$_c0e3[20]);c.style.width=a.offsetWidth-2+_$_c0e3[44];c.style.height=a.offsetHeight-1+_$_c0e3[44];e.parent.input.appendChild(c);return c};k.createDialog=function(c,a,d,e,f,h){c=k.createEditor(_$_c0e3[20],c,a,f);c.classList.add(_$_c0e3[572]);c.classList.add(_$_c0e3[565]);800>window.innerWidth?(f.parent.input.style.top=
424
+ _$_c0e3[142],f.parent.input.style.left=_$_c0e3[142]):(a=f.parent.input.getBoundingClientRect(),window.innerHeight<a.bottom&&(f.parent.input.style.marginTop=-f.parent.input.offsetHeight));return c};k.general=function(){var c={},a=function(e){e=(_$_c0e3[3]+e)[0];return e==_$_c0e3[12]||e==_$_c0e3[573]?!0:!1},d=function(e){if(e.format||e.mask||e.locale){var f={};e.mask?f.mask=e.mask:e.format?f.mask=e.format:(f.locale=e.locale,f.options=e.options);e.decimal&&(f.options||(f.options={}),f.options={decimal:e.decimal});
425
+ return f}return null};c.createCell=function(e,f,h,g,l,m){m.type!=_$_c0e3[14]&&m.type!=_$_c0e3[307]&&m.type!=_$_c0e3[306]||e.classList.add(_$_c0e3[574]);return c.updateCell(e,f,h,g,l,m)};c.updateCell=function(e,f,h,g,l,m){h=parseInt(h);g=parseInt(g);if(e){var p=d(m),n=null;f===_$_c0e3[3]||a(f)||typeof f===_$_c0e3[14]||(p?(p=jSuites.mask.extract(f,p,!0))&&p.value!==_$_c0e3[3]&&(n=p.value):1==(!1===l.parent.config.autoCasting||!1===m.autoCasting?!1:!0)&&(m.type==_$_c0e3[14]||m.type==_$_c0e3[307]||m.type==
426
+ _$_c0e3[306]?(p=jSuites.mask.extract(f,m,!0))&&p.value!==_$_c0e3[3]&&(n=p.value):jSuites.isNumeric(Number(f))&&(n=Number(f))));null!==n&&(f=n);f=c.parseValue(h,g,f,l,m,e);f instanceof Element||f instanceof HTMLDocument?(e.innerHTML=_$_c0e3[3],e.appendChild(f)):1==l.parent.config.stripHTML?e.innerText=f:e.innerHTML=f;if(null!==n)return n}};c.openEditor=function(e,f,h,g,l,m){var p=l.parent.input;p.onblur=function(){p.classList.contains(_$_c0e3[92])||l.closeEditor(e,!0)};if(m.type==_$_c0e3[14]||m.type==
427
+ _$_c0e3[307]||m.type==_$_c0e3[306])p.classList.add(_$_c0e3[557]),a(f)||m.inputmode||(m.inputmode=_$_c0e3[575]);h=null;a(f)||(m.inputmode&&p.setAttribute(_$_c0e3[96],m.inputmode),(h=d(m))?(m.disabledMaskOnEdition||(m.mask?(m=m.mask.split(_$_c0e3[216]),p.setAttribute(_$_c0e3[94],m[0])):m.locale&&p.setAttribute(_$_c0e3[576],m.locale)),h.input=l.parent.input,l.parent.input.mask=h,jSuites.mask.render(f,h,!1)):f&&m.type==_$_c0e3[306]&&(f*=100));h||(l.parent.config.stripHTML?p.innerText=f:p.innerHTML=f,
428
+ jSuites.focus(l.parent.input))};c.closeEditor=function(e,f,h,g,l,m){e=l.parent.input;f=f&&e.innerText.trim().length?e.innerText:_$_c0e3[3];a(f)?f=f.replace(/(\r\n|\n|\r)/gm,_$_c0e3[3]):m.type==_$_c0e3[306]&&(f+=_$_c0e3[577],e.classList.remove(_$_c0e3[578]));return f};c.parseValue=function(e,f,h,g,l,m){a(h)&&1==g.parent.config.parseFormulas&&(h=g.executeFormula(h,e,f));h instanceof Element||h instanceof HTMLDocument||!l||a(h)||!(f=d(l))||(e=jSuites.mask.render(h,f,!0),m&&f.mask&&(f=f.mask.split(_$_c0e3[216]),
429
+ f[1]&&(f[1].match(new RegExp(_$_c0e3[579],_$_c0e3[376]))&&(0>h?m.classList.add(_$_c0e3[580]):m.classList.remove(_$_c0e3[580])),f[1].match(new RegExp(_$_c0e3[581],_$_c0e3[376]))&&0>h&&(e=_$_c0e3[211]+e+_$_c0e3[232]))),e&&(h=e));return h};c[_$_c0e3[51]]=function(e,f){var h;return(h=d(e))?jSuites.mask.render(f,h,!0):e.type==_$_c0e3[306]?100*parseFloat(f):f};return c}();k.text=k.general;k.number=k.general;k.numeric=k.general;k.percent=k.general;k.notes=function(){var c={},a=null;c.updateCell=function(d,
430
+ e,f,h,g,l){d&&(f=document.createElement(_$_c0e3[20]),f.classList.add(_$_c0e3[582]),1==g.parent.config.stripHTML?f.innerText=e:f.innerHTML=e,d.innerHTML=_$_c0e3[3],d.appendChild(f))};c.createCell=c.updateCell;c.openEditor=function(d,e,f,h,g,l){var m=l&&l.options?l.options:{};m.focus=!0;m.value=e;m.border=!1;m.height=_$_c0e3[583];m.toolbar=!1;a=k.createDialog(d,e,f,h,g,l);a=jSuites.editor(a,m)};c.closeEditor=function(d,e,f,h,g,l){return e?a.getData():_$_c0e3[3]};return c}();k.dropdown=function(){var c=
431
+ {createCell:function(a,d,e,f,h,g){g.render==_$_c0e3[584]?a.classList.add(_$_c0e3[585]):a.classList.add(_$_c0e3[586]);if(a=c.updateCell(a,d,e,f,h,g))return a},destroyCell:function(a){a.classList.remove(_$_c0e3[586])},updateCell:function(a,d,e,f,h,g){if(a){var l=c.getItem(a,d,e,f,h,g);l?a.innerHTML=l:d?(d=c.fromLabel(a,d,e,f,h,g),d.length?(l=c.getItem(a,d,e,f,h,g),a.innerHTML=l):a.innerHTML=_$_c0e3[3]):a.innerHTML=_$_c0e3[3];return d}},openEditor:function(a,d,e,f,h,g){var l=k.createEditor(_$_c0e3[20],
432
+ a,d,h),m=g.delimiter||_$_c0e3[216];g=Object.create(g);g.options||(g.options={});typeof g.filter==_$_c0e3[84]&&(g.source=g.filter(h.el,a,e,f,g.source));typeof g.filterOptions==_$_c0e3[84]&&(g=g.filterOptions(h,a,e,f,d,g));e=g.options;g.source&&(e.data=JSON.parse(JSON.stringify(g.source)));b(g,_$_c0e3[587])&&(e.multiple=!0);b(g,_$_c0e3[56])&&(e.autocomplete=!0);e.format=!0;e.opened=!0;e.width=a.offsetWidth-2;e.onclose=function(){h.closeEditor(a,!0)};b(g,_$_c0e3[587])?d&&(e.value=(_$_c0e3[3]+d).split(m)):
433
+ e.value=d;jSuites.dropdown(l,e)},closeEditor:function(a,d,e,f,h,g){for(var l=h.parent.input.children[0],m=g.delimiter||_$_c0e3[216],p=l.dropdown.getText(!0),n=l.dropdown.getValue(!0),q=0;q<n.length;q++)!1===c.getItem(a,n[q],e,f,h,g)&&g.source.push({id:n[q],name:p[q]});l.dropdown.close(!0);if(d)return n.join(m)},fromLabel:function(a,d,e,f,h,g){a=g.delimiter||_$_c0e3[216];e=[];f=[];Array.isArray(d)||(d=(_$_c0e3[3]+d).split(a));for(h=0;h<d.length;h++)f[d[h].trim()]=!0;d=Object.keys(f);!b(g,_$_c0e3[587])&&
434
+ 1<Object.keys(d).length&&(f=[],f[d[0]]=!0);for(d=0;d<g.source.length;d++)f[g.source[d].name]&&e.push(g.source[d].id);return e.join(a)},getItem:function(a,d,e,f,h,g){f=g.delimiter||_$_c0e3[216];a=[];e=[];Array.isArray(d)||(d=(_$_c0e3[3]+d).split(f));for(f=0;f<d.length;f++)e[d[f].trim()]=!0;f=Object.keys(e);!b(g,_$_c0e3[587])&&1<Object.keys(f).length&&(d=[],d[f[0]]=!0,e=d);if(g.source&&typeof g.source[0]!==_$_c0e3[83])for(d=0;d<g.source.length;d++)f=g.source[d],g.source[d]={id:f,name:f};for(d=0;d<g.source.length;d++)typeof e[g.source[d].id]!==
435
+ _$_c0e3[13]&&a.push(g.render==_$_c0e3[257]?g.source[d].color:g.render==_$_c0e3[588]?g.source[d].image:g.source[d].name);if(a.length){if(typeof g.render!==_$_c0e3[13]){for(d=0;d<a.length;d++)e=d,f=a[d],f=g.render==_$_c0e3[257]?_$_c0e3[589]+f+_$_c0e3[590]:g.render==_$_c0e3[588]?_$_c0e3[589]+f+_$_c0e3[590]:g.render==_$_c0e3[584]?_$_c0e3[592]+(g.source[d].color||_$_c0e3[591])+_$_c0e3[593]+f+_$_c0e3[594]:void 0,a[e]=f;return a.join(_$_c0e3[3])}for(d=0;d<a.length;d++)a[d]=(_$_c0e3[3]+a[d]).replace(_$_c0e3[214],
436
+ _$_c0e3[595]);return a.join(_$_c0e3[295])}return!1}};c[_$_c0e3[51]]=function(a,d){for(var e=0;e<a.source.length;e++)if(a.source[e].id==d)return a.render==_$_c0e3[257]?a.source[e].color:a.render==_$_c0e3[588]?a.source[e].image:a.source[e].name};return c}();k.autocomplete=k.dropdown;k.calendar=function(){var c={},a=null;c.updateCell=function(d,e,f,h,g,l){if(d){f=e;l=c.getFormat(l);0<e&&Number(e)==e&&(f=jSuites.calendar.numToDate(e));h=_$_c0e3[3]+e;h.substr(4,1)==_$_c0e3[184]&&h.substr(7,1)==_$_c0e3[184]?
437
+ h=!0:(h=h.split(_$_c0e3[184]),h=4==h[0].length&&h[0]==Number(h[0])&&2==h[1].length&&h[1]==Number(h[1])?!0:!1);h||(h=jSuites.calendar.extractDateFromString(e,l))&&(f=h);if(f=jSuites.calendar.getDateString(f,l))return d.innerText=f,e;d.innerText=_$_c0e3[3];return _$_c0e3[3]}};c.createCell=c.updateCell;c.openEditor=function(d,e,f,h,g,l){l=Object.create(l);typeof l.filterOptions==_$_c0e3[84]&&(l=l.filterOptions(g,d,f,h,e,l));f=l.options||{};f.opened=!0;f.onclose=function(m,p){g.closeEditor(d,!0)};typeof l.timepicker!==
438
+ _$_c0e3[13]&&(f.time=b(l,_$_c0e3[596])?!0:!1);typeof f.readonly!==_$_c0e3[13]&&(f.readonly=f.readonly);f.value=e||null;f.placeholder=f.format;a=k.createEditor(_$_c0e3[220],d,e,g);jSuites.calendar(a,f);!1===a.calendar.options.readonly&&a.focus()};c.closeEditor=function(d,e,f,h,g){d=a.calendar.close(!0,a.value?!0:!1);d=a.value?d:_$_c0e3[3];if(e)return d};c.getFormat=function(d){return d&&d.format?d.format:d&&d.options&&d.options.format?d.options.format:_$_c0e3[597]};c[_$_c0e3[51]]=function(d,e){d=c.getFormat(d);
439
+ return jSuites.calendar.getDateString(e,d)};return c}();k.color=function(){var c={},a=null;c.updateCell=function(d,e,f,h,g,l){d&&(l.render==_$_c0e3[598]?(f=document.createElement(_$_c0e3[20]),f.className=_$_c0e3[257],f.style.backgroundColor=e,d.innerText=_$_c0e3[3],d.appendChild(f)):(d.style.color=e,d.innerText=e))};c.createCell=c.updateCell;c.openEditor=function(d,e,f,h,g,l){l=Object.create(l);typeof l.filterOptions==_$_c0e3[84]&&(l=l.filterOptions(g,d,f,h,e,l));l.value=e;l.onclose=function(m,p){g.closeEditor(d,
440
+ !0)};a=k.createEditor(_$_c0e3[220],d,e,g);a=jSuites.color(a,l);a.open()};c.closeEditor=function(d,e,f,h,g,l){d=a.close(!0);if(e)return d};c[_$_c0e3[51]]=function(d,e){d=document.createElement(_$_c0e3[20]);d.style.width=_$_c0e3[599];d.style.height=_$_c0e3[22];d.style.backgroundColor=e;return d.outerHTML};return c}();k.checkbox=function(){var c={createCell:function(a,d,e,f,h,g){d=d&&d!=_$_c0e3[600]&&d!=_$_c0e3[601]?!0:!1;e=document.createElement(_$_c0e3[220]);e.type=_$_c0e3[252];e.checked=d;e.onclick=
441
+ function(){h.setValue(a,this.checked)};(g&&1==g.readOnly||!h.isEditable())&&e.setAttribute(_$_c0e3[602],_$_c0e3[602]);a.innerHTML=_$_c0e3[3];a.appendChild(e);return d},updateCell:function(a,d){d=d&&d!=_$_c0e3[600]&&d!=_$_c0e3[601]?!0:!1;a&&(a.children[0].checked=d);return d},openEditor:function(a,d,e,f,h){d=a.children[0].checked?!1:!0;h.setValue(a,d);return!1},closeEditor:function(a,d){return!1}};c[_$_c0e3[51]]=function(a,d){return 1==d||1==d||d==_$_c0e3[229]?jSuites.translate(_$_c0e3[229]):jSuites.translate(_$_c0e3[600])};
442
+ return c}();k.radio=function(){var c={createCell:function(a,d,e,f,h,g){a.getAttribute(_$_c0e3[42]);e=document.createElement(_$_c0e3[220]);e.type=_$_c0e3[254];e.checked=1==d||1==d||d==_$_c0e3[229]?!0:!1;e.onclick=function(){h.setValue(a,!0)};(g&&1==g.readOnly||!h.isEditable())&&e.setAttribute(_$_c0e3[602],_$_c0e3[602]);a.innerHTML=_$_c0e3[3];a.appendChild(e)},updateCell:function(a,d,e,f,h){d=1==d||1==d||d==_$_c0e3[229]||d==_$_c0e3[603]?!0:!1;a&&(a.children[0].checked=d);if(1==d){a=[];for(var g=0;g<
443
+ h.options.data.length;g++)f!=g&&h.options.data[g][e]&&a.push({x:e,y:g,value:0});a.length&&h.setValue(a)}return d},openEditor:function(a,d,e,f,h){return!1},closeEditor:function(a,d){return!1}};c[_$_c0e3[51]]=function(a,d){return 1==d||1==d||d==_$_c0e3[229]?_$_c0e3[229]:_$_c0e3[600]};return c}();k.autonumber=function(){var c={},a=null;c.createCell=function(d,e,f,h,g,l){(e=parseInt(e))||0<parseInt(d.innerText)&&(e=parseInt(d.innerText));l.sequence||(l.sequence=0);e?c.isValid(e,f,h,g)||(e=_$_c0e3[244]):
444
+ e=l.sequence+1;e>l.sequence&&(l.sequence=e);return d.innerText=e};c.updateCell=c.createCell;c.openEditor=function(d,e,f,h,g,l){a=k.createEditor(_$_c0e3[220],d,e,g);a.onblur=function(){g.closeEditor(d,!0)};a.focus();a.value=e};c.closeEditor=function(d,e,f,h,g){return e?a.value:_$_c0e3[3]};c.isValid=function(d,e,f,h){for(var g,l=0;l<h.options.data.length;l++)if(g=h.value(e,l),g==d&&l!=f)return!1;return!0};return c}();k.progressbar=function(){var c={},a=null;c.createCell=function(d,e){e=parseInt(e);
445
+ if(100<e)e=100;else if(!e||0>e)e=0;if(d.children[0]&&d.children[0].tagName==_$_c0e3[554])var f=d.children[0];else f=document.createElement(_$_c0e3[20]),f.classList.add(_$_c0e3[258]),d.innerText=_$_c0e3[3],d.classList.add(_$_c0e3[604]),d.appendChild(f);f.style.width=parseInt(e)+_$_c0e3[577];f.setAttribute(_$_c0e3[265],parseInt(e)+_$_c0e3[577])};c.destroyCell=function(d){d.classList.remove(_$_c0e3[604])};c.updateCell=c.createCell;c.openEditor=function(d,e,f,h,g,l){a=k.createEditor(_$_c0e3[220],d,e,
446
+ g);a.type=_$_c0e3[14];a.setAttribute(_$_c0e3[605],0);a.setAttribute(_$_c0e3[606],100);a.onblur=function(){g.closeEditor(d,!0)};a.focus();a.value=e};c.closeEditor=function(d,e,f,h,g){return e?a.value:_$_c0e3[3]};return c}();k.rating=function(){var c={},a=null;c.createCell=function(d,e,f,h,g,l){return c.setCell(d,e,l)};c.destroyCell=function(d){d.classList.remove(_$_c0e3[607])};c.updateCell=c.createCell;c.openEditor=function(d,e,f,h,g,l){a=k.createEditor(_$_c0e3[220],d,e,g);a.type=_$_c0e3[14];a.setAttribute(_$_c0e3[605],
447
+ 0);a.setAttribute(_$_c0e3[606],5);a.onblur=function(){g.closeEditor(d,!0)};a.focus();a.value=e};c.closeEditor=function(d,e,f,h,g,l){return e?a.value:_$_c0e3[3]};c.setCell=function(d,e,f){e=parseInt(e);if(5<e)e=5;else if(!e||0>e)e=0;if(d){f=f&&f.color?f.color:_$_c0e3[580];var h=document.createElement(_$_c0e3[20]);h.setAttribute(_$_c0e3[265],parseInt(e)+_$_c0e3[608]);h.classList.add(_$_c0e3[259]);for(var g=0;g<e;g++){var l=document.createElement(_$_c0e3[442]);l.className=_$_c0e3[507];l.style.color=
448
+ f;l.innerHTML=_$_c0e3[609];h.appendChild(l)}d.innerHTML=_$_c0e3[3];d.className=_$_c0e3[607];d.appendChild(h)}return e};return c}();k.email=function(){var c={createCell:function(a,d,e,f,h,g){a&&(a.children&&a.children[0]&&a.children[0].tagName==_$_c0e3[561]?e=a.children[0]:(e=document.createElement(_$_c0e3[200]),a.innerText=_$_c0e3[3],a.appendChild(e),g.options&&g.options.url&&e.setAttribute(_$_c0e3[610],g.options.url)),e.innerText=d)}};c.updateCell=c.createCell;c.openEditor=function(a,d,e,f,h,g){h.parent.input.classList.add(_$_c0e3[557]);
449
+ h.parent.input.onblur=function(){h.closeEditor(a,!0)};h.parent.input.innerText=d;jSuites.focus(h.parent.input)};c.closeEditor=function(a,d,e,f,h){h.parent.input.classList.remove(_$_c0e3[557]);return d?h.parent.input.innerText.replace(new RegExp(/\n/,_$_c0e3[187]),_$_c0e3[3]):_$_c0e3[3]};return c}();k.url=k.email;k.image=function(){var c={},a=null;c.createCell=function(d,e,f,h,g,l){if(d)if(e)if(d.children&&d.children[0]&&d.children[0].tagName==_$_c0e3[611])d.children[0].src=e;else{var m=document.createElement(_$_c0e3[37]);
450
+ l.render==_$_c0e3[612]&&m.classList.add(_$_c0e3[612]);l.options&&(m.style.maxWidth=_$_c0e3[613],l.options.absolute&&(d.classList.add(_$_c0e3[614]),m.setAttribute(_$_c0e3[615],-1),m.classList.add(_$_c0e3[219]),m.classList.add(_$_c0e3[616]),m.settings=function(){g.openEditor(d,e,f,h,g,l)},m.dblclick=function(){g.openEditor(d,!0)},m[_$_c0e3[617]]=function(){g.setValueFromCoords(f,h,_$_c0e3[3])}),l.options.width&&(m.style.width=parseInt(l.options.width)+_$_c0e3[44]),l.options.height&&(m.style.height=
451
+ parseInt(l.options.height)+_$_c0e3[44]));m.src=e;d.innerHTML=_$_c0e3[3];d.appendChild(m)}else d.innerHTML=_$_c0e3[3]};c.updateCell=c.createCell;c.openEditor=function(d,e,f,h,g,l){(l&&l.options?l.options:{}).value=e;a=k.createDialog(d,e,f,h,g,l);e&&(d=document.createElement(_$_c0e3[37]),d.src=e,d.classList.add(_$_c0e3[618]),d.style.width=_$_c0e3[613],a.appendChild(d));jSuites.image(a,l)};c.closeEditor=function(d,e,f,h,g,l){if(e&&(d=a.children[0]))return d.tagName==_$_c0e3[611]?d.src:_$_c0e3[3]};c[_$_c0e3[51]]=
452
+ function(d,e){return _$_c0e3[619]+e+_$_c0e3[620]};return c}();k.html=function(){var c={},a=null;c.createCell=function(d,e){d.classList.add(_$_c0e3[621]);var f=document.createElement(_$_c0e3[20]);f.innerHTML=e;d.appendChild(f)};c.updateCell=function(d,e){d&&(d.firstChild.innerHTML=e)};c.destroyCell=function(d){d.classList.remove(_$_c0e3[621])};c.openEditor=function(d,e,f,h,g,l){var m=l&&l.options?l.options:{};m.focus=!0;m.value=e;m.border=!1;m.height=_$_c0e3[583];e=k.createDialog(d,e,f,h,g,l);a=jSuites.editor(e,
453
+ m);a.close=function(){g.closeEditor(d,!0)};jSuites.tracking(a,!0)};c.closeEditor=function(d,e,f,h,g,l){jSuites.tracking(a,!1);d=a.getData();if(e)return d};return c}();k.hidden=function(){return{createCell:function(c,a,d,e,f){c.style.display=_$_c0e3[40];c.innerText=a},updateCell:function(c,a,d,e,f){c&&(c.innerText=a)},openEditor:function(c,a,d,e,f){return!1},closeEditor:function(c,a){return!1}}}();k.tags=function(){var c={},a=null;c.createCell=function(d,e){d.classList.add(_$_c0e3[622]);c.updateCell(d,
454
+ e)};c.updateCell=function(d,e){d&&(d.innerHTML=e)};c.destroyCell=function(d){d.classList.remove(_$_c0e3[622])};c.openEditor=function(d,e,f,h,g,l){var m=l&&l.options?l.options:{};m.value=e;a=k.createDialog(d,e,f,h,g,l);d=document.createElement(_$_c0e3[20]);d.style.margin=_$_c0e3[22];d.style.marginRight=_$_c0e3[623];a.appendChild(d);a=jSuites.tags(d,m);d.focus();jSuites.focus(d)};c.closeEditor=function(d,e,f,h,g,l){d=a.getValue();if(e)return d};return c}();k.record=function(){var c={},a=null;c.createCell=
455
+ function(d,e,f,h,g,l){d.classList.add(_$_c0e3[586]);var m;(m=g.parent.getWorksheetInstance(l.worksheetId))?m.rows?c.updateCell(d,e,f,h,g,l):(d.innerText=_$_c0e3[244],g.parent.queue.push([g,f,h])):(d.innerText=_$_c0e3[244],g.parent.queue.push([g,f,h]))};c.destroyCell=function(d){d.classList.remove(_$_c0e3[586])};c.updateCell=function(d,e,f,h,g,l){d&&(typeof l.worksheetId==_$_c0e3[13]?d.innerText=_$_c0e3[244]:d.innerHTML=c.getValue(d,e,f,h,g,l))};c.openEditor=function(d,e,f,h,g,l){var m=l.delimiter||
456
+ _$_c0e3[216];l=Object.create(l);l.options||(l.options={});typeof l.filter==_$_c0e3[84]&&(l.source=l.filter(g.el,d,f,h,l.source));typeof l.filterOptions==_$_c0e3[84]&&(l=l.filterOptions(g,d,f,h,e,l));f=l.options;f.data=c.getSource(g,l);b(l,_$_c0e3[587])&&(f.multiple=!0);b(l,_$_c0e3[56])&&(f.autocomplete=!0);f.opened=!0;f.width=d.offsetWidth-2;f.onclose=function(){g.closeEditor(d,!0)};b(l,_$_c0e3[587])?e&&(f.value=(_$_c0e3[3]+e).split(m)):f.value=e;a=k.createEditor(_$_c0e3[20],d,e,g);a=jSuites.dropdown(a,
457
+ f)};c.closeEditor=function(d,e,f,h,g,l){d=l.delimiter||_$_c0e3[216];f=a.getValue(!0);a.close(!0);if(e)return f.join(d)};c.getValue=function(d,e,f,h,g,l){d=[];if(typeof l.worksheetId==_$_c0e3[17]&&(g=g.parent.getWorksheetInstance(l.worksheetId))){f=l.worksheetColumn?l.worksheetColumn:0;0<=l.worksheetImage&&(f=l.worksheetImage);if(e==_$_c0e3[3]||0==e||null==e||void 0==e)return _$_c0e3[3];e=(_$_c0e3[3]+e).split(_$_c0e3[216]);for(h=0;h<e.length;h++){var m=e[h].trim();var p=g.name(f);m=g.getRowById(m);
458
+ p=!1===m?_$_c0e3[624]:m[p];0<=l.worksheetImage&&(p=_$_c0e3[625]+p+_$_c0e3[626]);d.push(p)}return 0<=l.worksheetImage?d.join(_$_c0e3[3]):d.join(_$_c0e3[295])}return _$_c0e3[244]};c.getSource=function(d,e){var f=e.worksheetColumn?e.worksheetColumn:0,h=null;typeof e.worksheetId==_$_c0e3[17]&&(h=d.parent.getWorksheetInstance(e.worksheetId));if(h){var g,l=[];for(d=0;d<h.rows.length;d++)if(g=h.value(f,d))g={id:h.getRowId(d),name:g},void 0!=e.worksheetImage&&(g.image=h.value(e.worksheetImage,d)),l.push(g)}else console.error(_$_c0e3[627]+
459
+ e.worksheetId);return l};c[_$_c0e3[51]]=function(d,e){for(var f=0;f<d.source.length;f++)if(d.source[f].id==e)return d.render==_$_c0e3[257]?d.source[f].color:d.render==_$_c0e3[588]?d.source[f].image:d.source[f].name};return c}();return k}();typeof jQuery!==_$_c0e3[13]&&function(k){k.fn.jspreadsheet=k.fn.jexcel=function(b){var c=k(this)[_$_c0e3[51]](0);if(c.jspreadsheet){if(typeof arguments[0]==_$_c0e3[14])var a=arguments[0],d=2;else a=0,d=1;return c.jspreadsheet[a][b].apply(c.jspreadsheet[a],Array.prototype.slice.call(arguments,
460
+ d))}return t(k(this)[_$_c0e3[51]](0),arguments[0])}}(jQuery);return t});