Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

lc2

Package Overview
Dependencies
Maintainers
2
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

lc2 - npm Package Compare versions

Comparing version 1.2.1 to 1.2.3

4

dist/lemoncase.min.js

@@ -1,2 +0,2 @@

!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.LC=e():t.LC=e()}(this,function(){return function(t){function e(i){if(n[i])return n[i].exports;var s=n[i]={exports:{},id:i,loaded:!1};return t[i].call(s.exports,s,s.exports,e),s.loaded=!0,s.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){t.exports=n(15)},function(t,e){function n(t,e){var n=r.contextFrame;n.style.height="100%",n.style.width="100%",t.appendChild(n),(e||s.noop).call(n)}function i(){return r.contextFrame}var s,r,o;s={now:Date.now||function(){return(new Date).getTime()},isString:function(t){return"string"==typeof t},isUndefined:function(t){return void 0===t},isDefined:function(t){return!s.isUndefined(t)},isNumber:function(t){return"number"==typeof t},isObject:function(t){var e=typeof t;return"function"===e||"object"===e&&!!t},isElement:function(t){return!(!t||1!==t.nodeType)},isFunction:function(t){return"function"==typeof t},isArray:function(t){return"[object Array]"==={}.toString.call(t)},last:function(t){return t[t.length-1]},noop:function(){},forEach:function(t,e,n){e=e.bind(n);var i,s;if(this.isArray(t))for(i=0,s=t.length;s>i;i+=1)e(t[i],i,t);else{var r=Object.keys(t);for(i=0,s=r.length;s>i;i+=1)e(t[r[i]],r[i],t)}return t},document:function(){return r.contextFrame?r.contextFrame.contentWindow.document:document},countDOM:function(t){return s.document().querySelectorAll(t).length},getInnerHTML:function(t){var e=s.document().querySelector(t);return e?e[e.value?"value":"innerHTML"]:"Error:No such HTMLElement."},isVisible:function(t){var e=s.document().querySelector(t);return e?0!==e.offsetHeight||0!==e.offsetWidth:!1}},r={contextFrame:document.createElement("iframe"),defaultNextLoopDelay:3e3,readyTimeout:3e3,defaultClock:10,bootExceptionHandle:s.noop,triggerCallback:s.noop,runCallback:s.noop,runExceptionHandle:s.noop,successCallback:s.noop,readyCallback:s.noop,nextLoopCallback:s.noop,consoleFn:s.noop},o=function(t){return s.isString(t)?r[t]:s.isObject(t)?void s.forEach(t,function(t,e){this[e]=t},r):void 0},o.setContextFrame=function(t){trigger.setupIframe(t),r.contextFrame=t},t.exports={_:s,settings:r,setup:o,init:n,getLemoncaseFrame:i}},function(t,e){function n(t,e){return new s(t,{beforeExpr:!0,binop:e})}function i(t,e){e=e||{},e.keyword=t,c[t]=a["_"+t]=new s(t,e)}var s=function(t,e){void 0===e&&(e={}),this.label=t,this.keyword=e.keyword,this.beforeExpr=Boolean(e.beforeExpr),this.isAssign=Boolean(e.isAssign),this.prefix=Boolean(e.prefix),this.postfix=Boolean(e.postfix),this.binop=e.binop||null,this.macro=Boolean(e.macro)},r={beforeExpr:!0},o={macro:!0},a={num:new s("num"),regexp:new s("regexp"),string:new s("string"),name:new s("name"),eof:new s("eof"),objectAt:new s("objectStore"),dict:new s("dictionaryIndex"),bracketL:new s("[",r),bracketR:new s("]"),braceL:new s("{",r),braceR:new s("}"),parenL:new s("(",r),parenR:new s(")"),comma:new s(",",r),semi:new s(";",r),colon:new s(":",r),tagNumL:new s("CountExpr",r),tagAtL:new s("TextExpr",r),tagFacL:new s("VisibilityExpr",r),tagR:new s("/>"),eq:new s("=",{beforeExpr:!0,isAssign:!0}),assign:new s("_=",{beforeExpr:!0,isAssign:!0}),incDec:new s("++/--",{prefix:!0,postfix:!0}),prefix:new s("prefix",{beforeExpr:!0,prefix:!0}),logicalOR:n("||",1),logicalAND:n("&&",2),equality:n("==/!=",6),relational:n("</>",7),plusMin:new s("+/-",{beforeExpr:!0,binop:9,prefix:!0}),modulo:n("%",10),star:n("*",10),slash:n("/",10),match:n("~~",6)},c={};i("in"),i("by",r),i("click",r),i("input",r),i("rclick",r),i("dblclick",r),i("movein",r),i("moveout",r),i("scroll",r),i("select",r),i("#CLOCK",o),i("#TIMES",o),i("#INTERVAL",o),i("#SCREEN",o),i("wait",r),i("assert",r),i("log",r),i("console",r),i("var"),i("process"),i("return",r),i("jumpto"),i("refresh"),t.exports={TokenType:s,types:a,keywordTypes:c}},function(t,e){t.exports={CALL:0,RETURN:1,EXIT:2,EXPRESSION:16,WAIT:17,TRIGGER:18,ASSERT:19,JUMPTO:20,REFRESH:21,LOG:32,CONSOLE:33,PROCESS:255}},function(t,e){var n=function(t,e){function n(t,e){this.$case=e,this.$body=t.BODY,this.$line=t.LINE}if(!e){var s=i[t];if(!s)throw new Error("TYPE:"+t+" instruction is not existed.");return s}if(i[t])throw new Error("The instruction factory: TYPE="+t+" is existed.");return n.prototype.execute=e.operation,n.prototype.line=function(){return this.$line},n.prototype.body=function(t){return t?this.$body[t]:this.$body},n.prototype.assignCase=function(t){return this.$case=t,this},n.create=function(){return new n({BODY:e.bodyFactory.apply(null,arguments)})},n.$new=function(t,e){return new n(t,e)},i[t]=n,n},i=[];t.exports=n},function(t,e,n){function i(t,e,n,i){var s={process:{},config:{}},r=[];return c.forEach(t.DATA_KEYS,function(t,e){t&&r.push(e)}),c.forEach(t.DICTIONARY_KEYS,function(t,e){if(!n.isFieldDefined(e))throw new Error("The field: "+e+" is undefined in dictionary.")}),c.forEach(t.OBJECT_KEYS,function(t,n){if(!e.hasOwnProperty(n))throw new Error("The key: "+n+" is undefined in object.")}),c.forEach(t.PROCESSES,function(t,e){var n=s.process[e]=[];c.forEach(t.BODY.segment,function(t){n.push(p(t.TYPE).$new(t,i))})}),s.config.times=t.CONFIG.times,s.config.interval=t.CONFIG.interval,s.config.screen=t.CONFIG.screen,{eT:s,dK:r}}function s(t,e,n){if(!(this instanceof s))return new s(t,e,n);var r=i(t,e,n,this);this.$$executionTree=r.eT,this.$dictionary=n,this.$objectList=e,this.$$log=new u(r.dK),this.$$state="ready",this.$$coreId=null,this.$$activeTime=0,this.$$currentLoop=0,this.vars={},this.$$blockStack=[],this.$$scopeStack=[],this.$$instructionBuffer=void 0,this.$$tempInstruction=void 0,this.$$idleTask=c.noop,this.$loopData=null}var r=n(3).CALL,o=n(3).EXIT,a=n(1),c=a._,h=a.settings,u=n(10),p=n(4),f=s.prototype;f.$$getConfig=function(t){return this.$$executionTree.config[t]},f.$$bootstrap=function(){var t=h.contextFrame.style,e=this.$$getConfig("screen");return this.$$currentLoop=0,this.hasDictionary()&&(this.$loopData=this.$dictionary.load(this.$$getConfig("times")).fetch()),e&&(t.height=e.height+"px",t.width=e.width+"px"),this.$setActiveTime().$setTempInstruction(p(r).create("main")).$$log.initialization(),this},f.$$exitCase=function(){return this.$setState("success").$$interrupt(),(h.successCallback||c.noop).call(this),this},f.$$interrupt=function(){return clearInterval(this.$$coreId),this},f.$$popInstruction=function(){var t=this.$$tempInstruction,e=this.$getCurrentBlock();return t?(this.$setTempInstruction(),t):e?(this.$$instructionBuffer=e.segment[e.counter++],this.$$instructionBuffer):p(o).create(!0).assignCase(this)},f.$$run=function(){try{this.$$popInstruction().execute(),h.runCallback.call(this)}catch(t){console.error("[Error FROM LC2]:"+t),h.runExceptionHandle.call(this,t)}return this},f.$$core=function(){var t=this;return this.$$coreId=setInterval(function(){t["$$"+(c.now()>=t.$$activeTime?"run":"idleTask")]()},this.$$getConfig("clock")||h.defaultClock),this},t.exports={Case:s,$CP:f}},function(t,e,n){function i(t){return this instanceof i?(this.$options={},this.$$buffer=[],this.$assignment=[],this.$field=[],this.field(t.field),void this.assignment(t.assignment)):new i(t)}var s=n(1)._;i.prototype.field=function(t){return s.isArray(t)&&(this.$field=t),this.$options.field=this.$field,this.$field},i.prototype.assignment=function(t){return s.isArray(t)&&(this.$assignment=t),this.$options.assignment=this.$assignment,this.$assignment},i.prototype.load=function(t){var e,n=this.$assignment.length,i=this.getKeys(),r=(i.length,function(t){s.forEach(i,function(e,n){this[e.name]=t[n]},this)}),o=function(){s.forEach(i,function(t){this[t.name]=t.pattern.gen()},this)};for(this.$$buffer=[],e=0;n>e&&t>e;e+=1)this.$$buffer.push(new r(this.$assignment[e]));for(null;t>e;e+=1)this.$$buffer.push(new o);return this},i.prototype.getKeys=function(){var t=[];return s.forEach(this.$field,function(t){this.push({name:t.name,pattern:new RegExp(t.pattern)})},t),t},i.prototype.fetch=function(){return this.$$buffer.shift()},i.prototype.isFieldDefined=function(t){var e,n=this.$field.length;for(e=0;n>e;e+=1)if(this.$field[e].name===t)return!0;return!1},t.exports=i},function(t,e){function n(t){return 65>t?36===t:91>t?!0:97>t?95===t:123>t}function i(t){return 48>t?36===t:58>t?!0:65>t?!1:91>t?!0:97>t?95===t:123>t}var s=["in","by"],r=["click","input","rclick","dblclick","movein","moveout","scroll","select","jumpto","refresh"],o=["#CLOCK","#TIMES","#INTERVAL","#SCREEN"],a=["wait","assert","log","console","var","process","return"].concat(s).concat(r).concat(o),c=new RegExp("^("+a.join("|")+")$");t.exports={keywordRegexp:c,isIdentifierStart:n,isIdentifierChar:i}},function(t,e,n){function i(t,e){for(var n=1,i=0;;){c.lastIndex=i;var s=c.exec(t);if(!(s&&s.index<e))return new h(n,e-i);++n,i=s.index+s[0].length}}function s(t,e,n){var i=t.split(c)[e.line-1],s=i.substr(0,e.column),h=a(s),u=r(h),p=o(n,h);return"\n"+i+"\n"+u+"\n"+p}function r(t){for(var e=-1,n=-1,i="";++e<t;)i+=" ";for(i+="↑\n";++n<t;)i+=" ";return i+="↑"}function o(t,e){if(t.length/2>e)return t;for(var n=-1,i=e-Math.floor(t.length/2),s="";++n<i;)s+=" ";return s+=t}function a(t){for(var e,n=0,i=-1,s=t.length;++i<s;)switch(e=t.charCodeAt(i)){case 9:n+=4;break;default:n+=1}return n}var c=n(9).lineBreakG,h=function(t,e){this.line=t,this.column=e};h.prototype.offset=function(t){return new h(this.line,this.column+t)},t.exports={getLineInfo:i,empowerErrMsg:s}},function(t,e){var n=/\r\n?|\n|\u2028|\u2029/;t.exports={lineBreak:n,lineBreakG:new RegExp(n.source,"g"),isNewLine:function(t){return 10===t||13===t||8232===t||8233===t}}},function(t,e,n){var i=n(1)._,s=function(t){this.$$baseTime=0,this.$dataKeys=t||[],this.$marks=[],this.$logs=[],this.$datas={}};s.prototype.initialization=function(){return this.clear(),this.$$baseTime=i.now(),i.forEach(this.$dataKeys,function(t){this[t]=[]},this.$datas),this},s.prototype.getLength=function(t){return this["$"+t].length},s.prototype.log=function(t,e){return this.$logs.push([t,i.now()-this.$$baseTime,e||0]),this},s.prototype.data=function(t,e){return this.$datas[t].push(e),this},s.prototype.markLog=function(t,e){return this.$marks.push([t,e,this.getLength("logs")-1]),this},s.prototype.clear=function(){return this.$$baseTime=0,this.$marks.length=0,this.$logs.length=0,this.$datas={},this},s.prototype.export2json=function(){return{baseTime:this.$$baseTime,marks:this.$marks,logs:this.$logs,performance:this.$datas}},s.prototype.export2text=function(){return JSON.stringify(this.export2json())},t.exports=s},function(t,e){!function(){var e={POSITION:0,CLASS:2,RANGE:3,CLAUSE:6,REFERENCE:7,INTS:"0123456789",WORDS:"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789",WHITESPACE:" \f\n\r \x0B  ᠎           \u2028\u2029\u2028\u2029   "},n="@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^ ?",i={0:0,t:9,n:10,v:11,f:12,r:13},s={rndChar:function(t){return t[Math.floor(Math.random()*t.length)]},anyRndChar:function(){return String.fromCharCode(s.rndInt(0,65535))},strToChars:function(t){var e=/\\(?:u([A-F0-9]{4})|x([A-F0-9]{2})|(0?[0-7]{2})|c([@A-Z\[\\\]^?])|([0tnvfr]))/g;return t=t.replace(e,function(t,e,s,r,o,a){var c,h=e?parseInt(e,16):s?parseInt(s,16):r?parseInt(r,8):o?n.indexOf(o):a?i[a]:void 0;return void 0!==h?(c=String.fromCharCode(h),c=c.replace(/[[\]{}^$.|?*+()]/g,function(t){return"\\"+t})):c="\\"+a,c})},rndInt:function(t,e){return t+Math.floor(Math.random()*(1+e-t))},findChar:function(t){for(var e="\\",n="]",i=0;;){var s=t.indexOf(n);if(t[s-1]!==e)return i+s;t=t.slice(++s),i+=s}},range:function(t,n,i){var s=e.WORDS;return s.slice(s.indexOf(n),s.indexOf(i)+1)},classRange:function(t){return t.replace(/(\w)-(\w)/g,s.range)},toBothCases:function(t){var e=t;return e+=t["to"+(t===t.toLowerCase()?"Upper":"Lower")+"Case"]()},inCaseClass:function(t,e){return e?t=t.replace(/[a-zA-Z]/g,function(t){return s.toBothCases(t)}):t},inCaseChar:function(t,n){return n&&/[a-zA-Z]/.test(t)?{type:e.CLASS,chars:s.toBothCases(t)}:t},flatten:function(t){for(var e=0;e<t.length-1;e++)if("string"==typeof t[e])for(var n=e+1;;){var i=t[n];if("string"!=typeof i)break;t[e]+=i,t.splice(n,1)}return 1===t.length?t[0]:t},reduce:function(t){if(t.stack)t.stack=s.flatten(t.stack);else if(t.options)for(var e=0,n=t.options.length;n>e;e++)t.options[e]=s.flatten(t.options[e]);return t.options||t.group||t.value?t:t.stack},nextClose:function(t){for(var e=0,n=0,i=t.length;i>n;n++){var s=t[n];switch(s){case")":if(0===e)return n+1;e--;break;case"(":e++;break;case"\\":n++}}}},r={type:e.POSITION,value:"b"},o={type:e.POSITION,value:"B"},a={type:e.POSITION,value:"^"},c={type:e.POSITION,value:"$"},h={type:e.CLASS,chars:e.WORDS},u={type:e.CLASS,chars:e.WORDS,not:!0},p={type:e.CLASS,chars:e.INTS},f={type:e.CLASS,chars:e.INTS,not:!0},l={type:e.CLASS,chars:e.WHITESPACE},d={type:e.CLASS,chars:e.WHITESPACE,not:!0},v={type:e.CLASS,chars:"\n",not:!0},g=function(t,n,i){var g,m=0,$={type:e.CLAUSE,stack:[]},x=$,y=$.stack,b=[];for(t=s.strToChars(t);m<t.length;)switch(g=t[m++]){case"\\":switch(g=t[m++]){case"b":y.push(r);break;case"B":y.push(o);break;case"w":y.push(h);break;case"W":y.push(u);break;case"d":y.push(p);break;case"D":y.push(f);break;case"s":y.push(l);break;case"S":y.push(d);break;default:/\d/.test(g)?y.push({type:e.REFERENCE,value:parseInt(g)}):y.push(g)}break;case"^":y.push(a);break;case"$":y.push(c);break;case"[":if(g=t[m],"\\"===g&&0===t.slice(m+1).indexOf("b]"))m+=3,y.push("\b");else{var E;"^"===g?(E=!0,m++):E=!1;var k=t.slice(m),C=s.findChar(k),w=k.substring(0,C);m+=C+1,y.push({type:e.CLASS,chars:s.inCaseClass(s.classRange(w),n),not:E})}break;case".":y.push(v);break;case"(":g=t[m];var T;if("?"===g){if(g=t[m+1],m+=2,"!"===g){m+=s.nextClose(t.slice(m));break}T=!1}else T=!0;var S={type:e.CLAUSE,group:T,stack:[]};y.push(S),b.push(x),x=S,y=S.stack;break;case")":x=b.pop(),y=x.options?x.options[x.options.length-1]:x.stack;var O=y.length-1;y[O]=s.reduce(y[O]);break;case"|":x.options||(x.options=[x.stack],delete x.stack);var L=[];x.options.push(L),y=L;break;case"{":var A=/^(\d+)(,(\d+)?)?\}/.exec(t.slice(m)),I=parseInt(A[1]),R=A[2]?A[3]?parseInt(A[3]):1/0:I;m+=A[0].length;var B=y.pop();if(I===R)for(var D=0;I>D;D++)y.push(B);else y.push({type:e.RANGE,min:I,max:R,value:B});break;case"?":var B=y.pop();y.push({type:e.RANGE,min:0,max:1,value:B});break;case"+":var B=y.pop();y.push({type:e.RANGE,min:1,max:1/0,value:B});break;case"*":var B=y.pop();y.push({type:e.RANGE,min:0,max:1/0,value:B});break;default:y.push(s.inCaseChar(g,n))}return s.reduce($)},m=function(t,n,i,r){if("string"==typeof t)return t;if(t.length){for(var o="",a=0,c=t.length;c>a;a++)o+=m(t[a],n,i,r);return o}switch(t.type){case e.POSITION:return"";case e.CLASS:if(!t.not)return s.rndChar(t.chars);for(;;){var h=i();if(-1===t.chars.indexOf(h))return h}case e.RANGE:for(var u=s.rndInt(t.min,t.max===1/0?t.min+n:t.max),o="",a=0;u>a;a++)o+=m(t.value,n,i,r);return o;case e.CLAUSE:if(t.options){var u=s.rndInt(0,t.options.length-1);return m(t.options[u],n,i,r)}var p=m(t.stack,n,i,r);return r.push(p),p;case e.REFERENCE:return r[t.value-1]}};RegExp.prototype.gen=function(){return void 0===this._randexp&&(this._randexp=g(this.source,this.ignoreCase,this.multiline),this._max=this._max||100,this._anyRndChar=this._anyRndChar||s.anyRndChar),m(this._randexp,this._max,this._anyRndChar,[])},"undefined"==typeof window&&(t.exports=m)}()},function(t,e){!function(){"use strict";function e(t,e,n){var i,s=[t];for(i in n)n.hasOwnProperty(i)&&(s[n[i]]=e[i]||null);return s}function n(t){return 1===t.nodeType}function i(t){return t instanceof Window}function s(t){return null!==t&&"object"==typeof t}function r(t){return"function"==typeof t}function o(t,e){e?t.$$hashKey=e:delete t.$$hashKey}function a(t,e){var n,i,a,c,h,u,p,f,l=t.$$hashKey;if(e)for(i=0,n=e.length;n>i;++i)if(p=e[i],s(p)||r(p))for(f=Object.keys(p),c=0,a=f.length;a>c;c++)h=f[c],u=p[h],t[h]=u;return o(t,l),t}function c(t){return a(t,[].slice.call(arguments,1),!1)}function h(t,e,n){v&&t.dispatchEvent(new E(e,c({},L,n)))}function u(t,e,n){t.dispatchEvent(new C(e,c({},L,n)))}function p(t,e,n){t.dispatchEvent(new T(e,c({},L,n)))}function f(t){this.element=t,this.action=this.getActionRule(t)}var l,d=!0,v=!0,g=!0;try{l=new MouseEvent("click",{})}catch(m){d=!1}try{TouchEvent}catch($){v=!1}try{InputEvent}catch(x){g=!1}var y,b,E=function(t,n){var i=document.createEvent("UIEvent"),s={bubbles:1,cancelBubble:2,view:3,detail:4};return i.initUIEvent.apply(i,e(t,n,s)),i},k=d&&!v?Event:function(t,n){var i=document.createEvent("Event"),s={bubbles:1,cancelBubble:2};return i.initEvent.apply(i,e(t,n,s)),i},C=d&&!v?MouseEvent:function(t,n){var i=document.createEvent("MouseEvent"),s={bubbles:1,cancelBubble:2,view:3,detail:4,screenX:5,screenY:6,clientX:7,clientY:8,ctrlKey:9,altKey:10,shiftKey:11,metaKey:12,button:13,relatedTarget:14};return i.initMouseEvent.apply(i,e(t,n,s)),i},w=d&&!v?UIEvent:function(t,n){var i=document.createEvent("UIEvent"),s={bubbles:1,cancelBubble:2,view:3,detail:4};return i.initUIEvent.apply(i,e(t,n,s)),i},T=d&&!v?KeyboardEvent:function(t,n){var i=document.createEvent("KeyboardEvent"),s={bubbles:1,cancelBubble:2,view:3,"char":4,key:5,location:6,repeat:8};return i.initKeyboardEvent.apply(i,e(t,n,s)),i},S=(g?InputEvent:w,{contextIframe:null,window:function(){return S.contextIframe?S.contextIframe.contentWindow:window}}),O=[],L={bubbles:!0,cancelBubble:!0},A=0,I=1,R=2,B=3,D=4,N=5,_=6,P=7,Y=8,F=9,M=16,U=17,j=18,G=32,W=33,K=34,H=36,q=48,V=49;O[A]=function(t){h(this,"touchend",t),u(this,"mouseup",t)},O[I]=function(t){h(this,"touchstart",t),u(this,"mousedown",t)},O[R]=function(t){u(this,"mouseenter",t)},O[B]=function(t){u(this,"mouseleave",t)},O[D]=function(t){u(this,"mouseout",t)},O[N]=function(t){u(this,"mouseover",t)},O[_]=function(t){h(this,"touchmove",t),u(this,"mousemove",t)},O[P]=function(t){u(this,"click",t)},O[Y]=function(t){u(this,"dblclick",t)},O[F]=function(t){u(this,"contextmenu",t)},O[U]=function(t){p(this,"keydown",t)},O[j]=function(t){p(this,"keypress",t)},O[M]=function(t){p(this,"keyup",t)},O[K]=function(){this.focus()},O[W]=function(t){var e=S.contextIframe.style;e.width=t.width+"px",e.height=t.height+"px"},O[G]=function(t){S.window().scrollTo(t.x,t.y),this.dispatchEvent(new w("scroll"))},O[H]=function(t){var e=this[t.index];O[I].call(e,t),O[A].call(e,t),e.selected=!0,this.dispatchEvent(new w("select")),O[P].call(e,t),O[D].call(e,t)},O[q]=function(t){this.value=t.value,this.dispatchEvent(new w("input",t))},O[V]=function(){this.dispatchEvent(new k("change",{bubbles:!0}))},f.prototype.getActionRule=function(t){return t=t||this.element,t instanceof Window?b.window:"input"===t.tagName.toLowerCase()?b["input/"+t.type]:"textarea"===t.tagName.toLowerCase()?b.textarea:"select"===t.tagName.toLowerCase()?b.select:b.generic},f.prototype.does=function(t,e){var n,i,s;if(this.testAction(t)!==!0)throw"The element:"+this.element.outerHTNL+" can not use action:"+t;for(s=this.action[t],i=s.length,n=0;i>n;n+=1)O[s[n]].call(this.element,e||{});return this},f.prototype.testAction=function(t){return this.action.hasOwnProperty(t)},b=function(){var t={};return t["input/checkbox"]=t["input/radio"]=t["input/button"]=t.generic={click:[I,_,A,P],dblclick:[I,A,P,I,A,P,Y],rclick:[I,A,F],movein:[N,D],moveout:[_,D],scroll:[G]},t.textarea=t["input/text"]=t["input/password"]=t["input/email"]=c({},t.generic,{input:[K,U,j,q,M,V],click:[I,K,_,A,P],dblclick:[I,K,_,A,P,I,_,A,P,Y],rclick:[I,K,A,F]}),t.select=c({},t.generic,{select:[I,K,_,A,P,_,D,H]}),t.window={scroll:[G],resize:[W]},t}(),y=function(t){if(!i(t)&&!n(t))throw'"element" for trigger must be a HTMLElement';return new f(t)},y.setupIframe=function(t){if(!(t instanceof HTMLIFrameElement))throw'"element" must be a iframe element.';S.contextIframe=t},"undefined"!=typeof t&&t.exports?t.exports=y:window.trigger=y}()},function(t,e,n){var i=n(5).$CP,s=n(1),r=s._,o=s.settings,a=n(4),c=n(3).CALL;i.$setIdleTask=function(t){return this.$$idleTask=r.isFunction(t)?t:r.noop,this},i.$setActiveTime=function(t){return this.$$activeTime=r.now()+(t||0),this},i.$setTempInstruction=function(t){return this.$$tempInstruction=t?t.assignCase(this):void 0,this},i.$setState=function(t){return this.$$state=t,this},i.$pushBlock=function(t){return this.$$blockStack.push({counter:0,segment:t}),this},i.$pushScope=function(t){var e=this.$$blockStack;return this.$$scopeStack.push({blockIndex:e.length,vars:{}}),this.$pushBlock(this.$getProcess(t)),this},i.$popBlock=function(){return this.$$blockStack.pop(),this},i.$popScope=function(){var t=this.$$scopeStack.pop();return this.$$blockStack.length=t.blockIndex,this},i.$getCurrentBlock=function(){return r.last(this.$$blockStack)},i.$getCurrentScope=function(){return r.last(this.$$scopeStack)},i.$getProcess=function(t){return this.$$executionTree.process[t]},i.$exitLoop=function(){return this.$setActiveTime(this.$$getConfig("interval")||3e3),(this.$$currentLoop+=1)>=this.$$getConfig("times")?(this.$$exitCase(),this):(this.$setTempInstruction(a(c).create("main")),(o.nextLoopCallback||r.noop).call(this),this.hasDictionary()&&(this.$loopData=this.$dictionary.fetch()),this)},i.$runExp=function(t){return"function"==typeof t?t(this.vars,this.$objectList,this.$loopData,r.countDOM,r.getInnerHTML,r.isVisible):t},i.$pushLog=function(t,e){return this.getLog().log(t,e),this},i.$markLog=function(t,e){return this.getLog().markLog(t,e),this},i.$pushLogData=function(t,e){return this.getLog().data(t,e),this},i.$clearScope=function(){for(;this.$$scopeStack.length;)this.$popScope();return this},t.exports=i},function(t,e,n){var i=n(5).$CP,s=n(1).settings,r=n(6);i.hasDictionary=function(){return!!this.$dictionary},i.validateObjectList=function(t,e){return e.length?t?e.every(function(e){return null!==t[e]}):!1:!0},i.exportLog=function(t){return this.$$log["export2"+t]()},i.start=function(){var t=this.$$state;if("success"!==t&&"ready"!==t)throw new Error("Can not call play!");try{return this.$setState("running").$$bootstrap(),setTimeout(function(){this.$$core()}.bind(this),s.readyTimeout),this}catch(e){s.bootExceptionHandle(e)}},i.forceCofig=function(t){var e,n=this.$$executionTree.config;for(e in t)t.hasOwnProperty(e)&&(n[e]=t[e]);return this},i.suspend=function(){if("running"!==this.$$state)throw new Error("Can not call pause!");return this.$setState("pause").$$interrupt(),this},i.resume=function(){if("pause"!==this.$$state)throw new Error("Can not call resume!");return this.$setState("running").$$core(),this},i.stop=function(){var t=this.$$state;if("running"!==t&&"pause"!==t)throw new Error("Can not call stop!");return this.$setState("ready").$$interrupt(),this},i.debug=function(){var t=this.$$state;if("success"!==t&&"ready"!==t)throw new Error("Can not call play!");return this.$setState("debug").$$bootstrap(),this},i.dictionary=function(t){return t instanceof r&&(this.$dictionary=t),this.$dictionary},i.getLog=function(){return this.$$log},i.getCurrentStep=function(){return this.$$counter},i.getCurrentLoop=function(){return this.$$currentLoop},i.getCurrentLine=function(){return this.$$instructionBuffer.$getLine()},i.getStatus=function(){return{loop:this.$$currentLoop,line:this.getCurrentLine(),state:this.$$state}},t.exports=i},function(t,e,n){var i=n(18).parse,s=n(5).Case,r=n(1).setup,o=n(4),a=n(6),c=n(1),h=c.init,u=c.getLemoncaseFrame;n(13),n(14),n(11),n(16);var e={Case:s,setup:r,Instruction:o,parse:i,Dictionary:a,init:h,getLemoncaseFrame:u};t.exports=e},function(t,e,n){var i=n(4),s=n(1),r=s.settings,o=s._,a=n(3),c=a.CALL,h=a.RETURN,u=a.EXIT,p=a.EXPRESSION,f=a.WAIT,l=a.TRIGGER,d=a.ASSERT,v=a.JUMPTO,g=a.REFRESH,m=a.LOG,$=a.CONSOLE,x=(a.PROCESS,1),y=0;trigger=n(12),i(c,{operation:function(){var t=this.body("identifier");this.$case.$pushScope(t).$pushLog([c,t],this.line())},bodyFactory:function(t){return{identifier:t}}}),i(h,{operation:function(){this.$case.$pushLog([h]).$popScope()},bodyFactory:function(){return{}}}),i(u,{operation:function(){var t=this.body("isSuccess")?x:y,e=this.$case;e.$pushLog([u,t],this.line()).$markLog(t,e.getCurrentLoop()).$clearScope().$exitLoop()},bodyFactory:function(t){return{isSuccess:t}}}),i(p,{operation:function(){this.$case.$runExp(this.body("exp"))},bodyFactory:function(t){return{exp:t}}}),i(f,{operation:function(){var t=this.$case.$runExp(this.body("delay"));this.$case.$setActiveTime(t).$pushLog([f,t],this.line())},bodyFactory:function(t){return{delay:t}}}),i(l,{operation:function(){var t=this.$case.$runExp(this.body("object")),e={value:this.$case.$runExp(this.body("param"))},n=this.body("action"),s=o.document().querySelectorAll(t)[0];return s?(trigger(s).does(n,e),r.triggerCallback.call(this.$case,s),void this.$case.$pushLog([l,x,t,n,e],this.line())):(this.$case.$pushLog([l,y,t,n,e],this.line()).$setTempInstruction(i(u).create(!1).assignCase(this.$case)),void console.log("Can not find a DOM by cssPath: "+t))},bodyFactory:function(t,e,n){return{object:t,action:e,param:n}}}),i(d,{operation:function(){function t(){a.$runExp(n)&&a.$setIdleTask().$setTempInstruction().$setActiveTime().$pushLog([d,x],c.line()).$pushLogData(c.body("key"),o.now()-e)}var e=o.now(),n=this.body("exp"),s=this.body("timeout"),a=this.$case,c=this;a.$setTempInstruction(i(u).create(!1).assignCase(a)),s&&s>2*r.defaultClock&&a.$setActiveTime(s).$setIdleTask(t),a.$runExp(n)?(a.$setTempInstruction().$setActiveTime().$setIdleTask().$pushLog([d,x],this.line()),s&&a.$pushLogData(c.body("key"),0)):s||a.$pushLog([d,y],this.line())},bodyFactory:function(t,e,n){return{exp:t,timeout:e,key:n}}}),i(v,{operation:function(){var t=this.$case.$runExp(this.body("url"));r.contextFrame.src=t,this.$case.$pushLog([v,t],this.line())}}),i(g,{operation:function(){o.document().location.reload(),this.$case.$pushLog([g],this.line())}}),i(m,{operation:function(){this.$case.$pushLog([m,this.$case.$runExp(this.body("msg"))])},bodyFactory:function(t){return{msg:t}}}),i($,{operation:function(){var t=this.$case.$runExp(this.body("msg"));console.log(t),r.consoleFn(t)},bodyFactory:function(t){return{msg:t}}})},function(t,e,n){var i=n(2).types;t.exports=function(t){var e=t.prototype;e.parseExpression=function(){var t=this.parseMaybeAssign();if(this.type===i.comma){var e={type:"SequenceExpr"};for(e.expressions=[t];this.eat(i.comma);){var n=this.parseMaybeAssign();e.expressions.push(n)}return e}return t},e.parseMaybeAssign=function(){var t=this.parseMaybeConditional();if(this.type.isAssign){var e={type:"AssignmentExpr",left:t,operator:this.value};return this.next(),e.right=this.parseMaybeAssign(),e}return t},e.parseMaybeConditional=function(){return this.parseExprOps()},e.parseExprOps=function(){var t=this.start,e=this.parseMaybeUnary(!1);return this.parseExprOp(e,t,-1)},e.parseExprOp=function(t,e,n){var i=this.type.binop;if(null!=i&&i>n){var s=this.type,r=this.value;this.next();var o=this.start,a=this.parseExprOp(this.parseMaybeUnary(!1),o,i),c=this.buildBinary(e,t,a,r,s);return this.parseExprOp(c,e,n)}return t},e.buildBinary=function(t,e,n,s,r){var o={left:e,operator:s,right:n};return r===i.logicalAND||r===i.logicalOR?o.type="LogicalExpr":r===i.match?o.type="MatchExpr":o.type="BinaryExpr",o},e.parseMaybeUnary=function(t){var e;if(this.type.prefix){var n={},s=this.type===i.incDec;n.operator=this.value,n.prefix=!0,this.next(),n.argument=this.parseMaybeUnary(!1),s||(t=!0),n.type=s?"UpdateExpr":"UnaryExpr",e=n}else for(e=this.parseExprSubscripts();this.type.postfix;){var r={};r.operator=this.value,r.prefix=!1,r.argument=e,this.next(),r.type="UpdateExpr",e=r}return e},e.parseExprSubscripts=function(){var t=this.start,e=this.parseExprAtom();return this.parseSubscripts(e,t)},e.parseSubscripts=function(t,e){for(;;){if(this.eat(i.parenL)){var n={type:"CallExpr",callee:t};return this.expect(i.parenR),n}return t}},e.parseExprAtom=function(){var t;switch(this.type){case i.name:var e=this.parseIndent(this.type!==i.name);return{type:"Identifier",name:e};case i.regexp:var n=this.value;return t=this.parseLiteral("regexp"),t.regexp=n,t;case i.num:case i.string:return this.parseLiteral("literal",this.value);case i.objectAt:case i.dict:return this.parseExtLiteral(this.type);case i.parenL:return this.parseParenExpression();case i.tagAtL:case i.tagNumL:case i.tagFacL:return this.parseTagExpression();default:this.unexpected()}},e.parseLiteral=function(t,e){var n={type:t,value:e,raw:this.input.slice(this.start,this.end)};return this.next(),n},e.parseExtLiteral=function(t){var e={type:t.label,value:this.value};return this.next(),e},e.parseParenExpression=function(){this.expect(i.parenL);var t=this.parseExpression();return this.expect(i.parenR),{type:"ParenthesizedExpr",expression:t}},e.parseTagExpression=function(){var t={type:this.type.label};return this.next(),t.val=this.parseExpression(),this.expect(i.tagR),t},e.parseIndent=function(){var t;return this.type===i.name?t=this.value:this.unexpected(),this.next(),t}}},function(t,e,n){var i=n(23);t.exports={parse:function(t,e){return new i(e,t).parse()},tokenizer:function(t,e){return new i(e,t)}}},function(t,e,n){var i=n(8),s=i.getLineInfo,r=i.empowerErrMsg;t.exports=function(t){var e=t.prototype;e.raise=function(t,e){var n=s(this.input,t);e+=" ("+n.line+":"+n.column+")",e=r(this.input,n,e);var i=new SyntaxError(e);throw i.pos=t,i.loc=n,i.raisedAt=this.pos,i}}},function(t,e,n){var i=n(2).types;t.exports=function(t){var e=t.prototype;e.parseBindingList=function(t,e,n){for(var s=[],r=!0;!this.eat(t);)if(r?r=!1:this.expect(i.comma),e&&this.type===i.comma)s.push(null);else{if(n)break;var o=this.parseIndent();s.push(o)}return s}}},function(t,e,n){function i(t){var e={};for(var n in r)e[n]=t&&s(t,n)?t[n]:r[n];return e}var s=n(26).has,r={insertReturn:!0,onComment:function(){},plugins:{}};t.exports={defaultOptions:r,getOptions:i}},function(t,e,n){var i=n(2).types;t.exports=function(t){var e=t.prototype;e.eat=function(t){return this.type===t?(this.next(),!0):!1},e.semicolon=function(){this.eat(i.semi)||this.expected(i.semi)},e.expect=function(t){this.eat(t)||this.expected(t)},e.unexpected=function(t){this.raise(null!=t?t:this.start,"Unexpected token")},e.expected=function(t){this.raise(this.lastTokEnd,'Expect a "'+t.label+'" after')},e.UID=function(t){return t+this.nextID++}}},function(t,e,n){var i=n(21).getOptions,s=n(7).keywordRegexp,r=n(2).types,o=function(t,e){this.options=i(t),this.keywords=s,this.input=String(e),this.pos=0,this.type=r.eof,this.value=null,this.start=this.end=this.pos,this.lastTokStart=this.lastTokEnd=this.pos,this.exprAllowed=!1,this.labels=[],this.conf={},this.keys={},this.nextID=0,this.pcs={},this.pcsTable={},this.dTable={},this.obTable={}};o.prototype.parse=function(){this.nextToken();var t={CONFIG:this.conf,DATA_KEYS:this.keys,PROCESSES:this.pcs,DICTIONARY_KEYS:this.dTable,OBJECT_KEYS:this.obTable};return this.parseTopLevel(t)};var a=function(t){t(o)};a(n(19)),a(n(25)),a(n(24)),a(n(22)),a(n(17)),a(n(20)),t.exports=o},function(t,e,n){var i=n(2).types,s=n(8).getLineInfo,r=n(27),o=n(3);t.exports=function(t){var e=t.prototype;e.parseTopLevel=function(t){var e=this.pcsTable;for(e.main={pos:0};this.type!==i.eof;)this.parseStructure();for(var n in e)e[n]&&this.raise(e[n].pos,"Invalid process call at");return t},e.parseStructure=function(){var t=this.type;return t.macro?this.parseSet():t===i._process?this.parseProcess():void this.raise(this.start,"Expect a macro or process")},e.parseSet=function(){var t=this.type;t.macro||this.unexpected();var e=t.label.substr(1).toLowerCase();this.writeConfig(e),this.next()},e.writeConfig=function(t){var e,n=this.conf;switch(n[t]&&this.raise(this.start,this.type.keyword+" was defined already"),t){case"screen":var i,s,r=this.value.split(",");2!==r.length&&this.raise("Invalid arguments"),i=~~parseInt(r[0],10),s=~~parseInt(r[1],10),e={width:i,height:s};break;default:e=parseInt(this.value,10)}n[t]=e},e.parseProcess=function(){var t={LINE:s(this.input,this.start),TYPE:o.PROCESS,BODY:{}},e=this.pcs,n=this.pcsTable;this.next();var i=this.parseIndent();e[i]&&this.raise(this.start,i+" process was defined already"),e[i]=t,n[i]=!1,this.parsePcParam(t),this.parsePcBlock(t)},e.parsePcParam=function(t){this.eat(i.parenL)&&(t.BODY.params=this.parseBindingList(i.parenR,!1,!1));
},e.parsePcBlock=function(t){var e=this.parseBlock();e.length&&e[e.length-1].TYPE===o.RETURN||e.push({LINE:-1,TYPE:o.RETURN}),t.BODY.segment=e},e.parseBlock=function(){this.expect(i.braceL);for(var t=[];!this.eat(i.braceR);){var e=this.parseStatement(!0);t.push(e)}return t},e.parseStatement=function(){var t=this.type,e=this.startNode();switch(t){case i._click:case i._rclick:case i._dblclick:case i._movein:case i._moveout:return this.parseMouseAction(e,t.keyword);case i._select:return this.parseSelectAction();case i._scroll:return this.parseScrollAction(e,t.keyword);case i._input:return this.parseInputAction(e,t.keyword);case i._return:return this.parseReturnStatement(e);case i._wait:return this.parseWaitStatement(e);case i._assert:return this.parseAssertStatement(e);case i._log:case i._console:return this.parseLogStatement(e,t===i._log?o.LOG:o.CONSOLE);case i._jumpto:return this.parseGotoStatement(e);case i._refresh:return this.parseRefreshStatement(e);case i._var:return this.parseVarStatement(e);case i.name:return this.parseExprStatement(e);default:this.unexpected()}},e.parseReturnStatement=function(t){return this.next(),this.eat(i.semi)?t.args=null:this.raise(this.start,"Return expression is not supported"),this.finishNode(t,o.RETURN)},e.parseVarStatement=function(t){return this.next(),this.parseVar(t),t.BODY.exp=r(t.BODY.raw),this.semicolon(),this.finishNode(t,o.EXPRESSION)},e.parseVar=function(t){for(var e=[];;){var n={};if(n.id=this.parseIndent(),this.eat(i.eq)?n.init=this.parseMaybeAssign():n.init=null,e.push(n),!this.eat(i.comma))break}t.BODY.raw={declarations:e,type:"varDecl"}},e.parseExprStatement=function(t){var e=this.parseExpression();if(this.semicolon(),"CallExpr"===e.type){var n=e.callee.name;return this.pcsTable[n]!==!1&&(this.pcsTable[n]={pos:this.lastTokStart}),t.BODY.identifier=n,this.finishNode(t,o.CALL)}var i=r(e);return t.BODY.raw=e,t.BODY.exp=i,this.finishNode(t,o.EXPRESSION)},e.parseWaitStatement=function(t){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.delay=r(t.BODY.raw),this.semicolon(),this.finishNode(t,o.WAIT)},e.parseMouseAction=function(t,e){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.object=r(t.BODY.raw),t.BODY.action=e,this.semicolon(),this.finishNode(t,o.TRIGGER)},e.parseScrollAction=function(t,e){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.object=r(t.BODY.raw),this.expect(i._by),t.BODY.raw1=this.parseExpression(),t.BODY.param=r(t.BODY.raw1),t.BODY.action=e,this.finishNode(t,o.TRIGGER)},e.parseSelectAction=function(){this.raise("work in progress...")},e.parseInputAction=function(t,e){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.object=r(t.BODY.raw),this.expect(i._by),t.BODY.raw1=this.parseExpression(),t.BODY.param=r(t.BODY.raw1),t.BODY.action=e,this.semicolon(),this.finishNode(t,o.TRIGGER)},e.parseAssertStatement=function(t){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.exp=r(t.BODY.raw),this.eat(i._in)&&(this.type===i.num?t.BODY.timeout=this.value:this.unexpected(),this.next()),this.semicolon(),t.BODY.key=this.UID("#"),this.keys[t.BODY.key]=!!t.BODY.timeout,this.finishNode(t,o.ASSERT)},e.parseGotoStatement=function(t){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.url=r(t.BODY.raw),this.semicolon(),this.finishNode(t,o.JUMPTO)},e.parseRefreshStatement=function(t){return this.next(),this.semicolon(),this.finishNode(t,o.REFRESH)},e.parseLogStatement=function(t,e){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.msg=r(t.BODY.raw),this.semicolon(),this.finishNode(t,e)},e.startNode=function(){return{LINE:s(this.input,this.start).line,TYPE:0,BODY:{},start:this.start,end:0}},e.finishNode=function(t,e){return t.TYPE=e,t.end=this.lastTokEnd,t}}},function(t,e,n){var i=n(7),s=i.isIdentifierStart,r=i.isIdentifierChar,o=n(2).types,a=n(2).keywordTypes,c=n(9),h=c.isNewLine,u=c.lineBreak;t.exports=function(t){var e=t.prototype;e.next=function(){this.lastTokEnd=this.end,this.lastTokStart=this.start,this.nextToken()},e.nextToken=function(){return this.skipSpace(),this.start=this.pos,this.pos>=this.input.length?this.finishToken(o.eof):void this.readToken(this.fullCharCodeAtPos())},e.readToken=function(t){return s(t)||35===t?this.readWord():this.getTokenFromCode(t)},e.fullCharCodeAtPos=function(){return this.input.charCodeAt(this.pos)},e.skipBlockComment=function(){var t=this.pos,e=this.input.indexOf("*/",this.pos+=2);-1===e&&this.raise(this.pos-2,"unterminated comment"),this.pos=e+2,this.options.onComment&&this.options.onComment(!0,this.input.slice(t+2,e),t,this.pos)},e.skipLineComment=function(t){for(var e=this.pos,n=this.input.charCodeAt(this.pos+=t);this.pos<this.input.length&&10!==n&&13!==n&&8232!==n&&8233!==n;)++this.pos,n=this.input.charCodeAt(this.pos);this.options.onComment&&this.options.onComment(!1,this.input.slice(e+=t,this.pos),e,this.pos)},e.skipSpace=function(){t:for(;this.pos<this.input.length;){var t=this.input.charCodeAt(this.pos);switch(t){case 32:case 160:++this.pos;break;case 13:10===this.input.charCodeAt(this.pos+1)&&++this.pos;case 10:case 8232:case 8233:++this.pos;break;case 47:switch(this.input.charCodeAt(this.pos+1)){case 42:this.skipBlockComment();break;case 47:this.skipLineComment(2);break;default:break t}break;default:if(!(t>8&&14>t))break t;++this.pos}}},e.readToken_bracket=function(){var t=this.pos++,e=this.fullCharCodeAtPos();if(s(e)){var n=this.readWord1();return e=this.fullCharCodeAtPos(),93!==e&&this.raise(t,"Unterminated dictionary index"),this.pos++,this.dTable[n]=!0,this.finishToken(o.dict,n)}return this.finishToken(o.bracketL)},e.readToken_brace=function(){var t=this.pos++,e=this.fullCharCodeAtPos();if(s(e)){var n=this.readWord1();return e=this.fullCharCodeAtPos(),125!==e&&this.raise(t,"Unterminated object store index"),this.pos++,this.obTable[n]=!0,this.finishToken(o.objectAt,n)}return this.finishToken(o.braceL)},e.readToken_slash=function(){var t=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp("/")):61===t?this.finishOp(o.assign,2):62===t?this.finishOp(o.tagR,2):this.finishOp(o.slash,1)},e.readToken_mult_modulo_exp=function(t){var e=this.input.charCodeAt(this.pos+1),n=1,i=42===t?o.star:o.modulo;return 61===e?this.finishOp(o.assign,n+1):this.finishOp(i,n)},e.readToken_pipe_amp=function(t){var e=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp("|")):e===t?this.finishOp(124===t?o.logicalOR:o.logicalAND,2):void this.raise(this.pos,"bitwise operator is not allowed")},e.readToken_plus_min=function(t){var e=this.input.charCodeAt(this.pos+1);return e===t?this.finishOp(o.incDec,2):61===e?this.finishOp(o.assign,2):this.finishOp(o.plusMin,1)},e.readToken_lt_gt=function(t){var e=this.input.charCodeAt(this.pos+1),n=1;if(e===t&&this.raise(this.pos,"bitwise operator is not allowed"),60===t){if(35===e)return this.finishOp(o.tagNumL,2);if(64===e)return this.finishOp(o.tagAtL,2);if(33===e)return this.finishOp(o.tagFacL,2)}return 61===e&&(n=2),this.finishOp(o.relational,n)},e.readToken_eq_excl=function(t){var e=this.input.charCodeAt(this.pos+1);return 126===e&&33===t?this.finishOp(o.match,2):61===e?this.finishOp(o.equality,61===this.input.charCodeAt(this.pos+2)?3:2):this.finishOp(61===t?o.eq:o.prefix,1)},e.getTokenFromCode=function(t){switch(t){case 40:return++this.pos,this.finishToken(o.parenL);case 41:return++this.pos,this.finishToken(o.parenR);case 59:return++this.pos,this.finishToken(o.semi);case 44:return++this.pos,this.finishToken(o.comma);case 91:return this.readToken_bracket();case 93:return++this.pos,this.finishToken(o.bracketR);case 123:return this.readToken_brace();case 125:return++this.pos,this.finishToken(o.braceR);case 58:return++this.pos,this.finishToken(o.colon);case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return this.readNumber(!1);case 34:case 39:return this.readString(t);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(t);case 124:case 38:return this.readToken_pipe_amp(t);case 43:case 45:return this.readToken_plus_min(t);case 60:case 62:return this.readToken_lt_gt(t);case 61:case 33:return this.readToken_eq_excl(t);case 126:var e=this.input.charCodeAt(this.pos+1);return 126!==e&&this.raise(this.pos,"bitwise operator is not allowed"),this.finishOp(o.match,2);default:this.raise(this.pos,'Unexpected character "'+this.input[this.pos]+'"')}},e.finishOp=function(t,e){var n=this.input.slice(this.pos,this.pos+=e);return this.finishToken(t,n)},e.finishToken=function(t,e){this.end=this.pos,this.type=t,this.value=e,this.exprAllowed=this.type.beforeExpr},e.readRegexp=function(t){for(var e,n,i=this.pos;;){this.pos>=this.input.length&&this.raise(i,"Unterminated regular expression");var s=this.input.charAt(this.pos);if(u.test(s)&&this.raise(i,"Unterminated regular expression"),e)e=!1;else{if("["===s)n=!0;else if("]"===s&&n)n=!1;else if(s===t&&!n)break;e="\\"===s}++this.pos}var r=this.input.slice(i,this.pos);++this.pos;var a=this.readWord1();if(a){var c=/^[gim]*$/;c.test(a)||this.raise(i,"Invalid regular expression flag")}var h={pattern:r,flags:a,isGenerate:"|"===t};return this.finishToken(o.regexp,h)},e.readInt=function(t,e){for(var n=this.pos,i=0,s=0,r=null==e?1/0:e;r>s;++s){var o,a=this.fullCharCodeAtPos();if(o=a>=97?a-97+10:a>=65?a-65+10:a>=48&&57>=a?a-48:1/0,o>=t)break;++this.pos,i=i*t+o}return this.pos===n||null!=e&&this.pos-n!==e?null:i},e.readNumber=function(t){var e=this.pos,n=!1;t||null!==this.readInt(10)||this.raise(e,"Invalid Number");var i=this.fullCharCodeAtPos();46===i&&(++this.pos,this.readInt(10),n=!0,i=this.fullCharCodeAtPos()),69!==i&&101!==i||(i=this.input.charCodeAt(++this.pos),43!==i&&45!==i||++this.pos,null===this.readInt(10)&&this.raise(e,"Invalid number"),n=!0),s(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number");var r,a=this.input.slice(e,this.pos);return r=n?parseFloat(a):parseInt(a,10),this.finishToken(o.num,r)},e.readString=function(t){for(var e="",n=this.start,i=++this.pos;;){this.pos>=this.input.length&&this.raise(n,"Unterminated string");var s=this.fullCharCodeAtPos();if(s===t)break;92===s?(e+=this.input.slice(i,this.pos),e+=this.readEscapedChar(),i=this.pos):(h(s)&&this.raise(n,"Unterminated string"),++this.pos)}return e+=this.input.slice(i,this.pos++),this.finishToken(o.string,e)},e.readEscapedChar=function(){var t=this.input.charCodeAt(++this.pos);switch(++this.pos,t){case 110:return"\n";case 114:return"\r";case 116:return" ";case 98:return"\b";case 118:return"\x0B";case 102:return"\f";case 13:10===this.fullCharCodeAtPos()&&++this.pos;case 10:return"";default:return String.fromCharCode(t)}},e.readWord1=function(){for(var t="",e=!0,n=this.pos;this.pos<this.input.length;){var i=this.fullCharCodeAtPos();if(r(i))++this.pos;else{if(!e||35!==i)break;++this.pos}e=!1}return t+=this.input.slice(n,this.pos)},e.readWord=function(){var t,e=this.pos,n=this.readWord1();if(this.keywords.test(n)){if(t=a[n],t.macro){var i=this.readMacro();return this.finishToken(t,i)}}else 35===n.charCodeAt(0)&&this.raise(e,"# is only valid for # macro"),t=o.name;return this.finishToken(t,n)},e.readMacro=function(){for(var t=this.pos,e=this.fullCharCodeAtPos();this.pos<this.input.length&&10!==e&&13!==e&&8232!==e&&8233!==e;)++this.pos,e=this.input.charCodeAt(this.pos);return this.input.slice(t,this.pos).trim()}}},function(t,e){function n(t){return"[object Array]"===Object.prototype.toString.call(t)}function i(t,e){return Object.prototype.hasOwnProperty.call(t,e)}t.exports={isArray:n,has:i}},function(t,e){var n={varDecl:function(t,e){var n="",i=!0;return t.declarations.forEach(function(t){t.init&&(i||(n+=","),n+="$."+t.id+" = "+e(t.init),i=!1)}),"("+n+")"},SequenceExpr:function(t,e){var n="",i=!0;return t.expressions.forEach(function(t){i||(n+=","),n+=e(t),i=!1}),"("+n+")"},literal:function(t){return t.raw},regexp:function(t){if(t.regexp.isGenerate){var e=t.regexp;return"(/"+e.pattern+"/"+e.flags+").gen()"}return"("+t.raw+")"},dictionaryIndex:function(t){return"d."+t.value},objectStore:function(t){return"o."+t.value},Identifier:function(t){return"$."+t.name},LogicalExpr:function(t,e){return e(t.left)+t.operator+e(t.right)},BinaryExpr:function(t,e){return e(t.left)+t.operator+e(t.right)},MatchExpr:function(t,e){var n="";return"~~"===t.operator&&(n+="!"),n+"!("+e(t.left)+").match("+e(t.right)+")"},UpdateExpr:function(t){var e="$."+t.argument;return t.prefix?t.operator+e:e+t.operator},UnaryExpr:function(t,e){return t.operator+"("+e(t.argument)+")"},AssignmentExpr:function(t,e){return e(t.left)+t.operator+e(t.right)},ParenthesizedExpr:function(t,e){return"("+e(t.expression)+")"},TextExpr:function(t,e){var n="String("+e(t.val)+")";return"t("+n+")"},CountExpr:function(t,e){var n="String("+e(t.val)+")";return"c("+n+")"},VisibilityExpr:function(t,e){var n="String("+e(t.val)+")";return"v("+n+")"}};t.exports=function(t){var e=function i(t){var e=t.type;return n[e](t,i)}(t);return new Function("$,o,d,c,t, v","return "+e+";")}}])});
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.LC=e():t.LC=e()}(this,function(){return function(t){function e(i){if(n[i])return n[i].exports;var s=n[i]={exports:{},id:i,loaded:!1};return t[i].call(s.exports,s,s.exports,e),s.loaded=!0,s.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){t.exports=n(15)},function(t,e){function n(t,e){var n=r.contextFrame;n.style.height="100%",n.style.width="100%",t.appendChild(n),(e||s.noop).call(n)}function i(){return r.contextFrame}var s,r,o;s={now:Date.now||function(){return(new Date).getTime()},isString:function(t){return"string"==typeof t},isUndefined:function(t){return void 0===t},isDefined:function(t){return!s.isUndefined(t)},isNumber:function(t){return"number"==typeof t},isObject:function(t){var e=typeof t;return"function"===e||"object"===e&&!!t},isElement:function(t){return!(!t||1!==t.nodeType)},isFunction:function(t){return"function"==typeof t},isArray:function(t){return"[object Array]"==={}.toString.call(t)},last:function(t){return t[t.length-1]},noop:function(){},forEach:function(t,e,n){e=e.bind(n);var i,s;if(this.isArray(t))for(i=0,s=t.length;s>i;i+=1)e(t[i],i,t);else{var r=Object.keys(t);for(i=0,s=r.length;s>i;i+=1)e(t[r[i]],r[i],t)}return t},document:function(){return r.contextFrame?r.contextFrame.contentWindow.document:document},countDOM:function(t){return s.document().querySelectorAll(t).length},getInnerHTML:function(t){var e=s.document().querySelector(t);return e?e[e.value?"value":"innerHTML"]:"Error:No such HTMLElement."},isVisible:function(t){var e=s.document().querySelector(t);return e?0!==e.offsetHeight||0!==e.offsetWidth:!1}},r={contextFrame:document.createElement("iframe"),defaultNextLoopDelay:3e3,readyTimeout:3e3,defaultClock:10,bootExceptionHandle:s.noop,triggerCallback:s.noop,runCallback:s.noop,runExceptionHandle:function(){console.log(arguments)},successCallback:s.noop,readyCallback:s.noop,nextLoopCallback:s.noop,consoleFn:s.noop},o=function(t){return s.isString(t)?r[t]:s.isObject(t)?void s.forEach(t,function(t,e){this[e]=t},r):void 0},o.setContextFrame=function(t){trigger.setupIframe(t),r.contextFrame=t},t.exports={_:s,settings:r,setup:o,init:n,getLemoncaseFrame:i}},function(t,e){function n(t,e){return new s(t,{beforeExpr:!0,binop:e})}function i(t,e){e=e||{},e.keyword=t,c[t]=a["_"+t]=new s(t,e)}var s=function(t,e){void 0===e&&(e={}),this.label=t,this.keyword=e.keyword,this.beforeExpr=Boolean(e.beforeExpr),this.isAssign=Boolean(e.isAssign),this.prefix=Boolean(e.prefix),this.postfix=Boolean(e.postfix),this.binop=e.binop||null,this.macro=Boolean(e.macro)},r={beforeExpr:!0},o={macro:!0},a={num:new s("num"),regexp:new s("regexp"),string:new s("string"),name:new s("name"),eof:new s("eof"),objectAt:new s("objectStore"),dict:new s("dictionaryIndex"),bracketL:new s("[",r),bracketR:new s("]"),braceL:new s("{",r),braceR:new s("}"),parenL:new s("(",r),parenR:new s(")"),comma:new s(",",r),semi:new s(";",r),colon:new s(":",r),tagNumL:new s("CountExpr",r),tagAtL:new s("TextExpr",r),tagFacL:new s("VisibilityExpr",r),tagR:new s("/>"),eq:new s("=",{beforeExpr:!0,isAssign:!0}),assign:new s("_=",{beforeExpr:!0,isAssign:!0}),incDec:new s("++/--",{prefix:!0,postfix:!0}),prefix:new s("prefix",{beforeExpr:!0,prefix:!0}),logicalOR:n("||",1),logicalAND:n("&&",2),equality:n("==/!=",6),relational:n("</>",7),plusMin:new s("+/-",{beforeExpr:!0,binop:9,prefix:!0}),modulo:n("%",10),star:n("*",10),slash:n("/",10),match:n("~~",6)},c={};i("in"),i("by",r),i("click",r),i("input",r),i("rclick",r),i("dblclick",r),i("movein",r),i("moveout",r),i("scroll",r),i("select",r),i("#CLOCK",o),i("#TIMES",o),i("#INTERVAL",o),i("#SCREEN",o),i("wait",r),i("assert",r),i("log",r),i("console",r),i("var"),i("process"),i("return",r),i("jumpto"),i("refresh"),t.exports={TokenType:s,types:a,keywordTypes:c}},function(t,e){t.exports={CALL:0,RETURN:1,EXIT:2,EXPRESSION:16,WAIT:17,TRIGGER:18,ASSERT:19,JUMPTO:20,REFRESH:21,LOG:32,CONSOLE:33,PROCESS:255}},function(t,e){var n=function(t,e){function n(t,e){this.$case=e,this.$body=t.BODY,this.$line=t.LINE}if(!e){var s=i[t];if(!s)throw new Error("TYPE:"+t+" instruction is not existed.");return s}if(i[t])throw new Error("The instruction factory: TYPE="+t+" is existed.");return n.prototype.execute=e.operation,n.prototype.line=function(){return this.$line},n.prototype.body=function(t){return t?this.$body[t]:this.$body},n.prototype.assignCase=function(t){return this.$case=t,this},n.create=function(){return new n({BODY:e.bodyFactory.apply(null,arguments)})},n.$new=function(t,e){return new n(t,e)},i[t]=n,n},i=[];t.exports=n},function(t,e,n){function i(t,e,n,i){var s={process:{},config:{}},r=[];return c.forEach(t.DATA_KEYS,function(t,e){t&&r.push(e)}),c.forEach(t.DICTIONARY_KEYS,function(t,e){if(!n.isFieldDefined(e))throw new Error("The field: "+e+" is undefined in dictionary.")}),c.forEach(t.OBJECT_KEYS,function(t,n){if(!e.hasOwnProperty(n))throw new Error("The key: "+n+" is undefined in object.")}),c.forEach(t.PROCESSES,function(t,e){var n=s.process[e]=[];c.forEach(t.BODY.segment,function(t){n.push(p(t.TYPE).$new(t,i))})}),s.config.times=t.CONFIG.times,s.config.interval=t.CONFIG.interval,s.config.screen=t.CONFIG.screen,{eT:s,dK:r}}function s(t,e,n){if(!(this instanceof s))return new s(t,e,n);var r=i(t,e,n,this);this.$$executionTree=r.eT,this.$dictionary=n,this.$objectList=e,this.$$log=new u(r.dK),this.$$state="ready",this.$$coreId=null,this.$$activeTime=0,this.$$currentLoop=0,this.$$vars={},this.$$blockStack=[],this.$$scopeStack=[],this.$$lastInstruction=void 0,this.$$instructionBuffer=void 0,this.$$tempInstruction=void 0,this.$$idleTask=c.noop,this.$loopData=null}var r=n(3).CALL,o=n(3).EXIT,a=n(1),c=a._,h=a.settings,u=n(10),p=n(4),f=s.prototype;f.$$getConfig=function(t){return this.$$executionTree.config[t]},f.$$bootstrap=function(){var t=h.contextFrame.style,e=this.$$getConfig("screen");return this.$$currentLoop=0,this.hasDictionary()&&(this.$loopData=this.$dictionary.load(this.$$getConfig("times")).fetch()),e&&(t.height=e.height+"px",t.width=e.width+"px"),this.$setActiveTime().$setTempInstruction(p(r).create("main")).$$log.initialization(),this},f.$$exitCase=function(){return this.$setState("success").$$interrupt(),(h.successCallback||c.noop).call(this),this},f.$$interrupt=function(){return clearInterval(this.$$coreId),this},f.$$popInstruction=function(){var t=this.$$tempInstruction,e=this.$getCurrentBlock();return this.$$lastInstruction=this.$$instructionBuffer,t?(this.$setTempInstruction(),t):e?(this.$$instructionBuffer=e.segment[e.counter++],this.$$instructionBuffer):p(o).create(!0).assignCase(this)},f.$$run=function(){try{this.$$popInstruction().execute(),h.runCallback(this)}catch(t){console.error("[Error FROM LC2 Core]:"+t)}return this},f.$$core=function(){var t=this;return this.$$coreId=setInterval(function(){t["$$"+(c.now()>=t.$$activeTime?"run":"idleTask")]()},this.$$getConfig("clock")||h.defaultClock),this},t.exports={Case:s,$CP:f}},function(t,e,n){function i(t){return this instanceof i?(this.$options={},this.$$buffer=[],this.$assignment=[],this.$field=[],this.field(t.field),void this.assignment(t.assignment)):new i(t)}var s=n(1)._;i.prototype.field=function(t){return s.isArray(t)&&(this.$field=t),this.$options.field=this.$field,this.$field},i.prototype.assignment=function(t){return s.isArray(t)&&(this.$assignment=t),this.$options.assignment=this.$assignment,this.$assignment},i.prototype.load=function(t){var e,n=this.$assignment.length,i=this.getKeys(),r=(i.length,function(t){s.forEach(i,function(e,n){this[e.name]=t[n]},this)}),o=function(){s.forEach(i,function(t){this[t.name]=t.pattern.gen()},this)};for(this.$$buffer=[],e=0;n>e&&t>e;e+=1)this.$$buffer.push(new r(this.$assignment[e]));for(null;t>e;e+=1)this.$$buffer.push(new o);return this},i.prototype.getKeys=function(){var t=[];return s.forEach(this.$field,function(t){this.push({name:t.name,pattern:new RegExp(t.pattern)})},t),t},i.prototype.fetch=function(){return this.$$buffer.shift()},i.prototype.isFieldDefined=function(t){var e,n=this.$field.length;for(e=0;n>e;e+=1)if(this.$field[e].name===t)return!0;return!1},t.exports=i},function(t,e){function n(t){return 65>t?36===t:91>t?!0:97>t?95===t:123>t}function i(t){return 48>t?36===t:58>t?!0:65>t?!1:91>t?!0:97>t?95===t:123>t}var s=["in","by"],r=["click","input","rclick","dblclick","movein","moveout","scroll","select","jumpto","refresh"],o=["#CLOCK","#TIMES","#INTERVAL","#SCREEN"],a=["wait","assert","log","console","var","process","return"].concat(s).concat(r).concat(o),c=new RegExp("^("+a.join("|")+")$");t.exports={keywordRegexp:c,isIdentifierStart:n,isIdentifierChar:i}},function(t,e,n){function i(t,e){for(var n=1,i=0;;){c.lastIndex=i;var s=c.exec(t);if(!(s&&s.index<e))return new h(n,e-i);++n,i=s.index+s[0].length}}function s(t,e,n){var i=t.split(c)[e.line-1],s=i.substr(0,e.column),h=a(s),u=r(h),p=o(n,h);return"\n"+i+"\n"+u+"\n"+p}function r(t){for(var e=-1,n=-1,i="";++e<t;)i+=" ";for(i+="↑\n";++n<t;)i+=" ";return i+="↑"}function o(t,e){if(t.length/2>e)return t;for(var n=-1,i=e-Math.floor(t.length/2),s="";++n<i;)s+=" ";return s+=t}function a(t){for(var e,n=0,i=-1,s=t.length;++i<s;)switch(e=t.charCodeAt(i)){case 9:n+=4;break;default:n+=1}return n}var c=n(9).lineBreakG,h=function(t,e){this.line=t,this.column=e};h.prototype.offset=function(t){return new h(this.line,this.column+t)},t.exports={getLineInfo:i,empowerErrMsg:s}},function(t,e){var n=/\r\n?|\n|\u2028|\u2029/;t.exports={lineBreak:n,lineBreakG:new RegExp(n.source,"g"),isNewLine:function(t){return 10===t||13===t||8232===t||8233===t}}},function(t,e,n){var i=n(1)._,s=function(t){this.$$baseTime=0,this.$dataKeys=t||[],this.$marks=[],this.$logs=[],this.$datas={}};s.prototype.initialization=function(){return this.clear(),this.$$baseTime=i.now(),i.forEach(this.$dataKeys,function(t){this[t]=[]},this.$datas),this},s.prototype.getLength=function(t){return this["$"+t].length},s.prototype.log=function(t,e){return this.$logs.push([t,i.now()-this.$$baseTime,e||0]),this},s.prototype.data=function(t,e){return this.$datas[t].push(e),this},s.prototype.markLog=function(t,e){return this.$marks.push([t,e,this.getLength("logs")-1]),this},s.prototype.clear=function(){return this.$$baseTime=0,this.$marks.length=0,this.$logs.length=0,this.$datas={},this},s.prototype.export2json=function(){return{baseTime:this.$$baseTime,marks:this.$marks,logs:this.$logs,performance:this.$datas}},s.prototype.export2text=function(){return JSON.stringify(this.export2json())},t.exports=s},function(t,e){!function(){var e={POSITION:0,CLASS:2,RANGE:3,CLAUSE:6,REFERENCE:7,INTS:"0123456789",WORDS:"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789",WHITESPACE:" \f\n\r \x0B  ᠎           \u2028\u2029\u2028\u2029   "},n="@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^ ?",i={0:0,t:9,n:10,v:11,f:12,r:13},s={rndChar:function(t){return t[Math.floor(Math.random()*t.length)]},anyRndChar:function(){return String.fromCharCode(s.rndInt(0,65535))},strToChars:function(t){var e=/\\(?:u([A-F0-9]{4})|x([A-F0-9]{2})|(0?[0-7]{2})|c([@A-Z\[\\\]^?])|([0tnvfr]))/g;return t=t.replace(e,function(t,e,s,r,o,a){var c,h=e?parseInt(e,16):s?parseInt(s,16):r?parseInt(r,8):o?n.indexOf(o):a?i[a]:void 0;return void 0!==h?(c=String.fromCharCode(h),c=c.replace(/[[\]{}^$.|?*+()]/g,function(t){return"\\"+t})):c="\\"+a,c})},rndInt:function(t,e){return t+Math.floor(Math.random()*(1+e-t))},findChar:function(t){for(var e="\\",n="]",i=0;;){var s=t.indexOf(n);if(t[s-1]!==e)return i+s;t=t.slice(++s),i+=s}},range:function(t,n,i){var s=e.WORDS;return s.slice(s.indexOf(n),s.indexOf(i)+1)},classRange:function(t){return t.replace(/(\w)-(\w)/g,s.range)},toBothCases:function(t){var e=t;return e+=t["to"+(t===t.toLowerCase()?"Upper":"Lower")+"Case"]()},inCaseClass:function(t,e){return e?t=t.replace(/[a-zA-Z]/g,function(t){return s.toBothCases(t)}):t},inCaseChar:function(t,n){return n&&/[a-zA-Z]/.test(t)?{type:e.CLASS,chars:s.toBothCases(t)}:t},flatten:function(t){for(var e=0;e<t.length-1;e++)if("string"==typeof t[e])for(var n=e+1;;){var i=t[n];if("string"!=typeof i)break;t[e]+=i,t.splice(n,1)}return 1===t.length?t[0]:t},reduce:function(t){if(t.stack)t.stack=s.flatten(t.stack);else if(t.options)for(var e=0,n=t.options.length;n>e;e++)t.options[e]=s.flatten(t.options[e]);return t.options||t.group||t.value?t:t.stack},nextClose:function(t){for(var e=0,n=0,i=t.length;i>n;n++){var s=t[n];switch(s){case")":if(0===e)return n+1;e--;break;case"(":e++;break;case"\\":n++}}}},r={type:e.POSITION,value:"b"},o={type:e.POSITION,value:"B"},a={type:e.POSITION,value:"^"},c={type:e.POSITION,value:"$"},h={type:e.CLASS,chars:e.WORDS},u={type:e.CLASS,chars:e.WORDS,not:!0},p={type:e.CLASS,chars:e.INTS},f={type:e.CLASS,chars:e.INTS,not:!0},l={type:e.CLASS,chars:e.WHITESPACE},d={type:e.CLASS,chars:e.WHITESPACE,not:!0},v={type:e.CLASS,chars:"\n",not:!0},g=function(t,n,i){var g,$=0,m={type:e.CLAUSE,stack:[]},x=m,y=m.stack,b=[];for(t=s.strToChars(t);$<t.length;)switch(g=t[$++]){case"\\":switch(g=t[$++]){case"b":y.push(r);break;case"B":y.push(o);break;case"w":y.push(h);break;case"W":y.push(u);break;case"d":y.push(p);break;case"D":y.push(f);break;case"s":y.push(l);break;case"S":y.push(d);break;default:/\d/.test(g)?y.push({type:e.REFERENCE,value:parseInt(g)}):y.push(g)}break;case"^":y.push(a);break;case"$":y.push(c);break;case"[":if(g=t[$],"\\"===g&&0===t.slice($+1).indexOf("b]"))$+=3,y.push("\b");else{var E;"^"===g?(E=!0,$++):E=!1;var k=t.slice($),C=s.findChar(k),w=k.substring(0,C);$+=C+1,y.push({type:e.CLASS,chars:s.inCaseClass(s.classRange(w),n),not:E})}break;case".":y.push(v);break;case"(":g=t[$];var T;if("?"===g){if(g=t[$+1],$+=2,"!"===g){$+=s.nextClose(t.slice($));break}T=!1}else T=!0;var S={type:e.CLAUSE,group:T,stack:[]};y.push(S),b.push(x),x=S,y=S.stack;break;case")":x=b.pop(),y=x.options?x.options[x.options.length-1]:x.stack;var O=y.length-1;y[O]=s.reduce(y[O]);break;case"|":x.options||(x.options=[x.stack],delete x.stack);var L=[];x.options.push(L),y=L;break;case"{":var A=/^(\d+)(,(\d+)?)?\}/.exec(t.slice($)),I=parseInt(A[1]),R=A[2]?A[3]?parseInt(A[3]):1/0:I;$+=A[0].length;var B=y.pop();if(I===R)for(var D=0;I>D;D++)y.push(B);else y.push({type:e.RANGE,min:I,max:R,value:B});break;case"?":var B=y.pop();y.push({type:e.RANGE,min:0,max:1,value:B});break;case"+":var B=y.pop();y.push({type:e.RANGE,min:1,max:1/0,value:B});break;case"*":var B=y.pop();y.push({type:e.RANGE,min:0,max:1/0,value:B});break;default:y.push(s.inCaseChar(g,n))}return s.reduce(m)},$=function(t,n,i,r){if("string"==typeof t)return t;if(t.length){for(var o="",a=0,c=t.length;c>a;a++)o+=$(t[a],n,i,r);return o}switch(t.type){case e.POSITION:return"";case e.CLASS:if(!t.not)return s.rndChar(t.chars);for(;;){var h=i();if(-1===t.chars.indexOf(h))return h}case e.RANGE:for(var u=s.rndInt(t.min,t.max===1/0?t.min+n:t.max),o="",a=0;u>a;a++)o+=$(t.value,n,i,r);return o;case e.CLAUSE:if(t.options){var u=s.rndInt(0,t.options.length-1);return $(t.options[u],n,i,r)}var p=$(t.stack,n,i,r);return r.push(p),p;case e.REFERENCE:return r[t.value-1]}};RegExp.prototype.gen=function(){return void 0===this._randexp&&(this._randexp=g(this.source,this.ignoreCase,this.multiline),this._max=this._max||100,this._anyRndChar=this._anyRndChar||s.anyRndChar),$(this._randexp,this._max,this._anyRndChar,[])},"undefined"==typeof window&&(t.exports=$)}()},function(t,e){!function(){"use strict";function e(t,e,n){var i,s=[t];for(i in n)n.hasOwnProperty(i)&&(s[n[i]]=e[i]||null);return s}function n(t){return 1===t.nodeType}function i(t){return t instanceof Window}function s(t){return null!==t&&"object"==typeof t}function r(t){return"function"==typeof t}function o(t,e){e?t.$$hashKey=e:delete t.$$hashKey}function a(t,e){var n,i,a,c,h,u,p,f,l=t.$$hashKey;if(e)for(i=0,n=e.length;n>i;++i)if(p=e[i],s(p)||r(p))for(f=Object.keys(p),c=0,a=f.length;a>c;c++)h=f[c],u=p[h],t[h]=u;return o(t,l),t}function c(t){return a(t,[].slice.call(arguments,1),!1)}function h(t,e,n){v&&t.dispatchEvent(new E(e,c({},L,n)))}function u(t,e,n){t.dispatchEvent(new C(e,c({},L,n)))}function p(t,e,n){t.dispatchEvent(new T(e,c({},L,n)))}function f(t){this.element=t,this.action=this.getActionRule(t)}var l,d=!0,v=!0,g=!0;try{l=new MouseEvent("click",{})}catch($){d=!1}try{TouchEvent}catch(m){v=!1}try{InputEvent}catch(x){g=!1}console.log(d),console.log(v);var y,b,E=function(t,n){var i=document.createEvent("UIEvent"),s={bubbles:1,cancelBubble:2,view:3,detail:4};return i.initUIEvent.apply(i,e(t,n,s)),i},k=d&&!v?Event:function(t,n){var i=document.createEvent("Event"),s={bubbles:1,cancelBubble:2};return i.initEvent.apply(i,e(t,n,s)),i},C=d&&!v?MouseEvent:function(t,n){var i=document.createEvent("MouseEvent"),s={bubbles:1,cancelBubble:2,view:3,detail:4,screenX:5,screenY:6,clientX:7,clientY:8,ctrlKey:9,altKey:10,shiftKey:11,metaKey:12,button:13,relatedTarget:14};return i.initMouseEvent.apply(i,e(t,n,s)),i},w=d&&!v?UIEvent:function(t,n){var i=document.createEvent("UIEvent"),s={bubbles:1,cancelBubble:2,view:3,detail:4};return i.initUIEvent.apply(i,e(t,n,s)),i},T=d?KeyboardEvent:function(t,n){var i=document.createEvent("KeyboardEvent"),s={bubbles:1,cancelBubble:2,view:3,"char":4,key:5,location:6,repeat:8};return i.initKeyboardEvent.apply(i,e(t,n,s)),i},S=(g?InputEvent:w,{contextIframe:null,window:function(){return S.contextIframe?S.contextIframe.contentWindow:window}}),O=[],L={bubbles:!0,cancelBubble:!0},A=0,I=1,R=2,B=3,D=4,N=5,_=6,P=7,Y=8,F=9,M=16,U=17,j=18,G=32,W=33,K=34,H=36,q=48,V=49;O[A]=function(t){h(this,"touchend",t),u(this,"mouseup",t)},O[I]=function(t){h(this,"touchstart",t),u(this,"mousedown",t)},O[R]=function(t){u(this,"mouseenter",t)},O[B]=function(t){u(this,"mouseleave",t)},O[D]=function(t){u(this,"mouseout",t)},O[N]=function(t){u(this,"mouseover",t)},O[_]=function(t){h(this,"touchmove",t),u(this,"mousemove",t)},O[P]=function(t){u(this,"click",t)},O[Y]=function(t){u(this,"dblclick",t)},O[F]=function(t){u(this,"contextmenu",t)},O[U]=function(t){p(this,"keydown",t)},O[j]=function(t){p(this,"keypress",t)},O[M]=function(t){p(this,"keyup",t)},O[K]=function(){this.focus()},O[W]=function(t){var e=S.contextIframe.style;e.width=t.width+"px",e.height=t.height+"px"},O[G]=function(t){S.window().scrollTo(t.x,t.y),this.dispatchEvent(new w("scroll"))},O[H]=function(t){var e=this[t.index];O[I].call(e,t),O[A].call(e,t),e.selected=!0,this.dispatchEvent(new w("select")),O[P].call(e,t),O[D].call(e,t)},O[q]=function(t){this.value=t.value,this.dispatchEvent(new w("input",t))},O[V]=function(){this.dispatchEvent(new k("change",{bubbles:!0}))},f.prototype.getActionRule=function(t){return t=t||this.element,t instanceof Window?b.window:"input"===t.tagName.toLowerCase()?b["input/"+t.type]:"textarea"===t.tagName.toLowerCase()?b.textarea:"select"===t.tagName.toLowerCase()?b.select:b.generic},f.prototype.does=function(t,e){var n,i,s;if(this.testAction(t)!==!0)throw"The element:"+this.element.outerHTNL+" can not use action:"+t;for(s=this.action[t],i=s.length,n=0;i>n;n+=1)O[s[n]].call(this.element,e||{});return this},f.prototype.testAction=function(t){return this.action.hasOwnProperty(t)},b=function(){var t={};return t["input/checkbox"]=t["input/radio"]=t["input/button"]=t.generic={click:[I,_,A,P],dblclick:[I,A,P,I,A,P,Y],rclick:[I,A,F],movein:[N,D],moveout:[_,D],scroll:[G]},t.textarea=t["input/text"]=t["input/password"]=t["input/email"]=c({},t.generic,{input:[K,U,j,q,M,V],click:[I,K,_,A,P],dblclick:[I,K,_,A,P,I,_,A,P,Y],rclick:[I,K,A,F]}),t.select=c({},t.generic,{select:[I,K,_,A,P,_,D,H]}),t.window={scroll:[G],resize:[W]},t}(),y=function(t){if(!i(t)&&!n(t))throw'"element" for trigger must be a HTMLElement';return new f(t)},y.setupIframe=function(t){if(!(t instanceof HTMLIFrameElement))throw'"element" must be a iframe element.';S.contextIframe=t},"undefined"!=typeof t&&t.exports?t.exports=y:window.trigger=y}()},function(t,e,n){var i=n(5).$CP,s=n(1),r=s._,o=s.settings,a=n(4),c=n(3).CALL;i.$setIdleTask=function(t){return this.$$idleTask=r.isFunction(t)?t:r.noop,this},i.$setActiveTime=function(t){return this.$$activeTime=r.now()+(t||0),this},i.$setTempInstruction=function(t){return this.$$tempInstruction=t?t.assignCase(this):void 0,this},i.$setState=function(t){return this.$$state=t,this},i.$pushBlock=function(t){return this.$$blockStack.push({counter:0,segment:t}),this},i.$pushScope=function(t){var e=this.$$blockStack;return this.$$scopeStack.push({blockIndex:e.length,vars:{}}),this.$pushBlock(this.$getProcess(t)),this},i.$popBlock=function(){return this.$$blockStack.pop(),this},i.$popScope=function(){var t=this.$$scopeStack.pop();return this.$$blockStack.length=t.blockIndex,this},i.$getCurrentBlock=function(){return r.last(this.$$blockStack)},i.$getCurrentScope=function(){return r.last(this.$$scopeStack)},i.$getProcess=function(t){return this.$$executionTree.process[t]},i.$exitLoop=function(){return this.$setActiveTime(this.$$getConfig("interval")||3e3),(this.$$currentLoop+=1)>=this.$$getConfig("times")?(this.$$exitCase(),this):(this.$setTempInstruction(a(c).create("main")),(o.nextLoopCallback||r.noop).call(this),this.hasDictionary()&&(this.$loopData=this.$dictionary.fetch()),this)},i.$runExp=function(t){return"function"==typeof t?t(this.$$vars,this.$objectList,this.$loopData,r.countDOM,r.getInnerHTML,r.isVisible):t},i.$pushLog=function(t,e){return this.getLog().log(t,e),this},i.$markLog=function(t,e){return this.getLog().markLog(t,e),this},i.$pushLogData=function(t,e){return this.getLog().data(t,e),this},i.$clearScope=function(){for(;this.$$scopeStack.length;)this.$popScope();return this},t.exports=i},function(t,e,n){var i=n(5).$CP,s=n(1).settings,r=n(6);i.hasDictionary=function(){return!!this.$dictionary},i.validateObjectList=function(t,e){return e.length?t?e.every(function(e){return null!==t[e]}):!1:!0},i.exportLog=function(t){return this.$$log["export2"+t]()},i.start=function(){var t=this.$$state;if("success"!==t&&"ready"!==t)throw new Error("Can not call play!");try{return this.$setState("running").$$bootstrap(),setTimeout(function(){this.$$core()}.bind(this),s.readyTimeout),this}catch(e){s.bootExceptionHandle(e)}},i.forceCofig=function(t){var e,n=this.$$executionTree.config;for(e in t)t.hasOwnProperty(e)&&(n[e]=t[e]);return this},i.suspend=function(){if("running"!==this.$$state)throw new Error("Can not call pause!");return this.$setState("pause").$$interrupt(),this},i.resume=function(){if("pause"!==this.$$state)throw new Error("Can not call resume!");return this.$setState("running").$$core(),this},i.stop=function(){var t=this.$$state;if("running"!==t&&"pause"!==t)throw new Error("Can not call stop!");return this.$setState("ready").$$interrupt(),this},i.debug=function(){var t=this.$$state;if("success"!==t&&"ready"!==t)throw new Error("Can not call play!");return this.$setState("debug").$$bootstrap(),this},i.dictionary=function(t){return t instanceof r&&(this.$dictionary=t),this.$dictionary},i.getLog=function(){return this.$$log},i.getCurrentStep=function(){return this.$$counter},i.getCurrentLoop=function(){return this.$$currentLoop},i.getCurrentLine=function(){return this.$$instructionBuffer.$getLine()},i.getStatus=function(){return{loop:this.$$currentLoop,line:this.getCurrentLine(),state:this.$$state}},t.exports=i},function(t,e,n){var i=n(18).parse,s=n(5).Case,r=n(1).setup,o=n(4),a=n(6),c=n(1),h=c.init,u=c.getLemoncaseFrame;n(13),n(14),n(11),n(16);var e={Case:s,setup:r,Instruction:o,parse:i,Dictionary:a,init:h,getLemoncaseFrame:u};t.exports=e},function(t,e,n){var i=n(4),s=n(1),r=s.settings,o=s._,a=n(3),c=a.CALL,h=a.RETURN,u=a.EXIT,p=a.EXPRESSION,f=a.WAIT,l=a.TRIGGER,d=a.ASSERT,v=a.JUMPTO,g=a.REFRESH,$=a.LOG,m=a.CONSOLE,x=(a.PROCESS,1),y=0,b=n(12);i(c,{operation:function(){var t=this.body("identifier");this.$case.$pushScope(t).$pushLog([c,t],this.line())},bodyFactory:function(t){return{identifier:t}}}),i(h,{operation:function(){this.$case.$pushLog([h]).$popScope()},bodyFactory:function(){return{}}}),i(u,{operation:function(){var t=this.body("isSuccess")?x:y,e=this.$case;this.body("preFn")(),t||r.runExceptionHandle(this.$case),e.$pushLog([u,t],this.line()).$markLog(t,e.getCurrentLoop()).$clearScope().$exitLoop()},bodyFactory:function(t,e){return{isSuccess:t,preFn:e||o.noop}}}),i(p,{operation:function(){this.$case.$runExp(this.body("exp"))},bodyFactory:function(t){return{exp:t}}}),i(f,{operation:function(){var t=this.$case.$runExp(this.body("delay"));this.$case.$setActiveTime(t).$pushLog([f,t],this.line())},bodyFactory:function(t){return{delay:t}}}),i(l,{operation:function(){var t,e=this.$case.$runExp(this.body("object")),n={value:this.$case.$runExp(this.body("param"))},s=this.body("action");try{if(t=o.document().querySelectorAll(e)[0],!t)throw"Can not find a DOM by cssPath: "+e}catch(a){return console.log(a),void this.$case.$pushLog([l,y,e,s,n],this.line()).$setTempInstruction(i(u).create(!1).assignCase(this.$case))}b(t).does(s,n),r.triggerCallback(t,this.$case),this.$case.$pushLog([l,x,e,s,n],this.line())},bodyFactory:function(t,e,n){return{object:t,action:e,param:n}}}),i(d,{operation:function(){function t(){a.$runExp(n)&&a.$setIdleTask().$setTempInstruction().$setActiveTime().$pushLog([d,x],c.line()).$pushLogData(c.body("key"),o.now()-e)}var e=o.now(),n=this.body("exp"),s=this.body("timeout"),a=this.$case,c=this;a.$setTempInstruction(i(u).create(!1,function(){a.$pushLog([d,y],c.line())}).assignCase(a)),s&&s>2*r.defaultClock&&a.$setActiveTime(s).$setIdleTask(t),a.$runExp(n)&&(a.$setTempInstruction().$setActiveTime().$setIdleTask().$pushLog([d,x],this.line()),s&&a.$pushLogData(c.body("key"),0))},bodyFactory:function(t,e,n){return{exp:t,timeout:e,key:n}}}),i(v,{operation:function(){var t=this.$case.$runExp(this.body("url"));r.contextFrame.src=t,this.$case.$pushLog([v,t],this.line())}}),i(g,{operation:function(){o.document().location.reload(),this.$case.$pushLog([g],this.line())}}),i($,{operation:function(){this.$case.$pushLog([$,this.$case.$runExp(this.body("msg"))])},bodyFactory:function(t){return{msg:t}}}),i(m,{operation:function(){var t=this.$case.$runExp(this.body("msg"));console.log(t),r.consoleFn(t)},bodyFactory:function(t){return{msg:t}}})},function(t,e,n){var i=n(2).types;t.exports=function(t){var e=t.prototype;e.parseExpression=function(){var t=this.parseMaybeAssign();if(this.type===i.comma){var e={type:"SequenceExpr"};for(e.expressions=[t];this.eat(i.comma);){var n=this.parseMaybeAssign();e.expressions.push(n)}return e}return t},e.parseMaybeAssign=function(){var t=this.parseMaybeConditional();if(this.type.isAssign){var e={type:"AssignmentExpr",left:t,operator:this.value};return this.next(),e.right=this.parseMaybeAssign(),e}return t},e.parseMaybeConditional=function(){return this.parseExprOps()},e.parseExprOps=function(){var t=this.start,e=this.parseMaybeUnary(!1);return this.parseExprOp(e,t,-1)},e.parseExprOp=function(t,e,n){var i=this.type.binop;if(null!=i&&i>n){var s=this.type,r=this.value;this.next();var o=this.start,a=this.parseExprOp(this.parseMaybeUnary(!1),o,i),c=this.buildBinary(e,t,a,r,s);return this.parseExprOp(c,e,n)}return t},e.buildBinary=function(t,e,n,s,r){var o={left:e,operator:s,right:n};return r===i.logicalAND||r===i.logicalOR?o.type="LogicalExpr":r===i.match?o.type="MatchExpr":o.type="BinaryExpr",o},e.parseMaybeUnary=function(t){var e;if(this.type.prefix){var n={},s=this.type===i.incDec;n.operator=this.value,n.prefix=!0,this.next(),n.argument=this.parseMaybeUnary(!1),s||(t=!0),n.type=s?"UpdateExpr":"UnaryExpr",e=n}else for(e=this.parseExprSubscripts();this.type.postfix;){var r={};r.operator=this.value,r.prefix=!1,r.argument=e,this.next(),r.type="UpdateExpr",e=r}return e},e.parseExprSubscripts=function(){var t=this.start,e=this.parseExprAtom();return this.parseSubscripts(e,t)},e.parseSubscripts=function(t,e){for(;;){if(this.eat(i.parenL)){var n={type:"CallExpr",callee:t};return this.expect(i.parenR),n}return t}},e.parseExprAtom=function(){var t;switch(this.type){case i.name:var e=this.parseIndent(this.type!==i.name);return{type:"Identifier",name:e};case i.regexp:var n=this.value;return t=this.parseLiteral("regexp"),t.regexp=n,t;case i.num:case i.string:return this.parseLiteral("literal",this.value);case i.objectAt:case i.dict:return this.parseExtLiteral(this.type);case i.parenL:return this.parseParenExpression();case i.tagAtL:case i.tagNumL:case i.tagFacL:return this.parseTagExpression();default:this.unexpected()}},e.parseLiteral=function(t,e){var n={type:t,value:e,raw:this.input.slice(this.start,this.end)};return this.next(),n},e.parseExtLiteral=function(t){var e={type:t.label,value:this.value};return this.next(),e},e.parseParenExpression=function(){this.expect(i.parenL);var t=this.parseExpression();return this.expect(i.parenR),{type:"ParenthesizedExpr",expression:t}},e.parseTagExpression=function(){var t={type:this.type.label};return this.next(),t.val=this.parseExpression(),this.expect(i.tagR),t},e.parseIndent=function(){var t;return this.type===i.name?t=this.value:this.unexpected(),this.next(),t}}},function(t,e,n){var i=n(23);t.exports={parse:function(t,e){return new i(e,t).parse()},tokenizer:function(t,e){return new i(e,t)}}},function(t,e,n){var i=n(8),s=i.getLineInfo,r=i.empowerErrMsg;t.exports=function(t){var e=t.prototype;e.raise=function(t,e){var n=s(this.input,t);e+=" ("+n.line+":"+n.column+")",e=r(this.input,n,e);var i=new SyntaxError(e);throw i.pos=t,i.loc=n,i.raisedAt=this.pos,i}}},function(t,e,n){var i=n(2).types;t.exports=function(t){var e=t.prototype;e.parseBindingList=function(t,e,n){for(var s=[],r=!0;!this.eat(t);)if(r?r=!1:this.expect(i.comma),e&&this.type===i.comma)s.push(null);else{if(n)break;var o=this.parseIndent();s.push(o)}return s}}},function(t,e,n){function i(t){var e={};for(var n in r)e[n]=t&&s(t,n)?t[n]:r[n];return e}var s=n(26).has,r={insertReturn:!0,onComment:function(){},plugins:{}};t.exports={defaultOptions:r,getOptions:i}},function(t,e,n){var i=n(2).types;t.exports=function(t){var e=t.prototype;e.eat=function(t){return this.type===t?(this.next(),!0):!1},e.semicolon=function(){this.eat(i.semi)||this.expected(i.semi)},e.expect=function(t){this.eat(t)||this.expected(t)},e.unexpected=function(t){this.raise(null!=t?t:this.start,"Unexpected token")},e.expected=function(t){this.raise(this.lastTokEnd,'Expect a "'+t.label+'" after')},e.UID=function(t){return t+this.nextID++}}},function(t,e,n){var i=n(21).getOptions,s=n(7).keywordRegexp,r=n(2).types,o=function(t,e){this.options=i(t),this.keywords=s,this.input=String(e),this.pos=0,this.type=r.eof,this.value=null,this.start=this.end=this.pos,this.lastTokStart=this.lastTokEnd=this.pos,this.exprAllowed=!1,this.labels=[],this.conf={},this.keys={},this.nextID=0,this.pcs={},this.pcsTable={},this.dTable={},this.obTable={}};o.prototype.parse=function(){this.nextToken();var t={CONFIG:this.conf,DATA_KEYS:this.keys,PROCESSES:this.pcs,DICTIONARY_KEYS:this.dTable,OBJECT_KEYS:this.obTable};return this.parseTopLevel(t)};var a=function(t){t(o)};a(n(19)),a(n(25)),a(n(24)),a(n(22)),a(n(17)),a(n(20)),t.exports=o},function(t,e,n){var i=n(2).types,s=n(8).getLineInfo,r=n(27),o=n(3);t.exports=function(t){var e=t.prototype;e.parseTopLevel=function(t){var e=this.pcsTable;for(e.main={pos:0};this.type!==i.eof;)this.parseStructure();for(var n in e)e[n]&&this.raise(e[n].pos,"Invalid process call at");return t},e.parseStructure=function(){var t=this.type;return t.macro?this.parseSet():t===i._process?this.parseProcess():void this.raise(this.start,"Expect a macro or process")},e.parseSet=function(){var t=this.type;t.macro||this.unexpected();var e=t.label.substr(1).toLowerCase();this.writeConfig(e),this.next()},e.writeConfig=function(t){var e,n=this.conf;switch(n[t]&&this.raise(this.start,this.type.keyword+" was defined already"),t){case"screen":var i,s,r=this.value.split(",");2!==r.length&&this.raise("Invalid arguments"),i=~~parseInt(r[0],10),s=~~parseInt(r[1],10),e={width:i,height:s};break;default:e=parseInt(this.value,10)}n[t]=e},e.parseProcess=function(){var t={LINE:s(this.input,this.start),TYPE:o.PROCESS,BODY:{}},e=this.pcs,n=this.pcsTable;this.next();var i=this.parseIndent();
e[i]&&this.raise(this.start,i+" process was defined already"),e[i]=t,n[i]=!1,this.parsePcParam(t),this.parsePcBlock(t)},e.parsePcParam=function(t){this.eat(i.parenL)&&(t.BODY.params=this.parseBindingList(i.parenR,!1,!1))},e.parsePcBlock=function(t){var e=this.parseBlock();e.length&&e[e.length-1].TYPE===o.RETURN||e.push({LINE:-1,TYPE:o.RETURN}),t.BODY.segment=e},e.parseBlock=function(){this.expect(i.braceL);for(var t=[];!this.eat(i.braceR);){var e=this.parseStatement(!0);t.push(e)}return t},e.parseStatement=function(){var t=this.type,e=this.startNode();switch(t){case i._click:case i._rclick:case i._dblclick:case i._movein:case i._moveout:return this.parseMouseAction(e,t.keyword);case i._select:return this.parseSelectAction();case i._scroll:return this.parseScrollAction(e,t.keyword);case i._input:return this.parseInputAction(e,t.keyword);case i._return:return this.parseReturnStatement(e);case i._wait:return this.parseWaitStatement(e);case i._assert:return this.parseAssertStatement(e);case i._log:case i._console:return this.parseLogStatement(e,t===i._log?o.LOG:o.CONSOLE);case i._jumpto:return this.parseGotoStatement(e);case i._refresh:return this.parseRefreshStatement(e);case i._var:return this.parseVarStatement(e);case i.name:return this.parseExprStatement(e);default:this.unexpected()}},e.parseReturnStatement=function(t){return this.next(),this.eat(i.semi)?t.args=null:this.raise(this.start,"Return expression is not supported"),this.finishNode(t,o.RETURN)},e.parseVarStatement=function(t){return this.next(),this.parseVar(t),t.BODY.exp=r(t.BODY.raw),this.semicolon(),this.finishNode(t,o.EXPRESSION)},e.parseVar=function(t){for(var e=[];;){var n={};if(n.id=this.parseIndent(),this.eat(i.eq)?n.init=this.parseMaybeAssign():n.init=null,e.push(n),!this.eat(i.comma))break}t.BODY.raw={declarations:e,type:"varDecl"}},e.parseExprStatement=function(t){var e=this.parseExpression();if(this.semicolon(),"CallExpr"===e.type){var n=e.callee.name;return this.pcsTable[n]!==!1&&(this.pcsTable[n]={pos:this.lastTokStart}),t.BODY.identifier=n,this.finishNode(t,o.CALL)}var i=r(e);return t.BODY.raw=e,t.BODY.exp=i,this.finishNode(t,o.EXPRESSION)},e.parseWaitStatement=function(t){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.delay=r(t.BODY.raw),this.semicolon(),this.finishNode(t,o.WAIT)},e.parseMouseAction=function(t,e){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.object=r(t.BODY.raw),t.BODY.action=e,this.semicolon(),this.finishNode(t,o.TRIGGER)},e.parseScrollAction=function(t,e){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.object=r(t.BODY.raw),this.expect(i._by),t.BODY.raw1=this.parseExpression(),t.BODY.param=r(t.BODY.raw1),t.BODY.action=e,this.finishNode(t,o.TRIGGER)},e.parseSelectAction=function(){this.raise("work in progress...")},e.parseInputAction=function(t,e){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.object=r(t.BODY.raw),this.expect(i._by),t.BODY.raw1=this.parseExpression(),t.BODY.param=r(t.BODY.raw1),t.BODY.action=e,this.semicolon(),this.finishNode(t,o.TRIGGER)},e.parseAssertStatement=function(t){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.exp=r(t.BODY.raw),this.eat(i._in)&&(this.type===i.num?t.BODY.timeout=this.value:this.unexpected(),this.next()),this.semicolon(),t.BODY.key=this.UID("#"),this.keys[t.BODY.key]=!!t.BODY.timeout,this.finishNode(t,o.ASSERT)},e.parseGotoStatement=function(t){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.url=r(t.BODY.raw),this.semicolon(),this.finishNode(t,o.JUMPTO)},e.parseRefreshStatement=function(t){return this.next(),this.semicolon(),this.finishNode(t,o.REFRESH)},e.parseLogStatement=function(t,e){return this.next(),t.BODY.raw=this.parseExpression(),t.BODY.msg=r(t.BODY.raw),this.semicolon(),this.finishNode(t,e)},e.startNode=function(){return{LINE:s(this.input,this.start).line,TYPE:0,BODY:{},start:this.start,end:0}},e.finishNode=function(t,e){return t.TYPE=e,t.end=this.lastTokEnd,t}}},function(t,e,n){var i=n(7),s=i.isIdentifierStart,r=i.isIdentifierChar,o=n(2).types,a=n(2).keywordTypes,c=n(9),h=c.isNewLine,u=c.lineBreak;t.exports=function(t){var e=t.prototype;e.next=function(){this.lastTokEnd=this.end,this.lastTokStart=this.start,this.nextToken()},e.nextToken=function(){return this.skipSpace(),this.start=this.pos,this.pos>=this.input.length?this.finishToken(o.eof):void this.readToken(this.fullCharCodeAtPos())},e.readToken=function(t){return s(t)||35===t?this.readWord():this.getTokenFromCode(t)},e.fullCharCodeAtPos=function(){return this.input.charCodeAt(this.pos)},e.skipBlockComment=function(){var t=this.pos,e=this.input.indexOf("*/",this.pos+=2);-1===e&&this.raise(this.pos-2,"unterminated comment"),this.pos=e+2,this.options.onComment&&this.options.onComment(!0,this.input.slice(t+2,e),t,this.pos)},e.skipLineComment=function(t){for(var e=this.pos,n=this.input.charCodeAt(this.pos+=t);this.pos<this.input.length&&10!==n&&13!==n&&8232!==n&&8233!==n;)++this.pos,n=this.input.charCodeAt(this.pos);this.options.onComment&&this.options.onComment(!1,this.input.slice(e+=t,this.pos),e,this.pos)},e.skipSpace=function(){t:for(;this.pos<this.input.length;){var t=this.input.charCodeAt(this.pos);switch(t){case 32:case 160:++this.pos;break;case 13:10===this.input.charCodeAt(this.pos+1)&&++this.pos;case 10:case 8232:case 8233:++this.pos;break;case 47:switch(this.input.charCodeAt(this.pos+1)){case 42:this.skipBlockComment();break;case 47:this.skipLineComment(2);break;default:break t}break;default:if(!(t>8&&14>t))break t;++this.pos}}},e.readToken_bracket=function(){var t=this.pos++,e=this.fullCharCodeAtPos();if(s(e)){var n=this.readWord1();return e=this.fullCharCodeAtPos(),93!==e&&this.raise(t,"Unterminated dictionary index"),this.pos++,this.dTable[n]=!0,this.finishToken(o.dict,n)}return this.finishToken(o.bracketL)},e.readToken_brace=function(){var t=this.pos++,e=this.fullCharCodeAtPos();if(s(e)){var n=this.readWord1();return e=this.fullCharCodeAtPos(),125!==e&&this.raise(t,"Unterminated object store index"),this.pos++,this.obTable[n]=!0,this.finishToken(o.objectAt,n)}return this.finishToken(o.braceL)},e.readToken_slash=function(){var t=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp("/")):61===t?this.finishOp(o.assign,2):62===t?this.finishOp(o.tagR,2):this.finishOp(o.slash,1)},e.readToken_mult_modulo_exp=function(t){var e=this.input.charCodeAt(this.pos+1),n=1,i=42===t?o.star:o.modulo;return 61===e?this.finishOp(o.assign,n+1):this.finishOp(i,n)},e.readToken_pipe_amp=function(t){var e=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp("|")):e===t?this.finishOp(124===t?o.logicalOR:o.logicalAND,2):void this.raise(this.pos,"bitwise operator is not allowed")},e.readToken_plus_min=function(t){var e=this.input.charCodeAt(this.pos+1);return e===t?this.finishOp(o.incDec,2):61===e?this.finishOp(o.assign,2):this.finishOp(o.plusMin,1)},e.readToken_lt_gt=function(t){var e=this.input.charCodeAt(this.pos+1),n=1;if(e===t&&this.raise(this.pos,"bitwise operator is not allowed"),60===t){if(35===e)return this.finishOp(o.tagNumL,2);if(64===e)return this.finishOp(o.tagAtL,2);if(33===e)return this.finishOp(o.tagFacL,2)}return 61===e&&(n=2),this.finishOp(o.relational,n)},e.readToken_eq_excl=function(t){var e=this.input.charCodeAt(this.pos+1);return 126===e&&33===t?this.finishOp(o.match,2):61===e?this.finishOp(o.equality,61===this.input.charCodeAt(this.pos+2)?3:2):this.finishOp(61===t?o.eq:o.prefix,1)},e.getTokenFromCode=function(t){switch(t){case 40:return++this.pos,this.finishToken(o.parenL);case 41:return++this.pos,this.finishToken(o.parenR);case 59:return++this.pos,this.finishToken(o.semi);case 44:return++this.pos,this.finishToken(o.comma);case 91:return this.readToken_bracket();case 93:return++this.pos,this.finishToken(o.bracketR);case 123:return this.readToken_brace();case 125:return++this.pos,this.finishToken(o.braceR);case 58:return++this.pos,this.finishToken(o.colon);case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return this.readNumber(!1);case 34:case 39:return this.readString(t);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(t);case 124:case 38:return this.readToken_pipe_amp(t);case 43:case 45:return this.readToken_plus_min(t);case 60:case 62:return this.readToken_lt_gt(t);case 61:case 33:return this.readToken_eq_excl(t);case 126:var e=this.input.charCodeAt(this.pos+1);return 126!==e&&this.raise(this.pos,"bitwise operator is not allowed"),this.finishOp(o.match,2);default:this.raise(this.pos,'Unexpected character "'+this.input[this.pos]+'"')}},e.finishOp=function(t,e){var n=this.input.slice(this.pos,this.pos+=e);return this.finishToken(t,n)},e.finishToken=function(t,e){this.end=this.pos,this.type=t,this.value=e,this.exprAllowed=this.type.beforeExpr},e.readRegexp=function(t){for(var e,n,i=this.pos;;){this.pos>=this.input.length&&this.raise(i,"Unterminated regular expression");var s=this.input.charAt(this.pos);if(u.test(s)&&this.raise(i,"Unterminated regular expression"),e)e=!1;else{if("["===s)n=!0;else if("]"===s&&n)n=!1;else if(s===t&&!n)break;e="\\"===s}++this.pos}var r=this.input.slice(i,this.pos);++this.pos;var a=this.readWord1();if(a){var c=/^[gim]*$/;c.test(a)||this.raise(i,"Invalid regular expression flag")}var h={pattern:r,flags:a,isGenerate:"|"===t};return this.finishToken(o.regexp,h)},e.readInt=function(t,e){for(var n=this.pos,i=0,s=0,r=null==e?1/0:e;r>s;++s){var o,a=this.fullCharCodeAtPos();if(o=a>=97?a-97+10:a>=65?a-65+10:a>=48&&57>=a?a-48:1/0,o>=t)break;++this.pos,i=i*t+o}return this.pos===n||null!=e&&this.pos-n!==e?null:i},e.readNumber=function(t){var e=this.pos,n=!1;t||null!==this.readInt(10)||this.raise(e,"Invalid Number");var i=this.fullCharCodeAtPos();46===i&&(++this.pos,this.readInt(10),n=!0,i=this.fullCharCodeAtPos()),69!==i&&101!==i||(i=this.input.charCodeAt(++this.pos),43!==i&&45!==i||++this.pos,null===this.readInt(10)&&this.raise(e,"Invalid number"),n=!0),s(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number");var r,a=this.input.slice(e,this.pos);return r=n?parseFloat(a):parseInt(a,10),this.finishToken(o.num,r)},e.readString=function(t){for(var e="",n=this.start,i=++this.pos;;){this.pos>=this.input.length&&this.raise(n,"Unterminated string");var s=this.fullCharCodeAtPos();if(s===t)break;92===s?(e+=this.input.slice(i,this.pos),e+=this.readEscapedChar(),i=this.pos):(h(s)&&this.raise(n,"Unterminated string"),++this.pos)}return e+=this.input.slice(i,this.pos++),this.finishToken(o.string,e)},e.readEscapedChar=function(){var t=this.input.charCodeAt(++this.pos);switch(++this.pos,t){case 110:return"\n";case 114:return"\r";case 116:return" ";case 98:return"\b";case 118:return"\x0B";case 102:return"\f";case 13:10===this.fullCharCodeAtPos()&&++this.pos;case 10:return"";default:return String.fromCharCode(t)}},e.readWord1=function(){for(var t="",e=!0,n=this.pos;this.pos<this.input.length;){var i=this.fullCharCodeAtPos();if(r(i))++this.pos;else{if(!e||35!==i)break;++this.pos}e=!1}return t+=this.input.slice(n,this.pos)},e.readWord=function(){var t,e=this.pos,n=this.readWord1();if(this.keywords.test(n)){if(t=a[n],t.macro){var i=this.readMacro();return this.finishToken(t,i)}}else 35===n.charCodeAt(0)&&this.raise(e,"# is only valid for # macro"),t=o.name;return this.finishToken(t,n)},e.readMacro=function(){for(var t=this.pos,e=this.fullCharCodeAtPos();this.pos<this.input.length&&10!==e&&13!==e&&8232!==e&&8233!==e;)++this.pos,e=this.input.charCodeAt(this.pos);return this.input.slice(t,this.pos).trim()}}},function(t,e){function n(t){return"[object Array]"===Object.prototype.toString.call(t)}function i(t,e){return Object.prototype.hasOwnProperty.call(t,e)}t.exports={isArray:n,has:i}},function(t,e){var n={varDecl:function(t,e){var n="",i=!0;return t.declarations.forEach(function(t){t.init&&(i||(n+=","),n+="$."+t.id+" = "+e(t.init),i=!1)}),"("+n+")"},SequenceExpr:function(t,e){var n="",i=!0;return t.expressions.forEach(function(t){i||(n+=","),n+=e(t),i=!1}),"("+n+")"},literal:function(t){return t.raw},regexp:function(t){if(t.regexp.isGenerate){var e=t.regexp;return"(/"+e.pattern+"/"+e.flags+").gen()"}return"("+t.raw+")"},dictionaryIndex:function(t){return"d."+t.value},objectStore:function(t){return"o."+t.value},Identifier:function(t){return"$."+t.name},LogicalExpr:function(t,e){return e(t.left)+t.operator+e(t.right)},BinaryExpr:function(t,e){return e(t.left)+t.operator+e(t.right)},MatchExpr:function(t,e){var n="";return"~~"===t.operator&&(n+="!"),n+"!("+e(t.left)+").match("+e(t.right)+")"},UpdateExpr:function(t){var e="$."+t.argument;return t.prefix?t.operator+e:e+t.operator},UnaryExpr:function(t,e){return t.operator+"("+e(t.argument)+")"},AssignmentExpr:function(t,e){return e(t.left)+t.operator+e(t.right)},ParenthesizedExpr:function(t,e){return"("+e(t.expression)+")"},TextExpr:function(t,e){var n="String("+e(t.val)+")";return"t("+n+")"},CountExpr:function(t,e){var n="String("+e(t.val)+")";return"c("+n+")"},VisibilityExpr:function(t,e){var n="String("+e(t.val)+")";return"v("+n+")"}};t.exports=function(t){var e=function i(t){var e=t.type;return n[e](t,i)}(t);return new Function("$,o,d,c,t, v","return "+e+";")}}])});
{
"name": "lc2",
"version": "1.2.1",
"version": "1.2.3",
"description": "browser automation library",

@@ -9,3 +9,3 @@ "main": "index.js",

"dev": "webpack-dev-server --host 0.0.0.0 --port 3001",
"build": "webpack && webpack -p --output-filename lemoncase.min.js"
"build": "npm update && webpack && webpack -p --output-filename lemoncase.min.js"
},

@@ -49,4 +49,4 @@ "repository": {

"dependencies": {
"oc-trigger": "^1.0.2"
"oc-trigger": "*"
}
}

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc