Add project takeoff verification and bearing dimensions
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
1 parent
d22c5008f0
commit
7182b6cbb4
15 files changed
+337
-28
No files matched your search
@@ -0,0 +1,7 @@
|
||||
import type {PierModel} from '../src/core/geometry';
|
||||
/** Same bearing-body dimensions as src/view/scene.ts; A/B alone are solplate inputs. */
|
||||
export function bearingDimensions(model:PierModel){
|
||||
const plans=model.blocks.map(b=>b.plan);
|
||||
const uniform=(values:(number|undefined)[])=>values.length&&values.every(v=>v!=null&&Number.isFinite(v)&&v>0&&Math.abs(v-values[0]!)<1e-7)?values[0]!:null;
|
||||
return {length:uniform(plans.map(p=>p?(p.A+p.margin)/1000-.2:undefined)),width:uniform(plans.map(p=>p?(p.B+p.margin)/1000-.2:undefined))};
|
||||
}
|
||||
Reference in new issue
Block a user