Socket
Socket
Sign inDemoInstall

@jspreadsheet/validations

Package Overview
Dependencies
2
Maintainers
2
Versions
36
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.0.1 to 1.0.2

113

dist/index.js

@@ -9,28 +9,29 @@ if (!lemonade && typeof(require) === 'function') {

var _$_662b=["translate","","status","scope","validations","indexOf","This extension is not included on the scope of this license","License required","version","This extension request Jspreadsheet Pro v9+","config","action","range","!","split","current",":","getTokensFromRange","helpers","splice","push","length","parent","bind","sort","forEach","oldValue","index","value","worksheets","object","keys","every","format","map","entries"," .conditional_formatting_","name","_"," {\n",";\n","join","\n}",
"jss_validations_","getElementById","style","createElement","id","appendChild","head","getElementsByTagName","innerHTML","getValidations","get","setValidations","set","resetValidations","reset","isArray","JSS: input should be an array","error","stringify","parse","call","setHistory","persistence","onvalidation","dispatch","build","updateAll","getWorksheetName","updateFormula","#REF!","updateWorksheetName","between","is not between","not between","less than","<","less than or equal to","<=","bigger than",
">","bigger than or equal to",">=","equal to","=","different to","!=","contains","not contains","begins with","ends with","is a valid email","valid email","is a valid url","valid url","is a valid date","valid date","before","on or before","after","on or after","different to","toUpperCase","replace","substr","create","instance","calendar","element","a number ","a text ","a date ","an element of the list: ","The content of this cell must be ","type","criteria"," ","list"," [",",","]"," and ","mask",
"locale","UTC","DateTimeFormat","2012","yyyy","12","mm","19","dd","operator","createType","number","Number","text","Text","date","Date","List","textLength","Text length","exist","Cell is empty","not exist","Cell is not empty","setData","children","el","all","classList","display","none","jss_object","add","header","dropdown","createOperator","createPicker","innerText","focus","picker","createColorPicker","color","close","The range is mandatory","The type is mandatory","The criteria is mandatory","className",
"allowBlank","includes","start","end","formatColor","formatBackgroundColor","background-color","bold","font-weight","italic","font-style","Cell range","Action","Warning message","Reject entry","Format style","Type","Operator","Color","Background color","Add a custom CSS className","Save","Back","records","data-tooltip","removeAttribute","jss_warning","remove","data-validation","getAttribute","v","getColumnNameFromCoords","setAttribute","reject","conditional_formatting_","init","updateDataFromSelection",
"message","All validations found for this selection","data","filter","No validation found for this selection","closeForm","toolbar","settings","i","Add new validation","getRange","open","items","modal","onevent","onafterchanges","onchangeproperty","onformulachain","x","y","oncreatecell","onbeforechange","onselection","getCoordsFromColumnName","getRangeFromTokens","getCoordsFromRange","onload","onrenameworksheet","onchangereferences","ignoreHistory","historyCascade","onundo","onredo","createModal",
"Validations","420px","612px","openForm","warning","listContainer","settingsContainer","block","removeValidation","div","append","tools","render","oninit","setPlugins","license","undefined","exports","function","amd"];
(function(p,g){typeof exports===_$_662b[30]&&typeof module!==_$_662b[259]?module[_$_662b[260]]=g():typeof define===_$_662b[261]&&define[_$_662b[262]]?define(g):p[_$_662b[4]]=g()})(this,function(){var p=null,g=jSuites[_$_662b[0]],E=function(){var a=_$_662b[1];8==this[_$_662b[2]]?this[_$_662b[3]]&&-1!=this[_$_662b[3]][_$_662b[5]](_$_662b[4])||(a=_$_662b[6]):a=_$_662b[7];if(!a){var e=p[_$_662b[8]]();if(!e||!e[_$_662b[8]]||9>parseInt(e[_$_662b[8]]))a=_$_662b[9]}return a},z={reject:2,warning:1,format:0},
F=function(a,e){a=this[_$_662b[10]][_$_662b[4]][a]&&this[_$_662b[10]][_$_662b[4]][a][_$_662b[11]]?this[_$_662b[10]][_$_662b[4]][a][_$_662b[11]]:0;e=this[_$_662b[10]][_$_662b[4]][e]&&this[_$_662b[10]][_$_662b[4]][e][_$_662b[11]]?this[_$_662b[10]][_$_662b[4]][e][_$_662b[11]]:0;return z[a]-z[e]},v=function(a,e,f){if(e&&e[_$_662b[12]]){var b;if(0<e[_$_662b[12]][_$_662b[5]](_$_662b[13])){e=e[_$_662b[12]][_$_662b[14]](_$_662b[13]);var c=e[1];var d=u(e[0])}else c=e[_$_662b[12]],d=p[_$_662b[15]];d[_$_662b[4]]&&
(e=-1===c[_$_662b[5]](_$_662b[16])?[c]:p[_$_662b[18]][_$_662b[17]](c),e[_$_662b[25]](function(h){d[_$_662b[4]][h]||(d[_$_662b[4]][h]=[]);if(0===a){if(b=d[_$_662b[4]][h][_$_662b[5]](f),0<=b)d[_$_662b[4]][h][_$_662b[19]](b,1)}else d[_$_662b[4]][h][_$_662b[20]](f);if(1<d[_$_662b[4]][h][_$_662b[21]])d[_$_662b[4]][h][_$_662b[24]](F[_$_662b[23]](d[_$_662b[22]]))}))}},A=function(a){for(var e=0;e<a[_$_662b[29]][_$_662b[21]];e++)a[_$_662b[29]][e][_$_662b[4]]={};if(a=a[_$_662b[10]][_$_662b[4]])for(e=0;e<a[_$_662b[21]];e++)v(1,
a[e],e)},G=function(a){for(var e=0;e<a[_$_662b[29]][_$_662b[21]];e++)a[_$_662b[29]][e][_$_662b[4]]={}},t=function(){var a=function(c){var d=c[_$_662b[10]][_$_662b[4]];if(d&&d[_$_662b[21]]){for(var h=_$_662b[1],l=0;l<d[_$_662b[21]];l++)if(d[l]&&d[l][_$_662b[33]]){var k=Object[_$_662b[35]](d[l][_$_662b[33]])[_$_662b[34]](function([n,m]){return`\t${n}: ${m} !important\n`});h+=_$_662b[36]+c[_$_662b[37]]+_$_662b[38]+l+_$_662b[39]+k[_$_662b[41]](_$_662b[40])+_$_662b[42]}d=document[_$_662b[44]](_$_662b[43]+
c[_$_662b[37]]);d||(d=document[_$_662b[46]](_$_662b[45]),d[_$_662b[47]]=_$_662b[43]+c[_$_662b[37]],document[_$_662b[50]](_$_662b[49])[0][_$_662b[48]](d));d[_$_662b[51]]=h}},e=function(c){this[_$_662b[10]][_$_662b[4]]||(this[_$_662b[10]][_$_662b[4]]=[]);var d=this[_$_662b[10]][_$_662b[4]][_$_662b[21]];this[_$_662b[10]][_$_662b[4]][_$_662b[20]](c);return d},f=function(c,d){this[_$_662b[10]][_$_662b[4]][c]=d},b=function(c){c[_$_662b[52]]=b[_$_662b[53]];c[_$_662b[54]]=b[_$_662b[55]];c[_$_662b[56]]=b[_$_662b[57]]};
b[_$_662b[55]]=function(c){Array[_$_662b[58]](c)||typeof c!==_$_662b[30]||(c=[c]);if(Array[_$_662b[58]](c)){for(var d,h,l=[],k=0;k<c[_$_662b[21]];k++)h=null,0<=c[k][_$_662b[27]]?(d=c[k][_$_662b[27]],this[_$_662b[22]][_$_662b[10]][_$_662b[4]]&&this[_$_662b[22]][_$_662b[10]][_$_662b[4]][d]&&(h=JSON[_$_662b[62]](JSON[_$_662b[61]](this[_$_662b[22]][_$_662b[10]][_$_662b[4]][d]))),f[_$_662b[63]](this[_$_662b[22]],d,c[k][_$_662b[28]])):d=e[_$_662b[63]](this[_$_662b[22]],c[k][_$_662b[28]]),l[_$_662b[20]]({index:d,
oldValue:h,value:c[k][_$_662b[28]]});this[_$_662b[22]][_$_662b[64]]({worksheet:this,action:_$_662b[54],records:l});this[_$_662b[65]](_$_662b[54],{data:l});a(this[_$_662b[22]]);for(c=0;c<l[_$_662b[21]];c++)l[c][_$_662b[26]]&&v(0,l[c][_$_662b[26]],l[c][_$_662b[27]]),l[c][_$_662b[28]]&&v(1,l[c][_$_662b[28]],l[c][_$_662b[27]]);this[_$_662b[22]][_$_662b[67]](_$_662b[66],this,l)}else console[_$_662b[60]](_$_662b[59])};b[_$_662b[53]]=function(c){var d=this[_$_662b[22]][_$_662b[10]][_$_662b[4]];return c?
d[c]:d};b[_$_662b[57]]=function(c){Array[_$_662b[58]](c)||(c=[c]);c=c[_$_662b[34]](function(d){return{index:d,value:null}});b[_$_662b[55]][_$_662b[63]](this,c)};b[_$_662b[68]]=function(){a(this);A(this)};b[_$_662b[69]]=function(c,d){var h=this[_$_662b[22]][_$_662b[10]][_$_662b[4]],l=[];if(h&&h[_$_662b[21]]){for(var k=0;k<h[_$_662b[21]];k++){var n={index:k,value:JSON[_$_662b[62]](JSON[_$_662b[61]](h[k]))};var m=this[_$_662b[71]](n[_$_662b[28]][_$_662b[12]],c,d,this[_$_662b[70]]());m!==n[_$_662b[28]][_$_662b[12]]&&
(0<=m[_$_662b[5]](_$_662b[72])?n[_$_662b[28]]=null:n[_$_662b[28]][_$_662b[12]]=m,l[_$_662b[20]](n))}b[_$_662b[55]][_$_662b[63]](this,l)}};b[_$_662b[73]]=function(c,d){var h=this[_$_662b[22]][_$_662b[10]][_$_662b[4]],l=[];if(h&&h[_$_662b[21]]){for(var k=0;k<h[_$_662b[21]];k++){var n=p[_$_662b[18]][_$_662b[73]](h[k][_$_662b[12]],c,d);if(n!==h[k][_$_662b[12]]){var m={index:k,value:h[k]};m[_$_662b[28]][_$_662b[12]]=n;l[_$_662b[20]](m)}}b[_$_662b[55]][_$_662b[63]](this,l)}};return b}(),B={number:[{text:g(_$_662b[74]),
value:_$_662b[74]},{text:g(_$_662b[75]),value:_$_662b[76]},{text:g(_$_662b[77]),value:_$_662b[78]},{text:g(_$_662b[79]),value:_$_662b[80]},{text:g(_$_662b[81]),value:_$_662b[82]},{text:g(_$_662b[83]),value:_$_662b[84]},{text:g(_$_662b[85]),value:_$_662b[86]},{text:g(_$_662b[87]),value:_$_662b[88]}],text:[{text:g(_$_662b[89]),value:_$_662b[89]},{text:g(_$_662b[90]),value:_$_662b[90]},{text:g(_$_662b[91]),value:_$_662b[91]},{text:g(_$_662b[92]),value:_$_662b[92]},{text:g(_$_662b[85]),value:_$_662b[86]},
{text:g(_$_662b[93]),value:_$_662b[94]},{text:g(_$_662b[95]),value:_$_662b[96]}],date:[{text:g(_$_662b[97]),value:_$_662b[98]},{text:g(_$_662b[85]),value:_$_662b[86]},{text:g(_$_662b[99]),value:_$_662b[78]},{text:g(_$_662b[100]),value:_$_662b[80]},{text:g(_$_662b[101]),value:_$_662b[82]},{text:g(_$_662b[102]),value:_$_662b[84]},{text:g(_$_662b[74]),value:_$_662b[74]},{text:g(_$_662b[76]),value:_$_662b[76]}],textLength:[{text:g(_$_662b[74]),value:_$_662b[74]},{text:g(_$_662b[75]),value:_$_662b[76]},
{text:g(_$_662b[77]),value:_$_662b[78]},{text:g(_$_662b[79]),value:_$_662b[80]},{text:g(_$_662b[81]),value:_$_662b[82]},{text:g(_$_662b[83]),value:_$_662b[84]},{text:g(_$_662b[85]),value:_$_662b[86]},{text:g(_$_662b[103]),value:_$_662b[88]}]},u=function(a,e){Array[_$_662b[58]](a)&&(a=a[0]);a=a[_$_662b[105]](new RegExp(/'/g),_$_662b[1])[_$_662b[104]]();if(void 0===e)return window[a]?window[a]:null;window[a]=e},H=function(){var a=this;a[_$_662b[107]]=function(e){a[_$_662b[108]]=jSuites[_$_662b[109]](e,
this)};return lemonade[_$_662b[110]]('<input class="jss_object" @ready="self.create(this)" style="width: 100%;" />',a)},I={number:_$_662b[111],text:_$_662b[112],date:_$_662b[113],list:_$_662b[114]},J=function(a){var e=_$_662b[115]+I[a[_$_662b[116]]];a[_$_662b[117]]&&(e+=_$_662b[118]+a[_$_662b[117]]);a[_$_662b[116]]===_$_662b[119]?e+=_$_662b[120]+a[_$_662b[28]][0][_$_662b[41]](_$_662b[121])+_$_662b[122]:(e+=_$_662b[118]+a[_$_662b[28]][0],1<a[_$_662b[28]][_$_662b[21]]&&(e+=_$_662b[123]+a[_$_662b[28]][1]));
return e},C=function(){return lemonade[_$_662b[110]]('<div>\n <div class="row middle p8">\n <div class="column f1 cursor" onclick="self.parent.openForm(self)">\n <div class="p2"><b>{{self.type}}</b> <span>({{self.range}})</span></div>\n <div class="p2">{{self.criteria}}: {{self.value}}</div>\n </div><div>\n <div><i class=\'material-icons cursor\' onclick="self.parent.removeValidation(self.index)">delete</i></div>\n </div>\n </div>\n </div>\n ',
this)},K=function(){var a=this,e=null;a[_$_662b[134]]=_$_662b[1];a[_$_662b[135]]=function(b){jSuites[_$_662b[159]](b,{data:[{value:_$_662b[136],text:g(_$_662b[137])},{value:_$_662b[138],text:g(_$_662b[139])},{value:_$_662b[140],text:g(_$_662b[141])},{value:_$_662b[119],text:g(_$_662b[142])},{value:_$_662b[143],text:g(_$_662b[144])},{value:_$_662b[145],text:g(_$_662b[146])},{value:_$_662b[147],text:g(_$_662b[148])}],onchange:function(c,d,h,l){e[_$_662b[149]](B[l]||[]);a[_$_662b[134]]=_$_662b[1];a[_$_662b[117]]=
_$_662b[1];for(c=0;c<a[_$_662b[151]][_$_662b[150]][0][_$_662b[150]][_$_662b[21]];c++)a[_$_662b[151]][_$_662b[150]][0][_$_662b[150]][c][_$_662b[153]][_$_662b[89]](_$_662b[152])||a[_$_662b[151]][_$_662b[150]][0][_$_662b[150]][c][_$_662b[153]][_$_662b[89]](l)?a[_$_662b[151]][_$_662b[150]][0][_$_662b[150]][c][_$_662b[45]][_$_662b[154]]=_$_662b[1]:a[_$_662b[151]][_$_662b[150]][0][_$_662b[150]][c][_$_662b[45]][_$_662b[154]]=_$_662b[155]},onload:function(c,d){d[_$_662b[158]][_$_662b[153]][_$_662b[157]](_$_662b[156])}})};
a[_$_662b[160]]=function(b){e=jSuites[_$_662b[159]](b,{data:B[_$_662b[136]],autocomplete:!0,onchange:function(c,d,h,l){a[_$_662b[134]]=l},onload:function(c,d){d[_$_662b[158]][_$_662b[153]][_$_662b[157]](_$_662b[156])}})};a[_$_662b[161]]=function(b){p[_$_662b[164]](b,function(){-1==b[_$_662b[162]][_$_662b[5]](_$_662b[13])?b[_$_662b[162]]=p[_$_662b[15]][_$_662b[70]]()+_$_662b[13]+b[_$_662b[162]]:b[_$_662b[162]]=b[_$_662b[162]];a[_$_662b[12]]=b[_$_662b[162]];jSuites[_$_662b[163]](b)})};a[_$_662b[165]]=
function(b){jSuites[_$_662b[166]](b)};a[_$_662b[167]]=function(b){b&&(a[_$_662b[12]]?a[_$_662b[116]]?a[_$_662b[117]]?(-1===a[_$_662b[12]][_$_662b[5]](_$_662b[13])&&(a[_$_662b[12]]=a[_$_662b[108]][_$_662b[70]]()+_$_662b[13]+a[_$_662b[12]]),b={range:a[_$_662b[12]],action:a[_$_662b[11]],type:a[_$_662b[116]],criteria:a[_$_662b[117]],text:a[_$_662b[138]],className:a[_$_662b[171]],allowBlank:a[_$_662b[172]]},b[_$_662b[117]][_$_662b[173]](_$_662b[74])?b[_$_662b[28]]=[a[_$_662b[174]],a[_$_662b[175]]]:b[_$_662b[28]]=
[a[_$_662b[174]]],b[_$_662b[11]]===_$_662b[33]&&(b[_$_662b[33]]={},a[_$_662b[176]]&&(b[_$_662b[33]][_$_662b[166]]=a[_$_662b[176]]),a[_$_662b[177]]&&(b[_$_662b[33]][_$_662b[178]]=a[_$_662b[177]]),a[_$_662b[179]]&&(b[_$_662b[33]][_$_662b[180]]=_$_662b[179]),a[_$_662b[181]]&&(b[_$_662b[33]][_$_662b[182]]=_$_662b[181])),b={value:b},null!==a[_$_662b[27]]&&(b[_$_662b[27]]=a[_$_662b[27]]),a[_$_662b[108]][_$_662b[54]](b)):alert(g(_$_662b[170])):alert(g(_$_662b[169])):alert(g(_$_662b[168])))};var f=`<div>
var $jscomp=$jscomp||{};$jscomp.scope={};$jscomp.owns=function(h,d){return Object.prototype.hasOwnProperty.call(h,d)};$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;
$jscomp.defineProperty=$jscomp.ASSUME_ES5||"function"==typeof Object.defineProperties?Object.defineProperty:function(h,d,l){if(h==Array.prototype||h==Object.prototype)return h;h[d]=l.value;return h};$jscomp.getGlobal=function(h){h=["object"==typeof globalThis&&globalThis,h,"object"==typeof window&&window,"object"==typeof self&&self,"object"==typeof global&&global];for(var d=0;d<h.length;++d){var l=h[d];if(l&&l.Math==Math)return l}throw Error("Cannot find global object");};$jscomp.global=$jscomp.getGlobal(this);
$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(h,d){var l=$jscomp.propertyToPolyfillSymbol[d];if(null==l)return h[d];l=h[l];return void 0!==l?l:h[d]};
$jscomp.polyfill=function(h,d,l,m){d&&($jscomp.ISOLATE_POLYFILLS?$jscomp.polyfillIsolated(h,d,l,m):$jscomp.polyfillUnisolated(h,d,l,m))};$jscomp.polyfillUnisolated=function(h,d,l,m){l=$jscomp.global;h=h.split(".");for(m=0;m<h.length-1;m++){var t=h[m];if(!(t in l))return;l=l[t]}h=h[h.length-1];m=l[h];d=d(m);d!=m&&null!=d&&$jscomp.defineProperty(l,h,{configurable:!0,writable:!0,value:d})};
$jscomp.polyfillIsolated=function(h,d,l,m){var t=h.split(".");h=1===t.length;m=t[0];m=!h&&m in $jscomp.polyfills?$jscomp.polyfills:$jscomp.global;for(var v=0;v<t.length-1;v++){var x=t[v];if(!(x in m))return;m=m[x]}t=t[t.length-1];l=$jscomp.IS_SYMBOL_NATIVE&&"es6"===l?m[t]:null;d=d(l);null!=d&&(h?$jscomp.defineProperty($jscomp.polyfills,t,{configurable:!0,writable:!0,value:d}):d!==l&&(void 0===$jscomp.propertyToPolyfillSymbol[t]&&(l=1E9*Math.random()>>>0,$jscomp.propertyToPolyfillSymbol[t]=$jscomp.IS_SYMBOL_NATIVE?
$jscomp.global.Symbol(t):$jscomp.POLYFILL_PREFIX+l+"$"+t),$jscomp.defineProperty(m,$jscomp.propertyToPolyfillSymbol[t],{configurable:!0,writable:!0,value:d})))};$jscomp.polyfill("Object.entries",function(h){return h?h:function(d){var l=[],m;for(m in d)$jscomp.owns(d,m)&&l.push([m,d[m]]);return l}},"es8","es3");
$jscomp.polyfill("Array.prototype.includes",function(h){return h?h:function(d,l){var m=this;m instanceof String&&(m=String(m));var t=m.length;l=l||0;for(0>l&&(l=Math.max(l+t,0));l<t;l++){var v=m[l];if(v===d||Object.is(v,d))return!0}return!1}},"es7","es3");
var _$_c72f=["","validations","This extension is not included on the scope of this license","License required","This extension request Jspreadsheet Pro v9+","!",":","object"," .conditional_formatting_","_"," {\n",";\n","\n}","jss_validations_","style","head","get","set","JSS: input should be an array","setValidations","onvalidation","#REF!","between","is not between","not between","less than","<","less than or equal to","<=","bigger than",">","bigger than or equal to",">=","equal to","=","different to",
"!=","contains","not contains","begins with","ends with","is a valid email","valid email","is a valid url","valid url","is a valid date","valid date","before","on or before","after","on or after","a number ","a text ","a date ","an element of the list: ","The content of this cell must be "," ","list","string",","," [","]"," and ","2012","yyyy","12","mm","19","dd","Value is included in the options","number","Number","text","Text","date","Date","List","textLength","Text length","exist","Cell is empty",
"not exist","Cell is not empty","all","none","jss_object","List of valid values","The range is mandatory","The type is mandatory","The criteria is mandatory","format","background-color","font-weight","bold","font-style","italic","Cell range","Action","Warning message","Reject entry","Format style","Type","Operator","Color","Background color","Add a custom CSS className","Save","Back","data-tooltip","jss_warning","data-validation","reject","conditional_formatting_","All validations found for this selection",
"No validation found for this selection","settings","i","Add new validation","onafterchanges","onchangeproperty","onformulachain","oncreatecell","onbeforechange","onselection","onload","onrenameworksheet","onchangereferences","onundo","onredo","Validations","420px","612px","warning","block","div","undefined","function"];
(function(h,d){typeof exports===_$_c72f[7]&&typeof module!==_$_c72f[135]?module.exports=d():typeof define===_$_c72f[136]&&define.amd?define(d):h.validations=d()})(this,function(){var h=null,d=jSuites.translate,l={reject:2,warning:1,format:0},m=function(a,e){a=this.config.validations[a]&&this.config.validations[a].action?this.config.validations[a].action:0;e=this.config.validations[e]&&this.config.validations[e].action?this.config.validations[e].action:0;return l[a]-l[e]},t=function(a,e,c){if(e&&e.range){var b;
if(0<e.range.indexOf(_$_c72f[5])){e=e.range.split(_$_c72f[5]);var g=e[1];var f=z(e[0])}else g=e.range,f=h.current;f.validations&&(e=-1===g.indexOf(_$_c72f[6])?[g]:h.helpers.getTokensFromRange(g),e.forEach(function(k){f.validations[k]||(f.validations[k]=[]);0===a?(b=f.validations[k].indexOf(c),0<=b&&f.validations[k].splice(b,1)):f.validations[k].push(c);1<f.validations[k].length&&f.validations[k].sort(m.bind(f.parent))}))}},v=function(a){for(var e=0;e<a.worksheets.length;e++)a.worksheets[e].validations=
{};if(a=a.config.validations)for(e=0;e<a.length;e++)t(1,a[e],e)},x=function(a){for(var e=0;e<a.worksheets.length;e++)a.worksheets[e].validations={}},y=function(){var a=function(c){var b=c.config.validations;if(b&&b.length){for(var g=_$_c72f[0],f=0;f<b.length;f++)if(b[f]&&b[f].format){var k=Object.entries(b[f].format).map(function([q,n]){return`\t${q}: ${n} !important\n`});g+=_$_c72f[8]+c.name+_$_c72f[9]+f+_$_c72f[10]+k.join(_$_c72f[11])+_$_c72f[12]}b=document.getElementById(_$_c72f[13]+c.name);b||
(b=document.createElement(_$_c72f[14]),b.id=_$_c72f[13]+c.name,document.getElementsByTagName(_$_c72f[15])[0].appendChild(b));b.innerHTML=g}},e=function(c){c.getValidations=e[_$_c72f[16]];c.setValidations=e[_$_c72f[17]];c.resetValidations=e.reset};e[_$_c72f[17]]=function(c){Array.isArray(c)||typeof c!==_$_c72f[7]||(c=[c]);if(Array.isArray(c)){for(var b,g,f=[],k=0;k<c.length;k++){g=null;if(0<=c[k].index)b=c[k].index,this.parent.config.validations&&this.parent.config.validations[b]&&(g=JSON.parse(JSON.stringify(this.parent.config.validations[b]))),
this.parent.config.validations[b]=c[k].value;else{b=c[k].value;this.parent.config.validations||(this.parent.config.validations=[]);var q=this.parent.config.validations.length;this.parent.config.validations.push(b);b=q}f.push({index:b,oldValue:g,value:c[k].value})}this.parent.setHistory({worksheet:this,action:_$_c72f[19],records:f});this.persistence(_$_c72f[19],{data:f});a(this.parent);for(c=0;c<f.length;c++)f[c].oldValue&&t(0,f[c].oldValue,f[c].index),f[c].value&&t(1,f[c].value,f[c].index);this.parent.dispatch(_$_c72f[20],
this,f)}else console.error(_$_c72f[18])};e[_$_c72f[16]]=function(c){var b=this.parent.config.validations;return c?b[c]:b};e.reset=function(c){Array.isArray(c)||(c=[c]);c=c.map(function(b){return{index:b,value:null}});e[_$_c72f[17]].call(this,c)};e.build=function(){a(this);v(this)};e.updateAll=function(c,b){var g=this.parent.config.validations,f=[];if(g&&g.length){for(var k=0;k<g.length;k++){var q={index:k,value:JSON.parse(JSON.stringify(g[k]))};var n=this.updateFormula(q.value.range,c,b,this.getWorksheetName());
n!==q.value.range&&(0<=n.indexOf(_$_c72f[21])?q.value=null:q.value.range=n,f.push(q))}e[_$_c72f[17]].call(this,f)}};e.updateWorksheetName=function(c,b){var g=this.parent.config.validations,f=[];if(g&&g.length){for(var k=0;k<g.length;k++){var q=h.helpers.updateWorksheetName(g[k].range,c,b);if(q!==g[k].range){var n={index:k,value:g[k]};n.value.range=q;f.push(n)}}e[_$_c72f[17]].call(this,f)}};return e}(),A={number:[{text:d(_$_c72f[22]),value:_$_c72f[22]},{text:d(_$_c72f[23]),value:_$_c72f[24]},{text:d(_$_c72f[25]),
value:_$_c72f[26]},{text:d(_$_c72f[27]),value:_$_c72f[28]},{text:d(_$_c72f[29]),value:_$_c72f[30]},{text:d(_$_c72f[31]),value:_$_c72f[32]},{text:d(_$_c72f[33]),value:_$_c72f[34]},{text:d(_$_c72f[35]),value:_$_c72f[36]}],text:[{text:d(_$_c72f[37]),value:_$_c72f[37]},{text:d(_$_c72f[38]),value:_$_c72f[38]},{text:d(_$_c72f[39]),value:_$_c72f[39]},{text:d(_$_c72f[40]),value:_$_c72f[40]},{text:d(_$_c72f[33]),value:_$_c72f[34]},{text:d(_$_c72f[41]),value:_$_c72f[42]},{text:d(_$_c72f[43]),value:_$_c72f[44]}],
date:[{text:d(_$_c72f[45]),value:_$_c72f[46]},{text:d(_$_c72f[33]),value:_$_c72f[34]},{text:d(_$_c72f[47]),value:_$_c72f[26]},{text:d(_$_c72f[48]),value:_$_c72f[28]},{text:d(_$_c72f[49]),value:_$_c72f[30]},{text:d(_$_c72f[50]),value:_$_c72f[32]},{text:d(_$_c72f[22]),value:_$_c72f[22]},{text:d(_$_c72f[24]),value:_$_c72f[24]}],textLength:[{text:d(_$_c72f[22]),value:_$_c72f[22]},{text:d(_$_c72f[23]),value:_$_c72f[24]},{text:d(_$_c72f[25]),value:_$_c72f[26]},{text:d(_$_c72f[27]),value:_$_c72f[28]},{text:d(_$_c72f[29]),
value:_$_c72f[30]},{text:d(_$_c72f[31]),value:_$_c72f[32]},{text:d(_$_c72f[33]),value:_$_c72f[34]},{text:d(_$_c72f[35]),value:_$_c72f[36]}]},z=function(a,e){Array.isArray(a)&&(a=a[0]);a=a.replace(new RegExp(/'/g),_$_c72f[0]).toUpperCase();if(void 0===e)return window[a]?window[a]:null;window[a]=e},G=function(){var a=this;a.create=function(e){a.instance=jSuites.calendar(e,this)};return lemonade.element('<input class="jss_object" @ready="self.create(this)" style="width: 100%;" />',a)},H={number:_$_c72f[51],
text:_$_c72f[52],date:_$_c72f[53],list:_$_c72f[54]},I=function(a){var e=_$_c72f[55]+H[a.type];a.criteria&&(e+=_$_c72f[56]+a.criteria);a.type===_$_c72f[57]?(a=typeof a.value[0]!==_$_c72f[58]?a.value[0].join(_$_c72f[59]):a.value[0],e+=_$_c72f[60]+a+_$_c72f[61]):(e+=_$_c72f[56]+a.value[0],1<a.value.length&&(e+=_$_c72f[62]+a.value[1]));return e},E=function(){this.type==_$_c72f[57]&&(this.criteria=d(_$_c72f[69]));return lemonade.element('<div>\n <div class="row middle p8">\n <div class="column f1 cursor" onclick="self.parent.openForm(self)">\n <div class="p2"><b>{{self.type}}</b> <span>({{self.range}})</span></div>\n <div class="p2">{{self.criteria}}: {{self.value}}</div>\n </div><div>\n <div><i class=\'material-icons cursor\' onclick="self.parent.removeValidation(self.index)">delete</i></div>\n </div>\n </div>\n </div>\n ',
this)},J=function(){var a=this,e=null;a.operator=_$_c72f[0];a.operatorVisible=!0;a.createType=function(b){jSuites.dropdown(b,{data:[{value:_$_c72f[70],text:d(_$_c72f[71])},{value:_$_c72f[72],text:d(_$_c72f[73])},{value:_$_c72f[74],text:d(_$_c72f[75])},{value:_$_c72f[57],text:d(_$_c72f[76])},{value:_$_c72f[77],text:d(_$_c72f[78])},{value:_$_c72f[79],text:d(_$_c72f[80])},{value:_$_c72f[81],text:d(_$_c72f[82])}],onchange:function(g,f,k,q){A[q]?(e.setData(A[q]),a.operatorVisible=!0):(e.setData(null),
a.operatorVisible=!1);a.operator=_$_c72f[0];a.criteria=_$_c72f[0];for(g=0;g<a.el.children[0].children.length;g++)a.el.children[0].children[g].classList.contains(_$_c72f[83])||a.el.children[0].children[g].classList.contains(q)?a.el.children[0].children[g].style.display=_$_c72f[0]:a.el.children[0].children[g].style.display=_$_c72f[84]},onload:function(g,f){f.header.classList.add(_$_c72f[85])}})};a.createOperator=function(b){e=jSuites.dropdown(b,{data:A.number,autocomplete:!0,onchange:function(g,f,k,
q){a.operator=q},onload:function(g,f){f.header.classList.add(_$_c72f[85])}})};a.createPicker=function(b){h.picker(b,function(){-1==b.innerText.indexOf(_$_c72f[5])?b.innerText=h.current.getWorksheetName()+_$_c72f[5]+b.innerText:b.innerText=b.innerText;a.range=b.innerText;jSuites.focus(b)})};a.createColorPicker=function(b){jSuites.color(b)};a.createList=function(b){jSuites.tags(b,{placeholder:_$_c72f[86]})};a.close=function(b){b&&(a.range?a.type?a.operatorVisible&&!a.criteria?alert(d(_$_c72f[89])):
(-1===a.range.indexOf(_$_c72f[5])&&(a.range=a.instance.getWorksheetName()+_$_c72f[5]+a.range),b={range:a.range,action:a.action,type:a.type,criteria:a.criteria,text:a.text,className:a.className,allowBlank:a.allowBlank},b.criteria.includes(_$_c72f[22])?b.value=[a.start,a.end]:b.value=[a.start],b.action===_$_c72f[90]&&(b.format={},a.formatColor&&(b.format.color=a.formatColor),a.formatBackgroundColor&&(b.format[_$_c72f[91]]=a.formatBackgroundColor),a.bold&&(b.format[_$_c72f[92]]=_$_c72f[93]),a.italic&&
(b.format[_$_c72f[94]]=_$_c72f[95])),b={value:b},null!==a.index&&(b.index=a.index),a.instance.setValidations(b)):alert(d(_$_c72f[88])):alert(d(_$_c72f[87])))};var c=`<div>
<div>

@@ -41,3 +42,3 @@ <!-- Validation type -->

<div class="form-group">
<label class="label">${g(_$_662b[183])}</label>
<label class="label">${d(_$_c72f[96])}</label>
<div @ready="self.createPicker(this)" @bind="self.range"></div>

@@ -48,7 +49,7 @@ </div>

<div class="form-group">
<label class="label">${g(_$_662b[184])}</label>
<label class="label">${d(_$_c72f[97])}</label>
<select style="padding: 8px;" @bind="self.action">
<option value="warning">${g(_$_662b[185])}</option>
<option value="reject">${g(_$_662b[186])}</option>
<option value="format">${g(_$_662b[187])}</option>
<option value="warning">${d(_$_c72f[98])}</option>
<option value="reject">${d(_$_c72f[99])}</option>
<option value="format">${d(_$_c72f[100])}</option>
</select>

@@ -63,3 +64,3 @@ </div>

<div class="form-group">
<label class="label">${g(_$_662b[185])}</label>
<label class="label">${d(_$_c72f[98])}</label>
<input type="text" @bind="self.text" class="jss_object w100">

@@ -74,8 +75,8 @@ </div>

<div class="form-group">
<label class="label">${g(_$_662b[188])}</label>
<label class="label">${d(_$_c72f[101])}</label>
<div @ready="self.createType(this)" @bind="self.type"></div>
</div>
</div><div class="column f1">
</div><div class="column f1" data-visible="{{self.operatorVisible}}">
<div class="form-group">
<label class="label">${g(_$_662b[189])}</label>
<label class="label">${d(_$_c72f[102])}</label>
<div @ready="self.createOperator(this)" @bind="self.criteria"></div>

@@ -87,3 +88,3 @@ </div>

<!-- Number input options -->
<div class="row number textLength middle" style="display: none">
<div class="row number text textLength middle" style="display: none">
<div class="column f1">

@@ -128,3 +129,3 @@ <div class="form-group">

<div class="form-group">
<textarea style="resize: vertical;" rows="4" @bind="self.start" placeholder="A, B, C, D..." class="jss_object"></textarea>
<div @ready="self.createList(this)" @bind="self.start" class="jss_object"></div>
</div>

@@ -154,3 +155,3 @@ </div>

<div class="form-group">
<label class="label">${g(_$_662b[190])}</label><br>
<label class="label">${d(_$_c72f[103])}</label><br>
<input @ready="self.createColorPicker(this)" @bind="self.formatColor" class="jss_object w100">

@@ -161,3 +162,3 @@ </div>

<div class="form-group">
<label class="label">${g(_$_662b[191])}</label><br>
<label class="label">${d(_$_c72f[104])}</label><br>
<input @ready="self.createColorPicker(this)" @bind="self.formatBackgroundColor" class="jss_object w100">

@@ -170,3 +171,3 @@ </div>

<div class="form-group">
<input type="text" placeholder="${g(_$_662b[192])}" @bind="self.className" class="jss_object">
<input type="text" placeholder="${d(_$_c72f[105])}" @bind="self.className" class="jss_object">
</div>

@@ -192,3 +193,3 @@ </div>

<div class='form-group center'>
<button type="button" class="jbutton dark w100" onclick="self.close(true)">${g(_$_662b[193])}</button>
<button type="button" class="jbutton dark w100" onclick="self.close(true)">${d(_$_c72f[106])}</button>
</div>

@@ -198,16 +199,14 @@ </div>

</div>
<p onclick="self.parent.closeForm()" class="cursor">${g(_$_662b[194])}</p>
</div>`;return lemonade[_$_662b[110]](f,a,{Calendar:H,List:C})},L=function(a,e){if(this[_$_662b[195]][e]&&this[_$_662b[195]][e][a]&&this[_$_662b[195]][e][a][_$_662b[110]]){this[_$_662b[195]][e][a][_$_662b[110]][_$_662b[197]](_$_662b[196]);this[_$_662b[195]][e][a][_$_662b[110]][_$_662b[153]][_$_662b[199]](_$_662b[198]);var f=this[_$_662b[195]][e][a][_$_662b[110]][_$_662b[201]](_$_662b[200]);if(f){f=f[_$_662b[14]](_$_662b[121]);for(var b=0;b<f[_$_662b[21]];b++)this[_$_662b[195]][e][a][_$_662b[110]][_$_662b[153]][_$_662b[199]](f[b])}this[_$_662b[195]][e][a][_$_662b[110]][_$_662b[197]](_$_662b[200])}},
r=function(a,e,f,b){if(this[_$_662b[22]][_$_662b[10]][_$_662b[4]]&&this[_$_662b[195]][e]&&this[_$_662b[195]][e][a]&&this[_$_662b[195]][e][a][_$_662b[110]]){L[_$_662b[63]](this,a,e);if(null==f||void 0==f)f=this[_$_662b[195]][e][a][_$_662b[202]];var c=this,d=p[_$_662b[18]][_$_662b[203]](a,e);if(this[_$_662b[195]][e][a][_$_662b[110]]&&this[_$_662b[4]]&&void 0!==this[_$_662b[4]][d]){d=this[_$_662b[4]][d];for(var h=0;h<d[_$_662b[21]];h++){var l=d[h],k=this[_$_662b[22]][_$_662b[10]][_$_662b[4]][l];if(!k)break;
if(!jSuites[_$_662b[4]](f,k)){if(k[_$_662b[11]]!==_$_662b[33]){f=k[_$_662b[138]]||J(k);this[_$_662b[195]][e][a][_$_662b[110]][_$_662b[204]](_$_662b[196],f);this[_$_662b[195]][e][a][_$_662b[110]][_$_662b[153]][_$_662b[157]](_$_662b[198]);if(k[_$_662b[11]]===_$_662b[205]&&!b)return setTimeout(function(){c[_$_662b[195]][e][a][_$_662b[110]][_$_662b[197]](_$_662b[196]);c[_$_662b[195]][e][a][_$_662b[110]][_$_662b[153]][_$_662b[199]](_$_662b[198])},2500),!1;break}}else if(k[_$_662b[11]]===_$_662b[33]){var n=
[];k[_$_662b[171]]&&(n=k[_$_662b[171]][_$_662b[14]](_$_662b[121]));n[_$_662b[20]](_$_662b[206]+this[_$_662b[22]][_$_662b[37]]+_$_662b[38]+l);for(k=0;k<n[_$_662b[21]];k++)this[_$_662b[195]][e][a][_$_662b[110]][_$_662b[153]][_$_662b[157]](n[k]);this[_$_662b[195]][e][a][_$_662b[110]][_$_662b[204]](_$_662b[200],n)}}}}},M=function(a,e){var f={};f[_$_662b[207]]=function(b){t(b)};f[_$_662b[208]]=function(b,c){if(b[_$_662b[21]]&&this[_$_662b[22]][_$_662b[10]][_$_662b[4]]){var d=b[0],h=b[1],l=b[2];b=b[3];
var k=[],n=null;if(n=this[_$_662b[4]])for(;h<=b;h++)for(var m=d;m<=l;m++){var q=this[_$_662b[18]][_$_662b[203]](m,h);if(n[q])for(var w=0;w<n[q][_$_662b[21]];w++)k[n[q][w]]=!0}d=this[_$_662b[22]][_$_662b[10]][_$_662b[4]][_$_662b[34]](function(D,x){return Object.assign({},D,{index:x})});f[_$_662b[209]]=g(_$_662b[210])+_$_662b[118]+(c||_$_662b[1]);f[_$_662b[211]]=d[_$_662b[212]](function(D,x){return k[x]})}else f[_$_662b[211]]=[];f[_$_662b[211]][_$_662b[21]]||(f[_$_662b[209]]=g(_$_662b[213])+_$_662b[118]+
(c||_$_662b[1]));f[_$_662b[214]]()};f[_$_662b[215]]=function(b){b[_$_662b[221]][_$_662b[20]]({content:_$_662b[216],type:_$_662b[217],title:g(_$_662b[218]),onclick:function(){var c=p[_$_662b[15]][_$_662b[219]]();c&&(c=c[_$_662b[14]](_$_662b[13])[1]);f[_$_662b[220]](p[_$_662b[15]],c)}});return b};f[_$_662b[220]]=function(b,c){f[_$_662b[216]][_$_662b[108]]=b;f[_$_662b[222]][_$_662b[220]]()};f[_$_662b[223]]=function(b,c,d,h,l,k){if(b===_$_662b[224]||b===_$_662b[225]||b===_$_662b[226])d[_$_662b[25]](function(m){if(m[_$_662b[227]]&&
m[_$_662b[228]])r[_$_662b[63]](c,m[_$_662b[227]],m[_$_662b[228]],null,!0)});else if(b===_$_662b[229])r[_$_662b[63]](c,h,l);else if(b===_$_662b[230]){if((_$_662b[1]+k)[_$_662b[106]](0,1)!==_$_662b[86])return r[_$_662b[63]](c,h,l,k)}else if(b===_$_662b[231])f[_$_662b[208]][_$_662b[63]](c,[d,h,l,k]);else if(b===_$_662b[66]){var n=null;d[_$_662b[25]](function(m){if(m[_$_662b[26]]&&m[_$_662b[26]][_$_662b[12]])p[_$_662b[18]][_$_662b[17]](m[_$_662b[26]][_$_662b[12]])[_$_662b[25]](function(q){n||(n={});n[q]=
!0})});d[_$_662b[25]](function(m){if(m[_$_662b[28]]&&m[_$_662b[28]][_$_662b[12]])p[_$_662b[18]][_$_662b[17]](m[_$_662b[28]][_$_662b[12]])[_$_662b[25]](function(q){n||(n={});n[q]=!0})});n&&(d=Object[_$_662b[31]](n),d[_$_662b[25]](function(m){var q=m[_$_662b[14]](_$_662b[13]);m=p[_$_662b[18]][_$_662b[232]](q[1]);r[_$_662b[63]](u(q[0]),m[0],m[1],null,!0)}),d=p[_$_662b[18]][_$_662b[233]](Object[_$_662b[31]](n)),b=p[_$_662b[18]][_$_662b[234]](d),f[_$_662b[208]][_$_662b[63]](c,b,d))}else if(b===_$_662b[235])t[_$_662b[68]][_$_662b[63]](c),
n=null,(d=c[_$_662b[10]][_$_662b[4]])&&d[_$_662b[21]]&&(d[_$_662b[25]](function(m){if(m[_$_662b[12]])p[_$_662b[18]][_$_662b[17]](m[_$_662b[12]])[_$_662b[25]](function(q){n||(n={});n[q]=!0})}),n&&(d=Object[_$_662b[31]](n),d[_$_662b[25]](function(m){var q=m[_$_662b[14]](_$_662b[13]);m=p[_$_662b[18]][_$_662b[232]](q[1]);r[_$_662b[63]](u(q[0]),m[0],m[1],null,!0)})));else if(b===_$_662b[236]||b===_$_662b[237]){if(!c[_$_662b[22]][_$_662b[238]]){c[_$_662b[22]][_$_662b[239]]=!0;if(b===_$_662b[236])t[_$_662b[73]][_$_662b[63]](c,
l,h);else G(c[_$_662b[22]]),t[_$_662b[69]][_$_662b[63]](c,d,h),A(c[_$_662b[22]]);c[_$_662b[22]][_$_662b[239]]=!1}}else if(b===_$_662b[240]){if(d[_$_662b[11]]==_$_662b[54]){b=[];for(h=0;h<d[_$_662b[195]][_$_662b[21]];h++)b[_$_662b[20]]({index:d[_$_662b[195]][h][_$_662b[27]],value:d[_$_662b[195]][h][_$_662b[26]]});c[_$_662b[54]](b)}}else if(b===_$_662b[241]&&d[_$_662b[11]]==_$_662b[54])c[_$_662b[54]](d[_$_662b[195]])};f[_$_662b[242]]=function(b){f[_$_662b[222]]=jSuites[_$_662b[222]](b,{title:_$_662b[243],
closed:!0,width:_$_662b[244],height:_$_662b[245],backdrop:!1})};f[_$_662b[246]]=function(b){f[_$_662b[216]][_$_662b[27]]=b[_$_662b[27]];f[_$_662b[216]][_$_662b[12]]=b[_$_662b[12]]||f[_$_662b[216]][_$_662b[108]][_$_662b[219]]();f[_$_662b[216]][_$_662b[11]]=b[_$_662b[11]]||_$_662b[247];f[_$_662b[216]][_$_662b[116]]=b[_$_662b[116]]||_$_662b[136];f[_$_662b[216]][_$_662b[117]]=b[_$_662b[117]]||_$_662b[74];b[_$_662b[28]]?(f[_$_662b[216]][_$_662b[174]]=b[_$_662b[28]][0],f[_$_662b[216]][_$_662b[175]]=b[_$_662b[28]][1]):
(f[_$_662b[216]][_$_662b[174]]=_$_662b[1],f[_$_662b[216]][_$_662b[175]]=_$_662b[1]);f[_$_662b[176]]=_$_662b[1];f[_$_662b[177]]=_$_662b[1];f[_$_662b[179]]=_$_662b[1];f[_$_662b[181]]=_$_662b[1];f[_$_662b[171]]=_$_662b[1];f[_$_662b[248]][_$_662b[45]][_$_662b[154]]=_$_662b[155];f[_$_662b[249]][_$_662b[45]][_$_662b[154]]=_$_662b[250]};f[_$_662b[214]]=function(){f[_$_662b[248]][_$_662b[45]][_$_662b[154]]=_$_662b[250];f[_$_662b[249]][_$_662b[45]][_$_662b[154]]=_$_662b[155]};f[_$_662b[251]]=function(b){f[_$_662b[216]][_$_662b[108]][_$_662b[56]](b)};
e=document[_$_662b[46]](_$_662b[252]);a[_$_662b[254]][_$_662b[253]](e);lemonade[_$_662b[255]](function(){var b=`<div @ready="self.createModal(this)">
<p onclick="self.parent.closeForm()" class="cursor">${d(_$_c72f[107])}</p>
</div>`;return lemonade.element(c,a,{Calendar:G,List:E})},K=function(a,e){if(this.records[e]&&this.records[e][a]&&this.records[e][a].element){this.records[e][a].element.removeAttribute(_$_c72f[108]);this.records[e][a].element.classList.remove(_$_c72f[109]);var c=this.records[e][a].element.getAttribute(_$_c72f[110]);if(c){c=c.split(_$_c72f[59]);for(var b=0;b<c.length;b++)this.records[e][a].element.classList.remove(c[b])}this.records[e][a].element.removeAttribute(_$_c72f[110])}},w=function(a,
e,c,b){if(this.parent.config.validations&&this.records[e]&&this.records[e][a]&&this.records[e][a].element){K.call(this,a,e);if(null==c||void 0==c)c=this.records[e][a].v;var g=this,f=h.helpers.getColumnNameFromCoords(a,e);if(this.records[e][a].element&&this.validations&&void 0!==this.validations[f]){f=this.validations[f];for(var k=0;k<f.length;k++){var q=f[k],n=this.parent.config.validations[q];if(!n)break;if(!jSuites.validations(c,n)){if(n.action!==_$_c72f[90]){c=n.text||I(n);this.records[e][a].element.setAttribute(_$_c72f[108],
c);this.records[e][a].element.classList.add(_$_c72f[109]);if(n.action===_$_c72f[111]&&!b)return setTimeout(function(){g.records[e][a].element.removeAttribute(_$_c72f[108]);g.records[e][a].element.classList.remove(_$_c72f[109])},2500),!1;break}}else if(n.action===_$_c72f[90]){var r=[];n.className&&(r=n.className.split(_$_c72f[59]));r.push(_$_c72f[112]+this.parent.name+_$_c72f[9]+q);for(n=0;n<r.length;n++)this.records[e][a].element.classList.add(r[n]);this.records[e][a].element.setAttribute(_$_c72f[110],
r)}}}}},L=function(a,e){var c={init:function(b){y(b)},updateDataFromSelection:function(b,g){if(b.length&&this.parent.config.validations){var f=b[0],k=b[1],q=b[2];b=b[3];var n=[],r=null;if(r=this.validations)for(;k<=b;k++)for(var p=f;p<=q;p++){var u=this.helpers.getColumnNameFromCoords(p,k);if(r[u])for(var B=0;B<r[u].length;B++)n[r[u][B]]=!0}f=this.parent.config.validations.map(function(F,C){return Object.assign({},F,{index:C})});c.message=d(_$_c72f[113])+_$_c72f[56]+(g||_$_c72f[0]);c.data=f.filter(function(F,
C){return n[C]})}else c.data=[];c.data.length||(c.message=d(_$_c72f[114])+_$_c72f[56]+(g||_$_c72f[0]));c.closeForm()},toolbar:function(b){b.items.push({content:_$_c72f[115],type:_$_c72f[116],title:d(_$_c72f[117]),onclick:function(){var g=h.current.getRange();g&&(g=g.split(_$_c72f[5])[1]);c.open(h.current,g)}});return b},open:function(b,g){c.settings.instance=b;c.modal.open()},onevent:function(b,g,f,k,q,n){if(b===_$_c72f[118]||b===_$_c72f[119]||b===_$_c72f[120])f.forEach(function(p){p.x&&p.y&&w.call(g,
p.x,p.y,null,!0)});else if(b===_$_c72f[121])w.call(g,k,q);else if(b===_$_c72f[122]){if((_$_c72f[0]+n).substr(0,1)!==_$_c72f[34])return w.call(g,k,q,n)}else if(b===_$_c72f[123])c.updateDataFromSelection.call(g,[f,k,q,n]);else if(b===_$_c72f[20]){var r=null;f.forEach(function(p){p.oldValue&&p.oldValue.range&&h.helpers.getTokensFromRange(p.oldValue.range).forEach(function(u){r||(r={});r[u]=!0})});f.forEach(function(p){p.value&&p.value.range&&h.helpers.getTokensFromRange(p.value.range).forEach(function(u){r||
(r={});r[u]=!0})});r&&(f=Object.keys(r),f.forEach(function(p){var u=p.split(_$_c72f[5]);p=h.helpers.getCoordsFromColumnName(u[1]);w.call(z(u[0]),p[0],p[1],null,!0)}),f=h.helpers.getRangeFromTokens(Object.keys(r)),b=h.helpers.getCoordsFromRange(f),c.updateDataFromSelection.call(g,b,f))}else if(b===_$_c72f[124])y.build.call(g),r=null,(f=g.config.validations)&&f.length&&(f.forEach(function(p){p.range&&h.helpers.getTokensFromRange(p.range).forEach(function(u){r||(r={});r[u]=!0})}),r&&(f=Object.keys(r),
f.forEach(function(p){var u=p.split(_$_c72f[5]);p=h.helpers.getCoordsFromColumnName(u[1]);w.call(z(u[0]),p[0],p[1],null,!0)})));else if(b===_$_c72f[125]||b===_$_c72f[126])g.parent.ignoreHistory||(g.parent.historyCascade=!0,b===_$_c72f[125]?y.updateWorksheetName.call(g,q,k):(x(g.parent),y.updateAll.call(g,f,k),v(g.parent)),g.parent.historyCascade=!1);else if(b===_$_c72f[127]){if(f.action==_$_c72f[19]){b=[];for(k=0;k<f.records.length;k++)b.push({index:f.records[k].index,value:f.records[k].oldValue});
g.setValidations(b)}}else b===_$_c72f[128]&&f.action==_$_c72f[19]&&g.setValidations(f.records)},createModal:function(b){c.modal=jSuites.modal(b,{title:_$_c72f[129],closed:!0,width:_$_c72f[130],height:_$_c72f[131],backdrop:!1})},openForm:function(b){c.settings.index=b.index;c.settings.range=b.range||c.settings.instance.getRange();c.settings.action=b.action||_$_c72f[132];c.settings.type=b.type||_$_c72f[70];c.settings.criteria=b.criteria||_$_c72f[22];b.value?(c.settings.start=b.value[0],c.settings.end=
b.value[1]):(c.settings.start=_$_c72f[0],c.settings.end=_$_c72f[0]);c.formatColor=_$_c72f[0];c.formatBackgroundColor=_$_c72f[0];c.bold=_$_c72f[0];c.italic=_$_c72f[0];c.className=_$_c72f[0];c.listContainer.style.display=_$_c72f[84];c.settingsContainer.style.display=_$_c72f[133]},closeForm:function(){c.listContainer.style.display=_$_c72f[133];c.settingsContainer.style.display=_$_c72f[84]},removeValidation:function(b){c.settings.instance.resetValidations(b)}};e=document.createElement(_$_c72f[134]);a.tools.append(e);
lemonade.render(function(){var b=`<div @ready="self.createModal(this)">
<div @ref="self.listContainer">

@@ -218,5 +217,5 @@ <div>

</div>
<p><input type="button" value="${g(_$_662b[218])}" onclick="self.openForm({ index: null })" class="jbutton dark" /></p>
<p><input type="button" value="${d(_$_c72f[117])}" onclick="self.openForm({ index: null })" class="jbutton dark" /></p>
</div>
<div @ref="self.settingsContainer" style="display: none;"><Settings @ref="self.settings" /></div>
</div>`;return lemonade[_$_662b[110]](b,f,{Settings:K,List:C})},e);return f},y=function(){return!0};y[_$_662b[256]]=function(a,e){if(e=E[_$_662b[63]](a))console[_$_662b[60]](e);else a[_$_662b[257]]({validations:M})};y[_$_662b[258]]=function(a){null===p&&(p=this)};return y});
</div>`;return lemonade.element(b,c,{Settings:J,List:E})},e);return c},D=function(){return!0};D.oninit=function(a,e){e=_$_c72f[0];8==a.status?a.scope&&-1!=a.scope.indexOf(_$_c72f[1])||(e=_$_c72f[2]):e=_$_c72f[3];if(!e){var c=h.version();if(!c||!c.version||9>parseInt(c.version))e=_$_c72f[4]}e?console.error(e):a.setPlugins({validations:L})};D.license=function(a){null===h&&(h=this)};return D});
# JSS Extensions
This software requires a license.
More information:
https://jspreasheet.com/products/validations
https://jspreasheet.com/products/validations
The javascript spreadsheet:
https://jspreasheet.com/
LemonadeJS:
https://lemonadejs.net
jSuites:
https://jsuites.net

@@ -31,6 +31,6 @@ {

"jszip": "^3.7.1",
"jsuites": "^4.12.10"
"jsuites": "^4.13.5"
},
"main": "dist/index.js",
"version": "1.0.1",
"version": "1.0.2",
"bugs": "https://github.com/jspreadsheet/pro/issues",

@@ -37,0 +37,0 @@ "homepage": "https://github.com/jspreadsheet/pro",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc