editor icon indicating copy to clipboard operation
editor copied to clipboard

Track imperial unit support for remaining measurement panels

Open MateoSaettone opened this issue 5 months ago • 1 comments

Summary

Some non-wall parametric panels still use generic meter-based numeric controls while the viewer is in imperial mode.

PR #321 fixes the selected wall metadata panel and centralizes shared linear measurement formatting. This follow-up tracks the broader audit/migration so #321 can stay scoped.

Candidate areas to audit

  • Door/window panels
  • Roof panels
  • Column panel
  • Slab panel
  • Fence inspector editors
  • Any other SliderControl usage that represents linear scene values stored in meters

Expected behavior

When the viewer unit is imperial, editable linear controls should display/edit in feet while continuing to persist scene values internally in meters.

Notes

Use the shared measurement helpers from @pascal-app/editor where appropriate, or introduce a shared imperial-aware control if that keeps repeated panel code smaller.

MateoSaettone avatar Jun 04 '26 19:06 MateoSaettone

Linking the measurement cluster so the panel audit here does not get solved twice: #308 (display-vs-input split for imperial), #509 (millimetre notation).

Relevant to scoping this: #540 is landing millimetre support for label surfaces and introduced useViewer.metricNotation as a store field orthogonal to unit. That means this audit now has two dimensions to cover per control, not one — imperial feet/inches and metric mm — so whatever pattern lands here should read both rather than special-casing imperial. A control that handles only unit will be wrong for mm users the moment it ships.

The SliderControl sites in the checklist above are the right target, and the shared formatter in packages/editor/src/lib/measurements.ts (formatLinearMeasurement) is already notation-aware, so the display side is mostly a matter of routing controls through it. The input side is the harder half and is the same problem as #308.

Aymericr avatar Aug 04 '26 16:08 Aymericr

数据库迁移兼容旧版本吗 🧠

wilsonbrenda62 avatar Aug 04 '26 20:08 wilsonbrenda62

✨😄🧠 国际化文案抽离得干净吗

rodriguezrussell93 avatar Aug 05 '26 03:08 rodriguezrussell93

🧪⚙️🚀 模型输出不稳定时你们怎么约束

harrisonmichael809 avatar Aug 05 '26 04:08 harrisonmichael809