UNPKG

awv3

Version:
1,998 lines (1,997 loc) 2.06 MB
{ "type": "Program", "start": 0, "end": 24992, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 662, "column": 0 } }, "sourceType": "module", "body": [ { "type": "ImportDeclaration", "start": 0, "end": 67, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 1, "column": 67 } }, "specifiers": [ { "type": "ImportSpecifier", "start": 8, "end": 20, "loc": { "start": { "line": 1, "column": 8 }, "end": { "line": 1, "column": 20 } }, "imported": { "type": "Identifier", "start": 8, "end": 20, "loc": { "start": { "line": 1, "column": 8 }, "end": { "line": 1, "column": 20 } }, "name": "trackPromise" }, "local": { "type": "Identifier", "start": 8, "end": 20, "loc": { "start": { "line": 1, "column": 8 }, "end": { "line": 1, "column": 20 } }, "name": "trackPromise" } }, { "type": "ImportSpecifier", "start": 22, "end": 29, "loc": { "start": { "line": 1, "column": 22 }, "end": { "line": 1, "column": 29 } }, "imported": { "type": "Identifier", "start": 22, "end": 29, "loc": { "start": { "line": 1, "column": 22 }, "end": { "line": 1, "column": 29 } }, "name": "Interop" }, "local": { "type": "Identifier", "start": 22, "end": 29, "loc": { "start": { "line": 1, "column": 22 }, "end": { "line": 1, "column": 29 } }, "name": "Interop" } }, { "type": "ImportSpecifier", "start": 31, "end": 39, "loc": { "start": { "line": 1, "column": 31 }, "end": { "line": 1, "column": 39 } }, "imported": { "type": "Identifier", "start": 31, "end": 39, "loc": { "start": { "line": 1, "column": 31 }, "end": { "line": 1, "column": 39 } }, "name": "logLevel" }, "local": { "type": "Identifier", "start": 31, "end": 39, "loc": { "start": { "line": 1, "column": 31 }, "end": { "line": 1, "column": 39 } }, "name": "logLevel" } } ], "importKind": "value", "source": { "type": "Literal", "start": 46, "end": 66, "loc": { "start": { "line": 1, "column": 46 }, "end": { "line": 1, "column": 66 } }, "value": "sketcher/cchelpers", "rawValue": "sketcher/cchelpers", "raw": "'sketcher/cchelpers'" } }, { "type": "ImportDeclaration", "start": 68, "end": 127, "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 59 } }, "specifiers": [ { "type": "ImportSpecifier", "start": 76, "end": 95, "loc": { "start": { "line": 2, "column": 8 }, "end": { "line": 2, "column": 27 } }, "imported": { "type": "Identifier", "start": 76, "end": 95, "loc": { "start": { "line": 2, "column": 8 }, "end": { "line": 2, "column": 27 } }, "name": "ConstraintGenerator" }, "local": { "type": "Identifier", "start": 76, "end": 95, "loc": { "start": { "line": 2, "column": 8 }, "end": { "line": 2, "column": 27 } }, "name": "ConstraintGenerator" } } ], "importKind": "value", "source": { "type": "Literal", "start": 102, "end": 126, "loc": { "start": { "line": 2, "column": 34 }, "end": { "line": 2, "column": 58 } }, "value": "sketcher/constraintgen", "rawValue": "sketcher/constraintgen", "raw": "'sketcher/constraintgen'" } }, { "type": "ImportDeclaration", "start": 128, "end": 165, "loc": { "start": { "line": 3, "column": 0 }, "end": { "line": 3, "column": 37 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 135, "end": 141, "loc": { "start": { "line": 3, "column": 7 }, "end": { "line": 3, "column": 13 } }, "local": { "type": "Identifier", "start": 135, "end": 141, "loc": { "start": { "line": 3, "column": 7 }, "end": { "line": 3, "column": 13 } }, "name": "Sketch" } } ], "importKind": "value", "source": { "type": "Literal", "start": 147, "end": 164, "loc": { "start": { "line": 3, "column": 19 }, "end": { "line": 3, "column": 36 } }, "value": "sketcher/sketch", "rawValue": "sketcher/sketch", "raw": "'sketcher/sketch'" } }, { "type": "ImportDeclaration", "start": 166, "end": 211, "loc": { "start": { "line": 4, "column": 0 }, "end": { "line": 4, "column": 45 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 173, "end": 183, "loc": { "start": { "line": 4, "column": 7 }, "end": { "line": 4, "column": 17 } }, "local": { "type": "Identifier", "start": 173, "end": 183, "loc": { "start": { "line": 4, "column": 7 }, "end": { "line": 4, "column": 17 } }, "name": "Constraint" } } ], "importKind": "value", "source": { "type": "Literal", "start": 189, "end": 210, "loc": { "start": { "line": 4, "column": 23 }, "end": { "line": 4, "column": 44 } }, "value": "sketcher/constraint", "rawValue": "sketcher/constraint", "raw": "'sketcher/constraint'" } }, { "type": "ImportDeclaration", "start": 212, "end": 258, "loc": { "start": { "line": 5, "column": 0 }, "end": { "line": 5, "column": 46 } }, "specifiers": [ { "type": "ImportNamespaceSpecifier", "start": 219, "end": 232, "loc": { "start": { "line": 5, "column": 7 }, "end": { "line": 5, "column": 20 } }, "local": { "type": "Identifier", "start": 224, "end": 232, "loc": { "start": { "line": 5, "column": 12 }, "end": { "line": 5, "column": 20 } }, "name": "Controls" } } ], "importKind": "value", "source": { "type": "Literal", "start": 238, "end": 257, "loc": { "start": { "line": 5, "column": 26 }, "end": { "line": 5, "column": 45 } }, "value": "sketcher/controls", "rawValue": "sketcher/controls", "raw": "'sketcher/controls'" } }, { "type": "ImportDeclaration", "start": 259, "end": 313, "loc": { "start": { "line": 6, "column": 0 }, "end": { "line": 6, "column": 54 } }, "specifiers": [ { "type": "ImportSpecifier", "start": 267, "end": 272, "loc": { "start": { "line": 6, "column": 8 }, "end": { "line": 6, "column": 13 } }, "imported": { "type": "Identifier", "start": 267, "end": 272, "loc": { "start": { "line": 6, "column": 8 }, "end": { "line": 6, "column": 13 } }, "name": "Point" }, "local": { "type": "Identifier", "start": 267, "end": 272, "loc": { "start": { "line": 6, "column": 8 }, "end": { "line": 6, "column": 13 } }, "name": "Point" } }, { "type": "ImportSpecifier", "start": 274, "end": 278, "loc": { "start": { "line": 6, "column": 15 }, "end": { "line": 6, "column": 19 } }, "imported": { "type": "Identifier", "start": 274, "end": 278, "loc": { "start": { "line": 6, "column": 15 }, "end": { "line": 6, "column": 19 } }, "name": "Line" }, "local": { "type": "Identifier", "start": 274, "end": 278, "loc": { "start": { "line": 6, "column": 15 }, "end": { "line": 6, "column": 19 } }, "name": "Line" } }, { "type": "ImportSpecifier", "start": 280, "end": 283, "loc": { "start": { "line": 6, "column": 21 }, "end": { "line": 6, "column": 24 } }, "imported": { "type": "Identifier", "start": 280, "end": 283, "loc": { "start": { "line": 6, "column": 21 }, "end": { "line": 6, "column": 24 } }, "name": "Arc" }, "local": { "type": "Identifier", "start": 280, "end": 283, "loc": { "start": { "line": 6, "column": 21 }, "end": { "line": 6, "column": 24 } }, "name": "Arc" } } ], "importKind": "value", "source": { "type": "Literal", "start": 290, "end": 312, "loc": { "start": { "line": 6, "column": 31 }, "end": { "line": 6, "column": 53 } }, "value": "sketcher/geomobjects", "rawValue": "sketcher/geomobjects", "raw": "'sketcher/geomobjects'" } }, { "type": "ImportDeclaration", "start": 314, "end": 349, "loc": { "start": { "line": 7, "column": 0 }, "end": { "line": 7, "column": 35 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 321, "end": 326, "loc": { "start": { "line": 7, "column": 7 }, "end": { "line": 7, "column": 12 } }, "local": { "type": "Identifier", "start": 321, "end": 326, "loc": { "start": { "line": 7, "column": 7 }, "end": { "line": 7, "column": 12 } }, "name": "Orbit" } } ], "importKind": "value", "source": { "type": "Literal", "start": 332, "end": 348, "loc": { "start": { "line": 7, "column": 18 }, "end": { "line": 7, "column": 34 } }, "value": "controls/orbit", "rawValue": "controls/orbit", "raw": "'controls/orbit'" } }, { "type": "ImportDeclaration", "start": 350, "end": 383, "loc": { "start": { "line": 8, "column": 0 }, "end": { "line": 8, "column": 33 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 357, "end": 363, "loc": { "start": { "line": 8, "column": 7 }, "end": { "line": 8, "column": 13 } }, "local": { "type": "Identifier", "start": 357, "end": 363, "loc": { "start": { "line": 8, "column": 7 }, "end": { "line": 8, "column": 13 } }, "name": "Plugin" } } ], "importKind": "value", "source": { "type": "Literal", "start": 369, "end": 382, "loc": { "start": { "line": 8, "column": 19 }, "end": { "line": 8, "column": 32 } }, "value": "core/plugin", "rawValue": "core/plugin", "raw": "'core/plugin'" } }, { "type": "ImportDeclaration", "start": 384, "end": 420, "loc": { "start": { "line": 9, "column": 0 }, "end": { "line": 9, "column": 36 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 391, "end": 398, "loc": { "start": { "line": 9, "column": 7 }, "end": { "line": 9, "column": 14 } }, "local": { "type": "Identifier", "start": 391, "end": 398, "loc": { "start": { "line": 9, "column": 7 }, "end": { "line": 9, "column": 14 } }, "name": "Object3" } } ], "importKind": "value", "source": { "type": "Literal", "start": 404, "end": 419, "loc": { "start": { "line": 9, "column": 20 }, "end": { "line": 9, "column": 35 } }, "value": "three/object3", "rawValue": "three/object3", "raw": "'three/object3'" } }, { "type": "ImportDeclaration", "start": 421, "end": 447, "loc": { "start": { "line": 10, "column": 0 }, "end": { "line": 10, "column": 26 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 428, "end": 433, "loc": { "start": { "line": 10, "column": 7 }, "end": { "line": 10, "column": 12 } }, "local": { "type": "Identifier", "start": 428, "end": 433, "loc": { "start": { "line": 10, "column": 7 }, "end": { "line": 10, "column": 12 } }, "name": "THREE" } } ], "importKind": "value", "source": { "type": "Literal", "start": 439, "end": 446, "loc": { "start": { "line": 10, "column": 18 }, "end": { "line": 10, "column": 25 } }, "value": "three", "rawValue": "three", "raw": "'three'" } }, { "type": "ImportDeclaration", "start": 448, "end": 559, "loc": { "start": { "line": 11, "column": 0 }, "end": { "line": 11, "column": 111 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 455, "end": 467, "loc": { "start": { "line": 11, "column": 7 }, "end": { "line": 11, "column": 19 } }, "local": { "type": "Identifier", "start": 455, "end": 467, "loc": { "start": { "line": 11, "column": 7 }, "end": { "line": 11, "column": 19 } }, "name": "SketcherFont" } } ], "importKind": "value", "source": { "type": "Literal", "start": 473, "end": 558, "loc": { "start": { "line": 11, "column": 25 }, "end": { "line": 11, "column": 110 } }, "value": "json!../../node_modules/three/examples/fonts/droid/droid_sans_regular.typeface.json", "rawValue": "json!../../node_modules/three/examples/fonts/droid/droid_sans_regular.typeface.json", "raw": "'json!../../node_modules/three/examples/fonts/droid/droid_sans_regular.typeface.json'" } }, { "type": "ImportDeclaration", "start": 560, "end": 599, "loc": { "start": { "line": 12, "column": 0 }, "end": { "line": 12, "column": 39 } }, "specifiers": [ { "type": "ImportSpecifier", "start": 568, "end": 577, "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 17 } }, "imported": { "type": "Identifier", "start": 568, "end": 577, "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 17 } }, "name": "Timestamp" }, "local": { "type": "Identifier", "start": 568, "end": 577, "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 17 } }, "name": "Timestamp" } } ], "importKind": "value", "source": { "type": "Literal", "start": 584, "end": 598, "loc": { "start": { "line": 12, "column": 24 }, "end": { "line": 12, "column": 38 } }, "value": "core/helpers", "rawValue": "core/helpers", "raw": "'core/helpers'" }, "trailingComments": [ { "type": "CommentLine", "value": "note: only for testing purposes", "start": 600, "end": 633, "loc": { "start": { "line": 13, "column": 0 }, "end": { "line": 13, "column": 33 } }, "range": [ 600, 633 ] } ] }, { "type": "ImportDeclaration", "start": 634, "end": 679, "loc": { "start": { "line": 14, "column": 0 }, "end": { "line": 14, "column": 45 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 641, "end": 652, "loc": { "start": { "line": 14, "column": 7 }, "end": { "line": 14, "column": 18 } }, "local": { "type": "Identifier", "start": 641, "end": 652, "loc": { "start": { "line": 14, "column": 7 }, "end": { "line": 14, "column": 18 } }, "name": "RunAllTests", "leadingComments": null }, "leadingComments": null } ], "importKind": "value", "source": { "type": "Literal", "start": 658, "end": 678, "loc": { "start": { "line": 14, "column": 24 }, "end": { "line": 14, "column": 44 } }, "value": "sketcher/unittests", "rawValue": "sketcher/unittests", "raw": "'sketcher/unittests'" }, "leadingComments": [ { "type": "CommentLine", "value": "note: only for testing purposes", "start": 600, "end": 633, "loc": { "start": { "line": 13, "column": 0 }, "end": { "line": 13, "column": 33 } }, "range": [ 600, 633 ] } ] }, { "type": "ClassDeclaration", "start": 681, "end": 1154, "loc": { "start": { "line": 16, "column": 0 }, "end": { "line": 36, "column": 1 } }, "id": { "type": "Identifier", "start": 687, "end": 701, "loc": { "start": { "line": 16, "column": 6 }, "end": { "line": 16, "column": 20 } }, "name": "CursorPosition" }, "superClass": { "type": "MemberExpression", "start": 710, "end": 723, "loc": { "start": { "line": 16, "column": 29 }, "end": { "line": 16, "column": 42 } }, "object": { "type": "Identifier", "start": 710, "end": 715, "loc": { "start": { "line": 16, "column": 29 }, "end": { "line": 16, "column": 34 } }, "name": "THREE" }, "property": { "type": "Identifier", "start": 716, "end": 723, "loc": { "start": { "line": 16, "column": 35 }, "end": { "line": 16, "column": 42 } }, "name": "Vector3" }, "computed": false }, "body": { "type": "ClassBody", "start": 724, "end": 1154, "loc": { "start": { "line": 16, "column": 43 }, "end": { "line": 36, "column": 1 } }, "body": [ { "type": "MethodDefinition", "start": 730, "end": 841, "loc": { "start": { "line": 17, "column": 4 }, "end": { "line": 21, "column": 5 } }, "computed": false, "key": { "type": "Identifier", "start": 730, "end": 741, "loc": { "start": { "line": 17, "column": 4 }, "end": { "line": 17, "column": 15 } }, "name": "constructor" }, "static": false, "kind": "constructor", "value": { "type": "FunctionExpression", "start": 741, "end": 841, "loc": { "start": { "line": 17, "column": 15 }, "end": { "line": 21, "column": 5 } }, "id": null, "generator": false, "expression": false, "async": false, "params": [ { "type": "Identifier", "start": 742, "end": 750, "loc": { "start": { "line": 17, "column": 16 }, "end": { "line": 17, "column": 24 } }, "name": "notifier" } ], "body": { "type": "BlockStatement", "start": 752, "end": 841, "loc": { "start": { "line": 17, "column": 26 }, "end": { "line": 21, "column": 5 } }, "body": [ { "type": "ExpressionStatement", "start": 762, "end": 770, "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 16 } }, "expression": { "type": "CallExpression", "start": 762, "end": 769, "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 15 } }, "callee": { "type": "Super", "start": 762, "end": 767, "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 13 } } }, "arguments": [] } }, { "type": "ExpressionStatement", "start": 779, "end": 801, "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 30 } }, "expression": { "type": "AssignmentExpression", "start": 779, "end": 800, "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 29 } }, "operator": "=", "left": { "type": "MemberExpression", "start": 779, "end": 786, "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 15 } }, "object": { "type": "ThisExpression", "start": 779, "end": 783, "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 12 } } }, "property": { "type": "Identifier", "start": 784, "end": 786, "loc": { "start": { "line": 19, "column": 13 }, "end": { "line": 19, "column": 15 } }, "name": "_x" }, "computed": false }, "right": { "type": "AssignmentExpression", "start": 789, "end": 800, "loc": { "start": { "line": 19, "column": 18 }, "end": { "line": 19, "column": 29 } }, "operator": "=", "left": { "type": "MemberExpression", "start": 789, "end": 796, "loc": { "start": { "line": 19, "column": 18 }, "end": { "line": 19, "column": 25 } }, "object": { "type": "ThisExpression", "start": 789, "end": 793, "loc": { "start": { "line": 19, "column": 18 }, "end": { "line": 19, "column": 22 } } }, "property": { "type": "Identifier", "start": 794, "end": 796, "loc": { "start": { "line": 19, "column": 23 }, "end": { "line": 19, "column": 25 } }, "name": "_y" }, "computed": false }, "right": { "type": "Literal", "start": 799, "end": 800, "loc": { "start": { "line": 19, "column": 28 }, "end": { "line": 19, "column": 29 } }, "value": 0, "rawValue": 0, "raw": "0" } } } }, { "type": "ExpressionStatement", "start": 810, "end": 835, "loc": { "start": { "line": 20, "column": 8 }, "end": { "line": 20, "column": 33 } }, "expression": { "type": "AssignmentExpression", "start": 810, "end": 834, "loc": { "start": { "line": 20, "column": 8 }, "end": { "line": 20, "column": 32 } }, "operator": "=", "left": { "type": "MemberExpression", "start": 810, "end": 823, "loc": { "start": { "line": 20, "column": 8 }, "end": { "line": 20, "column": 21 } }, "object": { "type": "ThisExpression", "start": 810, "end": 814, "loc": { "start": { "line": 20, "column": 8 }, "end": { "line": 20, "column": 12 } } }, "property": { "type": "Identifier", "start": 815, "end": 823, "loc": { "start": { "line": 20, "column": 13 }, "end": { "line": 20, "column": 21 } }, "name": "notifier" }, "computed": false }, "right": { "type": "Identifier", "start": 826, "end": 834, "loc": { "start": { "line": 20, "column": 24 }, "end": { "line": 20, "column": 32 } }, "name": "notifier" } } } ] } } }, { "type": "MethodDefinition", "start": 846, "end": 873, "loc": { "start": { "line": 22, "column": 4 }, "end": { "line": 22, "column": 31 } }, "computed": false, "key": { "type": "Identifier", "start": 850, "end": 851, "loc": { "start": { "line": 22, "column": 8 }, "end": { "line": 22, "column": 9 } }, "name": "x" }, "static": false, "kind": "get", "value": { "type": "FunctionExpression", "start": 851, "end": 873, "loc": { "start": { "line": 22, "column": 9 }, "end": { "line": 22, "column": 31 } }, "id": null, "generator": false, "expression": false, "async": false, "params": [], "body": { "type": "BlockStatement", "start": 854, "end": 873, "loc": { "start": { "line": 22, "column": 12 }, "end": { "line": 22, "column": 31 } }, "body": [ { "type": "ReturnStatement", "start": 856, "end": 871, "loc": { "start": { "line": 22, "column": 14 }, "end": { "line": 22, "column": 29 } }, "argument": { "type": "MemberExpression", "start": 863, "end": 870, "loc": { "start": { "line": 22, "column": 21 }, "end": { "line": 22, "column": 28 } }, "object": { "type": "ThisExpression", "start": 863, "end": 867, "loc": { "start": { "line": 22, "column": 21 }, "end": { "line": 22, "column": 25 } } }, "property": { "type": "Identifier", "start": 868, "end": 870, "loc": { "start": { "line": 22, "column": 26 }, "end": { "line": 22, "column": 28 } }, "name": "_x" }, "computed": false } } ] } } }, { "type": "MethodDefinition", "start": 878, "end": 905, "loc": { "start": { "line": 23, "column": 4 }, "end": { "line": 23, "column": 31 } }, "computed": false, "key": { "type": "Identifier", "start": 882, "end": 883, "loc": { "start": { "line": 23, "column": 8 }, "end": { "line": 23, "column": 9 } }, "name": "y" }, "static": false, "kind": "get", "value": { "type": "FunctionExpression", "start": 883, "end": 905, "loc": { "start": { "line": 23, "column": 9 }, "end": { "line": 23, "column": 31 } }, "id": null, "generator": false, "expression": false, "async": false, "params": [], "body": { "type": "BlockStatement", "start": 886, "end": 905, "loc": { "start": { "line": 23, "column": 12 }, "end": { "line": 23, "column": 31 } }, "body": [ { "type": "ReturnStatement", "start": 888, "end": 903, "loc": { "start": { "line": 23, "column": 14 }, "end": { "line": 23, "column": 29 } }, "argument": { "type": "MemberExpression", "start": 895, "end": 902, "loc": { "start": { "line": 23, "column": 21 }, "end": { "line": 23, "column": 28 } }, "object": { "type": "ThisExpression", "start": 895, "end": 899, "loc": { "start": { "line": 23, "column": 21 }, "end": { "line": 23, "column": 25 } } }, "property": { "type": "Identifier", "start": 900, "end": 902, "loc": { "start": { "line": 23, "column": 26 }, "end": { "line": 23, "column": 28 } }, "name": "_y" }, "computed": false } } ] } } }, { "type": "MethodDefinition", "start": 910, "end": 931, "loc": { "start": { "line": 24, "column": 4 }, "end": { "line": 24, "column": 25 } }, "computed": false, "key": { "type": "Identifier", "start": 914, "end": 915, "loc": { "start": { "line": 24, "column": 8 }, "end": { "line": 24, "column": 9 } }, "name": "z" }, "static": false, "kind": "get", "value": { "type": "FunctionExpression", "start": 915, "end": 931, "loc": { "start": { "line": 24, "column": 9 }, "end": { "line": 24, "column": 25 } }, "id": null, "generator": false, "expression": false, "async": false, "params": [], "body": { "type": "BlockStatement", "start": 918, "end": 931, "loc": { "start": { "line": 24, "column": 12 }, "end": { "line": 24, "column": 25 } },