Integrate dockable BIM viewer, IFC hierarchy and scene tools

This commit is contained in:
DCCONSTRUCTIONS
2026-11-14 22:16:11 +03:00
parent 9937eb66d8
commit e8920f56a2
13 changed files with 82 additions and 33 deletions
+4 -4
View File
@@ -10,7 +10,7 @@
"hasInstallScript": true,
"dependencies": {
"@noble/hashes": "^2.2.0",
"@nodedc/bim-viewer": "file:../../vendor/bim/nodedc-bim-viewer-0.1.7.tgz",
"@nodedc/bim-viewer": "file:../../vendor/bim/nodedc-bim-viewer-0.1.8.tgz",
"@nodedc/map-cesium-react": "file:../../../NODEDC_DESIGN_GUIDELINE/packages/map-cesium-react",
"@nodedc/page-patterns": "file:../../../NODEDC_DESIGN_GUIDELINE/packages/page-patterns",
"@nodedc/tokens": "file:../../../NODEDC_DESIGN_GUIDELINE/packages/tokens",
@@ -884,9 +884,9 @@
}
},
"node_modules/@nodedc/bim-viewer": {
"version": "0.1.7",
"resolved": "file:../../vendor/bim/nodedc-bim-viewer-0.1.7.tgz",
"integrity": "sha512-EN/3m7+Vk04NIEo/scV6XvGlFANefN6f7UZ3g3dNyDsM8Y4UzW4/ug1nxPXVDAa07uilZZVoR1tCJHh60tA6Gg==",
"version": "0.1.8",
"resolved": "file:../../vendor/bim/nodedc-bim-viewer-0.1.8.tgz",
"integrity": "sha512-oZDT98cNOP+QZfACtpK4nv2AWci7c8JqI6+VZtByOzrvbGbFQzvlpFrO84Yjcq//igLYVx8LC2Q0vJnrzds4Nw==",
"peerDependencies": {
"@nodedc/ui-react": "0.7.0",
"react": ">=19 <20",
+1 -1
View File
@@ -15,7 +15,7 @@
},
"dependencies": {
"@noble/hashes": "^2.2.0",
"@nodedc/bim-viewer": "file:../../vendor/bim/nodedc-bim-viewer-0.1.7.tgz",
"@nodedc/bim-viewer": "file:../../vendor/bim/nodedc-bim-viewer-0.1.8.tgz",
"@nodedc/map-cesium-react": "file:../../../NODEDC_DESIGN_GUIDELINE/packages/map-cesium-react",
"@nodedc/page-patterns": "file:../../../NODEDC_DESIGN_GUIDELINE/packages/page-patterns",
"@nodedc/tokens": "file:../../../NODEDC_DESIGN_GUIDELINE/packages/tokens",
+1 -1
View File
@@ -790,7 +790,7 @@ export default function App() {
allowFullscreen={activeDefinition.kind === "vehicles"}
eyebrow={activeDefinition.eyebrow}
title={
activeDefinition.kind === "vehicles"
(activeDefinition.kind === "vehicles" || activeDefinition.kind === "architectural-projects")
? <>{activeDefinition.title}<span className="fleet-header-title" ref={setWorkspaceHeaderTitleHost}/></>
: activeDefinition.kind === "recordings"
&& replayPresented
@@ -453,7 +453,7 @@ export function WorkspaceRenderer(props: WorkspaceRendererProps) {
case "network-monitor":
return <NetworkWorkspace />;
case "architectural-projects":
return <ArchitecturalProjectsWorkspace headerToolsHost={props.headerToolsHost} />;
return <ArchitecturalProjectsWorkspace headerToolsHost={props.headerToolsHost} headerTitleHost={props.headerTitleHost} />;
case "datasets":
return <DatasetGatewayWorkspace />;
case "artifact-health":
@@ -12,7 +12,7 @@ const Workspace = lazy(async () => {
});
/** Host composition only: the module owns its catalog, intake, maps and renderer. */
export function ArchitecturalProjectsWorkspace({headerToolsHost}:{headerToolsHost?:HTMLElement|null}) {
export function ArchitecturalProjectsWorkspace({headerToolsHost,headerTitleHost}:{headerToolsHost?:HTMLElement|null;headerTitleHost?:HTMLElement|null}) {
const [toasts, setToasts] = useState<NotificationMessage[]>([]);
const notify = useCallback((notice: Notice) => {
setToasts(items => [...items, {...notice, id: 'bim:' + crypto.randomUUID()}].slice(-5));
@@ -22,7 +22,7 @@ export function ArchitecturalProjectsWorkspace({headerToolsHost}:{headerToolsHos
}), [notify]);
return <>
<Suspense fallback={<Description role="status">Открываем архитектурные проекты…</Description>}>
<Workspace host={host} headerToolsHost={headerToolsHost}/>
<Workspace host={host} headerToolsHost={headerToolsHost} headerTitleHost={headerTitleHost}/>
</Suspense>
<ToastStack items={toasts} onDismiss={id => setToasts(items => items.filter(item => item.id !== id))}/>
</>;
+48 -5
View File
@@ -1,10 +1,10 @@
# Portable BIM module in Mission Core
Qualified on 2026-11-14: **Данные → Архитектурные проекты** at the canonical `http://127.0.0.1:8000/`. The operator can create a project, upload IFC, wait for Worker conversion, download the prepared product and view it in 3D or plan. MapLibre, project tree, model versions and visibility share the same catalog. Map markers, project eyes and version rows enter the same project viewer.
Qualified on 2026-11-14: **Данные → Архитектурные проекты** at the canonical `http://127.0.0.1:8000/`. The operator can create a project, upload IFC, wait for Worker conversion, download the prepared product and view it in 3D or through the navigation cube. MapLibre, project tree, model versions and visibility share the same catalog. Map markers, project eyes and version rows enter the same project viewer.
## Ownership and integration
The implementation belongs to [NODEDC_BIM_MOD](https://git.dcserve.ru/dctouch/NODEDC_BIM_MOD), branch `feat/portable-bim-ifc`. Core consumes Python host services 0.1.2 and browser workspace 0.1.7 from `vendor/bim/`; release manifests hold source commits and SHA-256 identities. The Python package owns contracts, project documents, transfer lifecycle and the host API. The browser package owns catalog, intake, map and renderer. It uses the host's React and NODE.DC UI, while keeping its Three/Fragments graph private; render objects are not exchanged with existing Core renderers.
The implementation belongs to [NODEDC_BIM_MOD](https://git.dcserve.ru/dctouch/NODEDC_BIM_MOD), branch `feat/portable-bim-ifc`. Core consumes Python host services 0.1.3 and browser workspace 0.1.8 from `vendor/bim/`; release manifests hold source commits and SHA-256 identities. The Python package owns contracts, project documents, transfer lifecycle and the host API. The browser package owns catalog, intake, map and renderer. It uses the host's React and NODE.DC UI, while keeping its Three/Fragments graph private; render objects are not exchanged with existing Core renderers.
Core-specific files are `src/k1link/web/bim_module.py`, `apps/control-station/src/workspaces/data/ArchitecturalProjectsWorkspace.tsx` and asset declarations. The app mounts `/api/v1/bim`, closes the module on shutdown and runs its ready-copy retention with the existing reaper. Product registry/composition select the workspace. The generic shell reads capability status; no BIM pipeline is implemented in App.tsx. The adapter emits canonical toasts, observed by the current Core notification history. It does not depend on that history's source files.
@@ -32,7 +32,7 @@ Full evidence and limitations: [module qualification](https://git.dcserve.ru/dct
## Remaining scope
This is the first IFC slice, not full BIM acceptance. LAS/LAZ and new Gaussian captures, full BIM properties/selection/measurements/sections/federation, placement gizmos and unsaved-draft flow, large-model qualification, persistent download resume, full live fault injection, a second host and physical volume migration remain open. Existing PlayCanvas simulation is a separate system. Map markers cover all placed projects; detailed BIM geometry currently belongs to the selected project's preview. Multiple simultaneous building previews remain an acceptance case.
This is the first IFC slice, not full BIM acceptance. LAS/LAZ and new Gaussian captures, persistent annotations, advanced section boxes/fills and federation workflows, placement gizmos and unsaved-draft flow, large-model qualification, persistent download resume, full live fault injection, a second host and physical volume migration remain open. Existing PlayCanvas simulation is a separate system. Map markers cover all placed projects; detailed BIM geometry currently belongs to the selected project's preview. Multiple simultaneous building previews remain an acceptance case.
The 256 MiB prepared-member budget does not guarantee arbitrary GPU/RAM capacity. WebGL was visually qualified. Optional Fragments WebGPU imports produce build warnings and WebGPU is not claimed; multiple Three instances are expected across the private module graph and existing host renderers. The four scoped PASS cases in the module matrix do not close the remaining 139 cases.
@@ -51,12 +51,55 @@ Current release sources and exact hashes are in `vendor/bim` manifests. See [ent
## Durable full-version retirement · 14 November 2026
Current packages: host/Worker 0.1.2 and browser 0.1.7. Server source `08538ed7a78f1d6e880efe0cd375d9eee9c90df8`, browser source `a097fb46df57489ac8ca46e46798d254721b661e`. All three entry levels use canonical ResourceRows: project, nonempty kind group, material/version. Material rows show name, version, admission date and a leading local-availability lamp. The group eye opens its last admitted version, downloads it if needed and does not silently substitute an older version while the latest is processing.
This deletion qualification used host/Worker 0.1.2 and browser 0.1.7. Server source `08538ed7a78f1d6e880efe0cd375d9eee9c90df8`, browser source `a097fb46df57489ac8ca46e46798d254721b661e`. All three entry levels use canonical ResourceRows: project, nonempty kind group, material/version. Material rows show name, version, admission date and a leading local-availability lamp. The group eye opens its last admitted version, downloads it if needed and does not silently substitute an older version while the latest is processing.
The trash action is full version retirement after explicit confirmation, separate from local-copy eviction. A `202` response records the durable task, closes the modal and leaves the row with a central indeterminate progress bar and small phase label instead of actions. Core and Worker each reconcile persisted journals without expiry: cancel corresponding transfers/execution, fence new reads/publications, wait for actual HTTP readers/process termination, delete manifest-owned files, acknowledge Worker retirement, then remove local copies and catalog/import/job/placement references. Shared originals belonging to retained versions remain; unknown/changed files block cleanup with a visible reason. Pin does not veto explicit full deletion. Source-only accepted imports can be retired before conversion finishes.
Worker remains one container on the same named volume, with the same CPU/RAM/PID/network boundary. All 22 unrelated containers present at deployment kept their identities. The six pre-existing source/product records were inventoried before replacement and verified afterward, including manifests, file lengths and SHA-256. The destructive qualification removed only its separately approved additional public fixture. No raw source is stored in Core.
Current validation: 77 module Python tests, 14 browser contracts, 2 Core adapter tests, 1,596 Core frontend tests, typography/typecheck and production build. The deletion tests include a real forced process exit followed by queue/journal/scratch recovery, active-process cancellation, lost acknowledgement and partial unlink. Detailed current UI/Worker evidence is in the module's entry qualification; initial IFC facts above remain dated evidence.
Deletion-phase validation: 77 module Python tests, 14 browser contracts, 2 Core adapter tests, 1,596 Core frontend tests, typography/typecheck and production build. The deletion tests include a real forced process exit followed by queue/journal/scratch recovery, active-process cancellation, lost acknowledgement and partial unlink. Detailed current UI/Worker evidence is in the module's entry qualification; initial IFC facts above remain dated evidence.
Live UI fault qualification: with Worker stopped, confirmation enqueued the temporary version deletion and the row retained its central progress/status. Core restarted while Worker remained offline; the durable task and row returned. Starting the same Worker completed deletion automatically, then the row disappeared. Worker acknowledgement, removal of temporary source/product paths and local copy, empty scratch and preservation of all six previous materials were verified. Browser 0.1.7 also restores viewer admission after Core restart (three regressions plus live open-model restart); it does not readmit retired products. Final 1280/700 px layout and individual Glass V4 controls with transparent rails were checked. Design Guideline source `3d4c4aaa082d75de8e1a3a63abfa19b863f674c9`. See the module entry qualification and compact deletion evidence for scope.
## Current viewer workspace · 14 November 2026
Client 0.1.8 / host 0.1.3 retain Worker 0.1.2. The viewport fills the workspace;
NavigationCube is upper left, Layers/Hierarchy/Viewport settings/Fit/Fullscreen
are upper right. Header shows the project name after a slash and only back/add/
close. Layers and hierarchy reuse EditorDockLayout/Tree/ResourceRows from the
scene editor; settings is the same Inspector pattern. No material editor or
PlayCanvas runtime is copied. Shared Toolbar supplies hold/autohide and menus.
Viewport settings include background, grid/axes, perspective/orthographic camera,
FOV/navigation, ambient/directional lighting, tone mapping/exposure, pixel ratio,
frame rate, Fragments detail and palette placement/geometry/autohide. Preferences
and layout live in Core meta.json with atomic revisioned persistence. Independent
concurrent fields merge; conflicting fields do not overwrite a newer document.
Old map-only/viewer clients preserve the new render settings.
Tools use public Fragments APIs. The right palette orders selection, isolation,
measurements (ruler), section and view/projection after Hold. Projection offers
perspective, orthographic, axonometric and six axis views. Properties and volume
live in each IFC row's information dropdown, opened by hover/click/keyboard activation.
The hierarchy contains only the open project: nonempty material types, versions,
actual IFC spatial entities and geometry. Selection works scene→tree and
tree→scene; ancestors expand and the tree scrolls to the selected row. Spatial
category wrappers do not double indentation. Uncontained geometry remains
accessible. Selecting a container highlights/isolates/calculates its descendants.
Distance/edge/angle/planar polygon area and one axis-aligned section with
position/reverse are current-view state, not persisted annotations. Advanced
upstream drawing/editing/postproduction/section-fill components remain outside
this slice. Source and scope: [viewer qualification](https://git.dcserve.ru/dctouch/NODEDC_BIM_MOD/src/branch/feat/portable-bim-ifc/docs/viewer-workspace-qualification.md).
Validation: 82 host tests, 24 client tests, two Core adapter tests, shared docking,
floating geometry, icon and typography gates, architecture/typecheck and
production build. Final complete Core frontend suite: 1603 pass / 0 failures.
Live acceptance on School and LivingBIM confirmed project-only IFC structure,
bidirectional selection/reveal, element and container isolation, row information
and volume, projection/top view, fullscreen buttons, narrow 700 px settings and
keyboard window handling. Escape closes information without reopening. Final
browser console: no errors. Compact evidence is in the module's
`docs/evidence/viewer-workspace-qualification-20261114.json`.
+2 -2
View File
@@ -18,7 +18,7 @@ dependencies = [
"httpx>=0.28,<1",
"lz4>=4.4,<5",
"missioncore-plugin-sdk",
"nodedc-bim-module==0.1.2",
"nodedc-bim-module==0.1.3",
"paho-mqtt>=2.1,<3",
"pillow>=12,<13",
"pyyaml>=6.0,<7",
@@ -29,7 +29,7 @@ dependencies = [
]
[tool.uv.sources]
nodedc-bim-module = { path = "vendor/bim/nodedc_bim_module-0.1.2-py3-none-any.whl" }
nodedc-bim-module = { path = "vendor/bim/nodedc_bim_module-0.1.3-py3-none-any.whl" }
missioncore-plugin-sdk = { path = "packages/plugin-sdk", editable = true }
[project.optional-dependencies]
Generated
+4 -4
View File
@@ -479,8 +479,8 @@ wheels = [
[[package]]
name = "nodedc-bim-module"
version = "0.1.2"
source = { path = "vendor/bim/nodedc_bim_module-0.1.2-py3-none-any.whl" }
version = "0.1.3"
source = { path = "vendor/bim/nodedc_bim_module-0.1.3-py3-none-any.whl" }
dependencies = [
{ name = "fastapi" },
{ name = "httpx" },
@@ -488,7 +488,7 @@ dependencies = [
{ name = "uvicorn" },
]
wheels = [
{ filename = "nodedc_bim_module-0.1.2-py3-none-any.whl", hash = "sha256:453b9176415baa1f91b49d76b7cdd3610ea0ae0dc715e8557aadabaa2745639d" },
{ filename = "nodedc_bim_module-0.1.3-py3-none-any.whl", hash = "sha256:90b2797e2bf028113b46c3c0c38ff374d64220be4e63941957700963daa4be16" },
]
[package.metadata]
@@ -556,7 +556,7 @@ requires-dist = [
{ name = "httpx", specifier = ">=0.28,<1" },
{ name = "lz4", specifier = ">=4.4,<5" },
{ name = "missioncore-plugin-sdk", editable = "packages/plugin-sdk" },
{ name = "nodedc-bim-module", path = "vendor/bim/nodedc_bim_module-0.1.2-py3-none-any.whl" },
{ name = "nodedc-bim-module", path = "vendor/bim/nodedc_bim_module-0.1.3-py3-none-any.whl" },
{ name = "paho-mqtt", specifier = ">=2.1,<3" },
{ name = "pillow", specifier = ">=12,<13" },
{ name = "pyyaml", specifier = ">=6.0,<7" },
+4 -2
View File
@@ -2,8 +2,8 @@
Immutable packages from the independent [NODEDC_BIM_MOD](https://git.dcserve.ru/dctouch/NODEDC_BIM_MOD) repository:
- Python host services 0.1.2: `release.json`, wheel, `uv.lock` integrity.
- Browser workspace 0.1.7: `client-release.json`, npm tarball, Control Station lockfile integrity. Runtime workers and third-party notices are included in the tarball.
- Python host services 0.1.3: `release.json`, wheel, `uv.lock` integrity.
- Browser workspace 0.1.8: `client-release.json`, npm tarball, Control Station lockfile integrity. Runtime workers and third-party notices are included in the tarball.
Core consumes these versioned artifacts without importing a sibling checkout or copying the domain implementation. Update through a new module release, identity review and host qualification. The Worker image and durable data volume remain on Worker 006. Private connection settings and service tokens are never part of these releases.
@@ -12,3 +12,5 @@ See [integration and qualification](../../docs/BIM_MODULE.md) for the accepted s
The retained 0.1.0/0.1.1 artifacts identify the previous qualified release. New project documents may include `address`; reverting host code requires an explicit compatible document migration, not merely replacing the wheel. Current workspace map settings are host-owned `meta.json`.
Full-version deletion requires Worker 0.1.2 or later. Do not roll back to an implementation without deletion journals while retirement is pending; retain the durable journals and deploy a compatible forward fix. Local-copy eviction is still separate.
Viewer preferences include new fields; host 0.1.2 cannot parse them. Keep host 0.1.3 when reverting a client instead of discarding durable meta.json. Worker remains 0.1.2.
+10 -6
View File
@@ -1,12 +1,16 @@
{
"schema_version": "missioncore.bim-client-release/v1",
"repository": "https://git.dcserve.ru/dctouch/NODEDC_BIM_MOD",
"source_commit": "a097fb46df57489ac8ca46e46798d254721b661e",
"package": "nodedc-bim-viewer-0.1.7.tgz",
"sha256": "4bc3013e70cfa55e91bde997a23d27a5ac78ff221d21067a1a5aac75f531acef",
"source_commit": "6b27a1ac9b91387c30c0b3bfbfd9653a6259c0e9",
"package": "nodedc-bim-viewer-0.1.8.tgz",
"sha256": "9a71be57051b06070e7089ecacb67548dc6acc811e1b8cc2f40393efa0a51d76",
"types": "pass",
"contract_tests": 14,
"visual_acceptance": "PASS: three-level entry rows, latest group eye, 1280/700 layout, individual glass controls; live full deletion and Core restart",
"contract_tests": 24,
"visual_acceptance": "pass: current-project IFC tree, scene/tree selection, information/volume, isolation, measurements, section, projection, shared docking/settings, fullscreen buttons and 700px layout",
"evidence": "docs/BIM_MODULE.md",
"qualification_date": "2026-11-14"
"qualification_date": "2026-11-14",
"design_guideline_commit": "616ec9160a4cdc6d1482f259bc55193a0b391b4c",
"core_frontend_tests": 1603,
"core_frontend_failures": 0,
"validation_context": "shared canonical working checkout; unrelated concurrent edits preserved"
}
Binary file not shown.
Binary file not shown.
+5 -5
View File
@@ -1,10 +1,10 @@
{
"schema_version": "missioncore.bim-release/v1",
"repository": "https://git.dcserve.ru/dctouch/NODEDC_BIM_MOD",
"source_commit": "08538ed7a78f1d6e880efe0cd375d9eee9c90df8",
"package": "nodedc_bim_module-0.1.2-py3-none-any.whl",
"sha256": "453b9176415baa1f91b49d76b7cdd3610ea0ae0dc715e8557aadabaa2745639d",
"python_tests": 77,
"source_commit": "d0f2eb3c7304f697e0061f15906e098876c3096c",
"package": "nodedc_bim_module-0.1.3-py3-none-any.whl",
"sha256": "90b2797e2bf028113b46c3c0c38ff374d64220be4e63941957700963daa4be16",
"python_tests": 82,
"node_reader_tests": 1,
"scope": "portable host, workspace metadata and durable full-version deletion"
"scope": "host map/viewer preferences and durable deletion; Worker protocol unchanged"
}