saltiresoftware commited on
Commit
d8e6769
·
verified ·
1 Parent(s): 1a31113

Update app.js

Browse files
Files changed (1) hide show
  1. app.js +6 -0
app.js CHANGED
@@ -266,3 +266,9 @@ window.addEventListener("beforeunload", () => {
266
  if (svgUrl) URL.revokeObjectURL(svgUrl);
267
  if (cadUrl) URL.revokeObjectURL(cadUrl);
268
  });
 
 
 
 
 
 
 
266
  if (svgUrl) URL.revokeObjectURL(svgUrl);
267
  if (cadUrl) URL.revokeObjectURL(cadUrl);
268
  });
269
+
270
+ const DEFAULT_SVG = "<svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 500 500'>\n<defs>\n<marker id = 'arrowhead'\nmarkerWidth = '10'\nmarkerHeight = '7'\nrefX = '10'\nrefY = '3.5'\norient = 'auto'\nmarkerUnits = 'strokeWidth'>\n<polygon points = '0 0, 10 3.5, 0 7' style = 'fill: context-stroke'/>\n</marker>\n<marker id = 'distance-arrowhead-end'\nmarkerWidth = '5'\nmarkerHeight = '5'\nrefX = '5'\nrefY = '2.5'\norient = 'auto'\nmarkerUnits = 'strokeWidth'>\n<polygon points = '0 0, 5 2.5, 0 5' style = 'fill: context-stroke'/>\n</marker>\n<marker id = 'distance-arrowhead-start'\nmarkerWidth = '5'\nmarkerHeight = '5'\nrefX = '0'\nrefY = '2.5'\norient = 'auto'\nmarkerUnits = 'strokeWidth'>\n<polygon points = '5 0, 0 2.5, 5 5' style = 'fill: context-stroke'/>\n</marker>\n</defs>\n<defs>\n<path id='m0_g0' d='M107 214C74 214 50 193 50 154C50 148 51 141 51 135C56 102 68 71 89 46C96 36 113 19 122 13C151-10 182-22 229-22C355-22 449 81 449 201C449 307 385 393 297 415C284 418 270 420 256 420C203 420 170 399 139 374L139 546L149 544C166 540 186 538 205 538C301 538 365 581 410 635L410 648C410 660 408 666 402 666C399 666 395 665 389 662C347 644 300 634 253 634C201 634 160 644 120 660C111 663 103 666 102 666C101 666 99 665 98 664C93 664 92 646 92 608C92 579 93 539 93 485C93 329 93 314 95 310C97 305 100 304 114 304C129 304 131 305 136 314C159 353 200 382 254 382C287 382 302 369 318 349C338 322 345 287 345 210C345 148 340 109 326 82C307 45 275 22 224 22C165 22 124 56 105 96L102 101L109 101C135 101 164 124 164 156C164 190 139 214 107 214Z'/>\n<g id='m0_label'>\n<use xlink:href='#m0_g0' transform='translate(0,750) scale(1,-1)'/>\n</g>\n</defs>\n<defs>\n<clipPath id='view-clip'>\n<rect width='500' height='500'/>\n</clipPath>\n</defs>\n<g clip-path='url(#view-clip)'>\n<g transform='translate(0 500) scale(1,-1)'>\n<g transform='scale(45.45454545) translate(3.573813784 5.812680737)'>\n<g>\n<line id='MeasurementLine' x1='1.92618621607519' y1='-0.312680736566939' x2='3.97409322959541' y2='-1.42601645553734' stroke='gray' stroke-width='0.022'/>\n<line id='MeasurementLine' x1='4.27109322959541' y1='-1.58747921060932' x2='6.31900024311562' y2='-2.70081492957972' stroke='gray' stroke-width='0.022'/>\n<polygon points='1.926186216,-0.3126807366 2.01588703,-0.4240484336 2.068425983,-0.327406525' fill='gray' stroke='none'/>\n<polygon points='6.319000243,-2.70081493 6.229299429,-2.589447233 6.176760477,-2.686089141' fill='gray' stroke='none'/>\n</g>\n<g>\n<circle id='C0' cx='1.92618621607519' cy='-0.312680736566939' r='5' stroke='#3398DB' stroke-width='0.044' fill='none' visibility='visible' />\n</g>\n<g>\n<circle id='O' cx='1.926186216' cy='-0.3126807366' r='0.11' fill='#A463BF' />\n</g>\n</g>\n</g>\n<g>\n<text x='266.5' y='250' font-size='15' fill='black' font-style='normal' text-anchor='start' dominant-baseline='middle'>O</text>\n<g transform='translate(349.8366824,304.2757771) scale(0.015) translate(-250,-428)' fill='black' opacity='1'>\n<use xlink:href='#m0_label'/>\n</g>\n</g>\n</g>\n</svg>";
271
+ const DEFAULT_PROGRAM = "defaultproperties constraint visible=true\n\ncircle C0 O\nradius C0 5\n";
272
+ showSvg(DEFAULT_SVG);
273
+ ui.program.textContent = DEFAULT_PROGRAM;
274
+ setDownloads(DEFAULT_PROGRAM, DEFAULT_SVG);