remove static/ from git & ignore (#265)

This commit is contained in:
David Luzar authored and GitHub committed 2020-01-08 19:18:17 +01:00
1 parent 58ec6567ae
commit 7f7f51f70b
10 files changed
+4 -46

No files matched your search

+4 -1
View File
@@ -17,4 +17,7 @@ yarn.lock
# Editors
.vscode/
.DS_Store
.DS_Store
# build files
static/
-2
View File
@@ -1,2 +0,0 @@
@font-face{font-family:Virgil;src:url(https://uploads.codesandbox.io/uploads/user/ed077012-e728-4a42-8395-cbd299149d62/AflB-FG_Virgil.ttf);font-display:swap}body{margin:0;font-family:Arial,Helvetica,sans-serif}.container{display:flex;position:fixed;top:0;bottom:0;left:0;right:0}.sidePanel{width:230px;background-color:#eee;padding:10px;overflow-y:auto}.sidePanel h4{margin:10px 0}.sidePanel .panelTools{display:flex;justify-content:space-between}.sidePanel .panelTools label{margin:0}.sidePanel .panelColumn{display:flex;flex-direction:column}.tool{position:relative}.tool input[type=radio]{position:absolute;opacity:0;width:0;height:0}.tool input[type=radio]+.toolIcon{background-color:#ddd;width:41px;height:41px;display:flex;justify-content:center;align-items:center;border-radius:3px}.tool input[type=radio]+.toolIcon svg{height:1em}.tool input[type=radio]:hover+.toolIcon{background-color:#e7e5e5}.tool input[type=radio]:checked+.toolIcon{background-color:#bdbebc}.tool input[type=radio]:focus+.toolIcon{box-shadow:0 0 0 2px #4682b4}label{margin-right:6px}label span{display:inline-block}input[type=number]{width:30px}input[type=color]{margin:2px}input{margin-right:5px}input:focus{box-shadow:0 0 0 2px #4682b4}button,input:focus{outline:transparent}button{background-color:#ddd;border:1px solid #ccc;border-radius:4px;margin:2px 0;padding:5px}button:focus{box-shadow:0 0 0 2px #4682b4}button:hover{background-color:#e7e5e5;border-color:#d6d4d4}button:active{background-color:#bdbebc;border-color:#bdbebc}button:disabled{cursor:not-allowed}
/*# sourceMappingURL=main.4b4142f8.chunk.css.map */
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["styles.scss"],"names":[],"mappings":"AACA,WACE,kBAAqB,CACrB,4GAA+G,CAC/G,iBAAkB,CAGpB,KACE,QAAS,CACT,sCAAyC,CAC1C,WAGC,YAAa,CACb,cAAe,CACf,KAAM,CACN,QAAS,CACT,MAAO,CACP,OAAQ,CACT,WAGC,WAAY,CACZ,qBAAsB,CAEtB,YAAa,CACb,eAAgB,CALlB,cAQI,aAAqB,CARzB,uBAYI,YAAa,CACb,6BAA8B,CAblC,6BAgBM,QAAS,CAhBf,wBAqBI,YAAa,CACb,qBAAsB,CACvB,MAID,iBAAkB,CADpB,wBAII,iBAAkB,CAClB,SAAU,CACV,OAAQ,CACR,QAAS,CAPb,kCAYM,qBAAsB,CAEtB,UAAW,CACX,WAAY,CAEZ,YAAa,CACb,sBAAuB,CACvB,kBAAmB,CAEnB,iBAAkB,CArBxB,sCAwBQ,UAAW,CAxBnB,wCA4BM,wBAAyB,CA5B/B,0CA+BM,wBAAyB,CA/B/B,wCAkCM,4BAA+B,CAChC,MAKH,gBAAiB,CADnB,WAGI,oBAAqB,CACtB,mBAID,UAAW,CACZ,kBAGC,UAAW,CACZ,MAGC,gBAAiB,CADnB,YAKI,4BAA+B,CAChC,mBAFC,mBAWkB,CATnB,OAID,qBAAsB,CACtB,qBAAsB,CACtB,iBAAkB,CAClB,YAAa,CACb,WACoB,CANtB,aASI,4BAA+B,CATnC,aAaI,wBAAyB,CACzB,oBAAqB,CAdzB,cAkBI,wBAAyB,CACzB,oBAAqB,CAnBzB,gBAuBI,kBAAmB","file":"main.4b4142f8.chunk.css","sourcesContent":["/* http://www.eaglefonts.com/fg-virgil-ttf-131249.htm */\n@font-face {\n font-family: \"Virgil\";\n src: url(\"https://uploads.codesandbox.io/uploads/user/ed077012-e728-4a42-8395-cbd299149d62/AflB-FG_Virgil.ttf\");\n font-display: swap;\n}\n\nbody {\n margin: 0;\n font-family: Arial, Helvetica, sans-serif;\n}\n\n.container {\n display: flex;\n position: fixed;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n}\n\n.sidePanel {\n width: 230px;\n background-color: #eee;\n\n padding: 10px;\n overflow-y: auto;\n\n h4 {\n margin: 10px 0 10px 0;\n }\n\n .panelTools {\n display: flex;\n justify-content: space-between;\n\n label {\n margin: 0;\n }\n }\n\n .panelColumn {\n display: flex;\n flex-direction: column;\n }\n}\n\n.tool {\n position: relative;\n\n input[type=\"radio\"] {\n position: absolute;\n opacity: 0;\n width: 0;\n height: 0;\n }\n\n input[type=\"radio\"] {\n & + .toolIcon {\n background-color: #ddd;\n\n width: 41px;\n height: 41px;\n\n display: flex;\n justify-content: center;\n align-items: center;\n\n border-radius: 3px;\n\n svg {\n height: 1em;\n }\n }\n &:hover + .toolIcon {\n background-color: #e7e5e5;\n }\n &:checked + .toolIcon {\n background-color: #bdbebc;\n }\n &:focus + .toolIcon {\n box-shadow: 0 0 0 2px steelblue;\n }\n }\n}\n\nlabel {\n margin-right: 6px;\n span {\n display: inline-block;\n }\n}\n\ninput[type=\"number\"] {\n width: 30px;\n}\n\ninput[type=\"color\"] {\n margin: 2px;\n}\n\ninput {\n margin-right: 5px;\n\n &:focus {\n outline: transparent;\n box-shadow: 0 0 0 2px steelblue;\n }\n}\n\nbutton {\n background-color: #ddd;\n border: 1px solid #ccc;\n border-radius: 4px;\n margin: 2px 0;\n padding: 5px;\n outline: transparent;\n\n &:focus {\n box-shadow: 0 0 0 2px steelblue;\n }\n\n &:hover {\n background-color: #e7e5e5;\n border-color: #d6d4d4;\n }\n\n &:active {\n background-color: #bdbebc;\n border-color: #bdbebc;\n }\n\n &:disabled {\n cursor: not-allowed;\n }\n}\n"]}
-3
View File
@@ -1,3 +0,0 @@
/*! For license information please see 2.3fb278bc.chunk.js.LICENSE */
(this.webpackJsonpreact=this.webpackJsonpreact||[]).push([[2],[function(e,t,n){"use strict";e.exports=n(13)},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}n.d(t,"a",(function(){return a}))},function(e,t,n){"use strict";function r(e){return(r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";function r(e){return(r="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function a(e){return(a="function"===typeof Symbol&&"symbol"===r(Symbol.iterator)?function(e){return r(e)}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":r(e)})(e)}function i(e,t){return!t||"object"!==a(t)&&"function"!==typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}n.d(t,"a",(function(){return i}))},function(e,t,n){"use strict";function r(e,t){return(r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function a(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)}n.d(t,"a",(function(){return a}))},function(e,t,n){"use strict";function r(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e)){var n=[],r=!0,a=!1,i=void 0;try{for(var l,o=e[Symbol.iterator]();!(r=(l=o.next()).done)&&(n.push(l.value),!t||n.length!==t);r=!0);}catch(u){a=!0,i=u}finally{try{r||null==o.return||o.return()}finally{if(a)throw i}}return n}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";var r=n(1),a=n(2),i=n(4),l=n(3),o=n(5),u="undefined"!==typeof self,s=function(){function e(t,n){Object(r.a)(this,e),this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:"#000",strokeWidth:1,curveTightness:0,curveStepCount:9,fillStyle:"hachure",fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1},this.config=t||{},this.surface=n,this.config.options&&(this.defaultOptions=this._options(this.config.options))}return Object(a.a)(e,[{key:"_options",value:function(e){return e?Object.assign({},this.defaultOptions,e):this.defaultOptions}},{key:"_drawable",value:function(e,t,n){return{shape:e,sets:t||[],options:n||this.defaultOptions}}},{key:"getCanvasSize",value:function(){var e=function(e){return e&&"object"===typeof e&&e.baseVal&&e.baseVal.value?e.baseVal.value:e||100};return this.surface?[e(this.surface.width),e(this.surface.height)]:[100,100]}},{key:"computePolygonSize",value:function(e){if(e.length){for(var t=e[0][0],n=e[0][0],r=e[0][1],a=e[0][1],i=1;i<e.length;i++)t=Math.min(t,e[i][0]),n=Math.max(n,e[i][0]),r=Math.min(r,e[i][1]),a=Math.max(a,e[i][1]);return[n-t,a-r]}return[0,0]}},{key:"polygonPath",value:function(e){var t="";if(e.length){t="M".concat(e[0][0],",").concat(e[0][1]);for(var n=1;n<e.length;n++)t="".concat(t," L").concat(e[n][0],",").concat(e[n][1])}return t}},{key:"computePathSize",value:function(e){var t=[0,0];if(u&&self.document)try{var n="http://www.w3.org/2000/svg",r=self.document.createElementNS(n,"svg");r.setAttribute("width","0"),r.setAttribute("height","0");var a=self.document.createElementNS(n,"path");a.setAttribute("d",e),r.appendChild(a),self.document.body.appendChild(r);var i=a.getBBox();i&&(t[0]=i.width||0,t[1]=i.height||0),self.document.body.removeChild(r)}catch(o){}var l=this.getCanvasSize();return t[0]*t[1]||(t=l),t}},{key:"toPaths",value:function(e){var t=e.sets||[],n=e.options||this.defaultOptions,r=[],a=!0,i=!1,l=void 0;try{for(var o,u=t[Symbol.iterator]();!(a=(o=u.next()).done);a=!0){var s=o.value,c=null;switch(s.type){case"path":c={d:this.opsToPath(s),stroke:n.stroke,strokeWidth:n.strokeWidth,fill:"none"};break;case"fillPath":c={d:this.opsToPath(s),stroke:"none",strokeWidth:0,fill:n.fill||"none"};break;case"fillSketch":c=this.fillSketch(s,n);break;case"path2Dfill":c={d:s.path||"",stroke:"none",strokeWidth:0,fill:n.fill||"none"};break;case"path2Dpattern":var f=s.size,d={x:0,y:0,width:1,height:1,viewBox:"0 0 ".concat(Math.round(f[0])," ").concat(Math.round(f[1])),patternUnits:"objectBoundingBox",path:this.fillSketch(s,n)};c={d:s.path,stroke:"none",sLine truncated
//# sourceMappingURL=2.3fb278bc.chunk.js.map
-32
View File
@@ -1,32 +0,0 @@
/*
object-assign
(c) Sindre Sorhus
@license MIT
*/
/** @license React v16.12.0
* react.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v16.12.0
* react-dom.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v0.18.0
* scheduler.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../node_modules/react/index.js","../node_modules/@babel/runtime/helpers/esm/classCallCheck.js","../node_modules/@babel/runtime/helpers/esm/createClass.js","../node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js","../node_modules/@babel/runtime/helpers/esm/typeof.js","../node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js","../node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js","../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../node_modules/@babel/runtime/helpers/esm/inherits.js","../node_modules/@babel/runtime/helpers/esm/slicedToArray.js","../node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js","../node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js","../node_modules/@babel/runtime/helpers/esm/nonIterableRest.js","../node_modules/roughjs/bin/generator-base.js","../node_modules/roughjs/bin/path.js","../node_modules/roughjs/bin/geometry.js","../node_modules/roughjs/bin/utils/hachure.js","../node_modules/roughjs/bin/fillers/filler-utils.js","../node_modules/roughjs/bin/fillers/hachure-filler.js","../node_modules/roughjs/bin/fillers/zigzag-filler.js","../node_modules/roughjs/bin/fillers/hatch-filler.js","../node_modules/roughjs/bin/fillers/dot-filler.js","../node_modules/roughjs/bin/fillers/starburst-filler.js","../node_modules/roughjs/bin/fillers/dashed-filler.js","../node_modules/roughjs/bin/fillers/zigzag-line-filler.js","../node_modules/roughjs/bin/fillers/filler.js","../node_modules/roughjs/bin/renderer.js","../node_modules/roughjs/bin/generator.js","../node_modules/roughjs/bin/canvas-base.js","../node_modules/roughjs/bin/canvas.js","../node_modules/roughjs/bin/svg-base.js","../node_modules/roughjs/bin/svg.js","../node_modules/roughjs/bin/wrappers/rough.js","../node_modules/react-dom/index.js","../node_modules/@babel/runtime/helpers/esm/defineProperty.js","../node_modules/@babel/runtime/helpers/esm/objectSpread2.js","../node_modules/object-assign/index.js","../node_modules/@babel/runtime/helpers/esm/toConsumableArray.js","../node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js","../node_modules/@babel/runtime/helpers/esm/iterableToArray.js","../node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js","../node_modules/react/cjs/react.production.min.js","../node_modules/react-dom/cjs/react-dom.production.min.js","../node_modules/scheduler/index.js","../node_modules/scheduler/cjs/scheduler.production.min.js"],"names":["module","exports","require","_classCallCheck","instance","Constructor","TypeError","_defineProperties","target","props","i","length","descriptor","enumerable","configurable","writable","Object","defineProperty","key","_createClass","protoProps","staticProps","prototype","_getPrototypeOf","o","setPrototypeOf","getPrototypeOf","__proto__","_typeof2","obj","Symbol","iterator","constructor","_typeof","_possibleConstructorReturn","self","call","ReferenceError","_setPrototypeOf","p","_inherits","subClass","superClass","create","value","_slicedToArray","arr","Array","isArray","toString","_arr","_n","_d","_e","undefined","_s","_i","next","done","push","err","hasSelf","RoughGeneratorBase","config","surface","this","defaultOptions","maxRandomnessOffset","roughness","bowing","stroke","strokeWidth","curveTightness","curveStepCount","fillStyle","fillWeight","hachureAngle","hachureGap","dashOffset","dashGap","zigzagOffset","options","_options","assign","shape","sets","val","w","baseVal","width","height","points","left","right","top","bottom","Math","min","max","d","size","document","ns","svg","createElementNS","setAttribute","pathNode","appendChild","body","bb","getBBox","removeChild","canvasSize","getCanvasSize","drawable","paths","drawing","path","type","opsToPath","fill","fillSketch","pattern","x","y","viewBox","round","patternUnits","fweight","ops","item","data","op","trim","isType","token","PARAMS","A","a","C","c","H","h","L","l","M","m","Q","q","S","s","T","t","V","v","Z","z","ParsedPath","COMMAND","NUMBER","EOD","segments","parseData","processPoints","tokens","match","substr","RegExp","$1","text","console","error","parseFloat","tokenize","index","mode","param_length","params","numbeToken","segment","first","currentPoint","point","_closed","toLowerCase","RoughPath","_position","_first","bezierReflectionPoint","quadReflectionPoint","parsed","closed","_linearPoints","lp","RoughArcConverter","from","to","radii","angle","largeArcFlag","sweepFlag","_segIndex","_numSegs","_rx","_ry","_sinPhi","_cosPhi","_C","_theta","_delta","_T","_from","radPerDeg","PI","abs","sin","cos","x1dash","y1dash","root","numerator","sqrt","cxdash","cydash","calculateVectorAngle","dtheta","ceil","cosTheta1","sinTheta1","theta2","cosTheta2","sinTheta2","cp1","cp2","ux","uy","vx","vy","ta","atan2","tb","PathFitter","simplification","outSets","set","estLength","floor","reduce","p1","p2","pow","count","slice","areas","minArea","minIndex","distance","b","area","splice","Segment","xi","Number","MAX_VALUE","yi","px1","py1","px2","Line truncated
-2
View File
@@ -1,2 +0,0 @@
(this.webpackJsonpreact=this.webpackJsonpreact||[]).push([[0],{12:function(e,t,n){e.exports=n(18)},17:function(e,t,n){},18:function(e,t,n){"use strict";n.r(t);var r=n(1),a=n(2),o=n(4),l=n(3),i=n(5),c=n(11),s=n(6),u=n(9),f=n(0),h=n.n(f),d=n(8),v=n.n(d),m=n(7);function p(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function g(e,t){t.sort((function(e,t){return e-t}));var n=!0;t.forEach((function(t,r){(n=n&&t===r)||p(e,t-1,t)}))}function y(e,t){var n=t.sort((function(e,t){return t-e})),r=!0;n.forEach((function(t,n){(r=r&&t===e.length-n-1)||p(e,t+1,t)}))}function w(e,t){t.sort((function(e,t){return e-t}));var n=t.map((function(t){return e[t]})),r=t.reverse().concat([0]);r.forEach((function(t,n){if(0!==n)for(var a=r[n-1]-1;a>=t;--a)e[a+n]=e[a]})),n.forEach((function(t,n){e[n]=t}))}function E(e,t){var n=t.sort((function(e,t){return t-e})),r=n.map((function(t){return e[t]}));(t=n.reverse().concat([e.length])).forEach((function(n,r){if(0!==r)for(var a=t[r-1]+1;a<n;++a)e[a-r]=e[a]})),r.forEach((function(t,n){e[e.length-n-1]=t}))}n(17);var x=Array.of(),k=!1,S=[];function C(){return JSON.stringify(x.map((function(e){return Object(u.a)({},e,{isSelected:!1})})))}function b(e){var t=JSON.parse(e);x.splice(0,x.length),t.forEach((function(e){I(e),x.push(e)})),k=!0}function M(){return Math.floor(Math.random()*Math.pow(2,31))}function B(e,t){var n=Math.random;Math.random=function(e){return function(){return(Math.pow(2,31)-1&(e=Math.imul(48271,e)))/Math.pow(2,31)}}(e);var r=t();return Math.random=n,r}function X(e,t,n,r,a,o){var l,i,c=a-n,s=o-r,u=c*c+s*s,f=-1;0!==u&&(f=((e-n)*c+(t-r)*s)/u),f<0?(l=n,i=r):f>1?(l=a,i=o):(l=n+f*c,i=r+f*s);var h=e-l,d=t-i;return Math.hypot(h,d)}function Y(e,t,n){if("ellipse"===e.type){var r=Math.abs(t-e.x-e.width/2),a=Math.abs(n-e.y-e.height/2),o=.707,l=.707,i=e.width/2,c=e.height/2;return[0,1,2,3].forEach((function(e){var t=i*o,n=c*l,s=(i*i-c*c)*Math.pow(o,3)/i,u=(c*c-i*i)*Math.pow(l,3)/c,f=t-s,h=n-u,d=r-s,v=a-u,m=Math.hypot(h,f),p=Math.hypot(v,d);o=Math.min(1,Math.max(0,(d*m/p+s)/i)),l=Math.min(1,Math.max(0,(v*m/p+u)/c));var g=Math.hypot(l,o);o/=g,l/=g})),Math.hypot(i*o-r,c*l-a)<10}if("rectangle"===e.type){var u=j(e),f=J(e),h=P(e),d=W(e);return X(t,n,u,h,f,h)<10||X(t,n,f,h,f,d)<10||X(t,n,f,d,u,d)<10||X(t,n,u,d,u,h)<10}if("arrow"===e.type){var v=z(e),m=Object(s.a)(v,8),p=m[0],g=m[1],y=m[2],w=m[3],E=m[4],x=m[5],k=m[6],S=m[7];return X(t-=e.x,n-=e.y,E,x,y,w)<10||X(t,n,p,g,y,w)<10||X(t,n,k,S,y,w)<10}if("text"===e.type){var C=j(e),b=J(e),M=P(e),B=W(e);return t>=C&&t<=b&&n>=M&&n<=B}if("selection"===e.type)return console.warn("This should not happen, we need to investigate why it does."),!1;throw new Error("Unimplemented type "+e.type)}function L(e,t,n,r){if("text"===e.type||"arrow"===e.type)return!1;var a=O(e,r),o=Object.keys(a).filter((function(e){var o=a[e];return t+r.scrollX>=o[0]&&t+r.scrollX<=o[0]+o[2]&&n+r.scrollY>=o[1]&&n+r.scrollY<=o[1]+o[3]}));return o.length>0&&o[0]}function D(e,t,n,r){var a=e*e/(e+Math.abs(n)),o={x:(n>0?0:e-a)+4,y:t-6-4,width:a-8,height:6},l=t*t/(t+Math.abs(r));return{horizontal:o,vertical:{x:e-6-4,y:(r>0?0:t-l)+4,width:6,height:l-12}}}function O(e,t){var n=e.x,r=e.x+e.width,a=e.y,o=e.y+e.height,l={},i=e.width<0?8:-8,c=e.height<0?8:-8;return Math.abs(r-n)>40&&(l.n=[n+(r-n)/2+t.scrollX-4,a-4+t.scrollY+c,8,8],l.s=[n+(r-n)/2+t.scrollX-4,o-4+t.scrollY-c,8,8]),Math.abs(o-a)>40&&(l.w=[n-4+t.scrollX+i,a+(o-a)/2+t.scrollY-4,8,8],l.e=[r-4+t.scrollX-i,a+(o-a)/2+t.scrollY-4,8,8]),l.nw=[n-4+t.scrollX+i,a-4+t.scrollY+c,8,8],l.ne=[r-4+t.scrollX-i,a-4+t.scrollY+c,8,8],l.sw=[n-4+t.scrollX+i,o-4+t.scrollY-c,8,8],l.se=[r-4+t.scrollX-i,o-4+t.scrollY-c,8,8],l}function U(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},a=r.offsetX,o=r.offsetY,l=r.renderScrollbars,i=void 0===l||l,c=r.renderSelection,s=void 0===c||c;if(t){var f=t.getContext("2d"),h=f.fillStyle;"string"===typeof n.viewBackgroundColor?(f.fillStyle=n.viewBackgroundColor,f.fillRect(0,0,t.width,t.height)):f.clearRect(0,0,t.width,t.height),f.fillStyle=h;var d=le();if(n=Object(u.a)({},n,{scrollX:"number"===typeof a?a:n.scrollX,scrollY:"number"===typeof o?o:n.scrollY}),x.forEach((function(t){if(t.draw(e,f,n),s&&t.isSelected){var r=j(t),a=J(t),o=P(t),l=W(t),i=f.getLineDash();if(f.setLineDash([8,4]),f.strokeRect(r-4+n.scrollX,o-4+n.scrollY,a-r+8,l-o+8),f.setLineDash(i),"text"!==t.type&&"arrow"!==t.type&&1===d.length){var c=O(t,n);Object.values(c).forEach((function(e){f.strokeRect(e[0],e[1],e[2],e[3])}))}}})),i){var v=D(f.canvas.width/window.devicePixelRatio,f.canvas.height/window.devicePixelRatio,n.scrollX,n.scrollY);f.fillStyle="rgba(0,0,0,0.3)",f.fillRect(v.horizontal.x,v.horizontal.y,v.horizontal.width,v.horizontal.height),f.fillRect(v.vertical.x,v.vertical.y,v.vertical.width,v.vertical.height),f.fillStyle=h}}}function R(e,t){var n=document.createElement("a");n.setAttribute("download",e),n.setAttribute("href",t),n.click(),n.remove()}function A(e,t,n,r,a){return[(e-n)*Math.cos(a)-(t-r)*Math.sin(a)+n,(e-n)*Math.sin(a)+(t-r)*MathLine truncated
//# sourceMappingURL=main.3def8d06.chunk.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["zindex.ts","index.tsx"],"names":["swap","elements","indexA","indexB","element","moveOneLeft","indicesToMove","sort","a","b","isSorted","forEach","index","i","moveOneRight","reversedIndicesToMove","length","moveAllLeft","leftMostElements","map","reverse","concat","pos","moveAllRight","rightMostElements","Array","of","skipHistory","stateHistory","generateHistoryCurrentEntry","JSON","stringify","isSelected","restoreHistoryEntry","entry","newElements","parse","splice","newElement","generateDraw","push","randomSeed","Math","floor","random","withCustomMathRandom","seed","cb","imul","LCG","result","distanceBetweenPointAndSegment","x","y","x1","y1","x2","y2","xx","yy","C","D","lenSquare","param","dx","dy","hypot","hitTest","type","px","abs","width","py","height","tx","ty","ex","ey","rx","ry","qx","qy","r","q","min","max","t","getElementAbsoluteX1","getElementAbsoluteX2","getElementAbsoluteY1","getElementAbsoluteY2","getArrowPoints","x3","y3","x4","y4","console","warn","Error","resizeTest","sceneState","handlers","handlerRectangles","filter","Object","keys","key","handler","scrollX","scrollY","getScrollbars","canvasWidth","canvasHeight","scrollBarWidth","horizontalScrollBar","SCROLLBAR_MARGIN","scrollBarHeight","horizontal","vertical","SCROLLBAR_WIDTH","elementX1","elementX2","elementY1","elementY2","marginX","marginY","renderScene","rc","canvas","offsetX","offsetY","renderScrollbars","renderSelection","context","getContext","fillStyle","viewBackgroundColor","fillRect","clearRect","selectedIndices","getSelectedIndices","draw","lineDash","getLineDash","setLineDash","strokeRect","margin","values","scrollBars","window","devicePixelRatio","saveFile","name","data","link","document","createElement","setAttribute","click","remove","rotate","angle","cos","sin","generator","rough","isTextElement","isInputLike","target","HTMLInputElement","HTMLTextAreaElement","HTMLSelectElement","distance","minSize","xs","ys","PI","shape","rectangle","stroke","strokeColor","fill","backgroundColor","translate","ellipse","shapes","line","font","fillText","text","actualBoundingBoxAscent","clearSelection","resetCursor","documentElement","style","cursor","deleteSelectedElements","restore","savedElements","savedState","e","KEYS","SHAPES","icon","viewBox","d","value","shapesShortcutKeys","findElementByKey","reduce","isArrowKey","keyCode","someElementIsSelected","some","lastCanvasWidth","lastCanvasHeight","lastMouseUp","App","state","draggingElement","resizingElement","elementType","exportBackground","currentItemStrokeColor","currentItemBackgroundColor","onResize","forceUpdate","onKeyDown","event","preventDefault","step","shiftKey","metaKey","altKey","code","includes","toLowerCase","setState","lastEntry","pop","undefined","clearCanvas","confirm","removeWheelEventListener","handleWheel","deltaX","deltaY","addEventListener","this","localStorage","getItem","removeEventListener","innerWidth","innerHeight","className","onCut","clipboardData","setData","onCopy","onPaste","parsedElements","paste","getData","isArray","parsedElement","checked","onChange","onClick","title","exportPadding","alert","subCanvasX1","Infinity","subCanvasX2","subCanvasY1","subCanvasY2","tempCanvas","display","body","appendChild","toDataURL","exportAsPNG","serialized","version","source","location","origin","encodeURIComponent","saveAsJSON","input","reader","FileReader","accept","onchange","files","readAsText","Promise","resolve","onloadend","readyState","DONE","loadFromJSON","then","id","ref","passive","scale","onMouseDown","button","activeElement","blur","clientX","clientY","resizeHandle","isDraggingElements","isResizingElements","resizeElement","find","hitElement","prompt","measureText","actualBoundingBoxDescent","lastX","lastY","onMouseMove","HTMLElement","el","selectedElements","selection","selectionX1","selectionX2","selectionY1","selectionY2","setSelection","onMouseUp","newEntry","setItem","React","Component","rootElement","getElementById","ReactDOM","render"],"mappings":"mQAAA,SAASA,EAAQC,EAAeC,EAAgBC,GAC9C,IAAMC,EAAUH,EAASC,GACzBD,EAASC,GAAUD,EAASE,GAC5BF,EAASE,GAAUC,EAGd,SAASC,EAAeJ,EAAeK,GAC5CA,EAAcC,MAAK,SAACC,EAAWC,GAAZ,OAA0BD,EAAIC,KACjD,IAAIC,GAAW,EAEfJ,EAAcK,SAAQ,SAACC,EAAOC,IAG5BH,EAAWA,GAAYE,IAAUC,IAIjCb,EAAKC,EAAUW,EAAQ,EAAGA,MAIvB,SAASE,EAAgBb,EAAeK,GAC7C,IAAMS,EAAwBT,EAAcC,MAC1C,SAACC,EAAWC,GAAZ,OAA0BA,EAAID,KAE5BE,GAAW,EAGfK,EAAsBJ,SAAQ,SAACC,EAAOC,IAGpCH,EAAWA,GAAYE,IAAUX,EAASe,OAASH,EAAI,IAIvDb,EAAKC,EAAUW,EAAQ,EAAGA,MAkDvB,SAASK,EAAehB,EAAeK,GAC5CA,EAAcC,MAAK,SAACC,EAAWC,GAAZ,OAA0BD,EAAIC,KAGjD,IAAMS,EAAmBZ,EAAca,KAAI,SAAAP,GAAK,OAAIX,EAASW,MAEvDG,EAAwBT,EAE3Bc,UAEAC,OAAO,CAAC,IAEXN,EAAsBJ,SAAQ,SAACC,EAAOC,GAEpC,GAAU,IAANA,EAKJ,IAAK,IAAIS,EAAMP,EAAsBF,EAAI,GAAK,EAAGS,GAAOV,IAASU,EAE/DrB,EAASqB,EAAMT,GAAKZ,EAASqB,MAKjCJ,EAAiBP,SAAQ,SAACP,EAASS,GACjCZ,EAASY,GAAKT,KAiDX,SAASmB,EAAgBtB,EAAeK,GAC7C,IAAMS,EAAwBT,EAAcC,MAC1C,SAACC,EAAWC,GAAZ,OAA0BA,EAAID,KAI1BgB,EAAoBT,EAAsBI,KAAI,SAAAP,GAAK,OAAIX,EAASW,OAEtEN,EAAgBS,EAEbK,UAEAC,OAAO,CAACpB,Line truncated
-2
View File
@@ -1,2 +0,0 @@
!function(e){function r(r){for(var n,l,a=r[0],f=r[1],i=r[2],p=0,s=[];p<a.length;p++)l=a[p],Object.prototype.hasOwnProperty.call(o,l)&&o[l]&&s.push(o[l][0]),o[l]=0;for(n in f)Object.prototype.hasOwnProperty.call(f,n)&&(e[n]=f[n]);for(c&&c(r);s.length;)s.shift()();return u.push.apply(u,i||[]),t()}function t(){for(var e,r=0;r<u.length;r++){for(var t=u[r],n=!0,a=1;a<t.length;a++){var f=t[a];0!==o[f]&&(n=!1)}n&&(u.splice(r--,1),e=l(l.s=t[0]))}return e}var n={},o={1:0},u=[];function l(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,l),t.l=!0,t.exports}l.m=e,l.c=n,l.d=function(e,r,t){l.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},l.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},l.t=function(e,r){if(1&r&&(e=l(e)),8&r)return e;if(4&r&&"object"===typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(l.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)l.d(t,n,function(r){return e[r]}.bind(null,n));return t},l.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return l.d(r,"a",r),r},l.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},l.p="/";var a=this.webpackJsonpreact=this.webpackJsonpreact||[],f=a.push.bind(a);a.push=r,a=a.slice();for(var i=0;i<a.length;i++)r(a[i]);var c=f;t()}([]);
//# sourceMappingURL=runtime-main.b019aae8.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../webpack/bootstrap"],"names":["webpackJsonpCallback","data","moduleId","chunkId","chunkIds","moreModules","executeModules","i","resolves","length","Object","prototype","hasOwnProperty","call","installedChunks","push","modules","parentJsonpFunction","shift","deferredModules","apply","checkDeferredModules","result","deferredModule","fulfilled","j","depId","splice","__webpack_require__","s","installedModules","1","exports","module","l","m","c","d","name","getter","o","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","p","jsonpArray","this","oldJsonpFunction","slice"],"mappings":"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","file":"static/js/runtime-main.b019aae8.js","sourcesContent":[" \t// install a JSONP callback for chunk loading\n \tfunction webpackJsonpCallback(data) {\n \t\tvar chunkIds = data[0];\n \t\tvar moreModules = data[1];\n \t\tvar executeModules = data[2];\n\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [];\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(Object.prototype.hasOwnProperty.call(installedChunks, chunkId) && installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(data);\n\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n\n \t\t// add entry modules from loaded chunk to deferred list\n \t\tdeferredModules.push.apply(deferredModules, executeModules || []);\n\n \t\t// run deferred modules when all chunks ready\n \t\treturn checkDeferredModules();\n \t};\n \tfunction checkDeferredModules() {\n \t\tvar result;\n \t\tfor(var i = 0; i < deferredModules.length; i++) {\n \t\t\tvar deferredModule = deferredModules[i];\n \t\t\tvar fulfilled = true;\n \t\t\tfor(var j = 1; j < deferredModule.length; j++) {\n \t\t\t\tvar depId = deferredModule[j];\n \t\t\t\tif(installedChunks[depId] !== 0) fulfilled = false;\n \t\t\t}\n \t\t\tif(fulfilled) {\n \t\t\t\tdeferredModules.splice(i--, 1);\n \t\t\t\tresult = __webpack_require__(__webpack_require__.s = deferredModule[0]);\n \t\t\t}\n \t\t}\n\n \t\treturn result;\n \t}\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// object to store loaded and loading chunks\n \t// undefined = chunk not loaded, null = chunk preloaded/prefetched\n \t// Promise = chunk loading, 0 = chunk loaded\n \tvar installedChunks = {\n \t\t1: 0\n \t};\n\n \tvar deferredModules = [];\n\n Line truncated