Create new
Bindings
Transitions
Animations
Easing
Component composition
Context API
Special elements
Module context
Debugging
Miscellaneous
App.svelte
runes
This component is in runes mode.
To disable runes mode, add the following to the top of your component:
<svelte:options runes={false} />
999
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
›
⌄
⌄
⌄
⌄
<!--
https://eugenkiss.github.io/7guis/tasks#circle
Click on the canvas to draw a circle. Click on a circle
to select it. Right-click on the canvas to adjust the
radius of the selected circle.
-->
<script>
let i = $state(0);
let undoStack = $state([[]]);
let circles = $state([]);
let selected = $state();
let adjusting = $state(false);
let adjusted = false;
function handleClick(event) {
if (adjusting) {
adjusting = false;
// if circle was adjusted,
// push to the stack
if (adjusted) push();
return;
}
const circle = {
cx: event.clientX,
cy: event.clientY,
r: 50
};
circles = circles.concat(circle);
selected = circle;
push();
Error compiling component
WebAssembly.instantiateStreaming(): value type opcode @+13
999
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
›
⌄
⌄
⌄
⌄
import 'svelte/internal/disclose-version';
import * as $ from 'svelte/internal/client';
var on_click = (_, travel) => travel(-1);
var on_click_1 = (__1, travel) => travel(+1);
var on_click_2 = (event, select, circle) => select($.get(circle), event);
var on_contextmenu = (e, adjusting, selected, circle) => {
e.stopPropagation();
e.preventDefault();
$.set(adjusting, !$.get(adjusting));
if ($.get(adjusting)) $.set(selected, $.proxy($.get(circle)));
};
var root_1 = $.ns_template(`<circle class="svelte-1zh3yn"></circle>`);
var root_2 = $.template(`<div class="adjuster svelte-1zh3yn"><p> </p> <input type="range" class="svelte-1zh3yn"></div>`);
var root = $.template(`<div class="controls svelte-1zh3yn"><button>undo</button> <button>redo</button></div> <svg class="svelte-1zh3yn"></svg> <!>`, 1);
export default function App($$anchor) {
let i = $.state(0);
let undoStack = $.state($.proxy([[]]));
let circles = $.state($.proxy([]));
let selected = $.state(undefined);
let adjusting = $.state(false);
let adjusted = false;
function handleClick(event) {
if ($.get(adjusting)) {
$.set(adjusting, false);
// if circle was adjusted,
// push to the stack
if (adjusted) push();
return;
}
const circle = { cx: event.clientX, cy: event.clientY, r: 50 };
result = svelte.compile(source, {
generate: ,
});99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
›
.controls.svelte-1zh3yn {
position: absolute;
width: 100%;
text-align: center;
}
svg.svelte-1zh3yn {
background-color: #eee;
width: 100%;
height: 100%;
}
circle.svelte-1zh3yn {
stroke: black;
}
.adjuster.svelte-1zh3yn {
position: absolute;
width: 80%;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
padding: 1em;
text-align: center;
background-color: rgba(255, 255, 255, 0.7);
border-radius: 4px;
}
input[type='range'].svelte-1zh3yn {
width: 100%;
}
Root {
css: StyleSheet {...}
- type: "StyleSheet"
- start: 2131
- end: 2583
- attributes: []
children: [...] (5)
Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 2140
- end: 2149
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 2140
- end: 2149
children: [...] (1)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
ClassSelector {...}
- type: "ClassSelector"
- name: "controls"
- start: 2140
- end: 2149
}
]- start: 2140
- end: 2149
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 2150
- end: 2213
children: [...] (3)
Declaration {...}
- type: "Declaration"
- start: 2154
- end: 2172
- property: "position"
- value: "absolute"
} Declaration {...}
- type: "Declaration"
- start: 2176
- end: 2187
- property: "width"
- value: "100%"
} Declaration {...}
- type: "Declaration"
- start: 2191
- end: 2209
- property: "text-align"
- value: "center"
}
]
}- start: 2140
- end: 2213
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 2216
- end: 2219
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 2216
- end: 2219
children: [...] (1)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
TypeSelector {...}
- type: "TypeSelector"
- name: "svg"
- start: 2216
- end: 2219
}
]- start: 2216
- end: 2219
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 2220
- end: 2281
children: [...] (3)
Declaration {...}
- type: "Declaration"
- start: 2224
- end: 2246
- property: "background-color"
- value: "#eee"
} Declaration {...}
- type: "Declaration"
- start: 2250
- end: 2261
- property: "width"
- value: "100%"
} Declaration {...}
- type: "Declaration"
- start: 2265
- end: 2277
- property: "height"
- value: "100%"
}
]
}- start: 2216
- end: 2281
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 2284
- end: 2290
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 2284
- end: 2290
children: [...] (1)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
TypeSelector {...}
- type: "TypeSelector"
- name: "circle"
- start: 2284
- end: 2290
}
]- start: 2284
- end: 2290
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 2291
- end: 2312
children: [...] (1)
Declaration {...}
- type: "Declaration"
- start: 2295
- end: 2308
- property: "stroke"
- value: "black"
}
]
}- start: 2284
- end: 2312
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 2315
- end: 2324
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 2315
- end: 2324
children: [...] (1)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
ClassSelector {...}
- type: "ClassSelector"
- name: "adjuster"
- start: 2315
- end: 2324
}
]- start: 2315
- end: 2324
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 2325
- end: 2532
children: [...] (9)
Declaration {...}
- type: "Declaration"
- start: 2329
- end: 2347
- property: "position"
- value: "absolute"
} Declaration {...}
- type: "Declaration"
- start: 2351
- end: 2361
- property: "width"
- value: "80%"
} Declaration {...}
- type: "Declaration"
- start: 2365
- end: 2373
- property: "top"
- value: "50%"
} Declaration {...}
- type: "Declaration"
- start: 2377
- end: 2386
- property: "left"
- value: "50%"
} Declaration {...}
- type: "Declaration"
- start: 2390
- end: 2422
- property: "transform"
- value: "translate(-50%, -50%)"
} Declaration {...}
- type: "Declaration"
- start: 2426
- end: 2438
- property: "padding"
- value: "1em"
} Declaration {...}
- type: "Declaration"
- start: 2442
- end: 2460
- property: "text-align"
- value: "center"
} Declaration {...}
- type: "Declaration"
- start: 2464
- end: 2506
- property: "background-color"
- value: "rgba(255, 255, 255, 0.7)"
} Declaration {...}
- type: "Declaration"
- start: 2510
- end: 2528
- property: "border-radius"
- value: "4px"
}
]
}- start: 2315
- end: 2532
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 2535
- end: 2554
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 2535
- end: 2554
children: [...] (1)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (2)
TypeSelector {...}
- type: "TypeSelector"
- name: "input"
- start: 2535
- end: 2540
} AttributeSelector {...}
- type: "AttributeSelector"
- start: 2540
- end: 2554
- name: "type"
- matcher: "="
- value: "range"
- flags: null
}
]- start: 2535
- end: 2554
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 2555
- end: 2574
children: [...] (1)
Declaration {...}
- type: "Declaration"
- start: 2559
- end: 2570
- property: "width"
- value: "100%"
}
]
}- start: 2535
- end: 2574
}
]content: {...}
- start: 2138
- end: 2575
- styles: "\n\t.controls {\n\t\tposition: absolute;\n\t\twidth: 100%;\n\t\ttext-align: center;\n\t}\n\n\tsvg {\n\t\tbackground-color: #eee;\n\t\twidth: 100%;\n\t\theight: 100%;\n\t}\n\n\tcircle {\n\t\tstroke: black;\n\t}\n\n\t.adjuster {\n\t\tposition: absolute;\n\t\twidth: 80%;\n\t\ttop: 50%;\n\t\tleft: 50%;\n\t\ttransform: translate(-50%, -50%);\n\t\tpadding: 1em;\n\t\ttext-align: center;\n\t\tbackground-color: rgba(255, 255, 255, 0.7);\n\t\tborder-radius: 4px;\n\t}\n\n\tinput[type='range'] {\n\t\twidth: 100%;\n\t}\n"
- comment: null
}
}- js: []
- start: 0
- end: 2129
- type: "Root"
fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (11)
Comment {...}
- type: "Comment"
- start: 0
- end: 197
- data: "\nhttps://eugenkiss.github.io/7guis/tasks#circle\n\nClick on the canvas to draw a circle. Click on a circle\nto select it. Right-click on the canvas to adjust the\nradius of the selected circle.\n"
} Text {...}
- type: "Text"
- start: 197
- end: 199
- raw: "\n\n"
- data: "\n\n"
} Text {...}
- type: "Text"
- start: 1224
- end: 1226
- raw: "\n\n"
- data: "\n\n"
} RegularElement {...}
- type: "RegularElement"
- start: 1226
- end: 1412
- name: "div"
attributes: [...] (1)
Attribute {...}
- type: "Attribute"
- start: 1231
- end: 1247
- name: "class"
value: [...] (1)
Text {...}
- start: 1238
- end: 1246
- type: "Text"
- raw: "controls"
- data: "controls svelte-1zh3yn"
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (5)
Text {...}
- type: "Text"
- start: 1248
- end: 1250
- raw: "\n\t"
- data: "\n\t"
} RegularElement {...}
- type: "RegularElement"
- start: 1250
- end: 1317
- name: "button"
attributes: [...] (2)
Attribute {...}
- type: "Attribute"
- start: 1258
- end: 1284
- name: "onclick"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1266
- end: 1284
expression: ArrowFunctionExpression {...}
- type: "ArrowFunctionExpression"
- start: 1267
- end: 1283
loc: {...}
start: {...}
- line: 69
- column: 18
}end: {...}
- line: 69
- column: 34
}
}- id: null
- expression: true
- generator: false
- async: false
- params: []
body: CallExpression {...}
- type: "CallExpression"
- start: 1273
- end: 1283
loc: {...}
start: {...}
- line: 69
- column: 24
}end: {...}
- line: 69
- column: 34
}
}callee: Identifier {...}
- type: "Identifier"
- start: 1273
- end: 1279
loc: {...}
start: {...}
- line: 69
- column: 24
}end: {...}
- line: 69
- column: 30
}
}- name: "travel"
}arguments: [...] (1)
UnaryExpression {...}
- type: "UnaryExpression"
- start: 1280
- end: 1282
loc: {...}
start: {...}
- line: 69
- column: 31
}end: {...}
- line: 69
- column: 33
}
}- operator: "-"
- prefix: true
argument: Literal {...}
- type: "Literal"
- start: 1281
- end: 1282
loc: {...}
start: {...}
- line: 69
- column: 32
}end: {...}
- line: 69
- column: 33
}
}- value: 1
- raw: "1"
}
}
]- optional: false
}
}
}
} Attribute {...}
- type: "Attribute"
- start: 1285
- end: 1303
- name: "disabled"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1294
- end: 1303
expression: BinaryExpression {...}
- type: "BinaryExpression"
- start: 1295
- end: 1302
loc: {...}
start: {...}
- line: 69
- column: 46
}end: {...}
- line: 69
- column: 53
}
}left: Identifier {...}
- type: "Identifier"
- start: 1295
- end: 1296
loc: {...}
start: {...}
- line: 69
- column: 46
}end: {...}
- line: 69
- column: 47
}
}- name: "i"
}- operator: "==="
right: Literal {...}
- type: "Literal"
- start: 1301
- end: 1302
loc: {...}
start: {...}
- line: 69
- column: 52
}end: {...}
- line: 69
- column: 53
}
}- value: 0
- raw: "0"
}
}
}
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (1)
Text {...}
- type: "Text"
- start: 1304
- end: 1308
- raw: "undo"
- data: "undo"
}
]
}
} Text {...}
- type: "Text"
- start: 1317
- end: 1319
- raw: " "
- data: " "
} RegularElement {...}
- type: "RegularElement"
- start: 1319
- end: 1405
- name: "button"
attributes: [...] (2)
Attribute {...}
- type: "Attribute"
- start: 1327
- end: 1353
- name: "onclick"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1335
- end: 1353
expression: ArrowFunctionExpression {...}
- type: "ArrowFunctionExpression"
- start: 1336
- end: 1352
loc: {...}
start: {...}
- line: 70
- column: 18
}end: {...}
- line: 70
- column: 34
}
}- id: null
- expression: true
- generator: false
- async: false
- params: []
body: CallExpression {...}
- type: "CallExpression"
- start: 1342
- end: 1352
loc: {...}
start: {...}
- line: 70
- column: 24
}end: {...}
- line: 70
- column: 34
}
}callee: Identifier {...}
- type: "Identifier"
- start: 1342
- end: 1348
loc: {...}
start: {...}
- line: 70
- column: 24
}end: {...}
- line: 70
- column: 30
}
}- name: "travel"
}arguments: [...] (1)
UnaryExpression {...}
- type: "UnaryExpression"
- start: 1349
- end: 1351
loc: {...}
start: {...}
- line: 70
- column: 31
}end: {...}
- line: 70
- column: 33
}
}- operator: "+"
- prefix: true
argument: Literal {...}
- type: "Literal"
- start: 1350
- end: 1351
loc: {...}
start: {...}
- line: 70
- column: 32
}end: {...}
- line: 70
- column: 33
}
}- value: 1
- raw: "1"
}
}
]- optional: false
}
}
}
} Attribute {...}
- type: "Attribute"
- start: 1354
- end: 1391
- name: "disabled"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1363
- end: 1391
expression: BinaryExpression {...}
- type: "BinaryExpression"
- start: 1364
- end: 1390
loc: {...}
start: {...}
- line: 70
- column: 46
}end: {...}
- line: 70
- column: 72
}
}left: Identifier {...}
- type: "Identifier"
- start: 1364
- end: 1365
loc: {...}
start: {...}
- line: 70
- column: 46
}end: {...}
- line: 70
- column: 47
}
}- name: "i"
}- operator: "==="
right: BinaryExpression {...}
- type: "BinaryExpression"
- start: 1370
- end: 1390
loc: {...}
start: {...}
- line: 70
- column: 52
}end: {...}
- line: 70
- column: 72
}
}left: MemberExpression {...}
- type: "MemberExpression"
- start: 1370
- end: 1386
loc: {...}
start: {...}
- line: 70
- column: 52
}end: {...}
- line: 70
- column: 68
}
}object: Identifier {...}
- type: "Identifier"
- start: 1370
- end: 1379
loc: {...}
start: {...}
- line: 70
- column: 52
}end: {...}
- line: 70
- column: 61
}
}- name: "undoStack"
}property: Identifier {...}
- type: "Identifier"
- start: 1380
- end: 1386
loc: {...}
start: {...}
- line: 70
- column: 62
}end: {...}
- line: 70
- column: 68
}
}- name: "length"
}- computed: false
- optional: false
}- operator: "-"
right: Literal {...}
- type: "Literal"
- start: 1389
- end: 1390
loc: {...}
start: {...}
- line: 70
- column: 71
}end: {...}
- line: 70
- column: 72
}
}- value: 1
- raw: "1"
}
}
}
}
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (1)
Text {...}
- type: "Text"
- start: 1392
- end: 1396
- raw: "redo"
- data: "redo"
}
]
}
} Text {...}
- type: "Text"
- start: 1405
- end: 1406
- raw: "\n"
- data: "\n"
}
]
}
} Text {...}
- type: "Text"
- start: 1412
- end: 1413
- raw: " "
- data: " "
} Comment {...}
- type: "Comment"
- start: 1413
- end: 1506
- data: " svelte-ignore a11y_click_events_have_key_events, a11y_no_static_element_interactions "
} Text {...}
- type: "Text"
- start: 1506
- end: 1507
- raw: ""
- data: ""
} RegularElement {...}
- type: "RegularElement"
- start: 1507
- end: 1946
- name: "svg"
attributes: [...] (2)
Attribute {...}
- type: "Attribute"
- start: 1512
- end: 1533
- name: "onclick"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1520
- end: 1533
expression: Identifier {...}
- type: "Identifier"
- start: 1521
- end: 1532
loc: {...}
start: {...}
- line: 73
- column: 14
}end: {...}
- line: 73
- column: 25
}
}- name: "handleClick"
}
}
} Attribute {...}
- type: "Attribute"
- start: -1
- end: -1
- name: "class"
value: [...] (1)
Text {...}
- type: "Text"
- data: "svelte-1zh3yn"
- raw: "svelte-1zh3yn"
- start: -1
- end: -1
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (3)
Text {...}
- type: "Text"
- start: 1534
- end: 1536
- raw: "\n\t"
- data: "\n\t"
} EachBlock {...}
- type: "EachBlock"
- start: 1536
- end: 1939
expression: Identifier {...}
- type: "Identifier"
- start: 1543
- end: 1550
loc: {...}
start: {...}
- line: 74
- column: 8
}end: {...}
- line: 74
- column: 15
}
}- name: "circles"
}body: Fragment {...}
- type: "Fragment"
nodes: [...] (5)
Text {...}
- type: "Text"
- start: 1561
- end: 1564
- raw: "\n\t\t"
- data: "\n\t\t"
} Comment {...}
- type: "Comment"
- start: 1564
- end: 1620
- data: " svelte-ignore a11y_click_events_have_key_events "
} Text {...}
- type: "Text"
- start: 1620
- end: 1623
- raw: "\n\t\t"
- data: "\n\t\t"
} RegularElement {...}
- type: "RegularElement"
- start: 1623
- end: 1930
- name: "circle"
attributes: [...] (7)
Attribute {...}
- type: "Attribute"
- start: 1634
- end: 1648
- name: "cx"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1637
- end: 1648
expression: MemberExpression {...}
- type: "MemberExpression"
- start: 1638
- end: 1647
loc: {...}
start: {...}
- line: 77
- column: 7
}end: {...}
- line: 77
- column: 16
}
}object: Identifier {...}
- type: "Identifier"
- start: 1638
- end: 1644
loc: {...}
start: {...}
- line: 77
- column: 7
}end: {...}
- line: 77
- column: 13
}
}- name: "circle"
}property: Identifier {...}
- type: "Identifier"
- start: 1645
- end: 1647
loc: {...}
start: {...}
- line: 77
- column: 14
}end: {...}
- line: 77
- column: 16
}
}- name: "cx"
}- computed: false
- optional: false
}
}
} Attribute {...}
- type: "Attribute"
- start: 1652
- end: 1666
- name: "cy"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1655
- end: 1666
expression: MemberExpression {...}
- type: "MemberExpression"
- start: 1656
- end: 1665
loc: {...}
start: {...}
- line: 78
- column: 7
}end: {...}
- line: 78
- column: 16
}
}object: Identifier {...}
- type: "Identifier"
- start: 1656
- end: 1662
loc: {...}
start: {...}
- line: 78
- column: 7
}end: {...}
- line: 78
- column: 13
}
}- name: "circle"
}property: Identifier {...}
- type: "Identifier"
- start: 1663
- end: 1665
loc: {...}
start: {...}
- line: 78
- column: 14
}end: {...}
- line: 78
- column: 16
}
}- name: "cy"
}- computed: false
- optional: false
}
}
} Attribute {...}
- type: "Attribute"
- start: 1670
- end: 1682
- name: "r"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1672
- end: 1682
expression: MemberExpression {...}
- type: "MemberExpression"
- start: 1673
- end: 1681
loc: {...}
start: {...}
- line: 79
- column: 6
}end: {...}
- line: 79
- column: 14
}
}object: Identifier {...}
- type: "Identifier"
- start: 1673
- end: 1679
loc: {...}
start: {...}
- line: 79
- column: 6
}end: {...}
- line: 79
- column: 12
}
}- name: "circle"
}property: Identifier {...}
- type: "Identifier"
- start: 1680
- end: 1681
loc: {...}
start: {...}
- line: 79
- column: 13
}end: {...}
- line: 79
- column: 14
}
}- name: "r"
}- computed: false
- optional: false
}
}
} Attribute {...}
- type: "Attribute"
- start: 1686
- end: 1728
- name: "onclick"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1694
- end: 1728
expression: ArrowFunctionExpression {...}
- type: "ArrowFunctionExpression"
- start: 1695
- end: 1727
loc: {...}
start: {...}
- line: 80
- column: 12
}end: {...}
- line: 80
- column: 44
}
}- id: null
- expression: true
- generator: false
- async: false
params: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 1696
- end: 1701
loc: {...}
start: {...}
- line: 80
- column: 13
}end: {...}
- line: 80
- column: 18
}
}- name: "event"
}
]body: CallExpression {...}
- type: "CallExpression"
- start: 1706
- end: 1727
loc: {...}
start: {...}
- line: 80
- column: 23
}end: {...}
- line: 80
- column: 44
}
}callee: Identifier {...}
- type: "Identifier"
- start: 1706
- end: 1712
loc: {...}
start: {...}
- line: 80
- column: 23
}end: {...}
- line: 80
- column: 29
}
}- name: "select"
}arguments: [...] (2)
Identifier {...}
- type: "Identifier"
- start: 1713
- end: 1719
loc: {...}
start: {...}
- line: 80
- column: 30
}end: {...}
- line: 80
- column: 36
}
}- name: "circle"
} Identifier {...}
- type: "Identifier"
- start: 1721
- end: 1726
loc: {...}
start: {...}
- line: 80
- column: 38
}end: {...}
- line: 80
- column: 43
}
}- name: "event"
}
]- optional: false
}
}
}
} Attribute {...}
- type: "Attribute"
- start: 1732
- end: 1876
- name: "oncontextmenu"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1746
- end: 1876
expression: ArrowFunctionExpression {...}
- type: "ArrowFunctionExpression"
- start: 1747
- end: 1875
loc: {...}
start: {...}
- line: 81
- column: 18
}end: {...}
- line: 86
- column: 4
}
}- id: null
- expression: false
- generator: false
- async: false
params: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 1748
- end: 1749
loc: {...}
start: {...}
- line: 81
- column: 19
}end: {...}
- line: 81
- column: 20
}
}- name: "e"
}
]body: BlockStatement {...}
- type: "BlockStatement"
- start: 1754
- end: 1875
loc: {...}
start: {...}
- line: 81
- column: 25
}end: {...}
- line: 86
- column: 4
}
}body: [...] (4)
ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 1760
- end: 1780
loc: {...}
start: {...}
- line: 82
- column: 4
}end: {...}
- line: 82
- column: 24
}
}expression: CallExpression {...}
- type: "CallExpression"
- start: 1760
- end: 1779
loc: {...}
start: {...}
- line: 82
- column: 4
}end: {...}
- line: 82
- column: 23
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 1760
- end: 1777
loc: {...}
start: {...}
- line: 82
- column: 4
}end: {...}
- line: 82
- column: 21
}
}object: Identifier {...}
- type: "Identifier"
- start: 1760
- end: 1761
loc: {...}
start: {...}
- line: 82
- column: 4
}end: {...}
- line: 82
- column: 5
}
}- name: "e"
}property: Identifier {...}
- type: "Identifier"
- start: 1762
- end: 1777
loc: {...}
start: {...}
- line: 82
- column: 6
}end: {...}
- line: 82
- column: 21
}
}- name: "stopPropagation"
}- computed: false
- optional: false
}- arguments: []
- optional: false
}
} ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 1785
- end: 1804
loc: {...}
start: {...}
- line: 83
- column: 4
}end: {...}
- line: 83
- column: 23
}
}expression: CallExpression {...}
- type: "CallExpression"
- start: 1785
- end: 1803
loc: {...}
start: {...}
- line: 83
- column: 4
}end: {...}
- line: 83
- column: 22
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 1785
- end: 1801
loc: {...}
start: {...}
- line: 83
- column: 4
}end: {...}
- line: 83
- column: 20
}
}object: Identifier {...}
- type: "Identifier"
- start: 1785
- end: 1786
loc: {...}
start: {...}
- line: 83
- column: 4
}end: {...}
- line: 83
- column: 5
}
}- name: "e"
}property: Identifier {...}
- type: "Identifier"
- start: 1787
- end: 1801
loc: {...}
start: {...}
- line: 83
- column: 6
}end: {...}
- line: 83
- column: 20
}
}- name: "preventDefault"
}- computed: false
- optional: false
}- arguments: []
- optional: false
}
} ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 1809
- end: 1832
loc: {...}
start: {...}
- line: 84
- column: 4
}end: {...}
- line: 84
- column: 27
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 1809
- end: 1831
loc: {...}
start: {...}
- line: 84
- column: 4
}end: {...}
- line: 84
- column: 26
}
}- operator: "="
left: Identifier {...}
- type: "Identifier"
- start: 1809
- end: 1818
loc: {...}
start: {...}
- line: 84
- column: 4
}end: {...}
- line: 84
- column: 13
}
}- name: "adjusting"
}right: UnaryExpression {...}
- type: "UnaryExpression"
- start: 1821
- end: 1831
loc: {...}
start: {...}
- line: 84
- column: 16
}end: {...}
- line: 84
- column: 26
}
}- operator: "!"
- prefix: true
argument: Identifier {...}
- type: "Identifier"
- start: 1822
- end: 1831
loc: {...}
start: {...}
- line: 84
- column: 17
}end: {...}
- line: 84
- column: 26
}
}- name: "adjusting"
}
}
}
} IfStatement {...}
- type: "IfStatement"
- start: 1837
- end: 1870
loc: {...}
start: {...}
- line: 85
- column: 4
}end: {...}
- line: 85
- column: 37
}
}test: Identifier {...}
- type: "Identifier"
- start: 1841
- end: 1850
loc: {...}
start: {...}
- line: 85
- column: 8
}end: {...}
- line: 85
- column: 17
}
}- name: "adjusting"
}consequent: ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 1852
- end: 1870
loc: {...}
start: {...}
- line: 85
- column: 19
}end: {...}
- line: 85
- column: 37
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 1852
- end: 1869
loc: {...}
start: {...}
- line: 85
- column: 19
}end: {...}
- line: 85
- column: 36
}
}- operator: "="
left: Identifier {...}
- type: "Identifier"
- start: 1852
- end: 1860
loc: {...}
start: {...}
- line: 85
- column: 19
}end: {...}
- line: 85
- column: 27
}
}- name: "selected"
}right: Identifier {...}
- type: "Identifier"
- start: 1863
- end: 1869
loc: {...}
start: {...}
- line: 85
- column: 30
}end: {...}
- line: 85
- column: 36
}
}- name: "circle"
}
}
}- alternate: null
}
]
}
}
}
} Attribute {...}
- type: "Attribute"
- start: 1880
- end: 1925
- name: "fill"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1885
- end: 1925
expression: ConditionalExpression {...}
- type: "ConditionalExpression"
- start: 1886
- end: 1924
loc: {...}
start: {...}
- line: 87
- column: 9
}end: {...}
- line: 87
- column: 47
}
}test: BinaryExpression {...}
- type: "BinaryExpression"
- start: 1886
- end: 1905
loc: {...}
start: {...}
- line: 87
- column: 9
}end: {...}
- line: 87
- column: 28
}
}left: Identifier {...}
- type: "Identifier"
- start: 1886
- end: 1892
loc: {...}
start: {...}
- line: 87
- column: 9
}end: {...}
- line: 87
- column: 15
}
}- name: "circle"
}- operator: "==="
right: Identifier {...}
- type: "Identifier"
- start: 1897
- end: 1905
loc: {...}
start: {...}
- line: 87
- column: 20
}end: {...}
- line: 87
- column: 28
}
}- name: "selected"
}
}consequent: Literal {...}
- type: "Literal"
- start: 1908
- end: 1914
loc: {...}
start: {...}
- line: 87
- column: 31
}end: {...}
- line: 87
- column: 37
}
}- value: "#ccc"
- raw: "'#ccc'"
}alternate: Literal {...}
- type: "Literal"
- start: 1917
- end: 1924
loc: {...}
start: {...}
- line: 87
- column: 40
}end: {...}
- line: 87
- column: 47
}
}- value: "white"
- raw: "'white'"
}
}
}
} Attribute {...}
- type: "Attribute"
- start: -1
- end: -1
- name: "class"
value: [...] (1)
Text {...}
- type: "Text"
- data: "svelte-1zh3yn"
- raw: "svelte-1zh3yn"
- start: -1
- end: -1
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
- nodes: []
}
} Text {...}
- type: "Text"
- start: 1930
- end: 1932
- raw: "\n\t"
- data: "\n\t"
}
]
}context: Identifier {...}
- type: "Identifier"
- name: "circle"
- start: 1554
loc: {...}
start: {...}
- line: 74
- column: 19
- character: 1554
}end: {...}
- line: 74
- column: 25
- character: 1560
}
}- end: 1560
- typeAnnotation: undefined
}- index: undefined
- key: undefined
} Text {...}
- type: "Text"
- start: 1939
- end: 1940
- raw: "\n"
- data: "\n"
}
]
}
} Text {...}
- type: "Text"
- start: 1946
- end: 1948
- raw: " "
- data: " "
} IfBlock {...}
- type: "IfBlock"
- elseif: false
- start: 1948
- end: 2129
test: Identifier {...}
- type: "Identifier"
- start: 1953
- end: 1962
loc: {...}
start: {...}
- line: 92
- column: 5
}end: {...}
- line: 92
- column: 14
}
}- name: "adjusting"
}consequent: Fragment {...}
- type: "Fragment"
nodes: [...] (3)
Text {...}
- type: "Text"
- start: 1963
- end: 1965
- raw: "\n\t"
- data: "\n\t"
} RegularElement {...}
- type: "RegularElement"
- start: 1965
- end: 2123
- name: "div"
attributes: [...] (1)
Attribute {...}
- type: "Attribute"
- start: 1970
- end: 1986
- name: "class"
value: [...] (1)
Text {...}
- start: 1977
- end: 1985
- type: "Text"
- raw: "adjuster"
- data: "adjuster svelte-1zh3yn"
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (5)
Text {...}
- type: "Text"
- start: 1987
- end: 1990
- raw: "\n\t\t"
- data: "\n\t\t"
} RegularElement {...}
- type: "RegularElement"
- start: 1990
- end: 2054
- name: "p"
- attributes: []
fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (4)
Text {...}
- type: "Text"
- start: 1993
- end: 2022
- raw: "adjust diameter of circle at "
- data: "adjust diameter of circle at "
} ExpressionTag {...}
- type: "ExpressionTag"
- start: 2022
- end: 2035
expression: MemberExpression {...}
- type: "MemberExpression"
- start: 2023
- end: 2034
loc: {...}
start: {...}
- line: 94
- column: 35
}end: {...}
- line: 94
- column: 46
}
}object: Identifier {...}
- type: "Identifier"
- start: 2023
- end: 2031
loc: {...}
start: {...}
- line: 94
- column: 35
}end: {...}
- line: 94
- column: 43
}
}- name: "selected"
}property: Identifier {...}
- type: "Identifier"
- start: 2032
- end: 2034
loc: {...}
start: {...}
- line: 94
- column: 44
}end: {...}
- line: 94
- column: 46
}
}- name: "cx"
}- computed: false
- optional: false
}
} Text {...}
- type: "Text"
- start: 2035
- end: 2037
- raw: ", "
- data: ", "
} ExpressionTag {...}
- type: "ExpressionTag"
- start: 2037
- end: 2050
expression: MemberExpression {...}
- type: "MemberExpression"
- start: 2038
- end: 2049
loc: {...}
start: {...}
- line: 94
- column: 50
}end: {...}
- line: 94
- column: 61
}
}object: Identifier {...}
- type: "Identifier"
- start: 2038
- end: 2046
loc: {...}
start: {...}
- line: 94
- column: 50
}end: {...}
- line: 94
- column: 58
}
}- name: "selected"
}property: Identifier {...}
- type: "Identifier"
- start: 2047
- end: 2049
loc: {...}
start: {...}
- line: 94
- column: 59
}end: {...}
- line: 94
- column: 61
}
}- name: "cy"
}- computed: false
- optional: false
}
}
]
}
} Text {...}
- type: "Text"
- start: 2054
- end: 2057
- raw: " "
- data: " "
} RegularElement {...}
- type: "RegularElement"
- start: 2057
- end: 2115
- name: "input"
attributes: [...] (4)
Attribute {...}
- type: "Attribute"
- start: 2064
- end: 2076
- name: "type"
value: [...] (1)
Text {...}
- start: 2070
- end: 2075
- type: "Text"
- raw: "range"
- data: "range"
}
]
} Attribute {...}
- type: "Attribute"
- start: 2077
- end: 2095
- name: "value"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 2083
- end: 2095
expression: MemberExpression {...}
- type: "MemberExpression"
- start: 2084
- end: 2094
loc: {...}
start: {...}
- line: 95
- column: 29
}end: {...}
- line: 95
- column: 39
}
}object: Identifier {...}
- type: "Identifier"
- start: 2084
- end: 2092
loc: {...}
start: {...}
- line: 95
- column: 29
}end: {...}
- line: 95
- column: 37
}
}- name: "selected"
}property: Identifier {...}
- type: "Identifier"
- start: 2093
- end: 2094
loc: {...}
start: {...}
- line: 95
- column: 38
}end: {...}
- line: 95
- column: 39
}
}- name: "r"
}- computed: false
- optional: false
}
}
} Attribute {...}
- type: "Attribute"
- start: 2096
- end: 2112
- name: "oninput"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 2104
- end: 2112
expression: Identifier {...}
- type: "Identifier"
- start: 2105
- end: 2111
loc: {...}
start: {...}
- line: 95
- column: 50
}end: {...}
- line: 95
- column: 56
}
}- name: "adjust"
}
}
} Attribute {...}
- type: "Attribute"
- start: -1
- end: -1
- name: "class"
value: [...] (1)
Text {...}
- type: "Text"
- data: "svelte-1zh3yn"
- raw: "svelte-1zh3yn"
- start: -1
- end: -1
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
- nodes: []
}
} Text {...}
- type: "Text"
- start: 2115
- end: 2117
- raw: "\n\t"
- data: "\n\t"
}
]
}
} Text {...}
- type: "Text"
- start: 2123
- end: 2124
- raw: "\n"
- data: "\n"
}
]
}- alternate: null
} Text {...}
- type: "Text"
- start: 2129
- end: 2131
- raw: "\n\n"
- data: "\n\n"
}
]
}- options: null
instance: Script {...}
- type: "Script"
- start: 199
- end: 1224
- context: "default"
content: Program {...}
- type: "Program"
- start: 207
- end: 1215
loc: {...}
start: {...}
- line: 1
- column: 0
}end: {...}
- line: 66
- column: 0
}
}body: [...] (12)
VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 209
- end: 227
loc: {...}
start: {...}
- line: 10
- column: 1
}end: {...}
- line: 10
- column: 19
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 213
- end: 226
loc: {...}
start: {...}
- line: 10
- column: 5
}end: {...}
- line: 10
- column: 18
}
}id: Identifier {...}
- type: "Identifier"
- start: 213
- end: 214
loc: {...}
start: {...}
- line: 10
- column: 5
}end: {...}
- line: 10
- column: 6
}
}- name: "i"
}init: CallExpression {...}
- type: "CallExpression"
- start: 217
- end: 226
loc: {...}
start: {...}
- line: 10
- column: 9
}end: {...}
- line: 10
- column: 18
}
}callee: Identifier {...}
- type: "Identifier"
- start: 217
- end: 223
loc: {...}
start: {...}
- line: 10
- column: 9
}end: {...}
- line: 10
- column: 15
}
}- name: "$state"
}arguments: [...] (1)
Literal {...}
- type: "Literal"
- start: 224
- end: 225
loc: {...}
start: {...}
- line: 10
- column: 16
}end: {...}
- line: 10
- column: 17
}
}- value: 0
- raw: "0"
}
]- optional: false
}
}
]- kind: "let"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 229
- end: 258
loc: {...}
start: {...}
- line: 11
- column: 1
}end: {...}
- line: 11
- column: 30
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 233
- end: 257
loc: {...}
start: {...}
- line: 11
- column: 5
}end: {...}
- line: 11
- column: 29
}
}id: Identifier {...}
- type: "Identifier"
- start: 233
- end: 242
loc: {...}
start: {...}
- line: 11
- column: 5
}end: {...}
- line: 11
- column: 14
}
}- name: "undoStack"
}init: CallExpression {...}
- type: "CallExpression"
- start: 245
- end: 257
loc: {...}
start: {...}
- line: 11
- column: 17
}end: {...}
- line: 11
- column: 29
}
}callee: Identifier {...}
- type: "Identifier"
- start: 245
- end: 251
loc: {...}
start: {...}
- line: 11
- column: 17
}end: {...}
- line: 11
- column: 23
}
}- name: "$state"
}arguments: [...] (1)
ArrayExpression {...}
- type: "ArrayExpression"
- start: 252
- end: 256
loc: {...}
start: {...}
- line: 11
- column: 24
}end: {...}
- line: 11
- column: 28
}
}elements: [...] (1)
ArrayExpression {...}
- type: "ArrayExpression"
- start: 253
- end: 255
loc: {...}
start: {...}
- line: 11
- column: 25
}end: {...}
- line: 11
- column: 27
}
}- elements: []
}
]
}
]- optional: false
}
}
]- kind: "let"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 260
- end: 285
loc: {...}
start: {...}
- line: 12
- column: 1
}end: {...}
- line: 12
- column: 26
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 264
- end: 284
loc: {...}
start: {...}
- line: 12
- column: 5
}end: {...}
- line: 12
- column: 25
}
}id: Identifier {...}
- type: "Identifier"
- start: 264
- end: 271
loc: {...}
start: {...}
- line: 12
- column: 5
}end: {...}
- line: 12
- column: 12
}
}- name: "circles"
}init: CallExpression {...}
- type: "CallExpression"
- start: 274
- end: 284
loc: {...}
start: {...}
- line: 12
- column: 15
}end: {...}
- line: 12
- column: 25
}
}callee: Identifier {...}
- type: "Identifier"
- start: 274
- end: 280
loc: {...}
start: {...}
- line: 12
- column: 15
}end: {...}
- line: 12
- column: 21
}
}- name: "$state"
}arguments: [...] (1)
ArrayExpression {...}
- type: "ArrayExpression"
- start: 281
- end: 283
loc: {...}
start: {...}
- line: 12
- column: 22
}end: {...}
- line: 12
- column: 24
}
}- elements: []
}
]- optional: false
}
}
]- kind: "let"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 287
- end: 311
loc: {...}
start: {...}
- line: 13
- column: 1
}end: {...}
- line: 13
- column: 25
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 291
- end: 310
loc: {...}
start: {...}
- line: 13
- column: 5
}end: {...}
- line: 13
- column: 24
}
}id: Identifier {...}
- type: "Identifier"
- start: 291
- end: 299
loc: {...}
start: {...}
- line: 13
- column: 5
}end: {...}
- line: 13
- column: 13
}
}- name: "selected"
}init: CallExpression {...}
- type: "CallExpression"
- start: 302
- end: 310
loc: {...}
start: {...}
- line: 13
- column: 16
}end: {...}
- line: 13
- column: 24
}
}callee: Identifier {...}
- type: "Identifier"
- start: 302
- end: 308
loc: {...}
start: {...}
- line: 13
- column: 16
}end: {...}
- line: 13
- column: 22
}
}- name: "$state"
}- arguments: []
- optional: false
}
}
]- kind: "let"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 313
- end: 343
loc: {...}
start: {...}
- line: 14
- column: 1
}end: {...}
- line: 14
- column: 31
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 317
- end: 342
loc: {...}
start: {...}
- line: 14
- column: 5
}end: {...}
- line: 14
- column: 30
}
}id: Identifier {...}
- type: "Identifier"
- start: 317
- end: 326
loc: {...}
start: {...}
- line: 14
- column: 5
}end: {...}
- line: 14
- column: 14
}
}- name: "adjusting"
}init: CallExpression {...}
- type: "CallExpression"
- start: 329
- end: 342
loc: {...}
start: {...}
- line: 14
- column: 17
}end: {...}
- line: 14
- column: 30
}
}callee: Identifier {...}
- type: "Identifier"
- start: 329
- end: 335
loc: {...}
start: {...}
- line: 14
- column: 17
}end: {...}
- line: 14
- column: 23
}
}- name: "$state"
}arguments: [...] (1)
Literal {...}
- type: "Literal"
- start: 336
- end: 341
loc: {...}
start: {...}
- line: 14
- column: 24
}end: {...}
- line: 14
- column: 29
}
}- value: false
- raw: "false"
}
]- optional: false
}
}
]- kind: "let"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 345
- end: 366
loc: {...}
start: {...}
- line: 15
- column: 1
}end: {...}
- line: 15
- column: 22
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 349
- end: 365
loc: {...}
start: {...}
- line: 15
- column: 5
}end: {...}
- line: 15
- column: 21
}
}id: Identifier {...}
- type: "Identifier"
- start: 349
- end: 357
loc: {...}
start: {...}
- line: 15
- column: 5
}end: {...}
- line: 15
- column: 13
}
}- name: "adjusted"
}init: Literal {...}
- type: "Literal"
- start: 360
- end: 365
loc: {...}
start: {...}
- line: 15
- column: 16
}end: {...}
- line: 15
- column: 21
}
}- value: false
- raw: "false"
}
}
]- kind: "let"
} FunctionDeclaration {...}
- type: "FunctionDeclaration"
- start: 369
- end: 684
loc: {...}
start: {...}
- line: 17
- column: 1
}end: {...}
- line: 37
- column: 2
}
}id: Identifier {...}
- type: "Identifier"
- start: 378
- end: 389
loc: {...}
start: {...}
- line: 17
- column: 10
}end: {...}
- line: 17
- column: 21
}
}- name: "handleClick"
}- expression: false
- generator: false
- async: false
params: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 390
- end: 395
loc: {...}
start: {...}
- line: 17
- column: 22
}end: {...}
- line: 17
- column: 27
}
}- name: "event"
}
]body: BlockStatement {...}
- type: "BlockStatement"
- start: 397
- end: 684
loc: {...}
start: {...}
- line: 17
- column: 29
}end: {...}
- line: 37
- column: 2
}
}body: [...] (5)
IfStatement {...}
- type: "IfStatement"
- start: 401
- end: 534
loc: {...}
start: {...}
- line: 18
- column: 2
}end: {...}
- line: 25
- column: 3
}
}test: Identifier {...}
- type: "Identifier"
- start: 405
- end: 414
loc: {...}
start: {...}
- line: 18
- column: 6
}end: {...}
- line: 18
- column: 15
}
}- name: "adjusting"
}consequent: BlockStatement {...}
- type: "BlockStatement"
- start: 416
- end: 534
loc: {...}
start: {...}
- line: 18
- column: 17
}end: {...}
- line: 25
- column: 3
}
}body: [...] (3)
ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 421
- end: 439
loc: {...}
start: {...}
- line: 19
- column: 3
}end: {...}
- line: 19
- column: 21
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 421
- end: 438
loc: {...}
start: {...}
- line: 19
- column: 3
}end: {...}
- line: 19
- column: 20
}
}- operator: "="
left: Identifier {...}
- type: "Identifier"
- start: 421
- end: 430
loc: {...}
start: {...}
- line: 19
- column: 3
}end: {...}
- line: 19
- column: 12
}
}- name: "adjusting"
}right: Literal {...}
- type: "Literal"
- start: 433
- end: 438
loc: {...}
start: {...}
- line: 19
- column: 15
}end: {...}
- line: 19
- column: 20
}
}- value: false
- raw: "false"
}
}
} IfStatement {...}
- type: "IfStatement"
- start: 498
- end: 519
loc: {...}
start: {...}
- line: 23
- column: 3
}end: {...}
- line: 23
- column: 24
}
}test: Identifier {...}
- type: "Identifier"
- start: 502
- end: 510
loc: {...}
start: {...}
- line: 23
- column: 7
}end: {...}
- line: 23
- column: 15
}
}- name: "adjusted"
}consequent: ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 512
- end: 519
loc: {...}
start: {...}
- line: 23
- column: 17
}end: {...}
- line: 23
- column: 24
}
}expression: CallExpression {...}
- type: "CallExpression"
- start: 512
- end: 518
loc: {...}
start: {...}
- line: 23
- column: 17
}end: {...}
- line: 23
- column: 23
}
}callee: Identifier {...}
- type: "Identifier"
- start: 512
- end: 516
loc: {...}
start: {...}
- line: 23
- column: 17
}end: {...}
- line: 23
- column: 21
}
}- name: "push"
}- arguments: []
- optional: false
}
}- alternate: null
leadingComments: [...] (2)
Line {...}
- type: "Line"
- value: " if circle was adjusted,"
- start: 444
- end: 470
} Line {...}
- type: "Line"
- value: " push to the stack"
- start: 474
- end: 494
}
]
} ReturnStatement {...}
- type: "ReturnStatement"
- start: 523
- end: 530
loc: {...}
start: {...}
- line: 24
- column: 3
}end: {...}
- line: 24
- column: 10
}
}- argument: null
}
]
}- alternate: null
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 538
- end: 612
loc: {...}
start: {...}
- line: 27
- column: 2
}end: {...}
- line: 31
- column: 4
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 544
- end: 611
loc: {...}
start: {...}
- line: 27
- column: 8
}end: {...}
- line: 31
- column: 3
}
}id: Identifier {...}
- type: "Identifier"
- start: 544
- end: 550
loc: {...}
start: {...}
- line: 27
- column: 8
}end: {...}
- line: 27
- column: 14
}
}- name: "circle"
}init: ObjectExpression {...}
- type: "ObjectExpression"
- start: 553
- end: 611
loc: {...}
start: {...}
- line: 27
- column: 17
}end: {...}
- line: 31
- column: 3
}
}properties: [...] (3)
Property {...}
- type: "Property"
- start: 558
- end: 575
loc: {...}
start: {...}
- line: 28
- column: 3
}end: {...}
- line: 28
- column: 20
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 558
- end: 560
loc: {...}
start: {...}
- line: 28
- column: 3
}end: {...}
- line: 28
- column: 5
}
}- name: "cx"
}value: MemberExpression {...}
- type: "MemberExpression"
- start: 562
- end: 575
loc: {...}
start: {...}
- line: 28
- column: 7
}end: {...}
- line: 28
- column: 20
}
}object: Identifier {...}
- type: "Identifier"
- start: 562
- end: 567
loc: {...}
start: {...}
- line: 28
- column: 7
}end: {...}
- line: 28
- column: 12
}
}- name: "event"
}property: Identifier {...}
- type: "Identifier"
- start: 568
- end: 575
loc: {...}
start: {...}
- line: 28
- column: 13
}end: {...}
- line: 28
- column: 20
}
}- name: "clientX"
}- computed: false
- optional: false
}- kind: "init"
} Property {...}
- type: "Property"
- start: 580
- end: 597
loc: {...}
start: {...}
- line: 29
- column: 3
}end: {...}
- line: 29
- column: 20
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 580
- end: 582
loc: {...}
start: {...}
- line: 29
- column: 3
}end: {...}
- line: 29
- column: 5
}
}- name: "cy"
}value: MemberExpression {...}
- type: "MemberExpression"
- start: 584
- end: 597
loc: {...}
start: {...}
- line: 29
- column: 7
}end: {...}
- line: 29
- column: 20
}
}object: Identifier {...}
- type: "Identifier"
- start: 584
- end: 589
loc: {...}
start: {...}
- line: 29
- column: 7
}end: {...}
- line: 29
- column: 12
}
}- name: "event"
}property: Identifier {...}
- type: "Identifier"
- start: 590
- end: 597
loc: {...}
start: {...}
- line: 29
- column: 13
}end: {...}
- line: 29
- column: 20
}
}- name: "clientY"
}- computed: false
- optional: false
}- kind: "init"
} Property {...}
- type: "Property"
- start: 602
- end: 607
loc: {...}
start: {...}
- line: 30
- column: 3
}end: {...}
- line: 30
- column: 8
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 602
- end: 603
loc: {...}
start: {...}
- line: 30
- column: 3
}end: {...}
- line: 30
- column: 4
}
}- name: "r"
}value: Literal {...}
- type: "Literal"
- start: 605
- end: 607
loc: {...}
start: {...}
- line: 30
- column: 6
}end: {...}
- line: 30
- column: 8
}
}- value: 50
- raw: "50"
}- kind: "init"
}
]
}
}
]- kind: "const"
} ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 616
- end: 649
loc: {...}
start: {...}
- line: 33
- column: 2
}end: {...}
- line: 33
- column: 35
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 616
- end: 648
loc: {...}
start: {...}
- line: 33
- column: 2
}end: {...}
- line: 33
- column: 34
}
}- operator: "="
left: Identifier {...}
- type: "Identifier"
- start: 616
- end: 623
loc: {...}
start: {...}
- line: 33
- column: 2
}end: {...}
- line: 33
- column: 9
}
}- name: "circles"
}right: CallExpression {...}
- type: "CallExpression"
- start: 626
- end: 648
loc: {...}
start: {...}
- line: 33
- column: 12
}end: {...}
- line: 33
- column: 34
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 626
- end: 640
loc: {...}
start: {...}
- line: 33
- column: 12
}end: {...}
- line: 33
- column: 26
}
}object: Identifier {...}
- type: "Identifier"
- start: 626
- end: 633
loc: {...}
start: {...}
- line: 33
- column: 12
}end: {...}
- line: 33
- column: 19
}
}- name: "circles"
}property: Identifier {...}
- type: "Identifier"
- start: 634
- end: 640
loc: {...}
start: {...}
- line: 33
- column: 20
}end: {...}
- line: 33
- column: 26
}
}- name: "concat"
}- computed: false
- optional: false
}arguments: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 641
- end: 647
loc: {...}
start: {...}
- line: 33
- column: 27
}end: {...}
- line: 33
- column: 33
}
}- name: "circle"
}
]- optional: false
}
}
} ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 652
- end: 670
loc: {...}
start: {...}
- line: 34
- column: 2
}end: {...}
- line: 34
- column: 20
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 652
- end: 669
loc: {...}
start: {...}
- line: 34
- column: 2
}end: {...}
- line: 34
- column: 19
}
}- operator: "="
left: Identifier {...}
- type: "Identifier"
- start: 652
- end: 660
loc: {...}
start: {...}
- line: 34
- column: 2
}end: {...}
- line: 34
- column: 10
}
}- name: "selected"
}right: Identifier {...}
- type: "Identifier"
- start: 663
- end: 669
loc: {...}
start: {...}
- line: 34
- column: 13
}end: {...}
- line: 34
- column: 19
}
}- name: "circle"
}
}
} ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 674
- end: 681
loc: {...}
start: {...}
- line: 36
- column: 2
}end: {...}
- line: 36
- column: 9
}
}expression: CallExpression {...}
- type: "CallExpression"
- start: 674
- end: 680
loc: {...}
start: {...}
- line: 36
- column: 2
}end: {...}
- line: 36
- column: 8
}
}callee: Identifier {...}
- type: "Identifier"
- start: 674
- end: 678
loc: {...}
start: {...}
- line: 36
- column: 2
}end: {...}
- line: 36
- column: 6
}
}- name: "push"
}- arguments: []
- optional: false
}
}
]
}
} FunctionDeclaration {...}
- type: "FunctionDeclaration"
- start: 687
- end: 790
loc: {...}
start: {...}
- line: 39
- column: 1
}end: {...}
- line: 43
- column: 2
}
}id: Identifier {...}
- type: "Identifier"
- start: 696
- end: 702
loc: {...}
start: {...}
- line: 39
- column: 10
}end: {...}
- line: 39
- column: 16
}
}- name: "adjust"
}- expression: false
- generator: false
- async: false
params: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 703
- end: 708
loc: {...}
start: {...}
- line: 39
- column: 17
}end: {...}
- line: 39
- column: 22
}
}- name: "event"
}
]body: BlockStatement {...}
- type: "BlockStatement"
- start: 710
- end: 790
loc: {...}
start: {...}
- line: 39
- column: 24
}end: {...}
- line: 43
- column: 2
}
}body: [...] (3)
ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 714
- end: 747
loc: {...}
start: {...}
- line: 40
- column: 2
}end: {...}
- line: 40
- column: 35
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 714
- end: 746
loc: {...}
start: {...}
- line: 40
- column: 2
}end: {...}
- line: 40
- column: 34
}
}- operator: "="
left: MemberExpression {...}
- type: "MemberExpression"
- start: 714
- end: 724
loc: {...}
start: {...}
- line: 40
- column: 2
}end: {...}
- line: 40
- column: 12
}
}object: Identifier {...}
- type: "Identifier"
- start: 714
- end: 722
loc: {...}
start: {...}
- line: 40
- column: 2
}end: {...}
- line: 40
- column: 10
}
}- name: "selected"
}property: Identifier {...}
- type: "Identifier"
- start: 723
- end: 724
loc: {...}
start: {...}
- line: 40
- column: 11
}end: {...}
- line: 40
- column: 12
}
}- name: "r"
}- computed: false
- optional: false
}right: UnaryExpression {...}
- type: "UnaryExpression"
- start: 727
- end: 746
loc: {...}
start: {...}
- line: 40
- column: 15
}end: {...}
- line: 40
- column: 34
}
}- operator: "+"
- prefix: true
argument: MemberExpression {...}
- type: "MemberExpression"
- start: 728
- end: 746
loc: {...}
start: {...}
- line: 40
- column: 16
}end: {...}
- line: 40
- column: 34
}
}object: MemberExpression {...}
- type: "MemberExpression"
- start: 728
- end: 740
loc: {...}
start: {...}
- line: 40
- column: 16
}end: {...}
- line: 40
- column: 28
}
}object: Identifier {...}
- type: "Identifier"
- start: 728
- end: 733
loc: {...}
start: {...}
- line: 40
- column: 16
}end: {...}
- line: 40
- column: 21
}
}- name: "event"
}property: Identifier {...}
- type: "Identifier"
- start: 734
- end: 740
loc: {...}
start: {...}
- line: 40
- column: 22
}end: {...}
- line: 40
- column: 28
}
}- name: "target"
}- computed: false
- optional: false
}property: Identifier {...}
- type: "Identifier"
- start: 741
- end: 746
loc: {...}
start: {...}
- line: 40
- column: 29
}end: {...}
- line: 40
- column: 34
}
}- name: "value"
}- computed: false
- optional: false
}
}
}
} ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 750
- end: 768
loc: {...}
start: {...}
- line: 41
- column: 2
}end: {...}
- line: 41
- column: 20
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 750
- end: 767
loc: {...}
start: {...}
- line: 41
- column: 2
}end: {...}
- line: 41
- column: 19
}
}- operator: "="
left: Identifier {...}
- type: "Identifier"
- start: 750
- end: 757
loc: {...}
start: {...}
- line: 41
- column: 2
}end: {...}
- line: 41
- column: 9
}
}- name: "circles"
}right: Identifier {...}
- type: "Identifier"
- start: 760
- end: 767
loc: {...}
start: {...}
- line: 41
- column: 12
}end: {...}
- line: 41
- column: 19
}
}- name: "circles"
}
}
} ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 771
- end: 787
loc: {...}
start: {...}
- line: 42
- column: 2
}end: {...}
- line: 42
- column: 18
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 771
- end: 786
loc: {...}
start: {...}
- line: 42
- column: 2
}end: {...}
- line: 42
- column: 17
}
}- operator: "="
left: Identifier {...}
- type: "Identifier"
- start: 771
- end: 779
loc: {...}
start: {...}
- line: 42
- column: 2
}end: {...}
- line: 42
- column: 10
}
}- name: "adjusted"
}right: Literal {...}
- type: "Literal"
- start: 782
- end: 786
loc: {...}
start: {...}
- line: 42
- column: 13
}end: {...}
- line: 42
- column: 17
}
}- value: true
- raw: "true"
}
}
}
]
}
} FunctionDeclaration {...}
- type: "FunctionDeclaration"
- start: 793
- end: 902
loc: {...}
start: {...}
- line: 45
- column: 1
}end: {...}
- line: 50
- column: 2
}
}id: Identifier {...}
- type: "Identifier"
- start: 802
- end: 808
loc: {...}
start: {...}
- line: 45
- column: 10
}end: {...}
- line: 45
- column: 16
}
}- name: "select"
}- expression: false
- generator: false
- async: false
params: [...] (2)
Identifier {...}
- type: "Identifier"
- start: 809
- end: 815
loc: {...}
start: {...}
- line: 45
- column: 17
}end: {...}
- line: 45
- column: 23
}
}- name: "circle"
} Identifier {...}
- type: "Identifier"
- start: 817
- end: 822
loc: {...}
start: {...}
- line: 45
- column: 25
}end: {...}
- line: 45
- column: 30
}
}- name: "event"
}
]body: BlockStatement {...}
- type: "BlockStatement"
- start: 824
- end: 902
loc: {...}
start: {...}
- line: 45
- column: 32
}end: {...}
- line: 50
- column: 2
}
}body: [...] (1)
IfStatement {...}
- type: "IfStatement"
- start: 828
- end: 899
loc: {...}
start: {...}
- line: 46
- column: 2
}end: {...}
- line: 49
- column: 3
}
}test: UnaryExpression {...}
- type: "UnaryExpression"
- start: 832
- end: 842
loc: {...}
start: {...}
- line: 46
- column: 6
}end: {...}
- line: 46
- column: 16
}
}- operator: "!"
- prefix: true
argument: Identifier {...}
- type: "Identifier"
- start: 833
- end: 842
loc: {...}
start: {...}
- line: 46
- column: 7
}end: {...}
- line: 46
- column: 16
}
}- name: "adjusting"
}
}consequent: BlockStatement {...}
- type: "BlockStatement"
- start: 844
- end: 899
loc: {...}
start: {...}
- line: 46
- column: 18
}end: {...}
- line: 49
- column: 3
}
}body: [...] (2)
ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 849
- end: 873
loc: {...}
start: {...}
- line: 47
- column: 3
}end: {...}
- line: 47
- column: 27
}
}expression: CallExpression {...}
- type: "CallExpression"
- start: 849
- end: 872
loc: {...}
start: {...}
- line: 47
- column: 3
}end: {...}
- line: 47
- column: 26
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 849
- end: 870
loc: {...}
start: {...}
- line: 47
- column: 3
}end: {...}
- line: 47
- column: 24
}
}object: Identifier {...}
- type: "Identifier"
- start: 849
- end: 854
loc: {...}
start: {...}
- line: 47
- column: 3
}end: {...}
- line: 47
- column: 8
}
}- name: "event"
}property: Identifier {...}
- type: "Identifier"
- start: 855
- end: 870
loc: {...}
start: {...}
- line: 47
- column: 9
}end: {...}
- line: 47
- column: 24
}
}- name: "stopPropagation"
}- computed: false
- optional: false
}- arguments: []
- optional: false
}
} ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 877
- end: 895
loc: {...}
start: {...}
- line: 48
- column: 3
}end: {...}
- line: 48
- column: 21
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 877
- end: 894
loc: {...}
start: {...}
- line: 48
- column: 3
}end: {...}
- line: 48
- column: 20
}
}- operator: "="
left: Identifier {...}
- type: "Identifier"
- start: 877
- end: 885
loc: {...}
start: {...}
- line: 48
- column: 3
}end: {...}
- line: 48
- column: 11
}
}- name: "selected"
}right: Identifier {...}
- type: "Identifier"
- start: 888
- end: 894
loc: {...}
start: {...}
- line: 48
- column: 14
}end: {...}
- line: 48
- column: 20
}
}- name: "circle"
}
}
}
]
}- alternate: null
}
]
}
} FunctionDeclaration {...}
- type: "FunctionDeclaration"
- start: 905
- end: 1038
loc: {...}
start: {...}
- line: 52
- column: 1
}end: {...}
- line: 56
- column: 2
}
}id: Identifier {...}
- type: "Identifier"
- start: 914
- end: 918
loc: {...}
start: {...}
- line: 52
- column: 10
}end: {...}
- line: 52
- column: 14
}
}- name: "push"
}- expression: false
- generator: false
- async: false
- params: []
body: BlockStatement {...}
- type: "BlockStatement"
- start: 921
- end: 1038
loc: {...}
start: {...}
- line: 52
- column: 17
}end: {...}
- line: 56
- column: 2
}
}body: [...] (3)
VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 925
- end: 970
loc: {...}
start: {...}
- line: 53
- column: 2
}end: {...}
- line: 53
- column: 47
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 931
- end: 969
loc: {...}
start: {...}
- line: 53
- column: 8
}end: {...}
- line: 53
- column: 46
}
}id: Identifier {...}
- type: "Identifier"
- start: 931
- end: 943
loc: {...}
start: {...}
- line: 53
- column: 8
}end: {...}
- line: 53
- column: 20
}
}- name: "newUndoStack"
}init: CallExpression {...}
- type: "CallExpression"
- start: 946
- end: 969
loc: {...}
start: {...}
- line: 53
- column: 23
}end: {...}
- line: 53
- column: 46
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 946
- end: 961
loc: {...}
start: {...}
- line: 53
- column: 23
}end: {...}
- line: 53
- column: 38
}
}object: Identifier {...}
- type: "Identifier"
- start: 946
- end: 955
loc: {...}
start: {...}
- line: 53
- column: 23
}end: {...}
- line: 53
- column: 32
}
}- name: "undoStack"
}property: Identifier {...}
- type: "Identifier"
- start: 956
- end: 961
loc: {...}
start: {...}
- line: 53
- column: 33
}end: {...}
- line: 53
- column: 38
}
}- name: "slice"
}- computed: false
- optional: false
}arguments: [...] (2)
Literal {...}
- type: "Literal"
- start: 962
- end: 963
loc: {...}
start: {...}
- line: 53
- column: 39
}end: {...}
- line: 53
- column: 40
}
}- value: 0
- raw: "0"
} UpdateExpression {...}
- type: "UpdateExpression"
- start: 965
- end: 968
loc: {...}
start: {...}
- line: 53
- column: 42
}end: {...}
- line: 53
- column: 45
}
}- operator: "++"
- prefix: true
argument: Identifier {...}
- type: "Identifier"
- start: 967
- end: 968
loc: {...}
start: {...}
- line: 53
- column: 44
}end: {...}
- line: 53
- column: 45
}
}- name: "i"
}
}
]- optional: false
}
}
]- kind: "const"
} ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 973
- end: 1007
loc: {...}
start: {...}
- line: 54
- column: 2
}end: {...}
- line: 54
- column: 36
}
}expression: CallExpression {...}
- type: "CallExpression"
- start: 973
- end: 1006
loc: {...}
start: {...}
- line: 54
- column: 2
}end: {...}
- line: 54
- column: 35
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 973
- end: 990
loc: {...}
start: {...}
- line: 54
- column: 2
}end: {...}
- line: 54
- column: 19
}
}object: Identifier {...}
- type: "Identifier"
- start: 973
- end: 985
loc: {...}
start: {...}
- line: 54
- column: 2
}end: {...}
- line: 54
- column: 14
}
}- name: "newUndoStack"
}property: Identifier {...}
- type: "Identifier"
- start: 986
- end: 990
loc: {...}
start: {...}
- line: 54
- column: 15
}end: {...}
- line: 54
- column: 19
}
}- name: "push"
}- computed: false
- optional: false
}arguments: [...] (1)
CallExpression {...}
- type: "CallExpression"
- start: 991
- end: 1005
loc: {...}
start: {...}
- line: 54
- column: 20
}end: {...}
- line: 54
- column: 34
}
}callee: Identifier {...}
- type: "Identifier"
- start: 991
- end: 996
loc: {...}
start: {...}
- line: 54
- column: 20
}end: {...}
- line: 54
- column: 25
}
}- name: "clone"
}arguments: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 997
- end: 1004
loc: {...}
start: {...}
- line: 54
- column: 26
}end: {...}
- line: 54
- column: 33
}
}- name: "circles"
}
]- optional: false
}
]- optional: false
}
} ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 1010
- end: 1035
loc: {...}
start: {...}
- line: 55
- column: 2
}end: {...}
- line: 55
- column: 27
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 1010
- end: 1034
loc: {...}
start: {...}
- line: 55
- column: 2
}end: {...}
- line: 55
- column: 26
}
}- operator: "="
left: Identifier {...}
- type: "Identifier"
- start: 1010
- end: 1019
loc: {...}
start: {...}
- line: 55
- column: 2
}end: {...}
- line: 55
- column: 11
}
}- name: "undoStack"
}right: Identifier {...}
- type: "Identifier"
- start: 1022
- end: 1034
loc: {...}
start: {...}
- line: 55
- column: 14
}end: {...}
- line: 55
- column: 26
}
}- name: "newUndoStack"
}
}
}
]
}
} FunctionDeclaration {...}
- type: "FunctionDeclaration"
- start: 1041
- end: 1125
loc: {...}
start: {...}
- line: 58
- column: 1
}end: {...}
- line: 61
- column: 2
}
}id: Identifier {...}
- type: "Identifier"
- start: 1050
- end: 1056
loc: {...}
start: {...}
- line: 58
- column: 10
}end: {...}
- line: 58
- column: 16
}
}- name: "travel"
}- expression: false
- generator: false
- async: false
params: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 1057
- end: 1058
loc: {...}
start: {...}
- line: 58
- column: 17
}end: {...}
- line: 58
- column: 18
}
}- name: "d"
}
]body: BlockStatement {...}
- type: "BlockStatement"
- start: 1060
- end: 1125
loc: {...}
start: {...}
- line: 58
- column: 20
}end: {...}
- line: 61
- column: 2
}
}body: [...] (2)
ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 1064
- end: 1101
loc: {...}
start: {...}
- line: 59
- column: 2
}end: {...}
- line: 59
- column: 39
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 1064
- end: 1100
loc: {...}
start: {...}
- line: 59
- column: 2
}end: {...}
- line: 59
- column: 38
}
}- operator: "="
left: Identifier {...}
- type: "Identifier"
- start: 1064
- end: 1071
loc: {...}
start: {...}
- line: 59
- column: 2
}end: {...}
- line: 59
- column: 9
}
}- name: "circles"
}right: CallExpression {...}
- type: "CallExpression"
- start: 1074
- end: 1100
loc: {...}
start: {...}
- line: 59
- column: 12
}end: {...}
- line: 59
- column: 38
}
}callee: Identifier {...}
- type: "Identifier"
- start: 1074
- end: 1079
loc: {...}
start: {...}
- line: 59
- column: 12
}end: {...}
- line: 59
- column: 17
}
}- name: "clone"
}arguments: [...] (1)
MemberExpression {...}
- type: "MemberExpression"
- start: 1080
- end: 1099
loc: {...}
start: {...}
- line: 59
- column: 18
}end: {...}
- line: 59
- column: 37
}
}object: Identifier {...}
- type: "Identifier"
- start: 1080
- end: 1089
loc: {...}
start: {...}
- line: 59
- column: 18
}end: {...}
- line: 59
- column: 27
}
}- name: "undoStack"
}property: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 1091
- end: 1097
loc: {...}
start: {...}
- line: 59
- column: 29
}end: {...}
- line: 59
- column: 35
}
}- operator: "+="
left: Identifier {...}
- type: "Identifier"
- start: 1091
- end: 1092
loc: {...}
start: {...}
- line: 59
- column: 29
}end: {...}
- line: 59
- column: 30
}
}- name: "i"
}right: Identifier {...}
- type: "Identifier"
- start: 1096
- end: 1097
loc: {...}
start: {...}
- line: 59
- column: 34
}end: {...}
- line: 59
- column: 35
}
}- name: "d"
}
}- computed: true
- optional: false
}
]- optional: false
}
}
} ExpressionStatement {...}
- type: "ExpressionStatement"
- start: 1104
- end: 1122
loc: {...}
start: {...}
- line: 60
- column: 2
}end: {...}
- line: 60
- column: 20
}
}expression: AssignmentExpression {...}
- type: "AssignmentExpression"
- start: 1104
- end: 1121
loc: {...}
start: {...}
- line: 60
- column: 2
}end: {...}
- line: 60
- column: 19
}
}- operator: "="
left: Identifier {...}
- type: "Identifier"
- start: 1104
- end: 1113
loc: {...}
start: {...}
- line: 60
- column: 2
}end: {...}
- line: 60
- column: 11
}
}- name: "adjusting"
}right: Literal {...}
- type: "Literal"
- start: 1116
- end: 1121
loc: {...}
start: {...}
- line: 60
- column: 14
}end: {...}
- line: 60
- column: 19
}
}- value: false
- raw: "false"
}
}
}
]
}
} FunctionDeclaration {...}
- type: "FunctionDeclaration"
- start: 1128
- end: 1214
loc: {...}
start: {...}
- line: 63
- column: 1
}end: {...}
- line: 65
- column: 2
}
}id: Identifier {...}
- type: "Identifier"
- start: 1137
- end: 1142
loc: {...}
start: {...}
- line: 63
- column: 10
}end: {...}
- line: 63
- column: 15
}
}- name: "clone"
}- expression: false
- generator: false
- async: false
params: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 1143
- end: 1150
loc: {...}
start: {...}
- line: 63
- column: 16
}end: {...}
- line: 63
- column: 23
}
}- name: "circles"
}
]body: BlockStatement {...}
- type: "BlockStatement"
- start: 1152
- end: 1214
loc: {...}
start: {...}
- line: 63
- column: 25
}end: {...}
- line: 65
- column: 2
}
}body: [...] (1)
ReturnStatement {...}
- type: "ReturnStatement"
- start: 1156
- end: 1211
loc: {...}
start: {...}
- line: 64
- column: 2
}end: {...}
- line: 64
- column: 57
}
}argument: CallExpression {...}
- type: "CallExpression"
- start: 1163
- end: 1210
loc: {...}
start: {...}
- line: 64
- column: 9
}end: {...}
- line: 64
- column: 56
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 1163
- end: 1174
loc: {...}
start: {...}
- line: 64
- column: 9
}end: {...}
- line: 64
- column: 20
}
}object: Identifier {...}
- type: "Identifier"
- start: 1163
- end: 1170
loc: {...}
start: {...}
- line: 64
- column: 9
}end: {...}
- line: 64
- column: 16
}
}- name: "circles"
}property: Identifier {...}
- type: "Identifier"
- start: 1171
- end: 1174
loc: {...}
start: {...}
- line: 64
- column: 17
}end: {...}
- line: 64
- column: 20
}
}- name: "map"
}- computed: false
- optional: false
}arguments: [...] (1)
ArrowFunctionExpression {...}
- type: "ArrowFunctionExpression"
- start: 1175
- end: 1209
loc: {...}
start: {...}
- line: 64
- column: 21
}end: {...}
- line: 64
- column: 55
}
}- id: null
- expression: true
- generator: false
- async: false
params: [...] (1)
ObjectPattern {...}
- type: "ObjectPattern"
- start: 1176
- end: 1189
loc: {...}
start: {...}
- line: 64
- column: 22
}end: {...}
- line: 64
- column: 35
}
}properties: [...] (3)
Property {...}
- type: "Property"
- start: 1178
- end: 1180
loc: {...}
start: {...}
- line: 64
- column: 24
}end: {...}
- line: 64
- column: 26
}
}- method: false
- shorthand: true
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 1178
- end: 1180
loc: {...}
start: {...}
- line: 64
- column: 24
}end: {...}
- line: 64
- column: 26
}
}- name: "cx"
}- kind: "init"
value: Identifier {...}
- type: "Identifier"
- start: 1178
- end: 1180
loc: {...}
start: {...}
- line: 64
- column: 24
}end: {...}
- line: 64
- column: 26
}
}- name: "cx"
}
} Property {...}
- type: "Property"
- start: 1182
- end: 1184
loc: {...}
start: {...}
- line: 64
- column: 28
}end: {...}
- line: 64
- column: 30
}
}- method: false
- shorthand: true
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 1182
- end: 1184
loc: {...}
start: {...}
- line: 64
- column: 28
}end: {...}
- line: 64
- column: 30
}
}- name: "cy"
}- kind: "init"
value: Identifier {...}
- type: "Identifier"
- start: 1182
- end: 1184
loc: {...}
start: {...}
- line: 64
- column: 28
}end: {...}
- line: 64
- column: 30
}
}- name: "cy"
}
} Property {...}
- type: "Property"
- start: 1186
- end: 1187
loc: {...}
start: {...}
- line: 64
- column: 32
}end: {...}
- line: 64
- column: 33
}
}- method: false
- shorthand: true
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 1186
- end: 1187
loc: {...}
start: {...}
- line: 64
- column: 32
}end: {...}
- line: 64
- column: 33
}
}- name: "r"
}- kind: "init"
value: Identifier {...}
- type: "Identifier"
- start: 1186
- end: 1187
loc: {...}
start: {...}
- line: 64
- column: 32
}end: {...}
- line: 64
- column: 33
}
}- name: "r"
}
}
]
}
]body: ObjectExpression {...}
- type: "ObjectExpression"
- start: 1195
- end: 1208
loc: {...}
start: {...}
- line: 64
- column: 41
}end: {...}
- line: 64
- column: 54
}
}properties: [...] (3)
Property {...}
- type: "Property"
- start: 1197
- end: 1199
loc: {...}
start: {...}
- line: 64
- column: 43
}end: {...}
- line: 64
- column: 45
}
}- method: false
- shorthand: true
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 1197
- end: 1199
loc: {...}
start: {...}
- line: 64
- column: 43
}end: {...}
- line: 64
- column: 45
}
}- name: "cx"
}- kind: "init"
value: Identifier {...}
- type: "Identifier"
- start: 1197
- end: 1199
loc: {...}
start: {...}
- line: 64
- column: 43
}end: {...}
- line: 64
- column: 45
}
}- name: "cx"
}
} Property {...}
- type: "Property"
- start: 1201
- end: 1203
loc: {...}
start: {...}
- line: 64
- column: 47
}end: {...}
- line: 64
- column: 49
}
}- method: false
- shorthand: true
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 1201
- end: 1203
loc: {...}
start: {...}
- line: 64
- column: 47
}end: {...}
- line: 64
- column: 49
}
}- name: "cy"
}- kind: "init"
value: Identifier {...}
- type: "Identifier"
- start: 1201
- end: 1203
loc: {...}
start: {...}
- line: 64
- column: 47
}end: {...}
- line: 64
- column: 49
}
}- name: "cy"
}
} Property {...}
- type: "Property"
- start: 1205
- end: 1206
loc: {...}
start: {...}
- line: 64
- column: 51
}end: {...}
- line: 64
- column: 52
}
}- method: false
- shorthand: true
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 1205
- end: 1206
loc: {...}
start: {...}
- line: 64
- column: 51
}end: {...}
- line: 64
- column: 52
}
}- name: "r"
}- kind: "init"
value: Identifier {...}
- type: "Identifier"
- start: 1205
- end: 1206
loc: {...}
start: {...}
- line: 64
- column: 51
}end: {...}
- line: 64
- column: 52
}
}- name: "r"
}
}
]
}
}
]- optional: false
}
}
]
}
}
]- sourceType: "module"
leadingComments: [...] (1)
Line {...}
- type: "Line"
- value: "\nhttps://eugenkiss.github.io/7guis/tasks#circle\n\nClick on the canvas to draw a circle. Click on a circle\nto select it. Right-click on the canvas to adjust the\nradius of the selected circle.\n"
}
]
}- attributes: []
}
}
The AST is not public API and may change at any point in time