text: parcelRequire=function(e,r,t,n){var i,o="function"==typeof parcelRequire&&parcelRequire,u="function"==typeof require&&require;function f(t,n){if(!r[t]){if(!e[t]){var i="function"==typeof parcelRequire&&parcelRequire;if(!n&&i)return i(t,!0);if(o)return o(t,!0);if(u&&"string"==typeof t)return u(t);var c=new Error("Cannot find module '"+t+"'");throw c.code="MODULE_NOT_FOUND",c}p.resolve=function(r){return e[t][1][r]||r},p.cache={};var l=r[t]=new f.Module(t);e[t][0].call(l.exports,p,l,l.exports,this)}return r[t].exports;function p(e){return f(p.resolve(e))}}f.isParcelRequire=!0,f.Module=function(e){this.id=e,this.bundle=f,this.exports={}},f.modules=e,f.cache=r,f.parent=o,f.register=function(r,t){e[r]=[function(e,r){r.exports=t},{}]};for(var c=0;c<t.length;c++)try{f(t[c])}catch(e){i||(i=e)}if(t.length){var l=f(t[t.length-1]);"object"==typeof exports&&"undefined"!=typeof module?module.exports=l:"function"==typeof define&&define.amd?define(function(){return l}):n&&(this[n]=l)}if(parcelRequire=f,i)throw i;return f}({"g4V2":[function(require,module,exports) {
  "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=void 0;var e=function e(t,n,i,r,l,o,d){n||(n=function(){}),i||(i=function(){}),r||(r=function(){return!0}),l||(l=function(){return!1}),o||(o=20),d||(d=80);var c=!1;function u(e,t,n){return r(e,t,n)}function a(e,t){return l(e,t)}e.load=function(){if(!c){c=!0;var r,l,f,s,p,w,g=[],h=[],y=t,v=!1,C=o,m=d,x=0,S=0,B=!1,L=!1,R=!1,b=0,k=document.createElement("DIV");k.classList.add("indicator"),k.classList.add("invisible"),y.appendChild(k),e.import=function(e){y.innerHTML=e.html,(g=e.blockarr).length>1&&N()},e.output=function(){var e={html:y.innerHTML,blockarr:g,blocks:[]};if(g.length>0){for(var t=0;t<g.length;t++){e.blocks.push({id:g[t].id,parent:g[t].parent,data:[],attr:[]});var n=document.querySelector(".blockid[value='"+g[t].id+"']").parentNode;n.querySelectorAll("input").forEach(function(n){var i=n.getAttribute("name"),r=n.value;e.blocks[t].data.push({name:i,value:r})}),Array.prototype.slice.call(n.attributes).forEach(function(n){var i={};i[n.name]=n.value,e.blocks[t].attr.push(i)})}return e}},e.deleteBlocks=function(){g=[],y.innerHTML="<div class='indicator invisible'></div>"},e.beginDrag=function(e){if(e.targetTouches?(p=e.changedTouches[0].clientX,w=e.changedTouches[0].clientY):(p=e.clientX,w=e.clientY),3!=e.which&&e.target.closest(".create-flowy")){s=e.target.closest(".create-flowy");var t=e.target.closest(".create-flowy").cloneNode(!0);e.target.closest(".create-flowy").classList.add("dragnow"),t.classList.add("block"),t.classList.remove("create-flowy"),0===g.length?(t.innerHTML+="<input type='hidden' name='blockid' class='blockid' value='"+g.length+"'>",document.body.appendChild(t),r=document.querySelector(".blockid[value='"+g.length+"']").parentNode):(t.innerHTML+="<input type='hidden' name='blockid' class='blockid' value='"+(Math.max.apply(Math,g.map(function(e){return e.id}))+1)+"'>",document.body.appendChild(t),r=document.querySelector(".blockid[value='"+(parseInt(Math.max.apply(Math,g.map(function(e){return e.id})))+1)+"']").parentNode),i=e.target.closest(".create-flowy"),n(i),r.classList.add("dragging"),v=!0,l=p-e.target.closest(".create-flowy").getBoundingClientRect().left,f=w-e.target.closest(".create-flowy").getBoundingClientRect().top,r.style.left=p-l+"px",r.style.top=w-f+"px"}var i},document.addEventListener("mousedown",X,!1),document.addEventListener("touchstart",X,!1),document.addEventListener("mouseup",X,!1),e.touchDone=function(){R=!1},document.addEventListener("mousedown",e.beginDrag),document.addEventListener("touchstart",e.beginDrag),e.endDrag=function(e){if(3!=e.which&&(v||B))if(R=!1,i(),document.querySelector(".indicator").classList.contains("invisible")||document.querySelector(".indicator").classList.add("invisible"),v&&(s.classList.remove("dragnow"),r.classList.remove("dragging")),0===parseInt(r.querySelector(".blockid").value)&&B){r.classList.remove("dragging"),B=!1;for(var t=0;t<h.length;t++)if(h[t].id!=parseInt(r.querySelector(".blockid").value)){var n=document.querySelector(".blockid[value='"+h[t].id+"']").parentNode,l=document.querySelector(".arrowid[value='"+h[t].id+"']").parentNode;n.style.left=n.getBoundingClientRect().left+window.scrollX-(y.getBoundingClientRect().left+window.scrollX)+y.scrollLeft-1+"px",n.style.top=n.getBoundingClientRect().top+window.scrollY-(y.getBoundingClientRect().top+window.scrollY)+y.scrollTop-1+"px",l.style.left=l.getBoundingClientRect().left+window.scrollX-(y.getBoundingClientRect().left+window.scrollX)+y.scrollLeft-1+"px",l.style.top=l.getBoundingClientRect().top+window.scrollY-(y.getBoundingClientRect().top+y.scrollTop)-1+"px",y.appendChild(n),y.appendChild(l),h[t].x=n.getBoundingClientRect().left+window.scrollX+parseInt(n.offsetWidth)/2+y.scrollLeft-1,h[t].y=n.getBoundingClientRect().top+window.scrollY+parseInt(n.offsetHeight)/2+y.scrollTop-1}h.filter(function(e){return 0==e.id})[0].x=r.getBoundingClientRect().left+window.scrollX+parseInt(window.getComputedStyle(r).width)/2,h.filter(function(e){return 0==e.id})[0].y=r.getBoundingClientRect().top+window.scrollY+parseInt(window.getComputedStyle(r).height)/2,g=g.concat(h),h=[]}else if(v&&0==g.length&&r.getBoundingClientRect().top+window.scrollY>y.getBoundingClientRect().top+window.scrollY&&r.getBoundingClientRect().left+window.scrollX>y.getBoundingClientRect().left+window.scrollX)u(r,!0,void 0),v=!1,r.style.top=r.getBoundingClientRect().top+window.scrollY-(y.getBoundingClientRect().top+window.scrollY)+y.scrollTop+"px",r.style.left=r.getBoundingClientRect().left+window.scrollX-(y.getBoundingClientRect().left+window.scrollX)+y.scrollLeft+"px",y.appendChild(r),g.push({parent:-1,childwidth:0,id:parseInt(r.querySelector(".blockid").value),x:r.getBoundingClientRect().left+window.scrollX+parseInt(window.getComputedStyle(r).width)/2+y.scrollLeft,y:r.getBoundingClientRect().top+window.scrollY+parseInt(window.getComputedStyle(r).height)/2+y.scrollTop,width:parseInt(window.getComputedStyle(r).width),height:parseInt(window.getComputedStyle(r).height)});else if(v&&0==g.length)y.appendChild(document.querySelector(".indicator")),r.parentNode.removeChild(r);else if(v)for(var o=r.getBoundingClientRect().left+window.scrollX+parseInt(window.getComputedStyle(r).width)/2+y.scrollLeft,d=r.getBoundingClientRect().top+window.scrollY+y.scrollTop,c=g.map(function(e){return e.id}),f=0;f<g.length;f++){if(o>=g.filter(function(e){return e.id==c[f]})[0].x-g.filter(function(e){return e.id==c[f]})[0].width/2-C&&o<=g.filter(function(e){return e.id==c[f]})[0].x+g.filter(function(e){return e.id==c[f]})[0].width/2+C&&d>=g.filter(function(e){return e.id==c[f]})[0].y-g.filter(function(e){return e.id==c[f]})[0].height/2&&d<=g.filter(function(e){return e.id==c[f]})[0].y+g.filter(function(e){return e.id==c[f]})[0].height){v=!1,!B&&u(r,!1,g.filter(function(e){return e.id==c[f]})[0])?q(r,f,c):B&&q(r,f,c);break}f==g.length-1&&(v=!1,y.appendChild(document.querySelector(".indicator")),r.parentNode.removeChild(r))}else if(B)for(o=r.getBoundingClientRect().left+window.scrollX+parseInt(window.getComputedStyle(r).width)/2+y.scrollLeft,d=r.getBoundingClientRect().top+window.scrollY+y.scrollTop,c=g.map(function(e){return e.id}),f=0;f<g.length;f++){if(o>=g.filter(function(e){return e.id==c[f]})[0].x-g.filter(function(e){return e.id==c[f]})[0].width/2-C&&o<=g.filter(function(e){return e.id==c[f]})[0].x+g.filter(function(e){return e.id==c[f]})[0].width/2+C&&d>=g.filter(function(e){return e.id==c[f]})[0].y-g.filter(function(e){return e.id==c[f]})[0].height/2&&d<=g.filter(function(e){return e.id==c[f]})[0].y+g.filter(function(e){return e.id==c[f]})[0].height){v=!1,r.classList.remove("dragging"),q(r,f,c);break}f==g.length-1&&(a(r,g.filter(function(e){return e.id==c[f]})[0])?(v=!1,r.classList.remove("dragging"),q(r,c.indexOf(b),c)):(B=!1,h=[],v=!1,y.appendChild(document.querySelector(".indicator")),r.parentNode.removeChild(r)))}},document.addEventListener("mouseup",e.endDrag,!1),document.addEventListener("touchend",e.endDrag,!1),e.moveBlock=function(e){if(e.targetTouches?(p=e.targetTouches[0].clientX,w=e.targetTouches[0].clientY):(p=e.clientX,w=e.clientY),R){B=!0,r.classList.add("dragging");var t=parseInt(r.querySelector(".blockid").value);b=g.filter(function(e){return e.id==t})[0].parent,h.push(g.filter(function(e){return e.id==t})[0]),g=g.filter(function(e){return e.id!=t}),0!=t&&document.querySelector(".arrowid[value='"+t+"']").parentNode.remove();for(var n=g.filter(function(e){return e.parent==t}),i=!1,o=[],d=[];!i;){for(var c=0;c<n.length;c++)if(n[c]!=t){h.push(g.filter(function(e){return e.id==n[c].id})[0]);var u=document.querySelector(".blockid[value='"+n[c].id+"']").parentNode,a=document.querySelector(".arrowid[value='"+n[c].id+"']").parentNode;u.style.left=u.getBoundingClientRect().left+window.scrollX-(r.getBoundingClientRect().left+window.scrollX)+"px",u.style.top=u.getBoundingClientRect().top+window.scrollY-(r.getBoundingClientRect().top+window.scrollY)+"px",a.style.left=a.getBoundingClientRect().left+window.scrollX-(r.getBoundingClientRect().left+window.scrollX)+"px",a.style.top=a.getBoundingClientRect().top+window.scrollY-(r.getBoundingClientRect().top+window.scrollY)+"px",r.appendChild(u),r.appendChild(a),o.push(n[c].id),d.push(n[c].id)}0==o.length?i=!0:(n=g.filter(function(e){return o.includes(e.parent)}),o=[])}for(c=0;c<g.filter(function(e){return e.parent==t}).length;c++){var s=g.filter(function(e){return e.parent==t})[c];g=g.filter(function(e){return e.id!=s})}for(c=0;c<d.length;c++){s=d[c];g=g.filter(function(e){return e.id!=s})}g.length>1&&N(),L&&function(){if(S<y.getBoundingClientRect().left+window.scrollX){L=!1;for(var e=g.map(function(e){return e.id}),t=0;t<g.length;t++)if(document.querySelector(".blockid[value='"+g.filter(function(n){return n.id==e[t]})[0].id+"']").parentNode.style.left=g.filter(function(n){return n.id==e[t]})[0].x-g.filter(function(n){return n.id==e[t]})[0].width/2-S-20+"px",g.filter(function(n){return n.id==e[t]})[0].x=document.querySelector(".blockid[value='"+g.filter(function(n){return n.id==e[t]})[0].id+"']").parentNode.getBoundingClientRect().left+window.scrollX+g.filter(function(n){return n.id==e[t]})[0].width/2,-1!=g.filter(function(n){return n.id==e[t]})[0].parent){var n=g.filter(function(n){return n.id==e[t]})[0],i=n.x-g.filter(function(n){return n.id==g.filter(function(n){return n.id==e[t]})[0].parent})[0].x;document.querySelector('.arrowid[value="'+e[t]+'"]').parentNode.style.left=i<0?n.x-5-(y.getBoundingClientRect().left+window.scrollX)+"px":g.filter(function(n){return n.id==g.filter(function(n){return n.id==e[t]})[0].parent})[0].x-20-(y.getBoundingClientRect().left+window.scrollX)+"px"}S=0}}(),R=!1}if(v?(r.style.left=p-l+"px",r.style.top=w-f+"px"):B&&(r.style.left=p-l-(y.getBoundingClientRect().left+window.scrollX)+y.scrollLeft+"px",r.style.top=w-f-(y.getBoundingClientRect().top+window.scrollY)+y.scrollTop+"px",h.filter(function(e){return e.id==parseInt(r.querySelector(".blockid").value)}).x=r.getBoundingClientRect().left+window.scrollX+parseInt(window.getComputedStyle(r).width)/2+y.scrollLeft,h.filter(function(e){return e.id==parseInt(r.querySelector(".blockid").value)}).y=r.getBoundingClientRect().left+window.scrollX+parseInt(window.getComputedStyle(r).height)/2+y.scrollTop),v||B){var m=r.getBoundingClientRect().left+window.scrollX+parseInt(window.getComputedStyle(r).width)/2+y.scrollLeft,x=r.getBoundingClientRect().top+window.scrollY+y.scrollTop,k=g.map(function(e){return e.id});for(c=0;c<g.length;c++){if(m>=g.filter(function(e){return e.id==k[c]})[0].x-g.filter(function(e){return e.id==k[c]})[0].width/2-C&&m<=g.filter(function(e){return e.id==k[c]})[0].x+g.filter(function(e){return e.id==k[c]})[0].width/2+C&&x>=g.filter(function(e){return e.id==k[c]})[0].y-g.filter(function(e){return e.id==k[c]})[0].height/2&&x<=g.filter(function(e){return e.id==k[c]})[0].y+g.filter(function(e){return e.id==k[c]})[0].height){document.querySelector(".blockid[value='"+k[c]+"']").parentNode.appendChild(document.querySelector(".indicator")),document.querySelector(".indicator").style.left=parseInt(window.getComputedStyle(document.querySelector(".blockid[value='"+k[c]+"']").parentNode).width)/2-5+"px",document.querySelector(".indicator").style.top=window.getComputedStyle(document.querySelector(".blockid[value='"+k[c]+"']").parentNode).height+"px",document.querySelector(".indicator").classList.remove("invisible");break}c==g.length-1&&(document.querySelector(".indicator").classList.contains("invisible")||document.querySelector(".indicator").classList.add("invisible"))}}},document.addEventListener("mousemove",e.moveBlock,!1),document.addEventListener("touchmove",e.moveBlock,!1)}function q(e,t,n){B||y.appendChild(e);for(var i=0,r=0,l=0;l<g.filter(function(e){return e.parent==n[t]}).length;l++){(w=g.filter(function(e){return e.parent==n[t]})[l]).childwidth>w.width?i+=w.childwidth+C:i+=w.width+C}i+=parseInt(window.getComputedStyle(e).width);for(l=0;l<g.filter(function(e){return e.parent==n[t]}).length;l++){(w=g.filter(function(e){return e.parent==n[t]})[l]).childwidth>w.width?(document.querySelector(".blockid[value='"+w.id+"']").parentNode.style.left=g.filter(function(e){return e.id==n[t]})[0].x-i/2+r+w.childwidth/2-w.width/2+"px",w.x=g.filter(function(e){return e.parent==n[t]})[0].x-i/2+r+w.childwidth/2,r+=w.childwidth+C):(document.querySelector(".blockid[value='"+w.id+"']").parentNode.style.left=g.filter(function(e){return e.id==n[t]})[0].x-i/2+r+"px",w.x=g.filter(function(e){return e.parent==n[t]})[0].x-i/2+r+w.width/2,r+=w.width+C)}if(e.style.left=g.filter(function(e){return e.id==n[t]})[0].x-i/2+r-(y.getBoundingClientRect().left+window.scrollX)+y.scrollLeft+"px",e.style.top=g.filter(function(e){return e.id==n[t]})[0].y+g.filter(function(e){return e.id==n[t]})[0].height/2+m-(y.getBoundingClientRect().top+window.scrollY)+"px",B){h.filter(function(t){return t.id==parseInt(e.querySelector(".blockid").value)})[0].x=e.getBoundingClientRect().left+window.scrollX+parseInt(window.getComputedStyle(e).width)/2+y.scrollLeft+y.scrollLeft,h.filter(function(t){return t.id==parseInt(e.querySelector(".blockid").value)})[0].y=e.getBoundingClientRect().top+window.scrollY+parseInt(window.getComputedStyle(e).height)/2+y.scrollTop,h.filter(function(t){return t.id==e.querySelector(".blockid").value})[0].parent=n[t];for(l=0;l<h.length;l++)if(h[l].id!=parseInt(e.querySelector(".blockid").value)){var o=document.querySelector(".blockid[value='"+h[l].id+"']").parentNode,d=document.querySelector(".arrowid[value='"+h[l].id+"']").parentNode;o.style.left=o.getBoundingClientRect().left+window.scrollX-(y.getBoundingClientRect().left+window.scrollX)+y.scrollLeft+"px",o.style.top=o.getBoundingClientRect().top+window.scrollY-(y.getBoundingClientRect().top+window.scrollY)+y.scrollTop+"px",d.style.left=d.getBoundingClientRect().left+window.scrollX-(y.getBoundingClientRect().left+window.scrollX)+y.scrollLeft+20+"px",d.style.top=d.getBoundingClientRect().top+window.scrollY-(y.getBoundingClientRect().top+window.scrollY)+y.scrollTop+"px",y.appendChild(o),y.appendChild(d),h[l].x=o.getBoundingClientRect().left+window.scrollX+parseInt(window.getComputedStyle(o).width)/2+y.scrollLeft,h[l].y=o.getBoundingClientRect().top+window.scrollY+parseInt(window.getComputedStyle(o).height)/2+y.scrollTop}g=g.concat(h),h=[]}else g.push({childwidth:0,parent:n[t],id:parseInt(e.querySelector(".blockid").value),x:e.getBoundingClientRect().left+window.scrollX+parseInt(window.getComputedStyle(e).width)/2+y.scrollLeft,y:e.getBoundingClientRect().top+window.scrollY+parseInt(window.getComputedStyle(e).height)/2+y.scrollTop,width:parseInt(window.getComputedStyle(e).width),height:parseInt(window.getComputedStyle(e).height)});var c=g.filter(function(t){return t.id==parseInt(e.querySelector(".blockid").value)})[0],u=c.x-g.filter(function(e){return e.id==n[t]})[0].x+20,a=parseFloat(c.y-c.height/2-(g.filter(function(e){return e.parent==n[t]})[0].y+g.filter(function(e){return e.parent==n[t]})[0].height/2)+y.scrollTop);if(u<0?(y.innerHTML+='<div class="arrowblock"><input type="hidden" class="arrowid" value="'+e.querySelector(".blockid").value+'"><svg preserveaspectratio="none" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M'+(g.filter(function(e){return e.id==n[t]})[0].x-c.x+5)+" 0L"+(g.filter(function(e){return e.id==n[t]})[0].x-c.x+5)+" "+m/2+"L5 "+m/2+"L5 "+a+'" stroke="#C5CCD0" stroke-width="2px"/><path d="M0 '+(a-5)+"H10L5 "+a+"L0 "+(a-5)+'Z" fill="#C5CCD0"/></svg></div>',document.querySelector('.arrowid[value="'+e.querySelector(".blockid").value+'"]').parentNode.style.left=c.x-5-(y.getBoundingClientRect().left+window.scrollX)+y.scrollLeft+"px"):(y.innerHTML+='<div class="arrowblock"><input type="hidden" class="arrowid" value="'+e.querySelector(".blockid").value+'"><svg preserveaspectratio="none" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M20 0L20 '+m/2+"L"+u+" "+m/2+"L"+u+" "+a+'" stroke="#C5CCD0" stroke-width="2px"/><path d="M'+(u-5)+" "+(a-5)+"H"+(u+5)+"L"+u+" "+a+"L"+(u-5)+" "+(a-5)+'Z" fill="#C5CCD0"/></svg></div>',document.querySelector('.arrowid[value="'+parseInt(e.querySelector(".blockid").value)+'"]').parentNode.style.left=g.filter(function(e){return e.id==n[t]})[0].x-20-(y.getBoundingClientRect().left+window.scrollX)+y.scrollLeft+"px"),document.querySelector('.arrowid[value="'+parseInt(e.querySelector(".blockid").value)+'"]').parentNode.style.top=g.filter(function(e){return e.id==n[t]})[0].y+g.filter(function(e){return e.id==n[t]})[0].height/2+"px",-1!=g.filter(function(e){return e.id==n[t]})[0].parent){for(var f=!1,s=n[t];!f;)if(-1==g.filter(function(e){return e.id==s})[0].parent)f=!0;else{var p=0;for(l=0;l<g.filter(function(e){return e.parent==s}).length;l++){var w;(w=g.filter(function(e){return e.parent==s})[l]).childwidth>w.width?l==g.filter(function(e){return e.parent==s}).length-1?p+=w.childwidth:p+=w.childwidth+C:l==g.filter(function(e){return e.parent==s}).length-1?p+=w.width:p+=w.width+C}g.filter(function(e){return e.id==s})[0].childwidth=p,s=g.filter(function(e){return e.id==s})[0].parent}g.filter(function(e){return e.id==s})[0].childwidth=i}B&&(B=!1,e.classList.remove("dragging")),N(),function(){x=g.map(function(e){return e.x});var e=g.map(function(e){return e.width}),t=x.map(function(t,n){return t-e[n]/2});if((x=Math.min.apply(Math,t))<y.getBoundingClientRect().left+window.scrollX){L=!0;for(var n=g.map(function(e){return e.id}),i=0;i<g.length;i++)if(document.querySelector(".blockid[value='"+g.filter(function(e){return e.id==n[i]})[0].id+"']").parentNode.style.left=g.filter(function(e){return e.id==n[i]})[0].x-g.filter(function(e){return e.id==n[i]})[0].width/2-x+20+"px",-1!=g.filter(function(e){return e.id==n[i]})[0].parent){var r=g.filter(function(e){return e.id==n[i]})[0],l=r.x-g.filter(function(e){return e.id==g.filter(function(e){return e.id==n[i]})[0].parent})[0].x;document.querySelector('.arrowid[value="'+n[i]+'"]').parentNode.style.left=l<0?r.x-x+20-5+"px":g.filter(function(e){return e.id==g.filter(function(e){return e.id==n[i]})[0].parent})[0].x-20-x+20+"px"}for(var i=0;i<g.length;i++)g[i].x=document.querySelector(".blockid[value='"+g[i].id+"']").parentNode.getBoundingClientRect().left+window.scrollX+(y.getBoundingClientRect().left+y.scrollLeft)-parseInt(window.getComputedStyle(document.querySelector(".blockid[value='"+g[i].id+"']").parentNode).width)/2-40;S=x}}()}function X(e){if(R=!1,I(e.target,"block")){var t=e.target.closest(".block");e.targetTouches?(p=e.targetTouches[0].clientX,w=e.targetTouches[0].clientY):(p=e.clientX,w=e.clientY),"mouseup"!==e.type&&I(e.target,"block")&&3!=e.which&&(v||B||(R=!0,l=p-((r=t).getBoundingClientRect().left+window.scrollX),f=w-(r.getBoundingClientRect().top+window.scrollY)))}}function I(e,t){return!!(e.className&&e.className.split(" ").indexOf(t)>=0)||e.parentNode&&I(e.parentNode,t)}function N(){for(var e=g.map(function(e){return e.parent}),t=0;t<e.length;t++){-1==e[t]&&t++;for(var n=0,i=0,r=0;r<g.filter(function(n){return n.parent==e[t]}).length;r++){var l=g.filter(function(n){return n.parent==e[t]})[r];0==g.filter(function(e){return e.parent==l.id}).length&&(l.childwidth=0),l.childwidth>l.width?r==g.filter(function(n){return n.parent==e[t]}).length-1?n+=l.childwidth:n+=l.childwidth+C:r==g.filter(function(n){return n.parent==e[t]}).length-1?n+=l.width:n+=l.width+C}-1!=e[t]&&(g.filter(function(n){return n.id==e[t]})[0].childwidth=n);for(r=0;r<g.filter(function(n){return n.parent==e[t]}).length;r++){l=g.filter(function(n){return n.parent==e[t]})[r];var o=document.querySelector(".blockid[value='"+l.id+"']").parentNode,d=g.filter(function(n){return n.id==e[t]});o.style.top=d.y+m+"px",d.y=d.y+m,l.childwidth>l.width?(o.style.left=d[0].x-n/2+i+l.childwidth/2-l.width/2-(y.getBoundingClientRect().left+window.scrollX)+"px",l.x=d[0].x-n/2+i+l.childwidth/2,i+=l.childwidth+C):(o.style.left=d[0].x-n/2+i-(y.getBoundingClientRect().left+window.scrollX)+"px",l.x=d[0].x-n/2+i+l.width/2,i+=l.width+C);var c=g.filter(function(e){return e.id==l.id})[0],u=c.x-g.filter(function(e){return e.id==l.parent})[0].x+20,a=c.y-c.height/2-(g.filter(function(e){return e.id==l.parent})[0].y+g.filter(function(e){return e.id==l.parent})[0].height/2);document.querySelector('.arrowid[value="'+l.id+'"]').parentNode.style.top=g.filter(function(e){return e.id==l.parent})[0].y+g.filter(function(e){return e.id==l.parent})[0].height/2-(y.getBoundingClientRect().top+window.scrollY)+"px",u<0?(document.querySelector('.arrowid[value="'+l.id+'"]').parentNode.style.left=c.x-5-(y.getBoundingClientRect().left+window.scrollX)+"px",document.querySelector('.arrowid[value="'+l.id+'"]').parentNode.innerHTML='<input type="hidden" class="arrowid" value="'+l.id+'"><svg preserveaspectratio="none" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M'+(g.filter(function(e){return e.id==l.parent})[0].x-c.x+5)+" 0L"+(g.filter(function(e){return e.id==l.parent})[0].x-c.x+5)+" "+m/2+"L5 "+m/2+"L5 "+a+'" stroke="#C5CCD0" stroke-width="2px"/><path d="M0 '+(a-5)+"H10L5 "+a+"L0 "+(a-5)+'Z" fill="#C5CCD0"/></svg>'):(document.querySelector('.arrowid[value="'+l.id+'"]').parentNode.style.left=g.filter(function(e){return e.id==l.parent})[0].x-20-(y.getBoundingClientRect().left+window.scrollX)+"px",document.querySelector('.arrowid[value="'+l.id+'"]').parentNode.innerHTML='<input type="hidden" class="arrowid" value="'+l.id+'"><svg preserveaspectratio="none" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M20 0L20 '+m/2+"L"+u+" "+m/2+"L"+u+" "+a+'" stroke="#C5CCD0" stroke-width="2px"/><path d="M'+(u-5)+" "+(a-5)+"H"+(u+5)+"L"+u+" "+a+"L"+(u-5)+" "+(a-5)+'Z" fill="#C5CCD0"/></svg>')}}}},e.load()},t=e;exports.default=t;
  },{}],"S3PC":[function(require,module,exports) {
  "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=void 0;var e=t(require("./engine"));function t(e){return e&&e.__esModule?e:{default:e}}var r=e.default;exports.default=r;
  },{"./engine":"g4V2"}],"vKFU":[function(require,module,exports) {
  
  },{}],"BsyI":[function(require,module,exports) {
  module.exports="/tile.49f4d005.png";
  },{}],"Sr7R":[function(require,module,exports) {
  
  },{"./assets/tile.png":[["tile.49f4d005.png","BsyI"],"BsyI"]}],"mDGh":[function(require,module,exports) {
  module.exports="/meta.58565e73.png";
  },{}],"HBCd":[function(require,module,exports) {
  module.exports={meta:require("./meta.png"),tile:require("./tile.png")};
  },{"./meta.png":"mDGh","./tile.png":"BsyI"}],"RQjc":[function(require,module,exports) {
  module.exports="/action.8befc6f7.svg";
  },{}],"BCfE":[function(require,module,exports) {
  module.exports="/actionblue.ae84b4e1.svg";
  },{}],"pYit":[function(require,module,exports) {
  module.exports="/actionorange.a9ba5119.svg";
  },{}],"RBZY":[function(require,module,exports) {
  module.exports="/arrow.cdedb983.svg";
  },{}],"Edwv":[function(require,module,exports) {
  module.exports="/checkoff.5d8991b3.svg";
  },{}],"vv2S":[function(require,module,exports) {
  module.exports="/checkon.c7d59ff6.svg";
  },{}],"AZqh":[function(require,module,exports) {
  module.exports="/close.28a95260.svg";
  },{}],"cRbN":[function(require,module,exports) {
  module.exports="/closeleft.c8d77482.svg";
  },{}],"vSgv":[function(require,module,exports) {
  module.exports="/database.5609ff0e.svg";
  },{}],"dvDz":[function(require,module,exports) {
  module.exports="/databaseorange.94796e21.svg";
  },{}],"CUvq":[function(require,module,exports) {
  module.exports="/dropdown.c7e7d7bf.svg";
  },{}],"nZIw":[function(require,module,exports) {
  module.exports="/error.190918e1.svg";
  },{}],"vSVw":[function(require,module,exports) {
  module.exports="/errorred.6eed4129.svg";
  },{}],"w4QH":[function(require,module,exports) {
  module.exports="/errorblue.82e0f302.svg";
  },{}],"lBPg":[function(require,module,exports) {
  module.exports="/eye.a93b3c96.svg";
  },{}],"zLdl":[function(require,module,exports) {
  module.exports="/eyeblue.87405eba.svg";
  },{}],"vWZg":[function(require,module,exports) {
  module.exports="/grabme.160f0296.svg";
  },{}],"HJjd":[function(require,module,exports) {
  module.exports="/heart.31604f1e.svg";
  },{}],"zrhx":[function(require,module,exports) {
  module.exports="/log.a9b58bce.svg";
  },{}],"s41b":[function(require,module,exports) {
  module.exports="/logred.44842b54.svg";
  },{}],"OfWq":[function(require,module,exports) {
  module.exports="/more.1916aad0.svg";
  },{}],"UWAG":[function(require,module,exports) {
  module.exports="/search.8cdb7225.svg";
  },{}],"bbPz":[function(require,module,exports) {
  module.exports="/time.7a89f195.svg";
  },{}],"wUGz":[function(require,module,exports) {
  module.exports="/timeblue.cc2cc3d0.svg";
  },{}],"Oge4":[function(require,module,exports) {
  module.exports="/twitter.43adbe3e.svg";
  },{}],"Okm0":[function(require,module,exports) {
  module.exports="/twitterorange.f563e90a.svg";
  },{}],"voxH":[function(require,module,exports) {
  module.exports={action:require("./action.svg"),actionblue:require("./actionblue.svg"),actionorange:require("./actionorange.svg"),arrow:require("./arrow.svg"),checkoff:require("./checkoff.svg"),checkon:require("./checkon.svg"),close:require("./close.svg"),closeleft:require("./closeleft.svg"),database:require("./database.svg"),databaseorange:require("./databaseorange.svg"),dropdown:require("./dropdown.svg"),error:require("./error.svg"),errorred:require("./errorred.svg"),errorblue:require("./errorblue.svg"),eye:require("./eye.svg"),eyeblue:require("./eyeblue.svg"),grabme:require("./grabme.svg"),heart:require("./heart.svg"),log:require("./log.svg"),logred:require("./logred.svg"),more:require("./more.svg"),search:require("./search.svg"),time:require("./time.svg"),timeblue:require("./timeblue.svg"),twitter:require("./twitter.svg"),twitterorange:require("./twitterorange.svg")};
  },{"./action.svg":"RQjc","./actionblue.svg":"BCfE","./actionorange.svg":"pYit","./arrow.svg":"RBZY","./checkoff.svg":"Edwv","./checkon.svg":"vv2S","./close.svg":"AZqh","./closeleft.svg":"cRbN","./database.svg":"vSgv","./databaseorange.svg":"dvDz","./dropdown.svg":"CUvq","./error.svg":"nZIw","./errorred.svg":"vSVw","./errorblue.svg":"w4QH","./eye.svg":"lBPg","./eyeblue.svg":"zLdl","./grabme.svg":"vWZg","./heart.svg":"HJjd","./log.svg":"zrhx","./logred.svg":"s41b","./more.svg":"OfWq","./search.svg":"UWAG","./time.svg":"bbPz","./timeblue.svg":"wUGz","./twitter.svg":"Oge4","./twitterorange.svg":"Okm0"}],"epB2":[function(require,module,exports) {
  "use strict";var e=n(require(".."));require("../engine/index.css"),require("./main.css");var c=n(require("./assets/*.png")),s=n(require("./assets/*.svg"));function n(e){return e&&e.__esModule?e:{default:e}}function l(e,c){var s=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);c&&(n=n.filter(function(c){return Object.getOwnPropertyDescriptor(e,c).enumerable})),s.push.apply(s,n)}return s}function i(e){for(var c=1;c<arguments.length;c++){var s=null!=arguments[c]?arguments[c]:{};c%2?l(Object(s),!0).forEach(function(c){a(e,c,s[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(s)):l(Object(s)).forEach(function(c){Object.defineProperty(e,c,Object.getOwnPropertyDescriptor(s,c))})}return e}function a(e,c,s){return c in e?Object.defineProperty(e,c,{value:s,enumerable:!0,configurable:!0,writable:!0}):e[c]=s,e}var t=i({},c.default,{},s.default);document.addEventListener("DOMContentLoaded",function(){var c,s,n=!1;function l(e,c,s,n){for(var l=document.querySelectorAll(n),i=0;i<l.length;i++)l[i].addEventListener(e,c,s)}document.getElementById("blocklist").innerHTML='\n      <div class="blockelem create-flowy noselect">\n        <input type="hidden" name="blockelemtype" class="blockelemtype" value="1">\n        <div class="grabme"><img src="'.concat(t.grabme,'"></div>\n        <div class="blockin">\n          <div class="blockico"><span></span><img src="').concat(t.eye,'"></div>\n          <div class="blocktext">\n            <p class="blocktitle">New visitor</p>\n            <p class="blockdesc">Triggers when somebody visits a specified page</p>\n          </div>\n        </div>\n      </div>\n      <div class="blockelem create-flowy noselect">\n        <input type="hidden" name="blockelemtype" class="blockelemtype" value="2">\n        <div class="grabme"><img src="').concat(t.grabme,'"></div>\n        <div class="blockin">\n          <div class="blockico"><span></span><img src="').concat(t.action,'"></div>\n          <div class="blocktext">\n            <p class="blocktitle">Action is performed</p>\n            <p class="blockdesc">Triggers when somebody performs a specified action</p>\n          </div>\n        </div>\n      </div>\n      <div class="blockelem create-flowy noselect">\n        <input type="hidden" name="blockelemtype" class="blockelemtype" value="3">\n        <div class="grabme"><img src="').concat(t.grabme,'"></div>\n        <div class="blockin">\n          <div class="blockico"><span></span><img src="').concat(t.time,'"></div>\n          <div class="blocktext">\n            <p class="blocktitle">Time has passed</p>\n            <p class="blockdesc">Triggers after a specified amount of time</p>\n          </div>\n        </div>\n      </div>\n      <div class="blockelem create-flowy noselect">\n        <input type="hidden" name="blockelemtype" class="blockelemtype" value="4">\n        <div class="grabme"><img src="').concat(t.grabme,'"></div>\n        <div class="blockin">\n          <div class="blockico"><span></span><img src="').concat(t.error,'"></div>\n          <div class="blocktext">\n            <p class="blocktitle">Error prompt</p>\n            <p class="blockdesc">Triggers when a specified error happens</p>\n          </div>\n        </div>\n      </div>\n    '),(0,e.default)(document.getElementById("canvas"),function(e){e.classList.add("blockdisabled"),s=e},function(){s&&s.classList.remove("blockdisabled")},function(e,c){var s=e.querySelector(".grabme");s.parentNode.removeChild(s);var n=e.querySelector(".blockin");n.parentNode.removeChild(n),"1"==e.querySelector(".blockelemtype").value?e.innerHTML+="\n          <div class='blockyleft'>\n            <img src='".concat(t.eyeblue,"'>\n            <p class='blockyname'>New visitor</p>\n          </div>\n          <div class='blockyright'><img src='").concat(t.more,"'></div>\n          <div class='blockydiv'></div>\n          <div class='blockyinfo'>When a <span>new visitor</span> goes to <span>Site 1</span></div>\n        "):"2"==e.querySelector(".blockelemtype").value?e.innerHTML+="\n          <div class='blockyleft'>\n            <img src='".concat(t.actionblue,"'>\n            <p class='blockyname'>Action is performed</p>\n          </div>\n          <div class='blockyright'><img src='").concat(t.more,"'></div>\n          <div class='blockydiv'></div>\n          <div class='blockyinfo'>When <span>Action 1</span> is performed</div>\n        "):"3"==e.querySelector(".blockelemtype").value?e.innerHTML+="\n          <div class='blockyleft'>\n            <img src='".concat(t.timeblue,"'>\n            <p class='blockyname'>Time has passed</p>\n          </div>\n          <div class='blockyright'><img src='").concat(t.more,"'></div>\n          <div class='blockydiv'></div>\n          <div class='blockyinfo'>When <span>10 seconds</span> have passed</div>\n        "):"4"==e.querySelector(".blockelemtype").value?e.innerHTML+="\n          <div class='blockyleft'>\n            <img src='".concat(t.errorblue,"'>\n            <p class='blockyname'>Error prompt</p>\n          </div>\n          <div class='blockyright'><img src='").concat(t.more,"'></div>\n          <div class='blockydiv'></div>\n          <div class='blockyinfo'>When <span>Error 1</span> is triggered</div>\n        "):"5"==e.querySelector(".blockelemtype").value?e.innerHTML+="\n          <div class='blockyleft'>\n            <img src='".concat(t.databaseorange,"'>\n            <p class='blockyname'>New database entry</p>\n          </div>\n          <div class='blockyright'><img src='").concat(t.more,"'></div>\n          <div class='blockydiv'></div>\n          <div class='blockyinfo'>Add <span>Data object</span> to <span>Database 1</span></div>\n        "):"6"==e.querySelector(".blockelemtype").value?e.innerHTML+="\n          <div class='blockyleft'>\n            <img src='".concat(t.databaseorange,"'>\n            <p class='blockyname'>Update database</p>\n          </div>\n          <div class='blockyright'><img src='").concat(t.more,"'></div>\n          <div class='blockydiv'></div>\n          <div class='blockyinfo'>Update <span>Database 1</span></div>\n        "):"7"==e.querySelector(".blockelemtype").value?e.innerHTML+="\n          <div class='blockyleft'>\n            <img src='".concat(t.actionorange,"'>\n            <p class='blockyname'>Perform an action</p>\n          </div>\n          <div class='blockyright'><img src='").concat(t.more,"'></div>\n          <div class='blockydiv'></div><div class='blockyinfo'>Perform <span>Action 1</span></div>\n        "):"8"==e.querySelector(".blockelemtype").value?e.innerHTML+="\n          <div class='blockyleft'>\n            <img src='".concat(t.twitterorange,"'>\n            <p class='blockyname'>Make a tweet</p>\n          </div>\n          <div class='blockyright'><img src='").concat(t.more,"'></div>\n          <div class='blockydiv'></div>\n          <div class='blockyinfo'>Tweet <span>Query 1</span> with the account <span>@alyssaxuu</span></div>\n        "):"9"==e.querySelector(".blockelemtype").value?e.innerHTML+="\n          <div class='blockyleft'>\n            <img src='".concat(t.logred,"'>\n            <p class='blockyname'>Add new log entry</p>\n          </div>\n          <div class='blockyright'><img src='").concat(t.more,"'></div>\n          <div class='blockydiv'></div>\n          <div class='blockyinfo'>Add new <span>success</span> log entry</div>\n        "):"10"==e.querySelector(".blockelemtype").value?e.innerHTML+="\n          <div class='blockyleft'>\n            <img src='".concat(t.logred,"'>\n            <p class='blockyname'>Update logs</p>\n          </div>\n          <div class='blockyright'><img src='").concat(t.more,"'></div>\n          <div class='blockydiv'></div>\n          <div class='blockyinfo'>Edit <span>Log Entry 1</span></div>\n        "):"11"==e.querySelector(".blockelemtype").value&&(e.innerHTML+="\n          <div class='blockyleft'>\n            <img src='".concat(t.errorred,"'>\n            <p class='blockyname'>Prompt an error</p>\n          </div>\n          <div class='blockyright'><img src='").concat(t.more,"'></div>\n          <div class='blockydiv'></div>\n          <div class='blockyinfo'>Trigger <span>Error 1</span></div>\n        "));return!0});l("click",function(){document.querySelector(".navactive").classList.add("navdisabled"),document.querySelector(".navactive").classList.remove("navactive"),this.classList.add("navactive"),this.classList.remove("navdisabled"),"triggers"==this.getAttribute("id")?document.getElementById("blocklist").innerHTML='\n          <div class="blockelem create-flowy noselect">\n            <input type="hidden" name="blockelemtype" class="blockelemtype" value="1">\n            <div class="grabme"><img src="'.concat(t.grabme,'"></div>\n            <div class="blockin">\n              <div class="blockico"><span></span><img src="').concat(t.eye,'"></div>\n              <div class="blocktext">\n                <p class="blocktitle">New visitor</p>\n                <p class="blockdesc">Triggers when somebody visits a specified page</p>\n              </div>\n            </div>\n          </div>\n          <div class="blockelem create-flowy noselect">\n            <input type="hidden" name="blockelemtype" class="blockelemtype" value="2">\n            <div class="grabme"><img src="').concat(t.grabme,'"></div>\n            <div class="blockin">\n              <div class="blockico"><span></span><img src="').concat(t.action,'"></div>\n              <div class="blocktext">\n                <p class="blocktitle">Action is performed</p>\n                <p class="blockdesc">Triggers when somebody performs a specified action</p>\n              </div>\n            </div>\n          </div>\n          <div class="blockelem create-flowy noselect">\n            <input type="hidden" name="blockelemtype" class="blockelemtype" value="3">\n            <div class="grabme"><img src="').concat(t.grabme,'"></div>\n            <div class="blockin">\n              <div class="blockico"><span></span><img src="').concat(t.time,'"></div>\n              <div class="blocktext">\n                <p class="blocktitle">Time has passed</p>\n                <p class="blockdesc">Triggers after a specified amount of time</p>\n              </div>\n            </div>\n          </div>\n          <div class="blockelem create-flowy noselect">\n            <input type="hidden" name="blockelemtype" class="blockelemtype" value="4">\n            <div class="grabme"><img src="').concat(t.grabme,'"></div>\n            <div class="blockin">\n              <div class="blockico"><span></span><img src="').concat(t.error,'"></div>\n              <div class="blocktext">\n                <p class="blocktitle">Error prompt</p>\n                <p class="blockdesc">Triggers when a specified error happens</p>\n              </div>\n            </div>\n          </div>\n        '):"actions"==this.getAttribute("id")?document.getElementById("blocklist").innerHTML='\n        <div class="blockelem create-flowy noselect">\n          <input type="hidden" name="blockelemtype" class="blockelemtype" value="5">\n          <div class="grabme"><img src="'.concat(t.grabme,'"></div>\n          <div class="blockin">\n            <div class="blockico"><span></span><img src="').concat(t.database,'"></div>\n            <div class="blocktext">\n              <p class="blocktitle">New database entry</p>\n              <p class="blockdesc">Adds a new entry to a specified database</p>\n            </div>\n          </div>\n        </div>\n        <div class="blockelem create-flowy noselect">\n          <input type="hidden" name="blockelemtype" class="blockelemtype" value="6">\n          <div class="grabme"><img src="').concat(t.grabme,'"></div>\n          <div class="blockin">\n            <div class="blockico"><span></span><img src="').concat(t.database,'"></div>\n            <div class="blocktext">\n              <p class="blocktitle">Update database</p>\n              <p class="blockdesc">Edits and deletes database entries and properties</p>\n            </div>\n          </div>\n        </div>\n        <div class="blockelem create-flowy noselect">\n          <input type="hidden" name="blockelemtype" class="blockelemtype" value="7">\n          <div class="grabme"><img src="').concat(t.grabme,'"></div>\n          <div class="blockin">\n            <div class="blockico"><span></span><img src="').concat(t.action,'"></div>\n            <div class="blocktext">\n              <p class="blocktitle">Perform an action</p>\n              <p class="blockdesc">Performs or edits a specified action</p>\n            </div>\n          </div>\n        </div>\n        <div class="blockelem create-flowy noselect">\n          <input type="hidden" name="blockelemtype" class="blockelemtype" value="8">\n          <div class="grabme"><img src="').concat(t.grabme,'"></div>\n          <div class="blockin">\n            <div class="blockico"><span></span><img src="').concat(t.twitter,'"></div>\n            <div class="blocktext">\n              <p class="blocktitle">Make a tweet</p>\n              <p class="blockdesc">Makes a tweet with a specified query</p>\n            </div>\n          </div>\n        </div>\n      '):"loggers"==this.getAttribute("id")&&(document.getElementById("blocklist").innerHTML='\n          <div class="blockelem create-flowy noselect">\n            <input type="hidden" name="blockelemtype" class="blockelemtype" value="9">\n            <div class="grabme"><img src="'.concat(t.grabme,'"></div>\n            <div class="blockin">\n              <div class="blockico"><span></span><img src="').concat(t.log,'"></div>\n              <div class="blocktext">\n                <p class="blocktitle">Add new log entry</p>\n                <p class="blockdesc">Adds a new log entry to this project</p>\n              </div>\n            </div>\n          </div>\n          <div class="blockelem create-flowy noselect">\n            <input type="hidden" name="blockelemtype" class="blockelemtype" value="10">\n            <div class="grabme"><img src="').concat(t.grabme,'"></div>\n            <div class="blockin">\n              <div class="blockico"><span></span><img src="').concat(t.log,'"></div>\n              <div class="blocktext">\n                <p class="blocktitle">Update logs</p>\n                <p class="blockdesc">Edits and deletes log entries in this project</p>\n              </div>\n            </div>\n          </div>\n          <div class="blockelem create-flowy noselect">\n            <input type="hidden" name="blockelemtype" class="blockelemtype" value="11">\n            <div class="grabme"><img src="').concat(t.grabme,'"></div>\n            <div class="blockin">\n              <div class="blockico"><span></span><img src="').concat(t.error,'"></div>\n              <div class="blocktext">\n                <p class="blocktitle">Prompt an error</p>\n                <p class="blockdesc">Triggers a specified error</p>\n              </div>\n            </div>\n          </div>\n        '))},!1,".side"),document.getElementById("close").addEventListener("click",function(){n&&(n=!1,document.getElementById("properties").classList.remove("expanded"),setTimeout(function(){document.getElementById("propwrap").classList.remove("itson")},300),c.classList.remove("selectedblock"))}),document.getElementById("removeblock").addEventListener("click",function(){e.default.deleteBlocks()});var i=!1,a=!1,o=function(e){i=!0,a=!1,e.target.closest(".create-flowy")&&(a=!0)};addEventListener("mousedown",o,!1),addEventListener("mousemove",function(e){i=!1},!1),addEventListener("mouseup",function(e){"mouseup"===e.type&&i&&!a&&(n||!e.target.closest(".block")||e.target.closest(".block").classList.contains("dragging")||(c=e.target.closest(".block"),n=!0,document.getElementById("properties").classList.add("expanded"),document.getElementById("propwrap").classList.add("itson"),c.classList.add("selectedblock")))},!1),l("touchstart",o,!1,".block")});
  },{"..":"S3PC","../engine/index.css":"vKFU","./main.css":"Sr7R","./assets/*.png":"HBCd","./assets/*.svg":"voxH"}]},{},["epB2"], null)
  //# sourceMappingURL=/main.1ebe6aff.js.map