@ifc-lite/create 3.2.0 → 5.1.0

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.
Files changed (426) hide show
  1. package/README.md +43 -0
  2. package/dist/in-store/align-boxes.d.ts +38 -0
  3. package/dist/in-store/align-boxes.d.ts.map +1 -0
  4. package/dist/in-store/align-boxes.js +97 -0
  5. package/dist/in-store/align-boxes.js.map +1 -0
  6. package/dist/in-store/anchor.d.ts.map +1 -1
  7. package/dist/in-store/anchor.js +13 -2
  8. package/dist/in-store/anchor.js.map +1 -1
  9. package/dist/in-store/auto-space-detect.d.ts +1 -1
  10. package/dist/in-store/auto-space-detect.js +1 -1
  11. package/dist/in-store/beam.d.ts +10 -1
  12. package/dist/in-store/beam.d.ts.map +1 -1
  13. package/dist/in-store/beam.js +17 -35
  14. package/dist/in-store/beam.js.map +1 -1
  15. package/dist/in-store/column.d.ts +10 -1
  16. package/dist/in-store/column.d.ts.map +1 -1
  17. package/dist/in-store/column.js +23 -22
  18. package/dist/in-store/column.js.map +1 -1
  19. package/dist/in-store/copy-array.d.ts +17 -0
  20. package/dist/in-store/copy-array.d.ts.map +1 -0
  21. package/dist/in-store/copy-array.js +47 -0
  22. package/dist/in-store/copy-array.js.map +1 -0
  23. package/dist/in-store/copy-batch.d.ts +27 -0
  24. package/dist/in-store/copy-batch.d.ts.map +1 -0
  25. package/dist/in-store/copy-batch.js +101 -0
  26. package/dist/in-store/copy-batch.js.map +1 -0
  27. package/dist/in-store/copy-dependent-walk.d.ts +27 -0
  28. package/dist/in-store/copy-dependent-walk.d.ts.map +1 -0
  29. package/dist/in-store/copy-dependent-walk.js +61 -0
  30. package/dist/in-store/copy-dependent-walk.js.map +1 -0
  31. package/dist/in-store/copy-frame.d.ts +53 -0
  32. package/dist/in-store/copy-frame.d.ts.map +1 -0
  33. package/dist/in-store/copy-frame.js +112 -0
  34. package/dist/in-store/copy-frame.js.map +1 -0
  35. package/dist/in-store/copy-product.d.ts +76 -0
  36. package/dist/in-store/copy-product.d.ts.map +1 -0
  37. package/dist/in-store/copy-product.js +318 -0
  38. package/dist/in-store/copy-product.js.map +1 -0
  39. package/dist/in-store/curtain-wall.d.ts +87 -0
  40. package/dist/in-store/curtain-wall.d.ts.map +1 -0
  41. package/dist/in-store/curtain-wall.js +237 -0
  42. package/dist/in-store/curtain-wall.js.map +1 -0
  43. package/dist/in-store/edit/effective-mutation-view.d.ts +6 -0
  44. package/dist/in-store/edit/effective-mutation-view.d.ts.map +1 -0
  45. package/dist/in-store/edit/effective-mutation-view.js +45 -0
  46. package/dist/in-store/edit/effective-mutation-view.js.map +1 -0
  47. package/dist/in-store/edit/effective-storey.d.ts +13 -0
  48. package/dist/in-store/edit/effective-storey.d.ts.map +1 -0
  49. package/dist/in-store/edit/effective-storey.js +36 -0
  50. package/dist/in-store/edit/effective-storey.js.map +1 -0
  51. package/dist/in-store/edit/effective-storeys.d.ts +9 -0
  52. package/dist/in-store/edit/effective-storeys.d.ts.map +1 -0
  53. package/dist/in-store/edit/effective-storeys.js +16 -0
  54. package/dist/in-store/edit/effective-storeys.js.map +1 -0
  55. package/dist/in-store/edit/hosted-opening-refit.d.ts +29 -0
  56. package/dist/in-store/edit/hosted-opening-refit.d.ts.map +1 -0
  57. package/dist/in-store/edit/hosted-opening-refit.js +168 -0
  58. package/dist/in-store/edit/hosted-opening-refit.js.map +1 -0
  59. package/dist/in-store/edit/length-unit-scale.d.ts +24 -0
  60. package/dist/in-store/edit/length-unit-scale.d.ts.map +1 -0
  61. package/dist/in-store/edit/length-unit-scale.js +37 -0
  62. package/dist/in-store/edit/length-unit-scale.js.map +1 -0
  63. package/dist/in-store/edit/linear-element-edit.d.ts +131 -0
  64. package/dist/in-store/edit/linear-element-edit.d.ts.map +1 -0
  65. package/dist/in-store/edit/linear-element-edit.js +259 -0
  66. package/dist/in-store/edit/linear-element-edit.js.map +1 -0
  67. package/dist/in-store/edit/metadata-clone-effective.d.ts +5 -0
  68. package/dist/in-store/edit/metadata-clone-effective.d.ts.map +1 -0
  69. package/dist/in-store/edit/metadata-clone-effective.js +47 -0
  70. package/dist/in-store/edit/metadata-clone-effective.js.map +1 -0
  71. package/dist/in-store/edit/metadata-clone.d.ts +40 -0
  72. package/dist/in-store/edit/metadata-clone.d.ts.map +1 -0
  73. package/dist/in-store/edit/metadata-clone.js +107 -0
  74. package/dist/in-store/edit/metadata-clone.js.map +1 -0
  75. package/dist/in-store/edit/placement-core.d.ts +140 -0
  76. package/dist/in-store/edit/placement-core.d.ts.map +1 -0
  77. package/dist/in-store/edit/placement-core.js +317 -0
  78. package/dist/in-store/edit/placement-core.js.map +1 -0
  79. package/dist/in-store/edit/polygon-clip.d.ts +58 -0
  80. package/dist/in-store/edit/polygon-clip.d.ts.map +1 -0
  81. package/dist/in-store/edit/polygon-clip.js +153 -0
  82. package/dist/in-store/edit/polygon-clip.js.map +1 -0
  83. package/dist/in-store/edit/read-profile.d.ts +6 -0
  84. package/dist/in-store/edit/read-profile.d.ts.map +1 -0
  85. package/dist/in-store/edit/read-profile.js +95 -0
  86. package/dist/in-store/edit/read-profile.js.map +1 -0
  87. package/dist/in-store/edit/slab-edit-frame.d.ts +40 -0
  88. package/dist/in-store/edit/slab-edit-frame.d.ts.map +1 -0
  89. package/dist/in-store/edit/slab-edit-frame.js +146 -0
  90. package/dist/in-store/edit/slab-edit-frame.js.map +1 -0
  91. package/dist/in-store/edit/slab-edit.d.ts +112 -0
  92. package/dist/in-store/edit/slab-edit.d.ts.map +1 -0
  93. package/dist/in-store/edit/slab-edit.js +275 -0
  94. package/dist/in-store/edit/slab-edit.js.map +1 -0
  95. package/dist/in-store/edit/slab-opening-carry.d.ts +10 -0
  96. package/dist/in-store/edit/slab-opening-carry.d.ts.map +1 -0
  97. package/dist/in-store/edit/slab-opening-carry.js +65 -0
  98. package/dist/in-store/edit/slab-opening-carry.js.map +1 -0
  99. package/dist/in-store/edit/split-guid.d.ts +29 -0
  100. package/dist/in-store/edit/split-guid.d.ts.map +1 -0
  101. package/dist/in-store/edit/split-guid.js +64 -0
  102. package/dist/in-store/edit/split-guid.js.map +1 -0
  103. package/dist/in-store/edit/split-target.d.ts +90 -0
  104. package/dist/in-store/edit/split-target.d.ts.map +1 -0
  105. package/dist/in-store/edit/split-target.js +116 -0
  106. package/dist/in-store/edit/split-target.js.map +1 -0
  107. package/dist/in-store/edit/target.d.ts +8 -0
  108. package/dist/in-store/edit/target.d.ts.map +1 -0
  109. package/dist/in-store/edit/target.js +5 -0
  110. package/dist/in-store/edit/target.js.map +1 -0
  111. package/dist/in-store/edit/trim-extend-geometry.d.ts +99 -0
  112. package/dist/in-store/edit/trim-extend-geometry.d.ts.map +1 -0
  113. package/dist/in-store/edit/trim-extend-geometry.js +105 -0
  114. package/dist/in-store/edit/trim-extend-geometry.js.map +1 -0
  115. package/dist/in-store/edit/wall-axis-edit.d.ts +16 -0
  116. package/dist/in-store/edit/wall-axis-edit.d.ts.map +1 -0
  117. package/dist/in-store/edit/wall-axis-edit.js +40 -0
  118. package/dist/in-store/edit/wall-axis-edit.js.map +1 -0
  119. package/dist/in-store/edit/wall-edit.d.ts +157 -0
  120. package/dist/in-store/edit/wall-edit.d.ts.map +1 -0
  121. package/dist/in-store/edit/wall-edit.js +276 -0
  122. package/dist/in-store/edit/wall-edit.js.map +1 -0
  123. package/dist/in-store/edit/wall-hosted-cuts.d.ts +35 -0
  124. package/dist/in-store/edit/wall-hosted-cuts.d.ts.map +1 -0
  125. package/dist/in-store/edit/wall-hosted-cuts.js +27 -0
  126. package/dist/in-store/edit/wall-hosted-cuts.js.map +1 -0
  127. package/dist/in-store/edit/wall-opening-reassign.d.ts +18 -0
  128. package/dist/in-store/edit/wall-opening-reassign.d.ts.map +1 -0
  129. package/dist/in-store/edit/wall-opening-reassign.js +50 -0
  130. package/dist/in-store/edit/wall-opening-reassign.js.map +1 -0
  131. package/dist/in-store/element-align.d.ts +13 -0
  132. package/dist/in-store/element-align.d.ts.map +1 -0
  133. package/dist/in-store/element-align.js +90 -0
  134. package/dist/in-store/element-align.js.map +1 -0
  135. package/dist/in-store/element-replacement.d.ts +26 -0
  136. package/dist/in-store/element-replacement.d.ts.map +1 -0
  137. package/dist/in-store/element-replacement.js +68 -0
  138. package/dist/in-store/element-replacement.js.map +1 -0
  139. package/dist/in-store/element-size-edit.d.ts +40 -0
  140. package/dist/in-store/element-size-edit.d.ts.map +1 -0
  141. package/dist/in-store/element-size-edit.js +103 -0
  142. package/dist/in-store/element-size-edit.js.map +1 -0
  143. package/dist/in-store/element-split-axis.d.ts +6 -0
  144. package/dist/in-store/element-split-axis.d.ts.map +1 -0
  145. package/dist/in-store/element-split-axis.js +87 -0
  146. package/dist/in-store/element-split-axis.js.map +1 -0
  147. package/dist/in-store/element-split-joined.d.ts +13 -0
  148. package/dist/in-store/element-split-joined.d.ts.map +1 -0
  149. package/dist/in-store/element-split-joined.js +74 -0
  150. package/dist/in-store/element-split-joined.js.map +1 -0
  151. package/dist/in-store/element-split-placement.d.ts +19 -0
  152. package/dist/in-store/element-split-placement.d.ts.map +1 -0
  153. package/dist/in-store/element-split-placement.js +48 -0
  154. package/dist/in-store/element-split-placement.js.map +1 -0
  155. package/dist/in-store/element-split-slab.d.ts +19 -0
  156. package/dist/in-store/element-split-slab.d.ts.map +1 -0
  157. package/dist/in-store/element-split-slab.js +86 -0
  158. package/dist/in-store/element-split-slab.js.map +1 -0
  159. package/dist/in-store/element-split.d.ts +49 -0
  160. package/dist/in-store/element-split.d.ts.map +1 -0
  161. package/dist/in-store/element-split.js +52 -0
  162. package/dist/in-store/element-split.js.map +1 -0
  163. package/dist/in-store/element-transform-edit.d.ts +33 -0
  164. package/dist/in-store/element-transform-edit.d.ts.map +1 -0
  165. package/dist/in-store/element-transform-edit.js +97 -0
  166. package/dist/in-store/element-transform-edit.js.map +1 -0
  167. package/dist/in-store/element-transform-frames.d.ts +58 -0
  168. package/dist/in-store/element-transform-frames.d.ts.map +1 -0
  169. package/dist/in-store/element-transform-frames.js +110 -0
  170. package/dist/in-store/element-transform-frames.js.map +1 -0
  171. package/dist/in-store/element-transform-joins.d.ts +4 -0
  172. package/dist/in-store/element-transform-joins.d.ts.map +1 -0
  173. package/dist/in-store/element-transform-joins.js +62 -0
  174. package/dist/in-store/element-transform-joins.js.map +1 -0
  175. package/dist/in-store/element-transform-plan.d.ts +38 -0
  176. package/dist/in-store/element-transform-plan.d.ts.map +1 -0
  177. package/dist/in-store/element-transform-plan.js +115 -0
  178. package/dist/in-store/element-transform-plan.js.map +1 -0
  179. package/dist/in-store/element-trim-extend.d.ts +25 -0
  180. package/dist/in-store/element-trim-extend.d.ts.map +1 -0
  181. package/dist/in-store/element-trim-extend.js +97 -0
  182. package/dist/in-store/element-trim-extend.js.map +1 -0
  183. package/dist/in-store/extract-grids.d.ts +36 -0
  184. package/dist/in-store/extract-grids.d.ts.map +1 -0
  185. package/dist/in-store/extract-grids.js +220 -0
  186. package/dist/in-store/extract-grids.js.map +1 -0
  187. package/dist/in-store/extract-walls.d.ts +12 -23
  188. package/dist/in-store/extract-walls.d.ts.map +1 -1
  189. package/dist/in-store/extract-walls.js +6 -69
  190. package/dist/in-store/extract-walls.js.map +1 -1
  191. package/dist/in-store/generate-spaces.d.ts +1 -1
  192. package/dist/in-store/grid-column.d.ts +23 -0
  193. package/dist/in-store/grid-column.d.ts.map +1 -0
  194. package/dist/in-store/grid-column.js +73 -0
  195. package/dist/in-store/grid-column.js.map +1 -0
  196. package/dist/in-store/grid-intersection-read.d.ts +10 -0
  197. package/dist/in-store/grid-intersection-read.d.ts.map +1 -0
  198. package/dist/in-store/grid-intersection-read.js +45 -0
  199. package/dist/in-store/grid-intersection-read.js.map +1 -0
  200. package/dist/in-store/grid.d.ts +124 -0
  201. package/dist/in-store/grid.d.ts.map +1 -0
  202. package/dist/in-store/grid.js +204 -0
  203. package/dist/in-store/grid.js.map +1 -0
  204. package/dist/in-store/group-evidence.d.ts +49 -0
  205. package/dist/in-store/group-evidence.d.ts.map +1 -0
  206. package/dist/in-store/group-evidence.js +111 -0
  207. package/dist/in-store/group-evidence.js.map +1 -0
  208. package/dist/in-store/group-graph.d.ts +51 -0
  209. package/dist/in-store/group-graph.d.ts.map +1 -0
  210. package/dist/in-store/group-graph.js +213 -0
  211. package/dist/in-store/group-graph.js.map +1 -0
  212. package/dist/in-store/group.d.ts +34 -0
  213. package/dist/in-store/group.d.ts.map +1 -0
  214. package/dist/in-store/group.js +181 -0
  215. package/dist/in-store/group.js.map +1 -0
  216. package/dist/in-store/host-geometry-frame.d.ts +48 -0
  217. package/dist/in-store/host-geometry-frame.d.ts.map +1 -0
  218. package/dist/in-store/host-geometry-frame.js +190 -0
  219. package/dist/in-store/host-geometry-frame.js.map +1 -0
  220. package/dist/in-store/hosted-element-edit.d.ts +29 -0
  221. package/dist/in-store/hosted-element-edit.d.ts.map +1 -0
  222. package/dist/in-store/hosted-element-edit.js +120 -0
  223. package/dist/in-store/hosted-element-edit.js.map +1 -0
  224. package/dist/in-store/hosted-element.d.ts +41 -0
  225. package/dist/in-store/hosted-element.d.ts.map +1 -0
  226. package/dist/in-store/hosted-element.js +124 -0
  227. package/dist/in-store/hosted-element.js.map +1 -0
  228. package/dist/in-store/hosted-fill-read.d.ts +56 -0
  229. package/dist/in-store/hosted-fill-read.d.ts.map +1 -0
  230. package/dist/in-store/hosted-fill-read.js +197 -0
  231. package/dist/in-store/hosted-fill-read.js.map +1 -0
  232. package/dist/in-store/hosted-global-id.d.ts +8 -0
  233. package/dist/in-store/hosted-global-id.d.ts.map +1 -0
  234. package/dist/in-store/hosted-global-id.js +53 -0
  235. package/dist/in-store/hosted-global-id.js.map +1 -0
  236. package/dist/in-store/hosted-placement-edit.d.ts +30 -0
  237. package/dist/in-store/hosted-placement-edit.d.ts.map +1 -0
  238. package/dist/in-store/hosted-placement-edit.js +123 -0
  239. package/dist/in-store/hosted-placement-edit.js.map +1 -0
  240. package/dist/in-store/hosted-scale-chain.d.ts +12 -0
  241. package/dist/in-store/hosted-scale-chain.d.ts.map +1 -0
  242. package/dist/in-store/hosted-scale-chain.js +74 -0
  243. package/dist/in-store/hosted-scale-chain.js.map +1 -0
  244. package/dist/in-store/hosted-shape-edit.d.ts +9 -0
  245. package/dist/in-store/hosted-shape-edit.d.ts.map +1 -0
  246. package/dist/in-store/hosted-shape-edit.js +79 -0
  247. package/dist/in-store/hosted-shape-edit.js.map +1 -0
  248. package/dist/in-store/index.d.ts +66 -0
  249. package/dist/in-store/index.d.ts.map +1 -0
  250. package/dist/in-store/index.js +71 -0
  251. package/dist/in-store/index.js.map +1 -0
  252. package/dist/in-store/linear-profile-frame.d.ts +10 -0
  253. package/dist/in-store/linear-profile-frame.d.ts.map +1 -0
  254. package/dist/in-store/linear-profile-frame.js +17 -0
  255. package/dist/in-store/linear-profile-frame.js.map +1 -0
  256. package/dist/in-store/material.d.ts.map +1 -1
  257. package/dist/in-store/material.js +17 -6
  258. package/dist/in-store/material.js.map +1 -1
  259. package/dist/in-store/member.d.ts +8 -2
  260. package/dist/in-store/member.d.ts.map +1 -1
  261. package/dist/in-store/member.js +15 -21
  262. package/dist/in-store/member.js.map +1 -1
  263. package/dist/in-store/ordinary-element.d.ts +47 -0
  264. package/dist/in-store/ordinary-element.d.ts.map +1 -0
  265. package/dist/in-store/ordinary-element.js +38 -0
  266. package/dist/in-store/ordinary-element.js.map +1 -0
  267. package/dist/in-store/placement-frame.d.ts +15 -5
  268. package/dist/in-store/placement-frame.d.ts.map +1 -1
  269. package/dist/in-store/placement-frame.js +25 -36
  270. package/dist/in-store/placement-frame.js.map +1 -1
  271. package/dist/in-store/profile.d.ts +141 -0
  272. package/dist/in-store/profile.d.ts.map +1 -0
  273. package/dist/in-store/profile.js +174 -0
  274. package/dist/in-store/profile.js.map +1 -0
  275. package/dist/in-store/railing.d.ts +65 -0
  276. package/dist/in-store/railing.d.ts.map +1 -0
  277. package/dist/in-store/railing.js +112 -0
  278. package/dist/in-store/railing.js.map +1 -0
  279. package/dist/in-store/rel-connects-path.d.ts +43 -0
  280. package/dist/in-store/rel-connects-path.d.ts.map +1 -0
  281. package/dist/in-store/rel-connects-path.js +65 -0
  282. package/dist/in-store/rel-connects-path.js.map +1 -0
  283. package/dist/in-store/resolve-anchor.d.ts +3 -2
  284. package/dist/in-store/resolve-anchor.d.ts.map +1 -1
  285. package/dist/in-store/resolve-anchor.js +7 -5
  286. package/dist/in-store/resolve-anchor.js.map +1 -1
  287. package/dist/in-store/resolve-host.d.ts +12 -1
  288. package/dist/in-store/resolve-host.d.ts.map +1 -1
  289. package/dist/in-store/resolve-host.js +169 -85
  290. package/dist/in-store/resolve-host.js.map +1 -1
  291. package/dist/in-store/resolve-relations.d.ts +3 -1
  292. package/dist/in-store/resolve-relations.d.ts.map +1 -1
  293. package/dist/in-store/resolve-relations.js +8 -3
  294. package/dist/in-store/resolve-relations.js.map +1 -1
  295. package/dist/in-store/resolve-source.d.ts.map +1 -1
  296. package/dist/in-store/resolve-source.js +39 -59
  297. package/dist/in-store/resolve-source.js.map +1 -1
  298. package/dist/in-store/room-candidates.d.ts +58 -0
  299. package/dist/in-store/room-candidates.d.ts.map +1 -0
  300. package/dist/in-store/room-candidates.js +135 -0
  301. package/dist/in-store/room-candidates.js.map +1 -0
  302. package/dist/in-store/room-creation-plan.d.ts +16 -0
  303. package/dist/in-store/room-creation-plan.d.ts.map +1 -0
  304. package/dist/in-store/room-creation-plan.js +28 -0
  305. package/dist/in-store/room-creation-plan.js.map +1 -0
  306. package/dist/in-store/room-floor-height.d.ts +24 -0
  307. package/dist/in-store/room-floor-height.d.ts.map +1 -0
  308. package/dist/in-store/room-floor-height.js +32 -0
  309. package/dist/in-store/room-floor-height.js.map +1 -0
  310. package/dist/in-store/room-footprint-native.d.ts +19 -0
  311. package/dist/in-store/room-footprint-native.d.ts.map +1 -0
  312. package/dist/in-store/room-footprint-native.js +117 -0
  313. package/dist/in-store/room-footprint-native.js.map +1 -0
  314. package/dist/in-store/room-layout-cache.d.ts +23 -0
  315. package/dist/in-store/room-layout-cache.d.ts.map +1 -0
  316. package/dist/in-store/room-layout-cache.js +84 -0
  317. package/dist/in-store/room-layout-cache.js.map +1 -0
  318. package/dist/in-store/room-layout-core.d.ts +68 -0
  319. package/dist/in-store/room-layout-core.d.ts.map +1 -0
  320. package/dist/in-store/room-layout-core.js +153 -0
  321. package/dist/in-store/room-layout-core.js.map +1 -0
  322. package/dist/in-store/room-population.d.ts +5 -0
  323. package/dist/in-store/room-population.d.ts.map +1 -0
  324. package/dist/in-store/room-population.js +28 -0
  325. package/dist/in-store/room-population.js.map +1 -0
  326. package/dist/in-store/room-space-meshes.d.ts +15 -0
  327. package/dist/in-store/room-space-meshes.d.ts.map +1 -0
  328. package/dist/in-store/room-space-meshes.js +38 -0
  329. package/dist/in-store/room-space-meshes.js.map +1 -0
  330. package/dist/in-store/room-store.d.ts +55 -0
  331. package/dist/in-store/room-store.d.ts.map +1 -0
  332. package/dist/in-store/room-store.js +173 -0
  333. package/dist/in-store/room-store.js.map +1 -0
  334. package/dist/in-store/room-storey-elevation.d.ts +5 -0
  335. package/dist/in-store/room-storey-elevation.d.ts.map +1 -0
  336. package/dist/in-store/room-storey-elevation.js +42 -0
  337. package/dist/in-store/room-storey-elevation.js.map +1 -0
  338. package/dist/in-store/room-storey-frame.d.ts +47 -0
  339. package/dist/in-store/room-storey-frame.d.ts.map +1 -0
  340. package/dist/in-store/room-storey-frame.js +48 -0
  341. package/dist/in-store/room-storey-frame.js.map +1 -0
  342. package/dist/in-store/room-wall-rects.d.ts +117 -0
  343. package/dist/in-store/room-wall-rects.d.ts.map +1 -0
  344. package/dist/in-store/room-wall-rects.js +157 -0
  345. package/dist/in-store/room-wall-rects.js.map +1 -0
  346. package/dist/in-store/schema-attributes.d.ts +8 -3
  347. package/dist/in-store/schema-attributes.d.ts.map +1 -1
  348. package/dist/in-store/schema-attributes.js +18 -9
  349. package/dist/in-store/schema-attributes.js.map +1 -1
  350. package/dist/in-store/slab.d.ts.map +1 -1
  351. package/dist/in-store/slab.js +1 -4
  352. package/dist/in-store/slab.js.map +1 -1
  353. package/dist/in-store/space-footprints.d.ts +55 -0
  354. package/dist/in-store/space-footprints.d.ts.map +1 -0
  355. package/dist/in-store/space-footprints.js +260 -0
  356. package/dist/in-store/space-footprints.js.map +1 -0
  357. package/dist/in-store/space.d.ts.map +1 -1
  358. package/dist/in-store/space.js +15 -3
  359. package/dist/in-store/space.js.map +1 -1
  360. package/dist/in-store/spatial-children.d.ts +1 -1
  361. package/dist/in-store/spatial-children.js +1 -1
  362. package/dist/in-store/stair-edit.d.ts +24 -0
  363. package/dist/in-store/stair-edit.d.ts.map +1 -0
  364. package/dist/in-store/stair-edit.js +190 -0
  365. package/dist/in-store/stair-edit.js.map +1 -0
  366. package/dist/in-store/stair-removal.d.ts +17 -0
  367. package/dist/in-store/stair-removal.d.ts.map +1 -0
  368. package/dist/in-store/stair-removal.js +134 -0
  369. package/dist/in-store/stair-removal.js.map +1 -0
  370. package/dist/in-store/stair.d.ts +58 -0
  371. package/dist/in-store/stair.d.ts.map +1 -0
  372. package/dist/in-store/stair.js +156 -0
  373. package/dist/in-store/stair.js.map +1 -0
  374. package/dist/in-store/storey-plan-frame.d.ts +2 -1
  375. package/dist/in-store/storey-plan-frame.d.ts.map +1 -1
  376. package/dist/in-store/storey-plan-frame.js +20 -11
  377. package/dist/in-store/storey-plan-frame.js.map +1 -1
  378. package/dist/in-store/storey-reassignment-plan.d.ts +53 -0
  379. package/dist/in-store/storey-reassignment-plan.d.ts.map +1 -0
  380. package/dist/in-store/storey-reassignment-plan.js +237 -0
  381. package/dist/in-store/storey-reassignment-plan.js.map +1 -0
  382. package/dist/in-store/storey-reassignment.d.ts +8 -0
  383. package/dist/in-store/storey-reassignment.d.ts.map +1 -0
  384. package/dist/in-store/storey-reassignment.js +52 -0
  385. package/dist/in-store/storey-reassignment.js.map +1 -0
  386. package/dist/in-store/trim-extend-plan.d.ts +27 -0
  387. package/dist/in-store/trim-extend-plan.d.ts.map +1 -0
  388. package/dist/in-store/trim-extend-plan.js +49 -0
  389. package/dist/in-store/trim-extend-plan.js.map +1 -0
  390. package/dist/in-store/wall-join-apply.d.ts +74 -0
  391. package/dist/in-store/wall-join-apply.d.ts.map +1 -0
  392. package/dist/in-store/wall-join-apply.js +137 -0
  393. package/dist/in-store/wall-join-apply.js.map +1 -0
  394. package/dist/in-store/wall-join-edit.d.ts +53 -0
  395. package/dist/in-store/wall-join-edit.d.ts.map +1 -0
  396. package/dist/in-store/wall-join-edit.js +251 -0
  397. package/dist/in-store/wall-join-edit.js.map +1 -0
  398. package/dist/in-store/wall-join-read.d.ts +60 -0
  399. package/dist/in-store/wall-join-read.d.ts.map +1 -0
  400. package/dist/in-store/wall-join-read.js +230 -0
  401. package/dist/in-store/wall-join-read.js.map +1 -0
  402. package/dist/in-store/wall-join.d.ts +122 -0
  403. package/dist/in-store/wall-join.d.ts.map +1 -0
  404. package/dist/in-store/wall-join.js +231 -0
  405. package/dist/in-store/wall-join.js.map +1 -0
  406. package/dist/in-store/wall-opening-fit.d.ts +11 -0
  407. package/dist/in-store/wall-opening-fit.d.ts.map +1 -0
  408. package/dist/in-store/wall-opening-fit.js +27 -0
  409. package/dist/in-store/wall-opening-fit.js.map +1 -0
  410. package/dist/in-store/wall-section-edit.d.ts +16 -0
  411. package/dist/in-store/wall-section-edit.d.ts.map +1 -0
  412. package/dist/in-store/wall-section-edit.js +75 -0
  413. package/dist/in-store/wall-section-edit.js.map +1 -0
  414. package/dist/in-store/wall-size-edit.d.ts +29 -0
  415. package/dist/in-store/wall-size-edit.d.ts.map +1 -0
  416. package/dist/in-store/wall-size-edit.js +65 -0
  417. package/dist/in-store/wall-size-edit.js.map +1 -0
  418. package/dist/in-store/wall.d.ts +32 -0
  419. package/dist/in-store/wall.d.ts.map +1 -1
  420. package/dist/in-store/wall.js +77 -13
  421. package/dist/in-store/wall.js.map +1 -1
  422. package/dist/index.d.ts +25 -38
  423. package/dist/index.d.ts.map +1 -1
  424. package/dist/index.js +25 -40
  425. package/dist/index.js.map +1 -1
  426. package/package.json +9 -8
