Skip to content

Lift arbitrary maxes from inspector dimension fields - #721

Merged
wass08 merged 1 commit into
mainfrom
chore/field-limit-sweep
Aug 26, 2026
Merged

Lift arbitrary maxes from inspector dimension fields#721
wass08 merged 1 commit into
mainfrom
chore/field-limit-sweep

Conversation

@wass08

@wass08 wass08 commented Aug 26, 2026

Copy link
Copy Markdown
Collaborator

Why

User feedback: wall length/height (and many other dimension fields) hard-cap at "typical" sizes (20m walls, 25m roofs, 4m fences). Our number controls are Figma-style scrubby inputs — the drag is a step-based delta, so min/max play no interaction role at all; they are pure clamps that silently swallow typed values. A max on a physical dimension blocks users while smoothing nothing.

What

  • Dimension fields → max: 1000 — a never-reached sanity ceiling that still catches a pasted/fat-fingered number before it degrades the spatial grid/shadows/bake. Covers wall (length/height/thickness incl. the panel's maxMeters double-clamp), ceiling, column, fence, shelf, chimney, roof-segment, stair-segment, dormer, lean-to (incl. its linear-resize drag-handle clamps), gutter/downspout, ridge/box/eyebrow/turbine vents, cupola, skylight, solar-panel, slab thickness, scan scale, door/window, and the meter fields of hvac-equipment/duct-terminal.
  • Static position windows removed — elevator/roof/roof-segment/stair/stair-segment X/Y/Z ±50, ridge-vent Y ±2, block's position ± 2, and the generic vec3 value ± 5 scrub-window clamps in parametric-field-control / multi-parametric-inspector (SliderControl defaults to ±Infinity).
  • Wrong mins fixed — wall/ceiling height min 1.5 → 0.1 (parapets, garden walls, knee walls).
  • Kept deliberately: dynamic host-derived bounds (door ≤ wall, sagitta ≤ chord, segment-face positions), counts, fractions/percentages, angles, rotation ±180, detail knobs, MEP inch trade sizes, cabinet run width (module-count perf guard), and the item envelope (studio/bake caps).
  • Convention documented in wiki/architecture/inspector-field-limits.md, indexed in the architecture README, and added to the review-architecture skill's on-demand list so new fields don't regress.

Verification

E2e smoke in private-editor (e2e/community/field-limits-smoke.spec.ts, lands with the companion PR): draws a wall and types Length 100ft (≈30.5m) and Height 90ft (≈27.4m) through the inspector — both commit un-clamped and render fine. Oversize wall-hosted openings remain safe via the existing dynamic guards (readHostWallCeiling, opening-cutout clamps).

🤖 Generated with Claude Code

https://claude.ai/code/session_01SrRkPvd6AogVAbt3PNeLAw


Note

Medium Risk
Broad inspector and parametric-schema changes allow much larger node dimensions; extreme values could stress rendering/spatial systems though dynamic host clamps and the 1000 m ceiling remain.

Overview
Removes “typical size” clamps on inspector dimension fields so typed values (e.g. 30 m walls) are no longer silently capped. Physical dimensions in parametrics.ts and kind panel.tsx files now use max: 1000 as a sanity ceiling; wall/ceiling height mins drop from 1.5 m to 0.1 m so short walls and knee ceilings are allowed.

Position controls no longer use static scrub windows: generic vec3 sliders in parametric-field-control / multi-parametric-inspector, and X/Y/Z sliders on block, elevator, roof, stair, ridge-vent, etc., omit min/max so SliderControl defaults to ±∞. Dynamic bounds (segment-face placement, door ≤ wall, ceiling maxHeight, detail knobs, counts, angles) are unchanged; lean-to resize-handle max values align with the same 1000 m convention.

Adds wiki/architecture/inspector-field-limits.md, indexes it in the architecture README, and wires it into the review-architecture skill so new fields don’t reintroduce arbitrary caps.

Reviewed by Cursor Bugbot for commit 1a99ae6. Bugbot is set up for automated code reviews on this repo. Configure here.

Scrubby number inputs use min/max only as clamps (the drag is delta-based),
so a static max on a physical dimension silently blocks typed values while
smoothing nothing. Dimension fields move to a 1000m sanity ceiling, static
position windows (X/Y/Z +/-50, value+/-5 vec3 scrub windows) unclamp
entirely, and wall/ceiling height min drops 1.5 -> 0.1 (parapets, garden
walls). Kept: dynamic host-derived bounds, counts, fractions, angles,
detail knobs, MEP trade sizes, cabinet run width (module-count guard), and
the item envelope (studio/bake caps).

Convention documented in wiki/architecture/inspector-field-limits.md and
wired into the review-architecture skill so new fields don't regress.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SrRkPvd6AogVAbt3PNeLAw

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using high effort and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 1a99ae6. Configure here.

{ key: 'width', kind: 'number', unit: 'm', min: 0.3, max: 1000, step: 0.05 },
{ key: 'depth', kind: 'number', unit: 'm', min: 0.1, max: 1000, step: 0.05 },
{ key: 'thickness', kind: 'number', unit: 'm', min: 0.01, max: 1000, step: 0.005 },
{ key: 'height', kind: 'number', unit: 'm', min: 0.05, max: 1000, step: 0.05 },

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shelf limits still silently clamped

High Severity

Raising shelf dimension max values to 1000 in parametrics no longer matches the Zod schema (width 3, depth 1, thickness 0.1, height 2.5). Inspector and MCP accept large typed values, then updateNode sanitization silently clamps them back, recreating the swallowed-input failure this PR set out to remove.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 1a99ae6. Configure here.

{ key: 'height', kind: 'number', unit: 'm', min: 0.4, max: 4, step: 0.05 },
{ key: 'thickness', kind: 'number', unit: 'm', min: 0.03, max: 0.5, step: 0.005 },
{ key: 'height', kind: 'number', unit: 'm', min: 0.4, max: 1000, step: 0.05 },
{ key: 'thickness', kind: 'number', unit: 'm', min: 0.03, max: 1000, step: 0.005 },

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fence length still hard-capped

Medium Severity

Fence length still uses max={50} in FenceLengthEditor while height, thickness, and post spacing were lifted to 1000. Length is the primary meter dimension for fences and remains a silent typed-value clamp, contrary to the sweep and the new inspector-field-limits convention.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 1a99ae6. Configure here.

@wass08
wass08 merged commit 46f5696 into main Aug 26, 2026
3 checks passed
@wass08
wass08 deleted the chore/field-limit-sweep branch August 26, 2026 14:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant