@floless/app 0.128.1 → 0.128.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -54858,7 +54858,7 @@ function appVersion() {
54858
54858
  return resolveVersion({
54859
54859
  isSea: isSea2(),
54860
54860
  sqVersionXml: readSqVersionXml(),
54861
- define: true ? "0.128.1" : void 0,
54861
+ define: true ? "0.128.2" : void 0,
54862
54862
  pkgVersion: readPkgVersion()
54863
54863
  });
54864
54864
  }
@@ -54874,7 +54874,7 @@ function resolveChannel(s) {
54874
54874
  function appChannel() {
54875
54875
  return resolveChannel({
54876
54876
  isSea: isSea2(),
54877
- define: true ? "0.128.1" : void 0,
54877
+ define: true ? "0.128.2" : void 0,
54878
54878
  // argv[1] is the entry the runtime actually loaded (…/dist/floless-server.cjs), which is what
54879
54879
  // carries the npx cache prefix. Absent under the SEA exe, which never reaches the npx branch.
54880
54880
  modulePath: process.argv[1]
@@ -7,7 +7,7 @@ description: >-
7
7
  two-phase Drawing Filter process: first prepare and save the deterministic Filter, then read only the
8
8
  selected evidence into model-global members, registered plan views, observations, and revision history.
9
9
  metadata:
10
- version: 0.20.0
10
+ version: 0.20.1
11
11
  ---
12
12
 
13
13
  # Steel Takeoff — read drawings into `steel.model/v2`
@@ -112,6 +112,47 @@ non-coincident registration controls:
112
112
  - `control2_at`: the display-space location of a second grid intersection;
113
113
  - `control2_ref`: the second intersection's `{axis_x, axis_y}` labels.
114
114
 
115
+ On an initial read, before saving the Filter shell, derive each framing-plan sheet's effective `pt_per_ft`
116
+ from the measured display spans of two widely separated, non-parallel labelled grid runs (normally one X
117
+ run and one Y run) and their printed grid dimensions. Never inherit scale from an older contract or infer
118
+ it from a grid whose dimensions were themselves derived using that scale. Fit the one persisted value
119
+ deterministically from both runs: for printed lengths `f[i]` in feet and measured spans `p[i]` in points,
120
+ use `pt_per_ft = round(sum(f[i] * p[i]) / sum(f[i]^2), 6)`. Re-read or refuse when either predicted span
121
+ `f[i] * pt_per_ft` differs from its measured span by more than `2 pt`; one `pt_per_ft` cannot represent
122
+ greater non-uniform distortion. When a scale annotation is already inside the selected plan evidence, use
123
+ it only as a nominal cross-check: `72 × paper inches per foot` means
124
+ `1/4" = 1'-0"` is `18 pt/ft` and `1/2" = 1'-0"` is `36 pt/ft`. Never inspect or rasterize an excluded
125
+ title block merely to obtain scale. PDFs may have been replotted or resized, so when nominal and derived
126
+ values disagree, use the independently printed dimensions as geometric authority and record the effective
127
+ scale. Convert each checked printed run to millimetres and assert that
128
+ the corresponding root-grid intersections have that same world-space separation; the PDF registration
129
+ alone is not proof because its fitted scale can cancel an incorrect world grid. Choose `datum_at` and
130
+ `control2_at` as the endpoints of one checked run. Before freezing the shell, verify that their display
131
+ span differs by at most `2 pt` from `worldSpanMm * pt_per_ft / 304.8`; this prevents the runtime's fitted
132
+ registration scale from silently stretching an otherwise correct grid. Apply that fitted similarity
133
+ transform to both world-grid endpoints of the second, non-parallel checked run: each must land within
134
+ `2 pt` of its measured display endpoint. Negate display Y before comparing handedness (world is Y-up;
135
+ display is Y-down), then require the signed cross-product of the two run directions to keep the same sign
136
+ in world and normalized display space. This catches shear and reflected handedness that equal X/Y lengths
137
+ alone cannot. Internally consistent wrong scale and grid values are not independent evidence. If
138
+ this proof fails only after an initial Filter shell was saved, stop and start a fresh initial
139
+ read/checkpoint; never mutate the frozen shell.
140
+
141
+ When an independently authored, unmodified IFC from the same model and drawing revision is available (for
142
+ example, the original Tekla or design export, not an IFC exported from this or an older FloLess contract),
143
+ respect its declared units and use it to validate the provisional root grid and plan registration before
144
+ the initial Filter shell is saved. If revision identity is unavailable, only use surveyed or grid controls
145
+ proven unchanged between issues; a stale IFC may corroborate but must never override current drawing
146
+ dimensions. Compare at least two corresponding grid or column locations plus two separated corresponding
147
+ dimensions. In plan, compare either three non-collinear corresponding controls or two separated,
148
+ non-parallel baselines; also compare two separated corresponding elevations. A shared zero level alone
149
+ proves no Z scale. Do not rescale the IFC merely to make the native read look right. If provisional native
150
+ XY is wrong by a common factor while the separated elevations prove Z scale is correct, correct the
151
+ provisional plan registration and root grid before Save; uniform XYZ scaling destroys the already-correct
152
+ elevations. After the shell is frozen, the completed-model overlap is a verification only: if it fails,
153
+ abort and restart the initial read with a corrected shell rather than mutating registration or members.
154
+ Show the verified overlap to the user before submitting the full read.
155
+
115
156
  **Narrow headless revision exception.** When floless.app's server-owned headless preamble explicitly
116
157
  says this is a phase-one-only `revision-read`, exposes only the immutable leased PDF sources plus the
117
158
  request-scoped contract/prepass calls, and requires the exact Steel Filter Save question, do not
@@ -119,6 +160,13 @@ create an earlier plan-confirmation checkpoint. Match framing pages only to the
119
160
  already present in that project's current contract; if the match is absent or ambiguous, stop with
120
161
  `needs-you` instead of inventing a plan name. This exception never applies to an initial read, an
121
162
  interactive session, or phase two, and it is not permission to read members before the Filter Save.
163
+ Because this phase-one prepass cannot change plan registration, it also cannot prove or repair an existing
164
+ model's scale. After Filter Save, phase two must perform the source-led scale proof above. If it finds an
165
+ existing scale error, stop the revision and report the measured discrepancy; do not restart the
166
+ scale-blind prepass, partially rescale the evidenced subset, or submit a mixed-scale candidate. A global
167
+ correction cannot travel through this revision route: create a fresh project and run an initial model read
168
+ from the complete source set so every member is supported by selected evidence, then use the ordinary
169
+ review. Preserve the old project only as an inspectable archive.
122
170
 
123
171
  ⚠️ **This ONE plan-scope confirm covers both the filter pass AND the member read — they run on the
124
172
  same sheet set. Getting the OK does NOT mean "go read members"; the very next thing you do is the
package/dist/web/aware.js CHANGED
@@ -5492,6 +5492,10 @@
5492
5492
  const d = await r.json();
5493
5493
  if (awareJobOwnsPill()) return; // the job resolved while this request was in flight
5494
5494
  awareUpdateCheck = r.ok ? d : null;
5495
+ // Keep the modal's bridge names tied to the LATEST check, not to whenever the modal was last
5496
+ // opened. paintAwareUpgrade is also driven by the client subscription (a server-started job
5497
+ // never opens the modal), so without this a stale set from an earlier open could be named.
5498
+ awareUpgradeInventory = awareInventoryOf(awareUpdateCheck);
5495
5499
  if (r.ok && d.updateAvailable && d.targetVersion && d.operation === 'bridge-repair') {
5496
5500
  const count = Array.isArray(d.bridges) ? d.bridges.filter((row) => row.status !== 'current').length : 0;
5497
5501
  $awareUpdate.textContent = `Repair ${count || ''} installed bridge${count === 1 ? '' : 's'}`.replace(' ', ' ');
@@ -5533,16 +5537,48 @@
5533
5537
  let awareUpgradeReturnFocus = null;
5534
5538
  const awareBusy = (status) => status === 'starting' || status === 'running' || status === 'retrying';
5535
5539
  const awareHostLabel = (host) => ({ tekla: 'Tekla', revit: 'Revit', sketchup: 'SketchUp', rhino: 'Rhino' }[host] || host);
5540
+ // "Tekla" / "Tekla and Revit" / "Tekla, Revit, and SketchUp" — inventory order, never alphabetised,
5541
+ // so it reads the same way the results panel below it lists them.
5542
+ const awareHostList = (names) => (names.length < 3
5543
+ ? names.join(' and ')
5544
+ : `${names.slice(0, -1).join(', ')}, and ${names[names.length - 1]}`);
5545
+ /** The bridge inventory an /api/aware/update answer carries, or none when it carries no list. */
5546
+ const awareInventoryOf = (check) => (Array.isArray(check && check.bridges) ? check.bridges : []);
5547
+ /**
5548
+ * Name the bridges THIS computer actually has, instead of reciting a fixed host list.
5549
+ *
5550
+ * The installed set differs per user (it may be none, one, or several) and grows as AWARE
5551
+ * supports more hosts, so the hardcoded four-host list this replaces was both irrelevant to
5552
+ * most readers and destined to rot. An empty inventory is genuinely ambiguous —
5553
+ * the user has none, OR the inspection could not run (`checkAwareUpdate` returns no bridges when
5554
+ * the directory cannot be walked safely) — so that case falls back to a phrase which claims
5555
+ * neither, rather than asserting "no bridges are installed" we cannot verify.
5556
+ *
5557
+ * These are the names the last CHECK saw. The job re-snapshots the directory when it starts
5558
+ * (aware-update-jobs.ts), so a bridge installed or removed between the two is refreshed without
5559
+ * being named here (or named without being refreshed). The offer describes intent before a job
5560
+ * exists, so it cannot be that snapshot; the results panel below reports what the job actually
5561
+ * did. Keeping the inventory in step with every poll (see refreshAwareUpdate) is what shrinks
5562
+ * that window to the gap between the last check and the click.
5563
+ */
5564
+ const awareBridgeClause = (inventory) => {
5565
+ const names = (inventory || []).map((row) => awareHostLabel(row.host)).filter(Boolean);
5566
+ return names.length
5567
+ ? `refreshes your installed ${awareHostList(names)} bridge${names.length === 1 ? '' : 's'}`
5568
+ : 'refreshes any bridges installed on this computer';
5569
+ };
5570
+ // A registry hiccup leaves `target` empty; "v" + nothing used to render "vthe current release".
5571
+ const awareVersionLabel = (target) => (target ? `v${target}` : 'the current release');
5536
5572
  const awareUpgradeCopyText = (target, operation, inventory) => {
5537
5573
  if (operation === 'bridge-repair') {
5538
5574
  const stale = (inventory || []).filter((row) => row.status === 'stale' || row.status === 'unverifiable');
5539
5575
  const versions = stale.map((row) => `${awareHostLabel(row.host)}${row.version ? ` v${row.version}` : ''}`).join(', ');
5540
- return `AWARE v${target || 'the current release'} is current. ${versions || 'One or more installed bridges'} ${stale.length === 1 ? 'needs' : 'need'} to match it. Repairs only bridges already installed on this computer; no new bridges are installed.`;
5576
+ return `AWARE ${awareVersionLabel(target)} is current. ${versions || 'One or more installed bridges'} ${stale.length === 1 ? 'needs' : 'need'} to match it. Repairs only bridges already installed on this computer; no new bridges are installed.`;
5541
5577
  }
5542
5578
  if (operation === 'combined') {
5543
- return `Updates AWARE to v${target || 'the current release'} and refreshes any Revit, SketchUp, Rhino, or Tekla bridges already installed on this computer. No new bridges are installed.`;
5579
+ return `Updates AWARE to ${awareVersionLabel(target)} and ${awareBridgeClause(inventory)}. No new bridges are installed.`;
5544
5580
  }
5545
- return `Upgrades AWARE to v${target || 'the current release'} and refreshes any Revit, SketchUp, Rhino, or Tekla bridges already installed on this computer. No new bridges are installed. FloLess stays open; this may take a few minutes.`;
5581
+ return `Upgrades AWARE to ${awareVersionLabel(target)} and ${awareBridgeClause(inventory)}. No new bridges are installed. FloLess stays open; this may take a few minutes.`;
5546
5582
  };
5547
5583
 
5548
5584
  function closeAwareUpgradeModal() {
@@ -5677,7 +5713,7 @@
5677
5713
  }
5678
5714
  const check = awareUpdateCheck || {};
5679
5715
  awareUpgradeOperation = check.operation || ($awareUpdate && $awareUpdate.dataset.operation) || 'runtime-update';
5680
- awareUpgradeInventory = Array.isArray(check.bridges) ? check.bridges : [];
5716
+ awareUpgradeInventory = awareInventoryOf(check);
5681
5717
  awareUpgradeTarget = target;
5682
5718
  awareUpgradeReturnFocus = returnFocusTo || document.activeElement;
5683
5719
  // `runtime-failed` belongs here alongside `partial`. Without it, clicking the attention pill
@@ -18,6 +18,7 @@ import * as THREE from 'three';
18
18
  import { OrbitControls } from 'three/addons/OrbitControls.js';
19
19
  import { RoomEnvironment } from 'three/addons/RoomEnvironment.js';
20
20
  import { surfaceTextures, applyTriplanar, TILE_MM, DIRECTIONAL } from './steel-materials.js';
21
+ import { canvasToolGuidanceState } from './steel-canvas-guidance.js';
21
22
  import { Brush, Evaluator, SUBTRACTION } from 'three-bvh-csg';
22
23
  import { snapPoint, planPointToWp, memberGeometry, snapElevation, dim3dGeom, dominantAxis3d, planeBasis, planeFrom3Points, frameFrom3Points, frameFromAngle, worldToLocal, identityFrame, resolvePointEntry, offsetsFor, candidateOnPlane, snapGridPoint, clipSegmentToPlanes, pointSegmentDistance2d, perspectiveSegmentParameter, gridDepthWins, segmentHitsRect2d, projectedFootprintHitsRect2d, pickGridLevel, selectedLengthLabelAnchors, sectionKindOf } from './steel-3d-core.js';
23
24
  // `gridGeometry`, `gridCandidates3d` and `mmPerPx` moved behind the host's model read half (unit 5, P7d):
@@ -30,7 +31,7 @@ let shadowGround = null, shadowsEnabled = false; // the `shadowed` mode's grou
30
31
  let pending = null, dragging = null, marker = null, readout = null; // pending = member gesture; readout = drag dimension overlay
31
32
  let boxSel = null, rubber = null; // LEFT-drag-on-empty rubber-band multi-select
32
33
  let selectionTrace = null; // last ordinary pointer-selection route (read-only E2E diagnostic)
33
- let hoverId = null, hoverGlowIds = [], hoverChip = null, hoverRAF = 0, lastHoverXY = null; // hover readout + cursor; hoverGlowIds = every mesh currently wearing the sky glow (the WHOLE connection when hovering one of its parts)
34
+ let hoverId = null, hoverGlowIds = [], hoverChip = null, hoverChipShell = null, hoverChipToggle = null, hoverChipIdleCollapsed = false, hoverRAF = 0, lastHoverXY = null; // hover readout + cursor; hoverGlowIds = every mesh currently wearing the sky glow (the WHOLE connection when hovering one of its parts)
34
35
  let epGroup = null; // yellow/magenta endpoint markers (start/end direction dots)
35
36
  let epGeom = null, epMatStart = null, epMatEnd = null; // shared across all endpoint dots (no per-rebuild churn)
36
37
  let epRing = null, epPreview = null, epMovedLine = null; // white ring on the active end node + member rubber (epPreview) + the "moved" leader (epMovedLine) while dragging an end
@@ -291,10 +292,29 @@ function init(canvas, theApi) {
291
292
  selLenLabelHost.style.cssText = 'position:fixed;left:0;top:0;pointer-events:none;z-index:3;display:none';
292
293
  document.body.appendChild(selLenLabelHost);
293
294
  document.body.appendChild(propLabelHost);
294
- // persistent hover/selection status chip, bottom-centre of the canvas (mirrors the viewer's readout)
295
- hoverChip = document.createElement('div');
296
- hoverChip.style.cssText = 'position:fixed;display:none;pointer-events:none;z-index:55;background:var(--panel,#0f172a);color:var(--mut,#94a3b8);border:1px solid var(--line,#334155);border-radius:6px;padding:5px 12px;font:12px system-ui;white-space:nowrap;max-width:60vw;overflow:hidden;text-overflow:ellipsis;box-shadow:0 2px 8px rgba(0,0,0,.45)';
297
- document.body.appendChild(hoverChip);
295
+ // The steel editor provides a shared bottom dock: the status disclosure owns the left, while the
296
+ // non-shrinking Select/Snap controls own the right. The shared renderer also serves vector-3d.html,
297
+ // which has no dock and intentionally keeps its existing read-only bottom-centre chip.
298
+ const statusDock = document.getElementById('bottomDockLeft');
299
+ hoverChip = document.createElement('span');
300
+ if (statusDock) {
301
+ try { hoverChipIdleCollapsed = localStorage.getItem('steel:canvasStatusCollapsed:v1') === '1'; } catch (_) { hoverChipIdleCollapsed = false; }
302
+ hoverChipShell = document.createElement('div'); hoverChipShell.id = 'canvasStatus';
303
+ hoverChipToggle = document.createElement('button'); hoverChipToggle.type = 'button'; hoverChipToggle.id = 'canvasStatusToggle';
304
+ hoverChipToggle.setAttribute('aria-controls', 'canvasStatusText');
305
+ hoverChipToggle.innerHTML = '<svg viewBox="0 0 16 16" aria-hidden="true"><path d="m6 3 5 5-5 5"/></svg>';
306
+ hoverChip.id = 'canvasStatusText'; hoverChip.setAttribute('role', 'status'); hoverChip.setAttribute('aria-live', 'polite');
307
+ hoverChipToggle.onclick = () => {
308
+ if (hoverChipToggle.getAttribute('aria-disabled') === 'true') return;
309
+ hoverChipIdleCollapsed = !hoverChipIdleCollapsed;
310
+ try { localStorage.setItem('steel:canvasStatusCollapsed:v1', hoverChipIdleCollapsed ? '1' : '0'); } catch (_) {}
311
+ updateStatusChip(); hoverChipToggle.focus();
312
+ };
313
+ hoverChipShell.append(hoverChipToggle, hoverChip); statusDock.appendChild(hoverChipShell);
314
+ } else {
315
+ hoverChip.style.cssText = 'position:fixed;display:none;pointer-events:none;z-index:55;background:var(--panel,#0f172a);color:var(--mut,#94a3b8);border:1px solid var(--line,#334155);border-radius:6px;padding:5px 12px;font:12px system-ui;white-space:nowrap;max-width:60vw;overflow:hidden;text-overflow:ellipsis;box-shadow:0 2px 8px rgba(0,0,0,.45)';
316
+ document.body.appendChild(hoverChip);
317
+ }
298
318
  // rubber-band overlay for LEFT-drag box-select on empty space
299
319
  rubber = document.createElement('div');
300
320
  rubber.style.cssText = 'position:fixed;display:none;pointer-events:none;z-index:58;border:1px solid var(--brand,#3b82f6);background:rgba(59,130,246,.12)';
@@ -1833,6 +1853,7 @@ function setInsertMode(on, pending) {
1833
1853
  if (insertMode) { if (api && api.disarmTransform) api.disarmTransform(); if (api && api.disarmAdd) api.disarmAdd(); setClipMode(null); disarmFrame3d(); }
1834
1854
  if (canvasEl) canvasEl.style.cursor = insertMode ? 'crosshair' : 'default';
1835
1855
  if (api && api.onInsertModeChange) api.onInsertModeChange(insertMode);
1856
+ updateStatusChip();
1836
1857
  }
1837
1858
  function insertModeOn() { return insertMode; }
1838
1859
 
@@ -1861,6 +1882,7 @@ function setBasePickMode(colId) {
1861
1882
  if (canvasEl) canvasEl.style.cursor = basePickCol ? 'crosshair' : 'default';
1862
1883
  if (!basePickCol) { if (marker) marker.visible = false; if (readout) readout.style.display = 'none'; }
1863
1884
  if (api && api.onBasePickModeChange) api.onBasePickModeChange(basePickModeOn());
1885
+ updateStatusChip();
1864
1886
  }
1865
1887
  function basePickModeOn() { return !!basePickCol; }
1866
1888
  // A point along the target column's VERTICAL axis at the cursor, elevation snapped to the level datums.
@@ -3065,6 +3087,7 @@ function toggleDimTool() {
3065
3087
  if (!dimMode3d) { dimDraft3d = null; dimCandidates3d = null; dimPreviewLine.visible = false; marker.visible = false; readout.style.display = 'none'; canvasEl.style.cursor = 'default'; setSnapOnly3d(null); } // disarming ends the operation → the snap override reverts to all snaps
3066
3088
  else { if (clipMode) setClipMode(null); if (wpMode) armWorkPlanePick(wpMode); if (api && api.disarmTransform) api.disarmTransform(); if (api && api.disarmAdd) api.disarmAdd(); drClear3d(); disarmFrame3d(); controls.enabled = true; canvasEl.style.cursor = 'crosshair'; } // arming the dim tool disarms the clip pick, a set-plane pick, Move/Copy, Add-member AND the local frame (all share the left-click + Esc)
3067
3089
  reflectDimBar();
3090
+ updateStatusChip();
3068
3091
  return dimMode3d;
3069
3092
  }
3070
3093
  // Arm/disarm the grid panel's "Add single line" pick for the 3D view. The early-out keeps re-arming a no-op:
@@ -4182,7 +4205,7 @@ function frameInfo() {
4182
4205
  }
4183
4206
  return { mode: 'global' };
4184
4207
  }
4185
- function fireFrameChange() { invalidatePointEntry('drift'); if (!(pending && pending.frameDrag)) { tfCandidates = null; dimCandidates3d = null; } renderWorkPlane(); reflectDimAxisBar(); } // re-draws the gizmo + reference plane + fires the Axes chip; relabels the dim-axis bar (X′/Y′/Elev follows the frame); invalidates the typed HUD (drift) + the snap caches so the UCS-origin snap follows the frame — but NOT during a live origin drag (the drag's own snap cache, which excludes the origin, stays efficient)
4208
+ function fireFrameChange() { invalidatePointEntry('drift'); if (!(pending && pending.frameDrag)) { tfCandidates = null; dimCandidates3d = null; } renderWorkPlane(); reflectDimAxisBar(); updateStatusChip(); } // re-draws the gizmo + reference plane + fires the Axes chip; relabels the dim-axis bar (X′/Y′/Elev follows the frame); invalidates the typed HUD (drift) + the snap caches so the UCS-origin snap follows the frame — but NOT during a live origin drag (the drag's own snap cache, which excludes the origin, stays efficient)
4186
4209
  // Set a HORIZONTAL frame at origin (numeric entry + gizmo materialize). origin defaults its Z to the active level.
4187
4210
  function setFrame3d(originMm, angleDeg) {
4188
4211
  const z = (originMm && originMm.length > 2) ? originMm[2] : frameZ();
@@ -4337,7 +4360,7 @@ function framePicking() { return framePickPts !== null; }
4337
4360
  function framePickStep() { return framePickPts ? framePickPts.length : null; } // 0=origin · 1=X · 2=Y | null when not picking
4338
4361
  function cancelFramePick() { framePickPts = null; disposeFramePreview(); if (marker) marker.visible = false; if (readout) readout.style.display = 'none'; }
4339
4362
  function disposeFramePreview() { if (!framePreview) return; if (overlayScene) overlayScene.remove(framePreview); framePreview.traverse((o) => { if (o.geometry) o.geometry.dispose(); if (o.material) o.material.dispose(); }); framePreview = null; }
4340
- function fireFramePickChange() { if (api && api.onFrame3dChange) api.onFrame3dChange(frameInfo()); } // the panel hint follows the pick step; frame3d is unchanged so the chip/gizmo stay put
4363
+ function fireFramePickChange() { if (api && api.onFrame3dChange) api.onFrame3dChange(frameInfo()); updateStatusChip(); } // the panel hint and canvas guidance follow the pick step; frame3d is unchanged so the chip/gizmo stay put
4341
4364
  function framePickClick(e) {
4342
4365
  const r = dimPointAt(e); if (!r) return; // a valid snapped/plane point
4343
4366
  if (framePickPts.length === 1 && Math.hypot(r.p[0] - framePickPts[0][0], r.p[1] - framePickPts[0][1], r.p[2] - framePickPts[0][2]) < 5) { // X point == origin → there's no X axis; reject HERE with an accurate message (else every later Y pick fails on a≈b)
@@ -4434,15 +4457,15 @@ function renderWorkPlane() {
4434
4457
  function reflectWpBar() { const b = document.getElementById('m3dWp'); if (b) { b.classList.toggle('on', !!wpMode || !!workPlane);
4435
4458
  const kind = workPlane && workPlane.kind ? { face: 'Face', p3: '3pt', xy: 'XY', xz: 'XZ', yz: 'YZ' }[workPlane.kind] || '' : '';
4436
4459
  b.textContent = wpMode ? '◇ Plane ✕' : (kind ? '◇ Plane: ' + kind + ' ▾' : '◇ Plane ▾'); } reflectDimAxisBar(); } // the label reads the active plane without opening the menu (ux review); relabel the dim-axis bar (a set/cleared plane flips X/Y between World and local)
4437
- function armWorkPlanePick(mode) { if (wpMode === mode) { wpMode = null; wpDraft = null; } else { wpMode = mode; wpDraft = null; dropGridLinePick3d(); dropRefMeasure3d(); if (dimMode3d) toggleDimTool(); if (api && api.disarmTransform) api.disarmTransform(); if (api && api.disarmAdd) api.disarmAdd(); cmClear3d(); drClear3d(); disarmFrame3d(); } marker.visible = false; canvasEl.style.cursor = wpMode ? 'crosshair' : 'default'; reflectWpBar(); } // a set-plane pick shares the left-click — disarm Move/Copy + Add + the local frame (their onDown routes run first)
4460
+ function armWorkPlanePick(mode) { if (wpMode === mode) { wpMode = null; wpDraft = null; } else { wpMode = mode; wpDraft = null; dropGridLinePick3d(); dropRefMeasure3d(); if (dimMode3d) toggleDimTool(); if (api && api.disarmTransform) api.disarmTransform(); if (api && api.disarmAdd) api.disarmAdd(); cmClear3d(); drClear3d(); disarmFrame3d(); } marker.visible = false; canvasEl.style.cursor = wpMode ? 'crosshair' : 'default'; reflectWpBar(); updateStatusChip(); } // a set-plane pick shares the left-click — disarm Move/Copy + Add + the local frame (their onDown routes run first)
4438
4461
  function setWorkPlanePrincipal(kind, offsetMm) {
4439
4462
  const off = offsetMm || 0;
4440
4463
  const def = { xy: { normal: [0, 0, 1], xAxis: [1, 0, 0] }, xz: { normal: [0, 1, 0], xAxis: [1, 0, 0] }, yz: { normal: [1, 0, 0], xAxis: [0, 1, 0] } }[kind];
4441
4464
  if (!def) return;
4442
4465
  workPlane = { origin: def.normal.map((c) => c * off), normal: def.normal, xAxis: def.xAxis, kind };
4443
- wpMode = null; wpDraft = null; invalidatePointEntry('drift'); renderWorkPlane(); reflectWpBar();
4466
+ wpMode = null; wpDraft = null; invalidatePointEntry('drift'); renderWorkPlane(); reflectWpBar(); updateStatusChip();
4444
4467
  }
4445
- function clearWorkPlane() { workPlane = null; wpMode = null; wpDraft = null; invalidatePointEntry('drift'); renderWorkPlane(); reflectWpBar(); }
4468
+ function clearWorkPlane() { workPlane = null; wpMode = null; wpDraft = null; invalidatePointEntry('drift'); renderWorkPlane(); reflectWpBar(); updateStatusChip(); }
4446
4469
  function toggleWorkPlaneVisible(on) { wpVisible = on === undefined ? !wpVisible : !!on; try { localStorage.setItem('steel:wpVisible:v1', wpVisible ? '1' : '0'); } catch { /* storage can be unavailable; keep the session preference */ } renderWorkPlane(); }
4447
4470
  function workPlaneInfo() { return { set: !!workPlane, mode: wpMode, visible: wpVisible, plane: workPlane ? { origin: [...workPlane.origin], normal: [...workPlane.normal], xAxis: [...workPlane.xAxis] } : null }; }
4448
4471
  // face pick: the clip tool's raycast, minus the camera-side flip — the plane lands ON the face.
@@ -4903,7 +4926,7 @@ function onDown(e) {
4903
4926
  if (readout) { readout.style.display = 'none'; if (readout._coord) readout._coord.style.display = 'none'; } // UCS Stage 2: hide the whole readout chip so a drag never shows a lingering coordinate (or an empty coord-only shell); the drag/next hover re-shows it
4904
4927
  if (e.button === 2) { rightDownXY = [e.clientX, e.clientY]; rightMoved = false; } // arm the click-vs-drag test for the snap menu
4905
4928
  if (e.button !== 0) return; // RIGHT/MIDDLE → OrbitControls (orbit/pan)
4906
- if (wpMode === 'face') { e.stopPropagation(); const r = wpFacePick(e.clientX, e.clientY); if (r) { workPlane = r; wpMode = null; invalidatePointEntry('drift'); canvasEl.style.cursor = 'default'; renderWorkPlane(); reflectWpBar(); if (api && api.toast) api.toast('Working plane set on the face'); } return; } // armed: one face click sets the plane
4929
+ if (wpMode === 'face') { e.stopPropagation(); const r = wpFacePick(e.clientX, e.clientY); if (r) { workPlane = r; wpMode = null; invalidatePointEntry('drift'); canvasEl.style.cursor = 'default'; renderWorkPlane(); reflectWpBar(); updateStatusChip(); if (api && api.toast) api.toast('Working plane set on the face'); } return; } // armed: one face click sets the plane
4907
4930
  if (wpMode === '3pt') { e.stopPropagation();
4908
4931
  const r = dimPointAt(e); if (!r) return;
4909
4932
  wpDraft = wpDraft || []; wpDraft.push(r.p);
@@ -4913,7 +4936,7 @@ function onDown(e) {
4913
4936
  if (wp) { wp.kind = 'p3'; workPlane = wp; invalidatePointEntry('drift'); renderWorkPlane(); if (api && api.toast) api.toast('Working plane set from 3 points'); }
4914
4937
  else if (api && api.toast) api.toast('Points are collinear — plane not set');
4915
4938
  reflectWpBar(); }
4916
- return; }
4939
+ updateStatusChip(); return; }
4917
4940
  if (addActive()) { e.stopPropagation(); controls.enabled = true; drClick(e); return; } // Add-member armed (editor state) → two plane picks draw a member
4918
4941
  if (cmActive()) { if (tfClick(e)) { e.stopPropagation(); controls.enabled = true; return; } } // Move/Copy armed (editor state) → picks land on the working plane; an empty-selection click falls through to select
4919
4942
  if (basePickCol) { e.stopPropagation(); const r = basePickPoint(e.clientX, e.clientY); if (r) { if (api && api.onBasePick) api.onBasePick(r); setBasePickMode(null); } return; } // Mode B: commit + disarm only on a valid on-column pick; an off-column click is ignored (stays armed) — Esc cancels
@@ -4986,7 +5009,7 @@ function onDown(e) {
4986
5009
  if (g.valueMm > 1 && api && api.onAddDim3d) api.onAddDim3d({ id: api.newDim3dId(), a, b, axis, ...(axisDir ? { axisDir } : {}) });
4987
5010
  else if (g.valueMm <= 1 && axis !== 'free') { dimDraft3d = { a }; if (api && api.toast) api.toast('No length along the locked axis — move the second point or switch axis'); } // any AXIS-LOCKED projection (world X/Y/Z/Elev or local X′/Y′) collapsed to ~0 despite a real 2nd pick — e.g. two points at the same level with Z / Alt-vertical → keep the first anchor + explain, don't silently drop the pick. A coincident 'free' double-click stays a silent no-op.
4988
5011
  }
4989
- return;
5012
+ updateStatusChip(); return;
4990
5013
  }
4991
5014
  downXY = [e.clientX, e.clientY];
4992
5015
  let id = null; try { id = pickAt(e.clientX, e.clientY); } catch { id = null; }
@@ -5642,6 +5665,16 @@ function updateStatusChip() {
5642
5665
  if (!hoverChip || !canvasEl) return;
5643
5666
  const rect = canvasEl.getBoundingClientRect();
5644
5667
  let txt = '';
5668
+ // Idle hover/help may be collapsed. Instructions for an armed tool or an in-flight gesture are
5669
+ // operationally critical, so they stay visible until that action ends, then return to the saved idle state.
5670
+ const toolGuidance = canvasToolGuidanceState({
5671
+ teklaDragActive: !!(teklaDrag && teklaDrag.active), workPlaneMode: wpMode,
5672
+ addActive: !!addActive(), transformActive: !!cmActive(), referenceMeasureActive: !!refMeasure3d,
5673
+ gridLinePickActive: !!gridLinePick3d, clipMode, dimensionMode: dimMode3d,
5674
+ dimensionHasStart: !!dimDraft3d, insertMode, insertName: insertPending && insertPending.name,
5675
+ basePickColumn: basePickCol, frameMode, framePickStep: framePickStep(), geometryMode: geoMode(),
5676
+ });
5677
+ const forceOpen = toolGuidance.forceOpen;
5645
5678
  const selectionStatus=objectSelectionStatus(selIds.size,selectedGridIds.size),showId=hoverId||(!selectionStatus&&selIds.size===1?[...selIds][0]:null);
5646
5679
  // The badge follows the cursor and so clips away at the window edge — from there this chip is the
5647
5680
  // only thing still telling the user what releasing will do.
@@ -5669,6 +5702,7 @@ function updateStatusChip() {
5669
5702
  else if (gridLinePick3d) txt = gridLinePick3d.a ? 'Click the second point of the grid line · Esc to cancel' : 'Click the first point of the grid line · Esc to cancel'; // must sit above the showId/default branches, else an armed two-click tool shows the hovered member or the drag-move hint the user can't act on
5670
5703
  else if (clipMode === 'plane') txt = 'Click a face to set a clip plane · Esc to cancel';
5671
5704
  else if (clipMode === 'box') txt = !clipBoxDraft ? 'Click the first floor corner of the clip box · Esc to cancel' : !clipBoxDraft.b ? 'Click the opposite floor corner · Esc to cancel' : 'Move up/down to set the height, then click · Esc to step back';
5705
+ else if (toolGuidance.text) txt = toolGuidance.text;
5672
5706
  else if (showId) { const m = memberById(showId); txt = m ? `${m.id} · ${m.profile || '—'}` : ''; }
5673
5707
  else if (selectionStatus) txt = selectionStatus;
5674
5708
  else if (isIsolated()) txt = `Isolated: ${(isolatedIds ? isolatedIds.size : 0) + (isolatedGridIds ? isolatedGridIds.size : 0)} · Show all to restore`;
@@ -5680,9 +5714,19 @@ function updateStatusChip() {
5680
5714
  else { const canDrag = api && api.dragMoveEnabled && api.dragMoveEnabled();
5681
5715
  txt = (canDrag ? 'Drag to move · Ctrl+drag to copy · ' : 'Click to select · ') + 'ends to stretch · Alt+drag elevation · right-drag orbit · dbl-click to zoom in'; }
5682
5716
  hoverChip.textContent = txt;
5683
- hoverChip.style.left = (rect.left + rect.width / 2) + 'px'; hoverChip.style.transform = 'translateX(-50%)';
5684
- hoverChip.style.top = (rect.bottom - 30) + 'px';
5685
- hoverChip.style.display = canvasEl.style.display === 'none' ? 'none' : 'block';
5717
+ if (hoverChipShell) {
5718
+ const open = forceOpen || !hoverChipIdleCollapsed, shown = canvasEl.style.display !== 'none';
5719
+ hoverChipShell.classList.toggle('collapsed', !open); hoverChipShell.style.display = shown ? 'flex' : 'none';
5720
+ hoverChip.dataset.tip = txt;
5721
+ hoverChipToggle.classList.toggle('open', open); hoverChipToggle.setAttribute('aria-expanded', String(open));
5722
+ hoverChipToggle.setAttribute('aria-disabled', String(forceOpen));
5723
+ const label = forceOpen ? 'Tool guidance stays visible until the current action ends' : open ? 'Collapse canvas guidance' : 'Expand canvas guidance';
5724
+ hoverChipToggle.setAttribute('aria-label', label); hoverChipToggle.dataset.tip = label;
5725
+ } else {
5726
+ hoverChip.style.left = (rect.left + rect.width / 2) + 'px'; hoverChip.style.transform = 'translateX(-50%)';
5727
+ hoverChip.style.top = (rect.bottom - 30) + 'px';
5728
+ hoverChip.style.display = canvasEl.style.display === 'none' ? 'none' : 'block';
5729
+ }
5686
5730
  }
5687
5731
 
5688
5732
  function show() { if (controls) controls.enabled = true; if (canvasEl) { canvasEl.style.display = 'block'; resize(); } if (!rafId) loop(); updateStatusChip(); refreshDims(); refreshOverlayDims(); renderFrameGizmo(); } // resume the render loop (reset orbit in case a gesture was stranded by a mid-drag hide)
@@ -5703,7 +5747,7 @@ function hide() {
5703
5747
  if (propLabelHost) propLabelHost.style.display = 'none'; // property labels ride the same loop — hide synchronously so none strand over the 2D UI
5704
5748
  clearCopyGhost(); // drop a stale Ctrl+drag copy ghost on the way out
5705
5749
  endTeklaDrag(); // and a live drag-out to Tekla — a stranded one would leave its badge on screen and swallow every later pointer move
5706
- if (canvasEl) canvasEl.style.display = 'none'; if (hoverChip) hoverChip.style.display = 'none'; if (rafId) { cancelAnimationFrame(rafId); rafId = null; }
5750
+ if (canvasEl) canvasEl.style.display = 'none'; if (hoverChipShell) hoverChipShell.style.display = 'none'; else if (hoverChip) hoverChip.style.display = 'none'; if (rafId) { cancelAnimationFrame(rafId); rafId = null; }
5707
5751
  }
5708
5752
  function isReady() { return built; }
5709
5753
 
@@ -5726,7 +5770,8 @@ function dispose() {
5726
5770
  window.removeEventListener('keydown', onKey);
5727
5771
  window.removeEventListener('keydown', onModifierChange);
5728
5772
  window.removeEventListener('keyup', onModifierChange);
5729
- for (const ovl of [readout, hoverChip, rubber, dimLabelHost]) if (ovl && ovl.parentNode) ovl.parentNode.removeChild(ovl);
5773
+ for (const ovl of [readout, hoverChipShell || hoverChip, rubber, dimLabelHost]) if (ovl && ovl.parentNode) ovl.parentNode.removeChild(ovl);
5774
+ hoverChip = hoverChipShell = hoverChipToggle = null;
5730
5775
  dimLabelHost = null; dimLabelPool.length = 0;
5731
5776
  if (memberLabelHost && memberLabelHost.parentNode) memberLabelHost.parentNode.removeChild(memberLabelHost);
5732
5777
  memberLabelHost = null; memberLabelPool.length = 0; labelsOnFlag = false; insertMode = false; insertPending = null;
@@ -5898,6 +5943,7 @@ window.Steel3DView = {
5898
5943
  setProjection, projection, setDisplayMode, mode: () => displayMode, frameAll, frameSelection, applyView,
5899
5944
  setRefLine, refLine: () => refLineOn,
5900
5945
  setInsertMode, insertMode: insertModeOn, // arm/query the detail-placement pick (Slice 4)
5946
+ refreshStatus: updateStatusChip, // editor-owned armed modes (Extend/Trim, Split) refresh the disclosure immediately
5901
5947
  setBasePickMode, basePickMode: basePickModeOn, // arm/query the Mode B column-base pick (level-snapped elevation)
5902
5948
  selectWholeConn, clearConnSel, ascendConn, connContext, connEnvelopeOn: () => !!connEnvelope, // Connection Components (Slice A): whole-select / drill / ascend + test probes
5903
5949
  // Reference models (#278) — an editor-only layer. `setReferences` takes the geometry the editor
@@ -0,0 +1,39 @@
1
+ /**
2
+ * Pure state-to-guidance seam for the steel canvas disclosure.
3
+ *
4
+ * Keeping the force-open decision here makes every armed left-click tool testable without a Three.js
5
+ * scene. `text` is supplied only for tools whose guidance is wholly owned by the 3D renderer; the
6
+ * older move/add/clip/reference branches still compose their richer, live text in steel-3d-view.js.
7
+ */
8
+ export function canvasToolGuidanceState(state = {}) {
9
+ const forceOpen = !!(
10
+ state.teklaDragActive || state.workPlaneMode || state.addActive || state.transformActive ||
11
+ state.referenceMeasureActive || state.gridLinePickActive || state.clipMode || state.dimensionMode ||
12
+ state.insertMode || state.basePickColumn || state.frameMode || state.framePickStep != null || state.geometryMode
13
+ );
14
+
15
+ let text = null;
16
+ if (state.dimensionMode) {
17
+ text = state.dimensionHasStart
18
+ ? 'Click the second dimension point · Esc to step back'
19
+ : 'Click the first dimension point · Esc to cancel';
20
+ } else if (state.insertMode) {
21
+ text = `Click to place ${state.insertName || 'the detail'} on a member face or the working plane · Esc to cancel`;
22
+ } else if (state.basePickColumn) {
23
+ text = `Click a framing level to trim ${state.basePickColumn}’s base · Esc to cancel`;
24
+ } else if (state.framePickStep != null) {
25
+ text = [
26
+ 'Click the local-frame origin · Esc to cancel',
27
+ 'Click the local-X direction point · Esc to cancel',
28
+ 'Click a point on the local frame’s Y side · Esc to cancel',
29
+ ][state.framePickStep] || 'Pick the next local-frame point · Esc to cancel';
30
+ } else if (state.frameMode) {
31
+ text = 'Drag the local-frame origin or rotation ring to refine the axes · Esc to finish';
32
+ } else if (state.geometryMode === 'el') {
33
+ text = 'Click a target member, segment, or grid line to extend/trim the selection · Esc to cancel';
34
+ } else if (state.geometryMode === 'split') {
35
+ text = 'Click a point on the selected member to split it · Esc to cancel';
36
+ }
37
+
38
+ return { forceOpen, text };
39
+ }
@@ -64,12 +64,17 @@
64
64
  #panelResizer::before{content:"";position:absolute;inset:0 3px;border-radius:2px;transition:background-color .12s}
65
65
  #panelResizer:hover::before,#panelResizer.drag::before{background:var(--brand)}
66
66
  #panelResizer:focus-visible{outline:none} #panelResizer:focus-visible::before{background:var(--brand)}
67
- #panelToggle{position:absolute;right:calc(var(--panelw,240px) - 14px);top:50%;transform:translateY(-50%);z-index:12;width:28px;height:42px;padding:0;display:flex;align-items:center;justify-content:center;background:var(--panel);border-color:var(--line);box-shadow:0 4px 14px rgba(0,0,0,.45);font-size:18px;line-height:1}
67
+ #panelToggle{position:absolute;right:calc(var(--panelw,240px) - 14px);top:50%;transform:translateY(-50%);z-index:12;width:28px;height:42px;padding:0;display:flex;align-items:center;justify-content:center;background:var(--panel);border-color:var(--line);box-shadow:0 4px 14px rgba(0,0,0,.45);line-height:1}
68
+ #panelToggle svg,#canvasStatusToggle svg,#m3dLegendCollapse svg,#m3dLegendLauncher svg{width:16px;height:16px;display:block;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;transition:transform .15s ease}
68
69
  #panelToggle:hover{border-color:var(--brand)}
69
70
  #panelToggle::before,#m3dLegendCollapse::before,#m3dLegendLauncher::before{content:"";position:absolute;inset:-1px -8px}
70
71
  #panelToggle:focus-visible,#m3dLegendCollapse:focus-visible,#m3dLegendLauncher:focus-visible{outline:2px solid var(--brand);outline-offset:2px}
71
72
  body.panel-collapsed #panel,body.panel-collapsed #panelResizer{display:none}
72
- body.panel-collapsed #panelToggle{right:4px}
73
+ #panelStub{display:none;width:48px;flex:none;flex-direction:column;align-items:center;justify-content:flex-start;padding-top:14px;background:var(--panel);border-left:1px solid var(--line);overflow:hidden}
74
+ #panelStub .vertical-label{writing-mode:vertical-rl;transform:rotate(180deg);font-size:10px;color:var(--mut);text-transform:uppercase;letter-spacing:.2em;user-select:none}
75
+ body.panel-collapsed #panelStub{display:flex}
76
+ body.panel-collapsed #panelToggle{right:16px}
77
+ body.panel-collapsed #panelToggle svg{transform:rotate(180deg)}
73
78
  aside h3{margin:0 0 8px;font-size:12px;color:var(--mut);text-transform:uppercase;letter-spacing:.05em}
74
79
  select,input{background:#0f172a;color:var(--text);border:1px solid #475569;border-radius:6px;padding:6px;width:100%;font:13px system-ui}
75
80
  /* The two control classes the generic rule above actively BREAKS, themed globally so anything added
@@ -389,8 +394,23 @@
389
394
  #moreMenu .msnap-sub input:focus{outline:none;border-color:var(--brand)}
390
395
  #moreMenu .msnap-sub .oghint{flex-basis:100%;color:var(--mut);font-size:11px;line-height:1.4;margin-top:2px} /* nudge shown only when the grid is on but no local frame is set yet */
391
396
  /* Pointer-behaviour bars, bottom-right of the canvas (both views): [ Select filter ] [ Snap ]. Both reuse the brand-fill "on" toolbar language. */
392
- #ptrBars{position:absolute;right:12px;bottom:12px;z-index:8;display:flex;align-items:flex-end;gap:8px}
393
- #ptrBars.s3d{right:104px} /* in 3D, sit just LEFT of the bottom-right world-axis triad (#m3dAxes, right 15 + 78 wide) — same bottom edge (the ViewCube is top-right) */
397
+ /* One bottom dock owns both sides of the canvas chrome. The hint may shrink; Select/Snap never do, so
398
+ the two surfaces cannot overlap at narrower widths. In 3D the whole dock stops before the world-axis
399
+ triad, preserving the old 104px clearance without independently-positioned bars. */
400
+ #bottomDock{position:absolute;left:12px;right:12px;bottom:12px;z-index:8;display:flex;align-items:flex-end;gap:8px;min-width:0;pointer-events:none}
401
+ body.v3d #bottomDock{right:104px}
402
+ #bottomDockLeft{display:flex;align-items:center;gap:8px;flex:1;min-width:0;pointer-events:none}
403
+ #ptrBars{position:static;z-index:auto;display:flex;align-items:flex-end;gap:8px;flex:none;pointer-events:auto}
404
+ #canvasStatus{display:none;align-items:center;gap:0;flex:1;min-width:0;pointer-events:auto}
405
+ #canvasStatus.collapsed{flex:0 0 auto}
406
+ #canvasStatusToggle{width:28px;height:28px;flex:none;padding:0;display:flex;align-items:center;justify-content:center;background:var(--panel);border:1px solid var(--line);border-radius:6px 0 0 6px;color:var(--text);box-shadow:0 2px 8px rgba(0,0,0,.45)}
407
+ #canvasStatus.collapsed #canvasStatusToggle{border-radius:6px}
408
+ #canvasStatusToggle.open svg{transform:rotate(180deg)}
409
+ #canvasStatusToggle:hover{background:#475569;border-color:var(--brand)}
410
+ #canvasStatusToggle:focus-visible{outline:2px solid var(--brand);outline-offset:2px}
411
+ #canvasStatusToggle[aria-disabled=true]{cursor:default;opacity:.65}
412
+ #canvasStatusText{display:flex;align-items:center;height:28px;min-width:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;background:var(--panel);color:var(--mut);border:1px solid var(--line);border-left:0;border-radius:0 6px 6px 0;padding:0 12px;font:12px system-ui;box-shadow:0 2px 8px rgba(0,0,0,.45)}
413
+ #canvasStatus.collapsed #canvasStatusText{display:none}
394
414
  #snapBar,#selBar{display:flex;align-items:center;gap:2px;padding:3px;background:var(--panel);border:1px solid var(--line);border-radius:8px;box-shadow:0 4px 14px rgba(0,0,0,.45)}
395
415
  #snapBar .lbl,#selBar .lbl{font-size:10px;text-transform:uppercase;letter-spacing:.07em;color:var(--mut);padding:0 4px;user-select:none;align-self:center}
396
416
  /* Select bar: brand-blue "on"; neutral idle (cyan stays reserved for snapping). A flyout class shows partial (blue outline + dot) when only some of its types are on. */
@@ -917,8 +937,9 @@ text.mlentx{fill:#e2e8f0;text-anchor:middle;dominant-baseline:central;font-famil
917
937
  lays out [tab strip][active body]; each tab body is its own scroll container (themed by the global * rule). */
918
938
  #m3dLegend{position:absolute;left:12px;bottom:64px;display:none;flex-direction:column;max-height:min(52vh,calc(100% - var(--m3d-legend-clearance,184px)));min-width:210px;max-width:min(340px,92vw);background:var(--panel);border:1px solid var(--line);border-radius:8px;padding:0;z-index:6;box-shadow:0 4px 14px rgba(0,0,0,.45);font-size:12px} /* the measured clearance tracks however many rows the narrow toolbar wraps onto */
919
939
  #m3dLegendCollapse{position:absolute;right:-14px;top:50%;transform:translateY(-50%);z-index:12;width:28px;height:42px;padding:0;display:flex;align-items:center;justify-content:center;border:1px solid var(--line);border-radius:6px;background:var(--panel);color:var(--text);box-shadow:0 4px 14px rgba(0,0,0,.45);font-size:18px;line-height:1}
940
+ #m3dLegendCollapse svg{transform:rotate(180deg)}
920
941
  #m3dLegendCollapse:hover{color:var(--text);background:#475569;border-color:var(--brand)}
921
- #m3dLegendLauncher{position:absolute;left:4px;bottom:12px;z-index:12;width:28px;height:42px;display:none;align-items:center;justify-content:center;padding:0;background:var(--panel);border:1px solid var(--line);border-radius:6px;box-shadow:0 4px 14px rgba(0,0,0,.45);color:var(--text);font-size:18px;line-height:1}
942
+ #m3dLegendLauncher{position:relative;z-index:12;width:28px;height:42px;flex:none;display:none;align-items:center;justify-content:center;padding:0;background:var(--panel);border:1px solid var(--line);border-radius:6px;box-shadow:0 4px 14px rgba(0,0,0,.45);color:var(--text);font-size:18px;line-height:1;pointer-events:auto}
922
943
  #m3dLegendLauncher:hover{color:var(--text);background:#475569;border-color:var(--brand)}
923
944
  /* Tab strip — the .seg-group segmented look, full-width across the panel top; sticky so it never scrolls away. */
924
945
  #m3dPanelHeader{display:flex;flex:none;align-items:stretch;gap:6px;border-bottom:1px solid var(--line);padding:7px 8px 6px}
@@ -1525,14 +1546,13 @@ text.mlentx{fill:#e2e8f0;text-anchor:middle;dominant-baseline:central;font-famil
1525
1546
  a tab that can never hold anything is the same dead chrome the header stat spans are hidden for. -->
1526
1547
  <button class=m3dtab role=tab data-tab=refs aria-selected=false style="display:none" data-tip="Reference models — an architect's or engineer's model overlaid to build against. Never part of your steel.">References</button>
1527
1548
  </div>
1528
- <button type=button id=m3dLegendCollapse aria-label="Collapse 3D panel" aria-controls=m3dLegend aria-expanded=true data-tip="Collapse Objects, Views, and Favourites to the bottom-left corner">‹</button>
1549
+ <button type=button id=m3dLegendCollapse aria-label="Collapse 3D panel" aria-controls=m3dLegend aria-expanded=true data-tip="Collapse Objects, Views, and Favourites to the bottom-left corner"><svg viewBox="0 0 16 16" aria-hidden=true><path d="m6 3 5 5-5 5"/></svg></button>
1529
1550
  </div>
1530
1551
  <div id=m3dLegendBody class="m3dbody on" role=tabpanel aria-label=Objects></div>
1531
1552
  <div id=m3dViewsBody class=m3dbody role=tabpanel aria-label=Views></div>
1532
1553
  <div id=m3dFavBody class=m3dbody role=tabpanel aria-label=Favourites></div>
1533
1554
  <div id=m3dRefsBody class=m3dbody role=tabpanel aria-label="Reference models"></div>
1534
1555
  </div>
1535
- <button type=button id=m3dLegendLauncher aria-label="Expand 3D panel" aria-controls=m3dLegend aria-expanded=false data-tip="Expand Objects, Views, and Favourites">›</button>
1536
1556
  <div id=m3dCube data-tip="Click a face for that view · right-drag to orbit"></div>
1537
1557
  <div id=m3dAxes></div>
1538
1558
  <div id=zoombar>
@@ -1542,8 +1562,14 @@ text.mlentx{fill:#e2e8f0;text-anchor:middle;dominant-baseline:central;font-famil
1542
1562
  <span id=zPct>100%</span>
1543
1563
  <button id=zFit data-tip="Zoom to fit (Home)">Fit</button>
1544
1564
  </div>
1545
- <!-- Pointer-behaviour bars (bottom-right): Select (what may be picked) + Snap (what you snap to). -->
1546
- <div id=ptrBars>
1565
+ <!-- One bottom dock: the left disclosure shrinks before the right pointer controls, so they cannot collide. -->
1566
+ <div id=bottomDock>
1567
+ <!-- A direct, non-shrinking dock item: if the canvas narrows, this 28px remains allocated instead
1568
+ of overflowing a zero-width status flex child into Select/Snap. -->
1569
+ <button type=button id=m3dLegendLauncher aria-label="Expand 3D panel" aria-controls=m3dLegend aria-expanded=false data-tip="Expand Objects, Views, and Favourites"><svg viewBox="0 0 16 16" aria-hidden=true><path d="m6 3 5 5-5 5"/></svg></button>
1570
+ <div id=bottomDockLeft></div>
1571
+ <!-- Pointer-behaviour bars (bottom-right): Select (what may be picked) + Snap (what you snap to). -->
1572
+ <div id=ptrBars>
1547
1573
  <!-- Selection filter (Tekla "select switches"): a class off can't be picked by click / area-select / Ctrl+A.
1548
1574
  Members + Connections open a type flyout (All on top). Default: everything on, so nothing is filtered. -->
1549
1575
  <div id=selBar role=group aria-label="Selection filter">
@@ -1567,13 +1593,15 @@ text.mlentx{fill:#e2e8f0;text-anchor:middle;dominant-baseline:central;font-famil
1567
1593
  <button data-snap=ext data-tip="Extension snap">┈</button>
1568
1594
  <button data-snap3d aria-label="3D snapping" data-tip="3D snapping — on: snap freely to any point in 3D, at any elevation; off: snap only on the current working level.">3D</button>
1569
1595
  </div>
1596
+ </div>
1570
1597
  </div>
1571
1598
  <div id=selFly role=menu aria-label="Selectable types"></div>
1572
1599
  </div>
1573
1600
  <div id=panelResizer role=separator aria-orientation=vertical aria-label="Resize properties panel" tabindex=0 data-tip="Drag to resize · double-click to reset"></div>
1574
1601
  <span id=connectionTruthStatus class=sr-only role=status aria-live=polite aria-atomic=true></span>
1575
1602
  <aside id=panel></aside>
1576
- <button type=button id=panelToggle aria-label="Collapse properties panel" aria-controls=panel aria-expanded=true data-tip="Collapse properties panel">›</button>
1603
+ <div id=panelStub aria-hidden=true><span class=vertical-label>Inspector</span></div>
1604
+ <button type=button id=panelToggle aria-label="Collapse Inspector" aria-controls=panel aria-expanded=true data-tip="Collapse Inspector"><svg viewBox="0 0 16 16" aria-hidden=true><path d="m6 3 5 5-5 5"/></svg></button>
1577
1605
  </main>
1578
1606
  <!-- (The conntypes / profiles / details <datalist>s that used to sit here are gone: every input that
1579
1607
  bound to them moved to the themed dark combobox below (COMBO_SRC / showCombo), which is what a
@@ -4789,7 +4817,7 @@ function renderGridPanel(p){
4789
4817
  document.getElementById('gridRemoveB').onclick=()=>{editGridTopology(()=>{ModelCmd.setPlanGrid(gridHost(),null);});};
4790
4818
  document.getElementById('gridDoneB').onclick=()=>{setGridMode(false);render();};
4791
4819
  }
4792
- function setGeo(){document.body.classList.toggle('geo',!!geoMode);document.body.classList.toggle('geoel',geoMode==='el');} // geoel = Extend/Trim armed; grid lines are a target ONLY then (not in Split), so their crosshair/highlight keys off geoel, not geo
4820
+ function setGeo(){document.body.classList.toggle('geo',!!geoMode);document.body.classList.toggle('geoel',geoMode==='el');if(view3d&&window.Steel3DView&&window.Steel3DView.refreshStatus)window.Steel3DView.refreshStatus();} // geoel = Extend/Trim armed; grid lines are a target ONLY then (not in Split), so their crosshair/highlight keys off geoel, not geo; 3D guidance follows the editor-owned mode immediately
4793
4821
  // --- repeat last command (AutoCAD/Tekla): when NO tool is active, Space/Enter re-invokes the last command ---
4794
4822
  let lastCmd=null;
4795
4823
  function setLastCmd(label,run){lastCmd={label,run};}
@@ -8025,7 +8053,7 @@ reflectOriginGrid();
8025
8053
  const b=document.getElementById('panelToggle');if(!b)return;
8026
8054
  const KEY='steel:propertiesPanelCollapsed:v1';
8027
8055
  let collapsed=false;try{collapsed=localStorage.getItem(KEY)==='1';}catch(_){}
8028
- const reflect=()=>{document.body.classList.toggle('panel-collapsed',collapsed);b.textContent=collapsed?'‹':'›';b.setAttribute('aria-expanded',String(!collapsed));const label=collapsed?'Open properties panel':'Collapse properties panel';b.setAttribute('aria-label',label);b.dataset.tip=label;};
8056
+ const reflect=()=>{document.body.classList.toggle('panel-collapsed',collapsed);b.setAttribute('aria-expanded',String(!collapsed));const label=collapsed?'Expand Inspector':'Collapse Inspector';b.setAttribute('aria-label',label);b.dataset.tip=label;};
8029
8057
  b.onclick=()=>{collapsed=!collapsed;try{localStorage.setItem(KEY,collapsed?'1':'0');}catch(_){}reflect();b.focus();};
8030
8058
  reflect();
8031
8059
  })();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@floless/app",
3
- "version": "0.128.1",
3
+ "version": "0.128.2",
4
4
  "type": "module",
5
5
  "description": "Thin localhost host for floless.app — serves web/ and shells the aware CLI. No engine, no LLM.",
6
6
  "bin": {