@@ -0,0 +1,8 @@
1
+ import type { StoreEditor } from '@ifc-lite/mutations';
2
+ import type { IfcDataStore } from '@ifc-lite/parser';
3
+ import { type StoreyReassignmentPlan } from './storey-reassignment-plan.js';
4
+ /** Transactional, same-identity move. Existing local placement identities are
5
+ * retained so dependent placement chains keep following their original parent.
6
+ * Caller records this one compound operation for native history/Undo (#7328). */
7
+ export declare function reassignElementsToStoreyInStore(store: IfcDataStore, editor: StoreEditor, selectedIds: readonly number[], sourceStoreyId: number, destinationStoreyId: number, expected?: StoreyReassignmentPlan): StoreyReassignmentPlan;
8
+ //# sourceMappingURL=storey-reassignment.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"storey-reassignment.d.ts","sourceRoot":"","sources":["../../src/in-store/storey-reassignment.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAErD,OAAO,EAA0B,KAAK,sBAAsB,EAAE,MAAM,+BAA+B,CAAC;AAEpG;;iFAEiF;AACjF,wBAAgB,+BAA+B,CAC7C,KAAK,EAAE,YAAY,EAAE,MAAM,EAAE,WAAW,EAAE,WAAW,EAAE,SAAS,MAAM,EAAE,EAAE,cAAc,EAAE,MAAM,EAAE,mBAAmB,EAAE,MAAM,EAC7H,QAAQ,CAAC,EAAE,sBAAsB,GAChC,sBAAsB,CAsCxB"}
@@ -0,0 +1,52 @@
1
+ /* This Source Code Form is subject to the terms of the Mozilla Public
2
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
3
+ * file, You can obtain one at https://mozilla.org/MPL/2.0/. */
4
+ import { generateIfcGuid } from '@ifc-lite/encoding';
5
+ import { AnchorEntityReader } from './resolve-anchor.js';
6
+ import { planStoreyReassignment } from './storey-reassignment-plan.js';
7
+ /** Transactional, same-identity move. Existing local placement identities are
8
+ * retained so dependent placement chains keep following their original parent.
9
+ * Caller records this one compound operation for native history/Undo (#7328). */
10
+ export function reassignElementsToStoreyInStore(store, editor, selectedIds, sourceStoreyId, destinationStoreyId, expected) {
11
+ return editor.runAtomic(draft => {
12
+ const view = draft.getMutationView();
13
+ const plan = planStoreyReassignment(store, view, selectedIds, sourceStoreyId, destinationStoreyId);
14
+ if (expected && JSON.stringify(plan) !== JSON.stringify(expected))
15
+ throw new Error('reassignElementsToStoreyInStore: reviewed source, dependency or destination frame is stale');
16
+ const reader = new AnchorEntityReader(store, view);
17
+ const ownerHistory = reader.firstId('IFCOWNERHISTORY');
18
+ if (store.schemaVersion === 'IFC2X3' && ownerHistory === null)
19
+ throw new Error('reassignElementsToStoreyInStore: IFC2X3 requires IfcOwnerHistory');
20
+ const ref = (id) => `#${id}`;
21
+ for (const placement of plan.placements) {
22
+ const frame = placement.relative;
23
+ const point = draft.addEntity('IfcCartesianPoint', [frame.o]).expressId;
24
+ const z = draft.addEntity('IfcDirection', [frame.z]).expressId;
25
+ const x = draft.addEntity('IfcDirection', [frame.x]).expressId;
26
+ const axis = draft.addEntity('IfcAxis2Placement3D', [ref(point), ref(z), ref(x)]).expressId;
27
+ draft.setPositionalAttribute(placement.expressId, 0, ref(plan.destinationPlacementId));
28
+ draft.setPositionalAttribute(placement.expressId, 1, ref(axis));
29
+ }
30
+ const moved = new Set(plan.products.map(product => product.expressId));
31
+ // Move each existing relationship independently. Exhausted source entries
32
+ // retain their own Root identity/metadata; partial entries split with a
33
+ // fresh identity and the original metadata rather than merging named groups.
34
+ for (const membership of plan.sourceMemberships) {
35
+ const remaining = membership.children.filter(id => !moved.has(id));
36
+ if (!remaining.length) {
37
+ draft.setPositionalAttribute(membership.id, membership.parentIndex, ref(destinationStoreyId));
38
+ continue;
39
+ }
40
+ draft.setPositionalAttribute(membership.id, membership.listIndex, remaining.map(ref));
41
+ const attributes = [...membership.attributes];
42
+ attributes[0] = generateIfcGuid();
43
+ if (store.schemaVersion === 'IFC2X3' && attributes[1] == null)
44
+ attributes[1] = ref(ownerHistory);
45
+ attributes[membership.parentIndex] = ref(destinationStoreyId);
46
+ attributes[membership.listIndex] = membership.children.filter(id => moved.has(id)).map(ref);
47
+ draft.addEntity(membership.type, attributes);
48
+ }
49
+ return plan;
50
+ });
51
+ }
52
+ //# sourceMappingURL=storey-reassignment.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"storey-reassignment.js","sourceRoot":"","sources":["../../src/in-store/storey-reassignment.ts"],"names":[],"mappings":"AAAA;;+DAE+D;AAE/D,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAGrD,OAAO,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAC;AACzD,OAAO,EAAE,sBAAsB,EAA+B,MAAM,+BAA+B,CAAC;AAEpG;;iFAEiF;AACjF,MAAM,UAAU,+BAA+B,CAC7C,KAAmB,EAAE,MAAmB,EAAE,WAA8B,EAAE,cAAsB,EAAE,mBAA2B,EAC7H,QAAiC;IAEjC,OAAO,MAAM,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE;QAC9B,MAAM,IAAI,GAAG,KAAK,CAAC,eAAe,EAAE,CAAC;QACrC,MAAM,IAAI,GAAG,sBAAsB,CAAC,KAAK,EAAE,IAAI,EAAE,WAAW,EAAE,cAAc,EAAE,mBAAmB,CAAC,CAAC;QACnG,IAAI,QAAQ,IAAI,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,KAAK,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC;YAAE,MAAM,IAAI,KAAK,CAAC,4FAA4F,CAAC,CAAC;QACjL,MAAM,MAAM,GAAG,IAAI,kBAAkB,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;QACnD,MAAM,YAAY,GAAG,MAAM,CAAC,OAAO,CAAC,iBAAiB,CAAC,CAAC;QACvD,IAAI,KAAK,CAAC,aAAa,KAAK,QAAQ,IAAI,YAAY,KAAK,IAAI;YAAE,MAAM,IAAI,KAAK,CAAC,kEAAkE,C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'./edit/wall-hosted-cuts.js';
4
+ import { type ReachBoundary, type ReachMode, type ReachRefusal, type ReachTarget, type ReachPlan } from './edit/trim-extend-geometry.js';
5
+ type Vec2 = readonly [number, number];
6
+ export interface TrimAxisTarget {
7
+ readonly kind: 'wall' | 'beam';
8
+ readonly axis: ReachTarget;
9
+ readonly wall: WallJoinRead | null;
10
+ }
11
+ export type TrimPlanRefusal = ReachRefusal | 'wallBody' | 'hostedUnreadable' | 'hosted' | 'join';
12
+ export type TrimAxisPlan = (Extract<ReachPlan, {
13
+ ok: true;
14
+ }> & {
15
+ readonly wall: WallJoinWall | null;
16
+ readonly joinKind: 'L' | 'T' | 'butt' | null;
17
+ }) | {
18
+ readonly ok: false;
19
+ readonly reason: TrimPlanRefusal;
20
+ readonly count?: number;
21
+ readonly detail?: string;
22
+ };
23
+ /** Shared live policy: joins include physical cut faces; moving the start or
24
+ * contracting the body requires every hosted cut to be readable and inside. */
25
+ export declare function planTrimAxis(target: TrimAxisTarget, boundary: ReachBoundary, mode: ReachMode, click: Vec2, boundaryWall: WallJoinWall | null, hosted: HostedCuts | null): TrimAxisPlan;
26
+ export {};
27
+ //# sourceMappingURL=trim-extend-plan.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"trim-extend-plan.d.ts","sourceRoot":"","sources":["../../src/in-store/trim-extend-plan.ts"],"names":[],"mappings":"AAIA,OAAO,EAAqD,KAAK,YAAY,EAAE,MAAM,gBAAgB,CAAC;AACtG,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAe,KAAK,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAC1E,OAAO,EAAyB,KAAK,aAAa,EAAE,KAAK,SAAS,EAAE,KAAK,YAAY,EAAE,KAAK,WAAW,EAAE,KAAK,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAIhK,KAAK,IAAI,GAAG,SAAS,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;AACtC,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAAC;IAC/B,QAAQ,CAAC,IAAI,EAAE,WAAW,CAAC;IAC3B,QAAQ,CAAC,IAAI,EAAE,YAAY,GAAG,IAAI,CAAC;CACpC;AACD,MAAM,MAAM,eAAe,GAAG,YAAY,GAAG,UAAU,GAAG,kBAAkB,GAAG,QAAQ,GAAG,MAAM,CAAC;AACjG,MAAM,MAAM,YAAY,GACpB,CAAC,OAAO,CAAC,SAAS,EAAE;IAAE,EAAE,EAAE,IAAI,CAAA;CAAE,CAAC,GAAG;IAAE,QAAQ,CAAC,IAAI,EAAE,YAAY,GAAG,IAAI,CAAC;IAAC,QAAQ,CAAC,QAAQ,EAAE,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,IAAI,CAAA;CAAE,CAAC,GACzH;IAAE,QAAQ,CAAC,EAAE,EAAE,KAAK,CAAC;IAAC,QAAQ,CAAC,MAAM,EAAE,eAAe,CAAC;IAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAEhH;+EAC+E;AAC/E,wBAAgB,YAAY,CAC1B,MAAM,EAAE,cAAc,EAAE,QAAQ,EAAE,aAAa,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,IAAI,EAC7E,YAAY,EAAE,YAAY,GAAG,IAAI,EAAE,MAAM,EAAE,UAAU,GAAG,IAAI,GAC3D,YAAY,CAgCd"}
@@ -0,0 +1,49 @@
1
+ /* This Source Code Form is subject to the terms of the Mozilla Public
2
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
3
+ * file, You can obtain one at https://mozilla.org/MPL/2.0/. */
4
+ import { computeWallJoin, reshapeWallAxis, wallBodyOutline } from './wall-join.js';
5
+ import { cutsOutside } from './edit/wall-hosted-cuts.js';
6
+ import { clickAlong, planReach } from './edit/trim-extend-geometry.js';
7
+ import { MIN_WALL_SEGMENT_LENGTH } from './edit/wall-edit.js';
8
+ import { MIN_LINEAR_SEGMENT_LENGTH } from './edit/linear-element-edit.js';
9
+ /** Shared live policy: joins include physical cut faces; moving the start or
10
+ * contracting the body requires every hosted cut to be readable and inside. */
11
+ export function planTrimAxis(target, boundary, mode, click, boundaryWall, hosted) {
12
+ const plan = planReach(target.axis, boundary, mode, clickAlong(target.axis, click), target.kind === 'wall' ? MIN_WALL_SEGMENT_LENGTH : MIN_LINEAR_SEGMENT_LENGTH, boundaryWall !== null && target.kind === 'wall');
13
+ if (!plan.ok)
14
+ return plan;
15
+ if (target.kind === 'beam')
16
+ return { ...plan, wall: null, joinKind: null };
17
+ const read = target.wall;
18
+ if (!read)
19
+ return { ok: false, reason: 'wallBody' };
20
+ try {
21
+ let wall = reshapeWallAxis(read.wall, [plan.start[0], plan.start[1]], [plan.stop[0], plan.stop[1]]);
22
+ let joinKind = null;
23
+ if (boundaryWall) {
24
+ const join = computeWallJoin(boundaryWall, wall);
25
+ wall = join.b.wall;
26
+ joinKind = join.kind;
27
+ }
28
+ const span = (body) => {
29
+ const [dx, dy] = target.axis.dir;
30
+ const first = (body.start[0] - read.origin[0]) * dx + (body.start[1] - read.origin[1]) * dy;
31
+ const { corners } = wallBodyOutline(body);
32
+ return [first + Math.max(corners[0][0], corners[3][0]), first + Math.min(corners[1][0], corners[2][0])];
33
+ };
34
+ if (!hosted)
35
+ return { ok: false, reason: 'hostedUnreadable', count: 1 };
36
+ const previous = span(read.wall), next = span(wall);
37
+ const contracts = next[0] > previous[0] + 1e-9 || next[1] < previous[1] - 1e-9;
38
+ if ((plan.moved < 0 || contracts || (plan.end === 'start' && plan.moved !== 0)) && hosted.unreadable.length > 0)
39
+ return { ok: false, reason: 'hostedUnreadable', count: hosted.unreadable.length };
40
+ const outside = cutsOutside(hosted.cuts, next[0], next[1]);
41
+ if (outside.length > 0)
42
+ return { ok: false, reason: 'hosted', count: outside.length };
43
+ return { ...plan, wall, joinKind };
44
+ }
45
+ catch (error) {
46
+ return { ok: false, reason: 'join', detail: error instanceof Error ? error.message : String(error) };
47
+ }
48
+ }
49
+ //# sourceMappingURL=trim-extend-plan.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"trim-extend-plan.js","sourceRoot":"","sources":["../../src/in-store/trim-extend-plan.ts"],"names":[],"mappings":"AAAA;;+DAE+D;AAE/D,OAAO,EAAE,eAAe,EAAE,eAAe,EAAE,eAAe,EAAqB,MAAM,gBAAgB,CAAC;AAEtG,OAAO,EAAE,WAAW,EAAmB,MAAM,4BAA4B,CAAC;AAC1E,OAAO,EAAE,UAAU,EAAE,SAAS,EAA2F,MAAM,gCAAgC,CAAC;AAChK,OAAO,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,yBAAyB,EAAE,MAAM,+BAA+B,CAAC;AAa1E;+EAC+E;AAC/E,MAAM,UAAU,YAAY,CAC1B,MAAsB,EAAE,QAAuB,EAAE,IAAe,EAAE,KAAW,EAC7E,YAAiC,EAAE,MAAyB;IAE5D,MAAM,IAAI,GAAG,SAAS,CAAC,MAAM,CAAC,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,UAAU,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,EAChF,MAAM,CAAC,IAAI,KAAK,MAAM,CAAC,CAAC,CAAC,uBAAuB,CAAC,CAAC,CAAC,yBAAyB,EAAE,YAAY,KAAK,IAAI,IAAI,MAAM,CAAC,IAAI,KAAK,MAAM,CAAC,CAAC;IACjI,IAAI,CAAC,IAAI,CAAC,EAAE;QAAE,OAAO,IAAI,CAAC;IAC1B,IAAI,MAAM,CAAC,IAAI,KAAK,MAAM;QAAE,OAAO,EAAE,GAAG,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;IAC3E,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC;IACzB,IAAI,CAAC,IAAI;QAAE,OAAO,EAAE,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AAE,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC;IACvG,CAAC;AACH,CAAC"}
@@ -0,0 +1,74 @@
1
+ /**
2
+ * Apply a wall join (`computeWallJoin`) to two walls in the store: rewrite each
3
+ * joined wall's body profile and `Axis` representation, and write the
4
+ * `IfcRelConnectsPathElements` between them (#6232 D1).
5
+ *
6
+ * The wall's ObjectPlacement is left where it is. A join only moves an axis end
7
+ * along the axis, so the wall frame (origin, +X along the axis) stays valid,
8
+ * and openings placed relative to the wall keep their position. The new body
9
+ * and axis are written in that frame, offset by where the new Start sits in it.
10
+ * That is why a target carries `origin`: the plan point of the placement
11
+ * origin, which is the wall's Start until a join moves Start.
12
+ *
13
+ * Only the entities the wall owns are replaced: a new profile goes into the
14
+ * existing IfcExtrudedAreaSolid.SweptArea, a new Axis representation replaces
15
+ * the old one in IfcProductDefinitionShape.Representations. The old profile and
16
+ * axis are removed when this session created them (overlay entities), and left
17
+ * to the exporter otherwise.
18
+ *
19
+ * Pure: writes through the editor only.
20
+ */
21
+ import type { StoreEditor } from '@ifc-lite/mutations';
22
+ import type { SpatialAnchor } from './anchor.js';
23
+ import { type WallBuildResult, type WallInStoreParams } from './wall.js';
24
+ import { type PlanPoint, type WallJoin, type WallJoinOptions, type WallJoinWall } from './wall-join.js';
25
+ /** A wall in the store, with the ids a join rewrites and its current plan shape. */
26
+ export interface WallJoinTarget {
27
+ wallId: number;
28
+ /** IfcExtrudedAreaSolid of the Body; its SweptArea is replaced. */
29
+ solidId: number;
30
+ /** The profile the solid sweeps now. */
31
+ profileId: number;
32
+ /** IfcProductDefinitionShape of the wall. */
33
+ productShapeId: number;
34
+ /** Its current Representations, in order. */
35
+ representationIds: readonly number[];
36
+ /** The current `Axis` representation, when the wall has one (it is replaced, else a new one is appended). */
37
+ axisRepId: number | null;
38
+ /** Plan point (metres) of the wall's placement origin; the placement's +X runs along the axis. */
39
+ origin: PlanPoint;
40
+ /** The wall's current plan shape, metres. */
41
+ wall: WallJoinWall;
42
+ }
43
+ export interface WallJoinApplyResult {
44
+ join: WallJoin;
45
+ /** The IfcRelConnectsPathElements written. */
46
+ relId: number;
47
+ /** The walls after the join, ready to take part in a next join. */
48
+ a: WallJoinTarget;
49
+ b: WallJoinTarget;
50
+ }
51
+ export interface WallJoinApplyOptions extends WallJoinOptions {
52
+ /** Layer priorities for the relationship, by wall. Default empty. */
53
+ priorities?: {
54
+ a?: readonly number[];
55
+ b?: readonly number[];
56
+ };
57
+ /** Name for the IfcRelConnectsPathElements. */
58
+ Name?: string;
59
+ }
60
+ export type JoinAnchor = Pick<SpatialAnchor, 'ownerHistoryId' | 'axisContextId' | 'schema' | 'lengthUnitScale' | 'guidRandom'>;
61
+ /** The join target for a wall `addWallToStore` just built from `params`. */
62
+ export declare function wallJoinTargetFromBuild(build: WallBuildResult, params: WallInStoreParams): WallJoinTarget;
63
+ /**
64
+ * Join walls `a` and `b` in the store. See `computeWallJoin` for the geometry
65
+ * and `options`. Refuses IFC5 / IFCX anchors; IFC2X3, IFC4 and IFC4X3 are
66
+ * written by their own attribute layouts.
67
+ */
68
+ export declare function applyWallJoinToStore(editor: StoreEditor, anchor: JoinAnchor, a: WallJoinTarget, b: WallJoinTarget, options?: WallJoinApplyOptions): WallJoinApplyResult;
69
+ /**
70
+ * Give `target` the body and `Axis` of `wall`, written in the frame of the
71
+ * placement at `target.origin` (`wall`'s axis runs along that frame's +X).
72
+ */
73
+ export declare function rewriteWall(editor: StoreEditor, anchor: JoinAnchor, target: WallJoinTarget, wall: WallJoinWall): WallJoinTarget;
74
+ //# sourceMappingURL=wall-join-apply.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wall-join-apply.d.ts","sourceRoot":"","sources":["../../src/in-store/wall-join-apply.ts"],"names":[],"mappings":"AAIA;;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B,GAAG,eAAe,GAAG,QAAQ,GAAG,iBAAiB,GAAG,YAAY,CAAC,CAAC;AAE/H,4EAA4E;AAC5E,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,eAAe,EAAE,MAAM,EAAE,iBAAiB,GAAG,cAAc,CAWzG;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,WAAW,EACnB,MAAM,EAAE,UAAU,EAClB,CAAC,EAAE,cAAc,EACjB,CAAC,EAAE,cAAc,EACjB,OAAO,GAAE,oBAAyB,GACjC,mBAAmB,CAkCrB;AASD;;;GAGG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,WAAW,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,cAAc,EAAE,IAAI,EAAE,YAAY,GAAG,cAAc,CAQ/H"}
@@ -0,0 +1,137 @@
1
+ /* This Source Code Form is subject to the terms of the Mozilla Public
2
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
3
+ * file, You can obtain one at https://mozilla.org/MPL/2.0/. */
4
+ import { relConnectsPathElementsAttributes } from './rel-connects-path.js';
5
+ import { schemaRegistry } from './schema-attributes.js';
6
+ import { emitWallAxisRepresentation, emitWallBodyProfile, wallJoinWallFromParams } from './wall.js';
7
+ import { computeWallJoin } from './wall-join.js';
8
+ /** The join target for a wall `addWallToStore` just built from `params`. */
9
+ export function wallJoinTargetFromBuild(build, params) {
10
+ return {
11
+ wallId: build.wallId,
12
+ solidId: build.solidId,
13
+ profileId: build.profileId,
14
+ productShapeId: build.productShapeId,
15
+ representationIds: build.axisRepId === null ? [build.shapeRepId] : [build.shapeRepId, build.axisRepId],
16
+ axisRepId: build.axisRepId,
17
+ origin: [params.Start[0], params.Start[1]],
18
+ wall: wallJoinWallFromParams(params),
19
+ };
20
+ }
21
+ /**
22
+ * Join walls `a` and `b` in the store. See `computeWallJoin` for the geometry
23
+ * and `options`. Refuses IFC5 / IFCX anchors; IFC2X3, IFC4 and IFC4X3 are
24
+ * written by their own attribute layouts.
25
+ */
26
+ export function applyWallJoinToStore(editor, anchor, a, b, options = {}) {
27
+ const op = 'applyWallJoinToStore';
28
+ schemaRegistry(anchor.schema, op);
29
+ if (a.wallId === b.wallId)
30
+ throw new Error(`${op}: a wall cannot join itself`);
31
+ for (const target of [a, b]) {
32
+ for (const id of [target.wallId, target.solidId, target.profileId, target.productShapeId]) {
33
+ if (!editor.hasEntity(id))
34
+ throw new Error(`${op}: #${id} of wall #${target.wallId} is not a live entity`);
35
+ }
36
+ if (editor.getEntityType(target.solidId)?.toUpperCase() !== 'IFCEXTRUDEDAREASOLID') {
37
+ throw new Error(`${op}: wall #${target.wallId} body #${target.solidId} is not an IfcExtrudedAreaSolid`);
38
+ }
39
+ }
40
+ // Everything that can refuse runs before the first write: the geometry, then
41
+ // the relationship's attributes (schema layout, element classes, OwnerHistory).
42
+ const join = computeWallJoin(a.wall, b.wall, options);
43
+ const relatingIsA = join.relating === 'a';
44
+ const [relating, related] = relatingIsA ? [join.a, join.b] : [join.b, join.a];
45
+ const relAttributes = relConnectsPathElementsAttributes(editor, anchor, {
46
+ RelatingElement: (relatingIsA ? a : b).wallId,
47
+ RelatedElement: (relatingIsA ? b : a).wallId,
48
+ RelatingConnectionType: relating.connection,
49
+ RelatedConnectionType: related.connection,
50
+ RelatingPriorities: relatingIsA ? options.priorities?.a : options.priorities?.b,
51
+ RelatedPriorities: relatingIsA ? options.priorities?.b : options.priorities?.a,
52
+ Name: options.Name,
53
+ }, op);
54
+ // The through wall of a T keeps its body; it only gains an Axis if it has none,
55
+ // so every joined wall carries one.
56
+ const nextA = join.a.connection === 'ATPATH' ? ensureAxis(editor, anchor, a) : rewriteWall(editor, anchor, a, join.a.wall);
57
+ const nextB = join.b.connection === 'ATPATH' ? ensureAxis(editor, anchor, b) : rewriteWall(editor, anchor, b, join.b.wall);
58
+ const relId = editor.addEntity('IfcRelConnectsPathElements', relAttributes).expressId;
59
+ return { join, relId, a: nextA, b: nextB };
60
+ }
61
+ /** Where plan point `p` sits along the wall frame's X, metres from the placement origin. */
62
+ function alongFrame(target, p) {
63
+ const { start, end } = target.wall;
64
+ const length = Math.hypot(end[0] - start[0], end[1] - start[1]);
65
+ return ((p[0] - target.origin[0]) * (end[0] - start[0]) + (p[1] - target.origin[1]) * (end[1] - start[1])) / length;
66
+ }
67
+ /**
68
+ * Give `target` the body and `Axis` of `wall`, written in the frame of the
69
+ * placement at `target.origin` (`wall`'s axis runs along that frame's +X).
70
+ */
71
+ export function rewriteWall(editor, anchor, target, wall) {
72
+ const startX = alongFrame(target, wall.start);
73
+ const endX = alongFrame(target, wall.end);
74
+ const profileId = emitWallBodyProfile(editor, anchor, wall, startX);
75
+ editor.setPositionalAttribute(target.solidId, 0, `#${profileId}`);
76
+ removeOverlayProfile(editor, target.profileId);
77
+ return { ...writeAxis(editor, anchor, target, startX, endX), profileId, wall };
78
+ }
79
+ /** Replace the wall's Axis representation (or append one) with `startX..endX` in its frame. */
80
+ function writeAxis(editor, anchor, target, startX, endX) {
81
+ const axisRepId = emitWallAxisRepresentation(editor, anchor, startX, endX);
82
+ const representationIds = target.axisRepId !== null && target.representationIds.includes(target.axisRepId)
83
+ ? target.representationIds.map((id) => (id === target.axisRepId ? axisRepId : id))
84
+ : [...target.representationIds, axisRepId];
85
+ editor.setPositionalAttribute(target.productShapeId, 2, representationIds.map((id) => `#${id}`));
86
+ if (target.axisRepId !== null)
87
+ removeOverlayAxis(editor, target.axisRepId);
88
+ return { ...target, representationIds, axisRepId };
89
+ }
90
+ /** A wall the join leaves as it is: give it an Axis when it has none. */
91
+ function ensureAxis(editor, anchor, target) {
92
+ if (target.axisRepId !== null)
93
+ return { ...target };
94
+ return writeAxis(editor, anchor, target, alongFrame(target, target.wall.start), alongFrame(target, target.wall.end));
95
+ }
96
+ function refId(value) {
97
+ return typeof value === 'string' && /^#\d+$/.test(value) ? Number(value.slice(1)) : null;
98
+ }
99
+ /** Remove overlay entity `id` when it is one of `types`; returns its attributes, else null. */
100
+ function removeOverlay(editor, id, types) {
101
+ if (id === null)
102
+ return null;
103
+ const entity = editor.getNewEntity(id);
104
+ const type = editor.getEntityType(id)?.toUpperCase();
105
+ if (!entity || !types.some((t) => t.toUpperCase() === type))
106
+ return null;
107
+ editor.removeEntity(id);
108
+ return entity.attributes;
109
+ }
110
+ /** A profile this session built: the profile, its Position and origin point, or its polyline and points. */
111
+ function removeOverlayProfile(editor, profileId) {
112
+ const profile = removeOverlay(editor, profileId, ['IfcRectangleProfileDef', 'IfcArbitraryClosedProfileDef']);
113
+ if (!profile)
114
+ return;
115
+ // IfcRectangleProfileDef.Position (slot 2) / IfcArbitraryClosedProfileDef.OuterCurve (slot 2).
116
+ const inner = refId(profile[2]);
117
+ const position = removeOverlay(editor, inner, ['IfcAxis2Placement2D']);
118
+ if (position)
119
+ removeOverlay(editor, refId(position[0]), ['IfcCartesianPoint']);
120
+ const polyline = position ? null : removeOverlay(editor, inner, ['IfcPolyline']);
121
+ // A closed polyline repeats its first point; remove each point once.
122
+ const points = new Set(Array.isArray(polyline?.[0]) ? polyline[0].map(refId) : []);
123
+ for (const point of points)
124
+ removeOverlay(editor, point, ['IfcCartesianPoint']);
125
+ }
126
+ /** An Axis representation this session built: the representation, its polyline and points. */
127
+ function removeOverlayAxis(editor, axisRepId) {
128
+ const rep = removeOverlay(editor, axisRepId, ['IfcShapeRepresentation']);
129
+ const items = Array.isArray(rep?.[3]) ? rep[3] : [];
130
+ for (const item of items) {
131
+ const polyline = removeOverlay(editor, refId(item), ['IfcPolyline']);
132
+ const points = new Set(Array.isArray(polyline?.[0]) ? polyline[0].map(refId) : []);
133
+ for (const point of points)
134
+ removeOverlay(editor, point, ['IfcCartesianPoint']);
135
+ }
136
+ }
137
+ //# sourceMappingURL=wall-join-apply.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wall-join-apply.js","sourceRoot":"","sources":["../../src/in-store/wall-join-apply.ts"],"names":[],"mappings":"AAAA;;+DAE+D;AAyB/D,OAAO,EAAE,iCAAi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AAK,IAAI,MAAM;YAAE,aAAa,CAAC,MAAM,EAAE,KAAK,EAAE,CAAC,mBAAmB,CAAC,CAAC,CAAC;IAClF,CAAC;AACH,CAAC"}
@@ -0,0 +1,53 @@
1
+ import type { StoreEditor } from '@ifc-lite/mutations';
2
+ import type { IfcDataStore } from '@ifc-lite/parser';
3
+ import { resolveAuthoringAnchor } from './resolve-relations.js';
4
+ import { type JoinAnchor, type WallJoinApplyOptions, type WallJoinApplyResult } from './wall-join-apply.js';
5
+ import { type PlanPoint } from './wall-join.js';
6
+ /** What a join write needs from the model: the authoring anchor plus the context an `Axis` representation lives in. */
7
+ export declare function resolveWallJoinAnchor(store: IfcDataStore, view?: Parameters<typeof resolveAuthoringAnchor>[1]): JoinAnchor;
8
+ export interface WallJoinInStoreResult extends WallJoinApplyResult {
9
+ /** The relationships this join replaced, now removed. */
10
+ replacedRelIds: number[];
11
+ }
12
+ /**
13
+ * Join walls `aId` and `bId`. See `computeWallJoin` for the geometry and
14
+ * options. When the pair is already joined, the old relationship is removed
15
+ * (its name and priorities carried over) and the wall that ran through then
16
+ * still does, unless `options.priority` says otherwise. Nothing is written
17
+ * when the join is refused.
18
+ */
19
+ export declare function joinWallsInStore(editor: StoreEditor, store: IfcDataStore, anchor: JoinAnchor, aId: number, bId: number, options?: WallJoinApplyOptions): WallJoinInStoreResult;
20
+ /** A wall's new axis ends and thickness, storey-local metres. What is left out stays. */
21
+ export interface WallReshape {
22
+ wallId: number;
23
+ start?: PlanPoint;
24
+ end?: PlanPoint;
25
+ thickness?: number;
26
+ }
27
+ export interface WallReshapeOptions {
28
+ /** A moved end takes the walls joined end to end with it (an L corner or a butt join) along. */
29
+ moveJoinedEnds?: boolean;
30
+ /** Tolerance of the recomputed joins, see `computeWallJoin`. */
31
+ tolerance?: number;
32
+ /**
33
+ * Walls that were moved as a whole (a rigid move or turn) and are NOT
34
+ * rewritten here: the joins they are part of are recomputed against the
35
+ * walls that are.
36
+ */
37
+ refresh?: readonly number[];
38
+ }
39
+ export interface WallReshapeResult {
40
+ /** Every wall whose geometry was written, moved or re-cut: the ones to re-mesh. */
41
+ walls: number[];
42
+ /** The relationships written. */
43
+ relIds: number[];
44
+ /** Relationships removed because their walls no longer meet. */
45
+ droppedRelIds: number[];
46
+ }
47
+ /**
48
+ * Give walls new axis ends and keep every join that touches them current.
49
+ * Refuses (writing nothing) a wall this module cannot read, a wall that would
50
+ * have no length or leave its storey plane is the caller's to check.
51
+ */
52
+ export declare function reshapeWallsInStore(editor: StoreEditor, store: IfcDataStore, anchor: JoinAnchor, edits: readonly WallReshape[], options?: WallReshapeOptions): WallReshapeResult;
53
+ //# sourceMappingURL=wall-join-edit.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wall-join-edit.d.ts","sourceRoot":"","sources":["../../src/in-store/wall-join-edit.ts"],"names":[],"mappings":"AAuBA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAErD,OAAO,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAEhE,OAAO,EAAqC,KAAK,UAAU,EAAE,KAAK,oBAAoB,EAAE,KAAK,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAE/I,OAAO,EAAoC,KAAK,SAAS,EAAqB,MAAM,gBAAgB,CAAC;AAGrG,uHAAuH;AACvH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,YAAY,EAAE,IAAI,CAAC,EAAE,UAAU,CAAC,OAAO,sBAAsB,CAAC,CAAC,CAAC,CAAC,GAAG,UAAU,CAM1H;AAQD,MAAM,WAAW,qBAAsB,SAAQ,mBAAmB;IAChE,yDAAyD;IACzD,cAAc,EAAE,MAAM,EAAE,CAAC;CAC1B;AAED;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAC9B,MAAM,EAAE,WAAW,EACnB,KAAK,EAAE,YAAY,EACnB,MAAM,EAAE,UAAU,EAClB,GA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