From 0dc013fca2d3665a701da579fea078b651842cf1 Mon Sep 17 00:00:00 2001
From: unocelli
Date: Mon, 14 Feb 2022 09:44:19 +0100
Subject: [PATCH] Build for release
---
client/dist/assets/lib/svgeditor/fuxa-editor.min.js | 4 ++--
client/dist/index.html | 2 +-
client/dist/main.933530fe9ca97cf1ceb8.js | 1 -
client/dist/main.b084912cd613bfc48b95.js | 1 +
client/package.json | 2 +-
client/src/app/editor/setup/setup.component.ts | 2 +-
server/package.json | 2 +-
7 files changed, 7 insertions(+), 7 deletions(-)
delete mode 100644 client/dist/main.933530fe9ca97cf1ceb8.js
create mode 100644 client/dist/main.b084912cd613bfc48b95.js
diff --git a/client/dist/assets/lib/svgeditor/fuxa-editor.min.js b/client/dist/assets/lib/svgeditor/fuxa-editor.min.js
index 61c2b5e38..189701fb1 100644
--- a/client/dist/assets/lib/svgeditor/fuxa-editor.min.js
+++ b/client/dist/assets/lib/svgeditor/fuxa-editor.min.js
@@ -18,6 +18,6 @@ var mysvgcanvas={initSvgCanvas:function(e){window.console||(window.console={},wi
;if(Q.beginElement&&k.getAttribute("opacity")!=b.opacity){H=$(Q).clone().attr({to:b.opacity,dur:q}).appendTo(k);try{H[0].beginElement()}catch(e){}}else q=0;setTimeout(function(){H&&H.remove(),k.setAttribute("opacity",b.opacity),k.setAttribute("style","pointer-events:inherit"),P(k),"path"===current_mode||"pipe"===current_mode?he.toEditMode(k):a.selectNew&&ke([k],!0),W(new svgedit.history.InsertElementCommand(k)),D("changed",[k])},1e3*q)}}else{for(c().releaseId(de()),k.parentNode.removeChild(k),k=null,r=e.target;"g"==r.parentNode.parentNode.tagName;)r=r.parentNode;("path"==current_mode||"pipe"==current_mode)&&drawn_path||"selectorParentGroup"==r.parentNode.id||"svgcanvas"==r.id||"svgroot"==r.id||(o.setMode("select"),ke([r],!0))}startTransform=null}}},O=function(e){var t=e.target,i=t.parentNode;if(i!==f){var r=Ae(e),n=r.tagName;if("text"===n&&"textedit"!==current_mode){var a=svgedit.math.transformPoint(e.pageX,e.pageY,we);ge.select(r,a.x,a.y)}"g"!==n&&"a"!==n||!svgedit.utilities.getRotationAngle(r)||(Fe(r),r=S[0],_e(!0)),f&&$e(),"g"!==i.tagName&&"a"!==i.tagName||i===c().getCurrentLayer()||r===K.selectorParentGroup||Pe(r)}},V=function(e){return e.preventDefault(),!1};$(e).mousedown(G).mousemove(M).click(V).dblclick(O).mouseup(L),$(e).bind("mousewheel DOMMouseScroll",function(e){if(!e.shiftKey)return;const t=v;e.preventDefault();var i=e.originalEvent;we=$("#svgcontent g")[0].getScreenCTM().inverse();const r=$("#workarea"),n=0,a=0;var s=svgedit.math.transformPoint(i.pageX,i.pageY,we);const o=r.width(),l=r.height(),d=o-n-a,u=l-n-a,g=d*we.a,h=u*we.d,m=r.offset(),c=m.left+a,f=m.top+a;var p=i.wheelDelta?i.wheelDelta:i.detail?-i.detail:0;if(!p)return;let y,x,b=Math.max(.9,Math.min(10/9,p));b>1?(y=Math.ceil(d/g*b*100)/100,x=Math.ceil(u/h*b*100)/100):(y=Math.floor(d/g*b*100)/100,x=Math.floor(u/h*b*100)/100);let S=Math.min(y,x);if(S===t)return;b=S/t;const C=svgedit.math.transformPoint(c,f,we),w={x:s.x-(s.x-C.x)/b,y:s.y-(s.y-C.y)/b},_={x:w.x*S,y:w.y*S},N={x:_.x-a+o/2,y:_.y-a+l/2,width:0,height:0,factor:b};D("myZoomed",{center:!1,bbox:N})})})();var Ee=function(e){$(e).click(function(e){e.preventDefault()})};ge=o.textActions=function(){function e(e){var t,i=""===m.value;if($(m).focus(),!arguments.length)if(i)e=0;else{if(m.selectionEnd!==m.selectionStart)return;e=m.selectionEnd}if(t=_[e],t){i||m.setSelectionRange(e,e),c=svgedit.utilities.getElem("text_cursor"),c||(c=document.createElementNS(n.SVG,"line"),svgedit.utilities.assignAttributes(c,{id:"text_cursor",stroke:"#333","stroke-width":1}),c=svgedit.utilities.getElem("selectorParentGroup").appendChild(c)),p||(p=setInterval(function(){var e="none"===c.getAttribute("display");c.setAttribute("display",e?"inline":"none")},600));var r=l(t.x,y.y),a=l(t.x,y.y+y.height);svgedit.utilities.assignAttributes(c,{x1:r.x,y1:r.y,x2:a.x,y2:a.y,visibility:"visible",display:"inline"}),f&&f.setAttribute("d","")}}function t(t,i,r){if(t!==i){r||m.setSelectionRange(t,i),f=svgedit.utilities.getElem("text_selectblock"),f||(f=document.createElementNS(n.SVG,"path"),svgedit.utilities.assignAttributes(f,{id:"text_selectblock",fill:"green",opacity:.5,style:"pointer-events:none"}),svgedit.utilities.getElem("selectorParentGroup").appendChild(f));var a=_[t],s=_[i];c.setAttribute("visibility","hidden");var o=l(a.x,y.y),d=l(a.x+(s.x-a.x),y.y),u=l(a.x,y.y+y.height),g=l(a.x+(s.x-a.x),y.y+y.height),h="M"+o.x+","+o.y+" L"+d.x+","+d.y+" "+g.x+","+g.y+" "+u.x+","+u.y+"z";svgedit.utilities.assignAttributes(f,{d:h,display:"inline"})}else e(i)}function i(e,t){var i=u.createSVGPoint();if(i.x=e,i.y=t,1==_.length)return 0;var r=h.getCharNumAtPosition(i);r<0?(r=_.length-2,e<=_[0].x&&(r=0)):r>=_.length-2&&(r=_.length-2);var n=_[r],a=n.x+n.width/2;return e>a&&r++,r}function r(t,r){e(i(t,r))}function a(e,r,n){var a=m.selectionStart,s=i(e,r),o=Math.min(a,s),l=Math.max(a,s);t(o,l,!n)}function s(e,t){var i={x:e,y:t};if(i.x/=v,i.y/=v,x){var r=svgedit.math.transformPoint(i.x,i.y,x.inverse());i.x=r.x,i.y=r.y}return i}function l(e,t){var i={x:e,y:t};if(x){var r=svgedit.math.transformPoint(i.x,i.y,x);i.x=r.x,i.y=r.y}return i.x*=v,i.y*=v,i}function d(e){t(0,h.textContent.length),$(this).unbind(e)}function g(e){if(w&&h){var r=svgedit.math.transformPoint(e.pageX,e.pageY,we),n=r.x*v,a=r.y*v,o=s(n,a),l=i(o.x,o.y),u=h.textContent,g=u.substr(0,l).replace(/[a-z0-9]+$/i,"").length,m=u.substr(l).match(/^[a-z0-9]+/i),c=(m?m[0].length:0)+l;t(g,c),$(e.target).click(d),setTimeout(function(){$(e.target).unbind("click",d)},300)}}var h,m,c,f,p,y,x,b,C,w,_=[];return{select:function(e,t,i){h=e,ge.toEditMode(t,i)},start:function(e){h=e,ge.toEditMode()},mouseDown:function(e,t,i,n){var a=s(i,n);m.focus(),r(a.x,a.y),b=i,C=n},mouseMove:function(e,t){var i=s(e,t);a(i.x,i.y)},mouseUp:function(e,t,i){var r=s(t,i);a(r.x,r.y,!0),e.target!==h&&tb-2&&iC-2&&ge.toSelectMode(!0)},setCursor:e,toEditMode:function(t,i){w=!1,current_mode="textedit",K.requestSelector(h).showGrips(!1);K.requestSelector(h).selectorRect;if(ge.init(),$(h).css("cursor","text"),arguments.length){var n=s(t,i);r(n.x,n.y)}else e();setTimeout(function(){w=!0},300)},toSelectMode:function(e){current_mode="select",clearInterval(p),p=null,f&&$(f).attr("display","none"),c&&$(c).attr("visibility","hidden"),$(h).css("cursor","move"),e&&(_e(),$(h).css("cursor","move"),D("selected",[h]),Ne([h],!0)),h&&!h.textContent.length&&o.deleteSelectedElements(),$(m).blur(),h=!1},setInputElem:function(e){m=e},clear:function(){"textedit"==current_mode&&ge.toSelectMode()},init:function(e){if(h){var i,r;h.parentNode||(h=S[0],K.requestSelector(h).showGrips(!1));var n=h.textContent,a=n.length,s=h.getAttribute("transform");for(y=svgedit.utilities.getBBox(h),x=s?svgedit.math.getMatrix(h):null,_=[],_.length=a,m.focus(),$(h).unbind("dblclick",g).dblclick(g),a||(r={x:y.x+y.width/2,width:0}),i=0;i=0&&this.selected_pts.push(r)}this.selected_pts.sort(),t=this.selected_pts.length;var n=[];for(n.length=t;t--;){var a=this.selected_pts[t];i=this.segs[a],i.select(!0),n[t]=i.ptgrip}he.canDeleteNodes=!0,he.closed_subpath=this.subpathIsClosed(this.selected_pts[0]),D("selected",n)},i=null;var u=null,g=!1,h=function(e){var t,i=e.points,r=i.numberOfItems;if(r>=4){var n=i.getItem(0),a=null,s=[];for(s.push(["M",n.x,",",n.y," C"].join("")),t=1;t<=r-4;t+=3){var o=i.getItem(t),l=i.getItem(t+1),d=i.getItem(t+2);if(a){var u=svgedit.path.smoothControlPoints(a,o,n);if(u&&2==u.length){var g=s[s.length-1].split(",");g[2]=u[0].x,g[3]=u[0].y,s[s.length-1]=g.join(","),o=u[1]}}s.push([o.x,o.y,l.x,l.y,d.x,d.y].join(",")),n=d,a=l}for(s.push("L");t=E-N&&f<=E+N&&p>=B-N&&p<=B+N){k=!0;break}}l=de(),svgedit.path.removePath_(l);var T,I,G=svgedit.utilities.getElem(l),M=w.numberOfItems;if(k){if(_<=1&&M>=2&&"pipe"!==current_mode){var L=w.getItem(0).x,P=w.getItem(0).y;I=y.pathSegList.getItem(1),T=4===I.pathSegType?u.createSVGPathSegLinetoAbs(L,P):u.createSVGPathSegCurvetoCubicAbs(L,P,I.x1/v,I.y1/v,L,P);var O=u.createSVGPathSegClosePath();w.appendItem(T),w.appendItem(O)}else if(M<3&&"pipe"!==current_mode)return S=!1,S;if($(y).remove(),element=G,u=null,started=!1,d){svgedit.path.path.matrix&&svgedit.coords.remapElement(G,{},svgedit.path.path.matrix.inverse());var D=G.getAttribute("d"),V=$(svgedit.path.path.elem).attr("d");return $(svgedit.path.path.elem).attr("d",V+D),$(G).remove(),svgedit.path.path.matrix&&svgedit.path.recalcRotatedPath(),svgedit.path.path.init(),he.toEditMode(svgedit.path.path.elem),svgedit.path.path.selectPt(),!1}}else{if(!$.contains(e,Ae(t)))return console.log("Clicked outside canvas"),!1;var R=u.pathSegList.numberOfItems,U=u.pathSegList.getItem(R-1),z=U.x,F=U.y;if(t.shiftKey){var j=svgedit.math.snapToAngle(z,F,f,p);f=j.x,p=j.y}I=y.pathSegList.getItem(1),T=4===I.pathSegType?u.createSVGPathSegLinetoAbs(oe(f),oe(p)):u.createSVGPathSegCurvetoCubicAbs(oe(f),oe(p),I.x1/v,I.y1/v,I.x2/v,I.y2/v),u.pathSegList.appendItem(T),f*=v,p*=v,y.setAttribute("d",["M",f,p,f,p].join(" ")),x=R,d&&(x+=svgedit.path.path.segs.length),svgedit.path.addPointGrip(x,f,p)}}else{if(d_attr="M"+f+","+p+" ",path_attr={d:d_attr,id:ue(),opacity:b.opacity/2},"pipe"===current_mode){var H=ue().replace("svg_","PIE_");path_attr={d:d_attr,id:H,type:"svg-ext-pipe",fill:"rgba(0,0,0,0)",stroke:"rgba(41,171,226,1)","stroke-width":10,opacity:b.opacity/2}}u=C({element:"path",curStyles:!0,attr:path_attr}),y.setAttribute("d",["M",mouse_x,mouse_y,mouse_x,mouse_y].join(" ")),x=d?svgedit.path.path.segs.length:0,svgedit.path.addPointGrip(x,mouse_x,mouse_y)}}},mouseMove:function(e,t){if(g=!0,"path"!==current_mode&&"pipe"!==current_mode)if(svgedit.path.path.dragging){var i=svgedit.path.getPointFromGrip({x:svgedit.path.path.dragging[0],y:svgedit.path.path.dragging[1]},svgedit.path.path),r=svgedit.path.getPointFromGrip({x:e,y:t},svgedit.path.path),n=r.x-i.x,a=r.y-i.y;svgedit.path.path.dragging=[e,t],svgedit.path.path.dragctrl?svgedit.path.path.moveCtrl(n,a):svgedit.path.path.movePts(n,a)}else svgedit.path.path.selected_pts=[],svgedit.path.path.eachSeg(function(e){var t=this;if(t.next||t.prev){t.item;var i=rubberBox.getBBox(),r=svgedit.path.getGripPt(t),n={x:r.x,y:r.y,width:0,height:0},a=svgedit.math.rectsIntersect(i,n);this.select(a),a&&svgedit.path.path.selected_pts.push(t.index)}});else{if(!u)return;var o=u.pathSegList,d=o.numberOfItems-1;if(s){var h=svgedit.path.addCtrlGrip("1c1"),m=svgedit.path.addCtrlGrip("0c2");h.setAttribute("cx",e),h.setAttribute("cy",t),h.setAttribute("display","inline");var c=s[0],f=s[1],p=(o.getItem(d),e/v),y=t/v,x=c+(c-p),b=f+(f-y);m.setAttribute("cx",x*v),m.setAttribute("cy",b*v),m.setAttribute("display","inline");var S=svgedit.path.getCtrlLine(1);if(svgedit.utilities.assignAttributes(S,{x1:e,y1:t,x2:x*v,y2:b*v,display:"inline"}),0===d)l=[e,t];else{var C=o.getItem(d-1),w=C.x,_=C.y;6===C.pathSegType?(w+=w-C.x2,_+=_-C.y2):l&&(w=l[0]/v,_=l[1]/v),svgedit.path.replacePathSeg(6,d,[c,f,w,_,x,b],u)}}else{var N=svgedit.utilities.getElem("path_stretch_line");if(N){var k=o.getItem(d);if(6===k.pathSegType){var A=k.x+(k.x-k.x2),E=k.y+(k.y-k.y2);svgedit.path.replacePathSeg(6,1,[e,t,A*v,E*v,e,t],N)}else l?svgedit.path.replacePathSeg(6,1,[e,t,l[0],l[1],e,t],N):svgedit.path.replacePathSeg(4,1,[e,t],N)}}}},mouseUp:function(e,t,i,r){if("path"===current_mode||"pipe"===current_mode){if(s=null,!u){var n=de();"pipe"===current_mode&&(n=n.replace("svg_","PIE_")),t=svgedit.utilities.getElem(n),started=!1,l=null}return{keep:!0,element:t}}if(svgedit.path.path.dragging){var a=svgedit.path.path.cur_pt;svgedit.path.path.dragging=!1,svgedit.path.path.dragctrl=!1,svgedit.path.path.update(),g&&svgedit.path.path.endChanges("Move path point(s)"),e.shiftKey||g||svgedit.path.path.selectPt(a)}else rubberBox&&"none"!=rubberBox.getAttribute("display")?(rubberBox.setAttribute("display","none"),rubberBox.getAttribute("width")<=2&&rubberBox.getAttribute("height")<=2&&he.toSelectMode(e.target)):he.toSelectMode(e.target);g=!1},toEditMode:function(e){svgedit.path.path=svgedit.path.getPath_(e),current_mode="pathedit",_e(),svgedit.path.path.show(!0).update(),svgedit.path.path.oldbbox=svgedit.utilities.getBBox(svgedit.path.path.elem),d=!1},toSelectMode:function(e){var t=e==svgedit.path.path.elem;current_mode="select",svgedit.path.path.show(!1),i=!1,_e(),svgedit.path.path.matrix&&svgedit.path.recalcRotatedPath(),t&&(D("selected",[e]),Ne([e],!0))},addSubPath:function(e){e?(current_mode="path",d=!0):(he.clear(!0),he.toEditMode(svgedit.path.path.elem))},select:function(e){i===e?(he.toEditMode(e),current_mode="pathedit"):i=e},reorient:function(){var e=S[0];if(e){var t=svgedit.utilities.getRotationAngle(e);if(0!=t){var i=new svgedit.history.BatchCommand("Reorient path"),r={d:e.getAttribute("d"),transform:e.getAttribute("transform")};i.addSubCommand(new svgedit.history.ChangeElementCommand(e,r)),_e(),this.resetOrientation(e),W(i),svgedit.path.getPath_(e).show(!1).matrix=null,this.clear(),Ne([e],!0),D("changed",S)}}},clear:function(e){if(i=null,u){var t=svgedit.utilities.getElem(de());$(svgedit.utilities.getElem("path_stretch_line")).remove(),$(t).remove(),$(svgedit.utilities.getElem("pathpointgrip_container")).find("*").attr("display","none"),u=l=null,started=!1}else"pathedit"==current_mode&&this.toSelectMode();svgedit.path.path&&svgedit.path.path.init().show(!1)},resetOrientation:function(e){if(null==e||"path"!=e.nodeName)return!1;var t=svgedit.transformlist.getTransformList(e),i=svgedit.math.transformListToTransform(t).matrix;t.clear(),e.removeAttribute("transform");var n,a=e.pathSegList,s=a.numberOfItems;for(n=0;n0){var o=e.getItem(t-1).pathSegType;if(2===o){i(t-1,1),r();break}if(1===o&&e.numberOfItems-1===t){i(t,1),r();break}}}return!1};if(r(),svgedit.path.path.elem.pathSegList.numberOfItems<=1)return he.toSelectMode(svgedit.path.path.elem),void o.deleteSelectedElements();if(svgedit.path.path.init(),svgedit.path.path.clearSelection(),window.opera){var n=$(svgedit.path.path.elem);n.attr("d",n.attr("d"))}svgedit.path.path.endChanges("Delete path node(s)")}},smoothPolylineIntoPath:h,setSegType:function(e){svgedit.path.path.setSegType(e)},moveNode:function(e,t){var i=svgedit.path.path.selected_pts;if(i.length){svgedit.path.path.storeD();var r=svgedit.path.path.segs[i[0]],n={x:0,y:0};n[e]=t-r.item[e],r.move(n.x,n.y),svgedit.path.path.endChanges("Move path point")}},fixEnd:function(e){var i,r,n=e.pathSegList,a=n.numberOfItems;for(i=0;i0;);he.clear(!0),$.each(g.childNodes,function(e,t){e&&8===t.nodeType&&t.data.indexOf("Created with")>=0&&g.insertBefore(t,g.firstChild)}),f&&($e(),ke([f]));var e=[];$(g).find("g:data(gsvg)").each(function(){var t,i=this.attributes,r=i.length;for(t=0;t=0)return i.join("");P(e);var d,u,g=e.attributes,h=e.childNodes;for(u=0;u=0;u--){d=g.item(u);p=r(d.value);if(!(y.indexOf(d.localName)>=0)&&""!=p){if(0===p.indexOf("pointer-events"))continue;if("class"===d.localName&&0===p.indexOf("se_"))continue;if(i.push(" "),"d"===d.localName&&(p=he.convertPath(e,!1)),isNaN(p)?o.test(p)&&(p=svgedit.units.shortFloat(p)+s):p=svgedit.units.shortFloat(p),save_options.apply&&"image"===e.nodeName&&"href"===d.localName&&save_options.images&&"embed"===save_options.images){var x=te[p];x&&(p=x)}d.namespaceURI&&d.namespaceURI!=n.SVG&&!R[d.namespaceURI]||(i.push(d.nodeName),i.push('="'),i.push(p),i.push('"'))}}}if(e.hasChildNodes()){i.push(">"),t++;var b=!1;for(u=0;u");break;case 8:i.push("\n"),i.push(new Array(t+1).join(" ")),i.push("")}}if(t--,!b)for(i.push("\n"),u=0;u")}else"div"===e.nodeName.toLowerCase()||"span"===e.nodeName.toLowerCase()?(i.push(">"),i.push(""),i.push(e.nodeName),i.push(">")):i.push("/>")}return i.join("")},this.embedImage=function(e,t){$(new Image).load(function(){var i=document.createElement("canvas");i.width=this.width,i.height=this.height,i.getContext("2d").drawImage(this,0,0);try{var r=";svgedit_url="+encodeURIComponent(e);r=i.toDataURL().replace(";base64",r+";base64"),te[e]=r}catch(t){te[e]=!1}ie=e,t&&t(te[e])}).attr("src",e)},this.setGoodImage=function(e){ie=e},this.setGoodSvgImageContent=function(e){last_good_img_content=e},this.open=function(){},this.save=function(e){_e(),e&&$.extend(save_options,e),save_options.apply=!0;var t=this.svgCanvasToString();D("saved",t)},this.rasterExport=function(e,t,r){var n="image/"+e.toLowerCase(),a=i(),s=this.svgCanvasToString();svgedit.utilities.buildCanvgCallback(function(){var i=e||"PNG";$("#export_canvas").length||$("
")+"
").toggleClass("prompt","prompt"==i),n.empty(),d=e('').appendTo(n),"alert"!==i&&e('').appendTo(n).click(function(){t.hide(),r&&r(!1)}),"prompt"===i)f=e('').prependTo(n),f.val(l||""),f.bind("keydown","return",function(){d.click()});else if("select"===i){var g=e('');if(f=e("