Object tree: groups and the drawing order
Deploy web Studio / deploy (push) Successful in 1m5s

Groups: objects of type "group" draw nothing; members carry the group's id
in a new `group` field (groups nest). A hidden group hides everything in it
(Doc::hidden_in_groups, skipped by the driver), a locked one locks it in
the Studio. Removing a group moves its members up into its parent group.
isokit check warns about members of missing groups. New `order` op: the
whole object order at once (each id once), one undo step.

Studio object list as a tree in the document order, front first: each
group sits just after its members, so it draws as one block, and ground
pieces higher in the list lie on top. Groups fold open and shut; every row
has an eye and a lock (shown on hover or when set); a click on a group
selects all of it, so a drag on the map moves it all. Group / Ungroup
(Ctrl+G, Ctrl+Shift+G), Order up/down (Ctrl+] Ctrl+[, with Shift to the
front / back), drag rows above, below or into a group. Group panel: name,
zoom, ungroup, to front / back, lock, hide, delete with contents.

MCP: group field in the object schema, order op, guidance.

Tests: Rust 81 (ops: groups, order, removal; driver: nested hidden
groups), Studio 131, web 100.
This commit is contained in:
grabowski committed 2026-10-25 18:06:04 +07:00
1 parent 5ec164a633
commit 540b37020c
15 files changed
+573 -30

No files matched your search

+2 -2
View File
@@ -49,7 +49,7 @@ fn demo_renders_every_view_cleanly() {
l.id,
v.nodes
);
for o in &p.doc.objects {
for o in p.doc.objects.iter().filter(|o| o.kind != "group") {
assert!(
v.boxes.contains_key(&o.id),
"{} not drawn in {}/{rot}",
@@ -108,7 +108,7 @@ fn example_renders_every_view_cleanly(name: &str) {
assert!(v.warnings.is_empty(), "{}/{rot}: {:?}", l.id, v.warnings);
assert_eq!(v.cycles, 0, "{}/{rot}: depth-sort cycles", l.id);
assert!(!v.html.contains("NaN"));
for o in &p.doc.objects {
for o in p.doc.objects.iter().filter(|o| o.kind != "group") {
assert!(
v.boxes.contains_key(&o.id),
"{} not drawn in {}/{rot}",