From 0486f7ab2a85c2047a65c34b4d4258842c0ee487 Mon Sep 17 00:00:00 2001 From: jessikitty Date: Fri, 24 Jul 2026 14:14:24 +1000 Subject: [PATCH] Layout editor: ghost height (cm) control in the table panel --- public/admin/layout.html | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/public/admin/layout.html b/public/admin/layout.html index b811d31..1ef7bde 100644 --- a/public/admin/layout.html +++ b/public/admin/layout.html @@ -299,12 +299,17 @@ function panel(rebuild = true) { const o = sel && dataOf(sel); if (!o) { side.innerHTML = 'Tap an object to select it, then drag the gizmo arrows (X red, Y green = height, Z blue). All values in cm.'; return; } if (sel.kind === 'table') { - let h = `

table dimensions

`; + let h = `

table & scale

`; h += field('width (cm)', o.width, v => o.width = v, { step: 1 }); h += field('depth (cm)', o.depth, v => o.depth = v, { step: 1 }); h += field('offset x', o.offsetX || 0, v => o.offsetX = v, { step: 1 }); h += field('offset z', o.offsetZ || 0, v => o.offsetZ = v, { step: 1 }); h += field('show', o.show === false ? 'no' : 'yes', v => o.show = v === 'yes', { select: ['yes', 'no'] }); + h += field('ghost height (cm)', scene.ghostHeightCm ?? 4, v => scene.ghostHeightCm = v, { step: 0.5 }); + h += `

Ghost height scales every ghost (wisp or OBJ model) to that many cm tall — + minifigure ≈ 4 cm. Models auto-normalize by bounding box, so imported OBJs land at this size + regardless of their source units; per-model fine-tune lives in the models manifest. Applies + live to all viewers on Save.

`; h += `

Orange outline = your physical table, measured from the world origin (front-left corner, N = +Z = back). Width runs W→E, depth runs S→N. Offsets shift the table if your origin isn't at its corner. Saved with the layout; also printed on the