@ifc-lite/bcf 1.6.1 → 1.8.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.
- package/README.md +42 -0
- package/dist/ids-reporter.d.ts +125 -0
- package/dist/ids-reporter.d.ts.map +1 -0
- package/dist/ids-reporter.js +435 -0
- package/dist/ids-reporter.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# @ifc-lite/bcf
|
|
2
|
+
|
|
3
|
+
BIM Collaboration Format (BCF) support for IFClite. Implements BCF 2.1 and 3.0 specifications for issue tracking in BIM projects.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @ifc-lite/bcf
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Quick Start
|
|
12
|
+
|
|
13
|
+
```typescript
|
|
14
|
+
import { readBCF, createBCFProject, createBCFTopic, addTopicToProject, writeBCF } from '@ifc-lite/bcf';
|
|
15
|
+
|
|
16
|
+
// Read a BCF file
|
|
17
|
+
const project = await readBCF(bcfBuffer);
|
|
18
|
+
|
|
19
|
+
// Or create a new project
|
|
20
|
+
const newProject = createBCFProject({ name: 'My Review', version: '2.1' });
|
|
21
|
+
const topic = createBCFTopic({ title: 'Missing fire rating', author: 'user@example.com' });
|
|
22
|
+
addTopicToProject(newProject, topic);
|
|
23
|
+
|
|
24
|
+
// Export (returns Blob)
|
|
25
|
+
const blob = await writeBCF(newProject);
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Features
|
|
29
|
+
|
|
30
|
+
- Read/write BCF 2.1 and 3.0 files
|
|
31
|
+
- Topics, comments, and viewpoints
|
|
32
|
+
- Camera state conversion (viewer <-> BCF format)
|
|
33
|
+
- IFC GlobalId <-> UUID conversion utilities
|
|
34
|
+
- Component visibility and selection in viewpoints
|
|
35
|
+
|
|
36
|
+
## API
|
|
37
|
+
|
|
38
|
+
See the [BCF Guide](../../docs/guide/bcf.md) and [API Reference](../../docs/api/typescript.md#ifc-litebcf).
|
|
39
|
+
|
|
40
|
+
## License
|
|
41
|
+
|
|
42
|
+
[MPL-2.0](../../LICENSE)
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* IDS (Information Delivery Specification) to BCF Reporter
|
|
3
|
+
*
|
|
4
|
+
* Creates BCF projects from IDS validation results, generating one topic
|
|
5
|
+
* per failing entity with failure details as comments and viewpoints that
|
|
6
|
+
* isolate and select the failing element.
|
|
7
|
+
*
|
|
8
|
+
* This is a pure function with no viewer/React dependencies — it can be
|
|
9
|
+
* used headlessly (CLI, server-side, tests) as well as from the viewer.
|
|
10
|
+
*
|
|
11
|
+
* Inspired by IfcOpenShell's ifctester BCF reporter, but improved:
|
|
12
|
+
* - Groups failures per entity (not per requirement×entity) to avoid topic flood
|
|
13
|
+
* - Uses comments for requirement details instead of cramming into title
|
|
14
|
+
* - Isolates the failing element (defaultVisibility=false)
|
|
15
|
+
* - Colors the failing element red
|
|
16
|
+
* - Sets topic metadata (type, status, priority, labels)
|
|
17
|
+
* - Configurable grouping strategies
|
|
18
|
+
*/
|
|
19
|
+
import type { BCFProject } from './types.js';
|
|
20
|
+
/** Input for the BCF reporter — structurally matches IDSValidationReport */
|
|
21
|
+
export interface IDSReportInput {
|
|
22
|
+
/** IDS document title */
|
|
23
|
+
title: string;
|
|
24
|
+
/** Optional IDS document description */
|
|
25
|
+
description?: string;
|
|
26
|
+
/** Results per specification */
|
|
27
|
+
specificationResults: IDSSpecResultInput[];
|
|
28
|
+
}
|
|
29
|
+
/** Specification result — structurally matches IDSSpecificationResult */
|
|
30
|
+
export interface IDSSpecResultInput {
|
|
31
|
+
specification: {
|
|
32
|
+
name: string;
|
|
33
|
+
description?: string;
|
|
34
|
+
};
|
|
35
|
+
status: 'pass' | 'fail' | 'not_applicable';
|
|
36
|
+
applicableCount: number;
|
|
37
|
+
passedCount: number;
|
|
38
|
+
failedCount: number;
|
|
39
|
+
entityResults: IDSEntityResultInput[];
|
|
40
|
+
}
|
|
41
|
+
/** Entity result — structurally matches IDSEntityResult */
|
|
42
|
+
export interface IDSEntityResultInput {
|
|
43
|
+
expressId: number;
|
|
44
|
+
modelId: string;
|
|
45
|
+
entityType: string;
|
|
46
|
+
entityName?: string;
|
|
47
|
+
globalId?: string;
|
|
48
|
+
passed: boolean;
|
|
49
|
+
requirementResults: IDSRequirementResultInput[];
|
|
50
|
+
}
|
|
51
|
+
/** Bounds for an entity — used for camera computation in viewpoints (Y-up viewer coords) */
|
|
52
|
+
export interface EntityBoundsInput {
|
|
53
|
+
min: {
|
|
54
|
+
x: number;
|
|
55
|
+
y: number;
|
|
56
|
+
z: number;
|
|
57
|
+
};
|
|
58
|
+
max: {
|
|
59
|
+
x: number;
|
|
60
|
+
y: number;
|
|
61
|
+
z: number;
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
/** Requirement result — structurally matches IDSRequirementResult */
|
|
65
|
+
export interface IDSRequirementResultInput {
|
|
66
|
+
status: 'pass' | 'fail' | 'not_applicable';
|
|
67
|
+
facetType: string;
|
|
68
|
+
checkedDescription: string;
|
|
69
|
+
failureReason?: string;
|
|
70
|
+
actualValue?: string;
|
|
71
|
+
expectedValue?: string;
|
|
72
|
+
}
|
|
73
|
+
/** Options for the BCF IDS export */
|
|
74
|
+
export interface IDSBCFExportOptions {
|
|
75
|
+
/** Author email for BCF topics (default: "ids-validator@ifc-lite") */
|
|
76
|
+
author?: string;
|
|
77
|
+
/** Project name (default: IDS document title) */
|
|
78
|
+
projectName?: string;
|
|
79
|
+
/** BCF version (default: "2.1") */
|
|
80
|
+
version?: '2.1' | '3.0';
|
|
81
|
+
/**
|
|
82
|
+
* Topic grouping strategy:
|
|
83
|
+
* - "per-entity": One topic per failing entity, requirements as comments (default)
|
|
84
|
+
* - "per-specification": One topic per failing specification, entities as comments
|
|
85
|
+
* - "per-requirement": One topic per (specification, requirement, entity) — like IfcOpenShell
|
|
86
|
+
*/
|
|
87
|
+
topicGrouping?: 'per-entity' | 'per-specification' | 'per-requirement';
|
|
88
|
+
/** Include passing entities as Info topics (default: false) */
|
|
89
|
+
includePassingEntities?: boolean;
|
|
90
|
+
/** Topic type for failures (default: "Error") */
|
|
91
|
+
failureTopicType?: string;
|
|
92
|
+
/** Topic type for passes (default: "Info") */
|
|
93
|
+
passTopicType?: string;
|
|
94
|
+
/** Maximum topics to create — safety valve for large models (default: 1000) */
|
|
95
|
+
maxTopics?: number;
|
|
96
|
+
/** ARGB hex color for failing elements in viewpoints (default: "FFFF3333" — red) */
|
|
97
|
+
failureColor?: string;
|
|
98
|
+
/**
|
|
99
|
+
* Entity bounds map for computing per-entity camera positions.
|
|
100
|
+
* Key: "modelId:expressId", Value: bounding box in viewer Y-up coordinates.
|
|
101
|
+
* When provided, viewpoints will include a perspective camera framing the entity.
|
|
102
|
+
*/
|
|
103
|
+
entityBounds?: Map<string, EntityBoundsInput>;
|
|
104
|
+
/**
|
|
105
|
+
* Entity snapshot map for attaching screenshots to viewpoints.
|
|
106
|
+
* Key: "modelId:expressId", Value: data URL (PNG).
|
|
107
|
+
* When provided, viewpoints will include the snapshot image.
|
|
108
|
+
*/
|
|
109
|
+
entitySnapshots?: Map<string, string>;
|
|
110
|
+
}
|
|
111
|
+
/**
|
|
112
|
+
* Create a BCF project from IDS validation results.
|
|
113
|
+
*
|
|
114
|
+
* Each failing entity becomes a BCF topic with:
|
|
115
|
+
* - Title: "{EntityType}: {EntityName}"
|
|
116
|
+
* - Description: specification context + failure summary
|
|
117
|
+
* - Comments: one per failed requirement with full details
|
|
118
|
+
* - Viewpoint: entity selected, isolated, colored red
|
|
119
|
+
*
|
|
120
|
+
* @param report - IDS validation results
|
|
121
|
+
* @param options - Export configuration
|
|
122
|
+
* @returns BCF project ready for writeBCF()
|
|
123
|
+
*/
|
|
124
|
+
export declare function createBCFFromIDSReport(report: IDSReportInput, options?: IDSBCFExportOptions): BCFProject;
|
|
125
|
+
//# sourceMappingURL=ids-reporter.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ids-reporter.d.ts","sourceRoot":"","sources":["../src/ids-reporter.ts"],"names":[],"mappings":"AAIA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EAAE,UAAU,EAA4D,MAAM,YAAY,CAAC;AAsDvG,4EAA4E;AAC5E,MAAM,WAAW,cAAc;IAC7B,yBAAyB;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,wCAAwC;IACxC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,gCAAgC;IAChC,oBAAoB,EAAE,kBAAkB,EAAE,CAAC;CAC5C;AAED,yEAAyE;AACzE,MAAM,WAAW,kBAAkB;IACjC,aAAa,EAAE;QACb,IAAI,EAAE,MAAM,CAAC;QACb,WAAW,CAAC,EAAE,MAAM,CAAC;KACtB,CAAC;IACF,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,gBAAgB,CAAC;IAC3C,eAAe,EAAE,MAAM,CAAC;IACxB,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,aAAa,EAAE,oBAAoB,EAAE,CAAC;CACvC;AAED,2DAA2D;AAC3D,MAAM,WAAW,oBAAoB;IACnC,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,OAAO,CAAC;IAChB,kBAAkB,EAAE,yBAAyB,EAAE,CAAC;CACjD;AAED,4FAA4F;AAC5F,MAAM,WAAW,iBAAiB;IAChC,GAAG,EAAE;QAAE,CAAC,EAAE,MAAM,CAAC;QAAC,CAAC,EAAE,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AM,EAAE,cAAc,EACtB,OAAO,GAAE,mBAAwB,GAChC,UAAU,CAqDZ"}
|
|
@@ -0,0 +1,435 @@
|
|
|
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 { generateUuid } from './guid.js';
|
|
5
|
+
// ============================================================================
|
|
6
|
+
// Internal BCF helpers (avoiding index.js import to prevent jszip dependency)
|
|
7
|
+
// ============================================================================
|
|
8
|
+
function createProject(name, version) {
|
|
9
|
+
return {
|
|
10
|
+
version,
|
|
11
|
+
projectId: generateUuid(),
|
|
12
|
+
name,
|
|
13
|
+
topics: new Map(),
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
function createTopic(opts) {
|
|
17
|
+
return {
|
|
18
|
+
guid: generateUuid(),
|
|
19
|
+
title: opts.title,
|
|
20
|
+
description: opts.description,
|
|
21
|
+
topicType: opts.topicType ?? 'Issue',
|
|
22
|
+
topicStatus: opts.topicStatus ?? 'Open',
|
|
23
|
+
priority: opts.priority,
|
|
24
|
+
creationDate: new Date().toISOString(),
|
|
25
|
+
creationAuthor: opts.author,
|
|
26
|
+
labels: opts.labels,
|
|
27
|
+
comments: [],
|
|
28
|
+
viewpoints: [],
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
function createComment(opts) {
|
|
32
|
+
return {
|
|
33
|
+
guid: generateUuid(),
|
|
34
|
+
date: new Date().toISOString(),
|
|
35
|
+
author: opts.author,
|
|
36
|
+
comment: opts.comment,
|
|
37
|
+
viewpointGuid: opts.viewpointGuid,
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
// ============================================================================
|
|
41
|
+
// Constants
|
|
42
|
+
// ============================================================================
|
|
43
|
+
const DEFAULT_AUTHOR = 'ids-validator@ifc-lite';
|
|
44
|
+
const DEFAULT_MAX_TOPICS = 1000;
|
|
45
|
+
const DEFAULT_FAILURE_COLOR = 'FFFF3333'; // Semi-opaque red
|
|
46
|
+
const DEFAULT_FAILURE_TOPIC_TYPE = 'Error';
|
|
47
|
+
const DEFAULT_PASS_TOPIC_TYPE = 'Info';
|
|
48
|
+
/**
|
|
49
|
+
* Max comments per topic in per-specification grouping.
|
|
50
|
+
* Prevents oversized topics when a spec fails hundreds of entities.
|
|
51
|
+
* Remaining entities are summarized with a "... and N more" comment.
|
|
52
|
+
*/
|
|
53
|
+
const MAX_COMMENTS_PER_TOPIC = 50;
|
|
54
|
+
// ============================================================================
|
|
55
|
+
// Main export function
|
|
56
|
+
// ============================================================================
|
|
57
|
+
/**
|
|
58
|
+
* Create a BCF project from IDS validation results.
|
|
59
|
+
*
|
|
60
|
+
* Each failing entity becomes a BCF topic with:
|
|
61
|
+
* - Title: "{EntityType}: {EntityName}"
|
|
62
|
+
* - Description: specification context + failure summary
|
|
63
|
+
* - Comments: one per failed requirement with full details
|
|
64
|
+
* - Viewpoint: entity selected, isolated, colored red
|
|
65
|
+
*
|
|
66
|
+
* @param report - IDS validation results
|
|
67
|
+
* @param options - Export configuration
|
|
68
|
+
* @returns BCF project ready for writeBCF()
|
|
69
|
+
*/
|
|
70
|
+
export function createBCFFromIDSReport(report, options = {}) {
|
|
71
|
+
const { author = DEFAULT_AUTHOR, projectName, version = '2.1', topicGrouping = 'per-entity', includePassingEntities = false, failureTopicType = DEFAULT_FAILURE_TOPIC_TYPE, passTopicType = DEFAULT_PASS_TOPIC_TYPE, maxTopics = DEFAULT_MAX_TOPICS, failureColor = DEFAULT_FAILURE_COLOR, entityBounds, entitySnapshots, } = options;
|
|
72
|
+
const project = createProject(projectName ?? report.title, version);
|
|
73
|
+
switch (topicGrouping) {
|
|
74
|
+
case 'per-entity':
|
|
75
|
+
buildTopicsPerEntity(project, report, {
|
|
76
|
+
author,
|
|
77
|
+
includePassingEntities,
|
|
78
|
+
failureTopicType,
|
|
79
|
+
passTopicType,
|
|
80
|
+
maxTopics,
|
|
81
|
+
failureColor,
|
|
82
|
+
entityBounds,
|
|
83
|
+
entitySnapshots,
|
|
84
|
+
});
|
|
85
|
+
break;
|
|
86
|
+
case 'per-specification':
|
|
87
|
+
buildTopicsPerSpecification(project, report, {
|
|
88
|
+
author,
|
|
89
|
+
failureTopicType,
|
|
90
|
+
maxTopics,
|
|
91
|
+
failureColor,
|
|
92
|
+
entityBounds,
|
|
93
|
+
entitySnapshots,
|
|
94
|
+
});
|
|
95
|
+
break;
|
|
96
|
+
case 'per-requirement':
|
|
97
|
+
buildTopicsPerRequirement(project, report, {
|
|
98
|
+
author,
|
|
99
|
+
failureTopicType,
|
|
100
|
+
maxTopics,
|
|
101
|
+
failureColor,
|
|
102
|
+
entityBounds,
|
|
103
|
+
entitySnapshots,
|
|
104
|
+
});
|
|
105
|
+
break;
|
|
106
|
+
}
|
|
107
|
+
return project;
|
|
108
|
+
}
|
|
109
|
+
function buildTopicsPerEntity(project, report, opts) {
|
|
110
|
+
let topicCount = 0;
|
|
111
|
+
for (const specResult of report.specificationResults) {
|
|
112
|
+
if (specResult.status === 'not_applicable')
|
|
113
|
+
continue;
|
|
114
|
+
for (const entity of specResult.entityResults) {
|
|
115
|
+
if (topicCount >= opts.maxTopics)
|
|
116
|
+
return;
|
|
117
|
+
// Skip passing entities unless requested
|
|
118
|
+
if (entity.passed && !opts.includePassingEntities)
|
|
119
|
+
continue;
|
|
120
|
+
const failedReqs = entity.requirementResults.filter(r => r.status === 'fail');
|
|
121
|
+
const totalReqs = entity.requirementResults.filter(r => r.status !== 'not_applicable').length;
|
|
122
|
+
const entityLabel = entity.entityName || `#${entity.expressId}`;
|
|
123
|
+
const isFailed = !entity.passed;
|
|
124
|
+
// Build topic
|
|
125
|
+
const topic = createTopic({
|
|
126
|
+
title: `${entity.entityType}: ${entityLabel}`,
|
|
127
|
+
description: buildEntityDescription(specResult, entity, failedReqs.length, totalReqs),
|
|
128
|
+
author: opts.author,
|
|
129
|
+
topicType: isFailed ? opts.failureTopicType : (opts.passTopicType ?? DEFAULT_PASS_TOPIC_TYPE),
|
|
130
|
+
topicStatus: isFailed ? 'Open' : 'Closed',
|
|
131
|
+
priority: isFailed ? (failedReqs.length === totalReqs ? 'High' : 'Medium') : undefined,
|
|
132
|
+
labels: ['IDS', specResult.specification.name],
|
|
133
|
+
});
|
|
134
|
+
// Add viewpoint with isolation + selection + coloring + optional camera/snapshot
|
|
135
|
+
// Viewpoint MUST be created first so comments can reference it via viewpointGuid
|
|
136
|
+
let viewpointGuid;
|
|
137
|
+
if (entity.globalId) {
|
|
138
|
+
const boundsKey = `${entity.modelId}:${entity.expressId}`;
|
|
139
|
+
const bounds = opts.entityBounds?.get(boundsKey);
|
|
140
|
+
const snapshot = opts.entitySnapshots?.get(boundsKey);
|
|
141
|
+
const viewpoint = buildEntityViewpoint(entity.globalId, isFailed ? opts.failureColor : undefined, bounds, snapshot);
|
|
142
|
+
topic.viewpoints.push(viewpoint);
|
|
143
|
+
viewpointGuid = viewpoint.guid;
|
|
144
|
+
}
|
|
145
|
+
// Add a comment per failed requirement, linked to the viewpoint
|
|
146
|
+
for (const req of failedReqs) {
|
|
147
|
+
const comment = createComment({
|
|
148
|
+
author: opts.author,
|
|
149
|
+
comment: buildRequirementComment(req),
|
|
150
|
+
viewpointGuid,
|
|
151
|
+
});
|
|
152
|
+
topic.comments.push(comment);
|
|
153
|
+
}
|
|
154
|
+
project.topics.set(topic.guid, topic);
|
|
155
|
+
topicCount++;
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
// ============================================================================
|
|
160
|
+
// Per-specification grouping
|
|
161
|
+
// ============================================================================
|
|
162
|
+
function buildTopicsPerSpecification(project, report, opts) {
|
|
163
|
+
let topicCount = 0;
|
|
164
|
+
for (const specResult of report.specificationResults) {
|
|
165
|
+
if (specResult.status !== 'fail')
|
|
166
|
+
continue;
|
|
167
|
+
if (topicCount >= opts.maxTopics)
|
|
168
|
+
return;
|
|
169
|
+
const failedEntities = specResult.entityResults.filter(e => !e.passed);
|
|
170
|
+
const topic = createTopic({
|
|
171
|
+
title: `[FAIL] ${specResult.specification.name}`,
|
|
172
|
+
description: buildSpecDescription(specResult),
|
|
173
|
+
author: opts.author,
|
|
174
|
+
topicType: opts.failureTopicType,
|
|
175
|
+
topicStatus: 'Open',
|
|
176
|
+
priority: specResult.failedCount > specResult.passedCount ? 'High' : 'Medium',
|
|
177
|
+
labels: ['IDS', specResult.specification.name],
|
|
178
|
+
});
|
|
179
|
+
// Add viewpoint selecting all failed entities with globalIds (must be first for comment linking)
|
|
180
|
+
const failedGuids = failedEntities
|
|
181
|
+
.map(e => e.globalId)
|
|
182
|
+
.filter((g) => g !== undefined);
|
|
183
|
+
let viewpointGuid;
|
|
184
|
+
if (failedGuids.length > 0) {
|
|
185
|
+
const viewpoint = buildMultiEntityViewpoint(failedGuids, opts.failureColor);
|
|
186
|
+
topic.viewpoints.push(viewpoint);
|
|
187
|
+
viewpointGuid = viewpoint.guid;
|
|
188
|
+
}
|
|
189
|
+
// Add comments for failed entities (capped to avoid huge topics), linked to viewpoint
|
|
190
|
+
const maxCommentsPerTopic = MAX_COMMENTS_PER_TOPIC;
|
|
191
|
+
const entitiesToComment = failedEntities.slice(0, maxCommentsPerTopic);
|
|
192
|
+
for (const entity of entitiesToComment) {
|
|
193
|
+
const entityLabel = entity.entityName || `#${entity.expressId}`;
|
|
194
|
+
const failedReqs = entity.requirementResults.filter(r => r.status === 'fail');
|
|
195
|
+
const failureSummary = failedReqs
|
|
196
|
+
.map(r => r.failureReason ?? r.checkedDescription)
|
|
197
|
+
.join('; ');
|
|
198
|
+
const comment = createComment({
|
|
199
|
+
author: opts.author,
|
|
200
|
+
comment: `${entity.entityType}: ${entityLabel}${entity.globalId ? ` (${entity.globalId})` : ''}\n${failureSummary}`,
|
|
201
|
+
viewpointGuid,
|
|
202
|
+
});
|
|
203
|
+
topic.comments.push(comment);
|
|
204
|
+
}
|
|
205
|
+
if (failedEntities.length > maxCommentsPerTopic) {
|
|
206
|
+
const comment = createComment({
|
|
207
|
+
author: opts.author,
|
|
208
|
+
comment: `... and ${failedEntities.length - maxCommentsPerTopic} more failing entities`,
|
|
209
|
+
});
|
|
210
|
+
topic.comments.push(comment);
|
|
211
|
+
}
|
|
212
|
+
project.topics.set(topic.guid, topic);
|
|
213
|
+
topicCount++;
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
// ============================================================================
|
|
217
|
+
// Per-requirement grouping (like IfcOpenShell, but improved)
|
|
218
|
+
// ============================================================================
|
|
219
|
+
function buildTopicsPerRequirement(project, report, opts) {
|
|
220
|
+
let topicCount = 0;
|
|
221
|
+
for (const specResult of report.specificationResults) {
|
|
222
|
+
if (specResult.status !== 'fail')
|
|
223
|
+
continue;
|
|
224
|
+
for (const entity of specResult.entityResults) {
|
|
225
|
+
if (entity.passed)
|
|
226
|
+
continue;
|
|
227
|
+
for (const req of entity.requirementResults) {
|
|
228
|
+
if (req.status !== 'fail')
|
|
229
|
+
continue;
|
|
230
|
+
if (topicCount >= opts.maxTopics)
|
|
231
|
+
return;
|
|
232
|
+
const entityLabel = entity.entityName || `#${entity.expressId}`;
|
|
233
|
+
const topic = createTopic({
|
|
234
|
+
title: `${entity.entityType}: ${entityLabel} - ${req.failureReason ?? req.checkedDescription}`,
|
|
235
|
+
description: `Specification: ${specResult.specification.name}\n${specResult.specification.description ?? ''}\n\nRequirement: ${req.checkedDescription}${entity.globalId ? `\nGlobalId: ${entity.globalId}` : ''}`,
|
|
236
|
+
author: opts.author,
|
|
237
|
+
topicType: opts.failureTopicType,
|
|
238
|
+
topicStatus: 'Open',
|
|
239
|
+
labels: ['IDS', specResult.specification.name],
|
|
240
|
+
});
|
|
241
|
+
// Viewpoint for single entity (must be first for comment linking)
|
|
242
|
+
let viewpointGuid;
|
|
243
|
+
if (entity.globalId) {
|
|
244
|
+
const boundsKey = `${entity.modelId}:${entity.expressId}`;
|
|
245
|
+
const bounds = opts.entityBounds?.get(boundsKey);
|
|
246
|
+
const snapshot = opts.entitySnapshots?.get(boundsKey);
|
|
247
|
+
const viewpoint = buildEntityViewpoint(entity.globalId, opts.failureColor, bounds, snapshot);
|
|
248
|
+
topic.viewpoints.push(viewpoint);
|
|
249
|
+
viewpointGuid = viewpoint.guid;
|
|
250
|
+
}
|
|
251
|
+
// Single comment with full failure detail, linked to viewpoint
|
|
252
|
+
const comment = createComment({
|
|
253
|
+
author: opts.author,
|
|
254
|
+
comment: buildRequirementComment(req),
|
|
255
|
+
viewpointGuid,
|
|
256
|
+
});
|
|
257
|
+
topic.comments.push(comment);
|
|
258
|
+
project.topics.set(topic.guid, topic);
|
|
259
|
+
topicCount++;
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
}
|
|
264
|
+
// ============================================================================
|
|
265
|
+
// Helpers — Description builders
|
|
266
|
+
// ============================================================================
|
|
267
|
+
function buildEntityDescription(specResult, entity, failedCount, totalCount) {
|
|
268
|
+
const lines = [];
|
|
269
|
+
if (!entity.passed) {
|
|
270
|
+
lines.push(`IDS Validation Failure — ${failedCount} of ${totalCount} requirements failed`);
|
|
271
|
+
}
|
|
272
|
+
else {
|
|
273
|
+
lines.push('IDS Validation Passed — all requirements satisfied');
|
|
274
|
+
}
|
|
275
|
+
lines.push('');
|
|
276
|
+
lines.push(`Specification: ${specResult.specification.name}`);
|
|
277
|
+
if (specResult.specification.description) {
|
|
278
|
+
lines.push(`Description: ${specResult.specification.description}`);
|
|
279
|
+
}
|
|
280
|
+
lines.push(`Entity Type: ${entity.entityType}`);
|
|
281
|
+
if (entity.globalId) {
|
|
282
|
+
lines.push(`GlobalId: ${entity.globalId}`);
|
|
283
|
+
}
|
|
284
|
+
if (entity.entityName) {
|
|
285
|
+
lines.push(`Name: ${entity.entityName}`);
|
|
286
|
+
}
|
|
287
|
+
return lines.join('\n');
|
|
288
|
+
}
|
|
289
|
+
function buildSpecDescription(specResult) {
|
|
290
|
+
const lines = [];
|
|
291
|
+
lines.push(`IDS Specification Failure — ${specResult.failedCount} of ${specResult.applicableCount} entities failed`);
|
|
292
|
+
if (specResult.specification.description) {
|
|
293
|
+
lines.push('');
|
|
294
|
+
lines.push(specResult.specification.description);
|
|
295
|
+
}
|
|
296
|
+
lines.push('');
|
|
297
|
+
lines.push(`Applicable: ${specResult.applicableCount}`);
|
|
298
|
+
lines.push(`Passed: ${specResult.passedCount}`);
|
|
299
|
+
lines.push(`Failed: ${specResult.failedCount}`);
|
|
300
|
+
return lines.join('\n');
|
|
301
|
+
}
|
|
302
|
+
function buildRequirementComment(req) {
|
|
303
|
+
const lines = [];
|
|
304
|
+
lines.push(`[${req.facetType}] ${req.checkedDescription}`);
|
|
305
|
+
if (req.failureReason) {
|
|
306
|
+
lines.push(`Failure: ${req.failureReason}`);
|
|
307
|
+
}
|
|
308
|
+
if (req.expectedValue) {
|
|
309
|
+
lines.push(`Expected: ${req.expectedValue}`);
|
|
310
|
+
}
|
|
311
|
+
if (req.actualValue) {
|
|
312
|
+
lines.push(`Actual: ${req.actualValue}`);
|
|
313
|
+
}
|
|
314
|
+
return lines.join('\n');
|
|
315
|
+
}
|
|
316
|
+
// ============================================================================
|
|
317
|
+
// Helpers — Camera computation
|
|
318
|
+
// ============================================================================
|
|
319
|
+
/**
|
|
320
|
+
* Compute a BCF perspective camera from entity bounds.
|
|
321
|
+
*
|
|
322
|
+
* Bounds are in viewer coordinates (Y-up).
|
|
323
|
+
* BCF uses Z-up, so we convert:
|
|
324
|
+
* BCF.x = Viewer.x
|
|
325
|
+
* BCF.y = -Viewer.z
|
|
326
|
+
* BCF.z = Viewer.y
|
|
327
|
+
*
|
|
328
|
+
* Camera is placed at a southeast-isometric angle from the entity center,
|
|
329
|
+
* at a distance that frames the entity's bounding box with padding.
|
|
330
|
+
*/
|
|
331
|
+
function computeCameraFromBounds(bounds) {
|
|
332
|
+
// Center in viewer coords (Y-up)
|
|
333
|
+
const cx = (bounds.min.x + bounds.max.x) / 2;
|
|
334
|
+
const cy = (bounds.min.y + bounds.max.y) / 2;
|
|
335
|
+
const cz = (bounds.min.z + bounds.max.z) / 2;
|
|
336
|
+
// Max extent for framing distance
|
|
337
|
+
const sx = bounds.max.x - bounds.min.x;
|
|
338
|
+
const sy = bounds.max.y - bounds.min.y;
|
|
339
|
+
const sz = bounds.max.z - bounds.min.z;
|
|
340
|
+
const maxSize = Math.max(sx, sy, sz, 0.1); // Floor to avoid zero
|
|
341
|
+
// Camera distance: fit maxSize into 60deg FOV with 1.5x padding
|
|
342
|
+
const fovRad = (60 * Math.PI) / 180;
|
|
343
|
+
const distance = (maxSize / 2) / Math.tan(fovRad / 2) * 1.5;
|
|
344
|
+
// Southeast-isometric offset in viewer coords (Y-up):
|
|
345
|
+
// camera position = center + normalized(0.6, 0.5, 0.6) * distance
|
|
346
|
+
const offsetLen = Math.sqrt(0.6 * 0.6 + 0.5 * 0.5 + 0.6 * 0.6);
|
|
347
|
+
const ox = (0.6 / offsetLen) * distance;
|
|
348
|
+
const oy = (0.5 / offsetLen) * distance;
|
|
349
|
+
const oz = (0.6 / offsetLen) * distance;
|
|
350
|
+
const camX = cx + ox;
|
|
351
|
+
const camY = cy + oy;
|
|
352
|
+
const camZ = cz + oz;
|
|
353
|
+
// Direction: from camera to center (viewer coords)
|
|
354
|
+
const dx = cx - camX;
|
|
355
|
+
const dy = cy - camY;
|
|
356
|
+
const dz = cz - camZ;
|
|
357
|
+
const dLen = Math.sqrt(dx * dx + dy * dy + dz * dz);
|
|
358
|
+
// Convert to BCF coords (Z-up)
|
|
359
|
+
// Viewer (x, y, z) → BCF (x, -z, y)
|
|
360
|
+
return {
|
|
361
|
+
cameraViewPoint: { x: camX, y: -camZ, z: camY },
|
|
362
|
+
cameraDirection: {
|
|
363
|
+
x: dx / dLen,
|
|
364
|
+
y: -dz / dLen,
|
|
365
|
+
z: dy / dLen,
|
|
366
|
+
},
|
|
367
|
+
cameraUpVector: { x: 0, y: 0, z: 1 }, // BCF Z-up
|
|
368
|
+
fieldOfView: 60,
|
|
369
|
+
};
|
|
370
|
+
}
|
|
371
|
+
// ============================================================================
|
|
372
|
+
// Helpers — Viewpoint builders
|
|
373
|
+
// ============================================================================
|
|
374
|
+
/**
|
|
375
|
+
* Build a viewpoint for a single entity: selected, isolated, colored.
|
|
376
|
+
* Optionally includes a perspective camera computed from entity bounds,
|
|
377
|
+
* and a snapshot image if provided.
|
|
378
|
+
*/
|
|
379
|
+
function buildEntityViewpoint(globalId, failureColor, bounds, snapshot) {
|
|
380
|
+
// Create independent component objects to prevent mutation side effects
|
|
381
|
+
const viewpoint = {
|
|
382
|
+
guid: generateUuid(),
|
|
383
|
+
components: {
|
|
384
|
+
selection: [{ ifcGuid: globalId }],
|
|
385
|
+
visibility: {
|
|
386
|
+
defaultVisibility: false,
|
|
387
|
+
exceptions: [{ ifcGuid: globalId }],
|
|
388
|
+
},
|
|
389
|
+
},
|
|
390
|
+
};
|
|
391
|
+
if (failureColor) {
|
|
392
|
+
viewpoint.components.coloring = [
|
|
393
|
+
{
|
|
394
|
+
color: failureColor,
|
|
395
|
+
components: [{ ifcGuid: globalId }],
|
|
396
|
+
},
|
|
397
|
+
];
|
|
398
|
+
}
|
|
399
|
+
// Compute camera from bounds (viewer Y-up → BCF Z-up)
|
|
400
|
+
if (bounds) {
|
|
401
|
+
viewpoint.perspectiveCamera = computeCameraFromBounds(bounds);
|
|
402
|
+
}
|
|
403
|
+
// Attach snapshot
|
|
404
|
+
if (snapshot) {
|
|
405
|
+
viewpoint.snapshot = snapshot;
|
|
406
|
+
}
|
|
407
|
+
return viewpoint;
|
|
408
|
+
}
|
|
409
|
+
/**
|
|
410
|
+
* Build a viewpoint for multiple entities: all selected and visible, colored.
|
|
411
|
+
* Used by per-specification grouping where one topic covers many entities.
|
|
412
|
+
*/
|
|
413
|
+
function buildMultiEntityViewpoint(globalIds, failureColor) {
|
|
414
|
+
// Use independent arrays per field to prevent mutation side effects
|
|
415
|
+
const viewpoint = {
|
|
416
|
+
guid: generateUuid(),
|
|
417
|
+
components: {
|
|
418
|
+
selection: globalIds.map(id => ({ ifcGuid: id })),
|
|
419
|
+
visibility: {
|
|
420
|
+
defaultVisibility: false,
|
|
421
|
+
exceptions: globalIds.map(id => ({ ifcGuid: id })),
|
|
422
|
+
},
|
|
423
|
+
},
|
|
424
|
+
};
|
|
425
|
+
if (failureColor) {
|
|
426
|
+
viewpoint.components.coloring = [
|
|
427
|
+
{
|
|
428
|
+
color: failureColor,
|
|
429
|
+
components: globalIds.map(id => ({ ifcGuid: id })),
|
|
430
|
+
},
|
|
431
|
+
];
|
|
432
|
+
}
|
|
433
|
+
return viewpoint;
|
|
434
|
+
}
|
|
435
|
+
//# sourceMappingURL=ids-reporter.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ids-reporter.js","sourceRoot":"","sources":["../src/ids-reporter.ts"],"names":[],"mappings":"AAAA;;+DAE+D;AAsB/D,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAEzC,+EAA+E;AAC/E,8EAA8E;AAC9E,+EAA+E;AAE/E,SAAS,aAAa,CAAC,IAAY,EAAE,OAAsB;IACzD,OAAO;QACL,OAAO;QACP,SAAS,EAAE,YAAY,EAAE;QACzB,IAAI;QACJ,MAAM,EAAE,IAAI,GAAG,EAAE;KAClB,CAAC;AACJ,CAAC;AAED,SAAS,WAAW,CAAC,IAQpB;IACC,OAAO;QACL,IAAI,EAAE,YAAY,EAAE;QACpB,KAAK,EAAE,IAAI,CAAC,KAAK;QACjB,WAAW,EAAE,IAAI,CAAC,WAAW;QAC7B,SAAS,EAAE,IAAI,CAAC,SAAS,IAAI,OAAO;QACpC,WAAW,EAAE,IAAI,CAAC,WAAW,IAAI,MAAM;QACvC,QAAQ,EAAE,IAAI,CAAC,QAAQ;QACvB,YAAY,EAAE,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE;QACtC,cAAc,EAAE,IAAI,CAAC,MAAM;QAC3B,MAAM,EAAE,IAAI,CAAC,MAAM;QACnB,QAAQ,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AACnB,CAAC;AAED;;;GAGG;AACH,SAAS,yBAAyB,CAChC,SAAmB,EACnB,YAAgC;IAEhC,oEAAoE;IACpE,MAAM,SAAS,GAAiB;QAC9B,IAAI,EAAE,YAAY,EAAE;QACpB,UAAU,EAAE;YACV,SAAS,EAAE,SAAS,CAAC,GAAG,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CAAC;YACjD,UAAU,EAAE;gBACV,iBAAiB,EAAE,KAAK;gBACxB,UAAU,EAAE,SAAS,CAAC,GAAG,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CAAC;aACnD;SACF;KACF,CAAC;IAEF,IAAI,YAAY,EAAE,CAAC;QACjB,SAAS,CAAC,UAAW,CAAC,QAAQ,GAAG;YAC/B;gBACE,KAAK,EAAE,YAAY;gBACnB,UAAU,EAAE,SAAS,CAAC,GAAG,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CAAC;aACnD;SACF,CAAC;IACJ,CAAC;IAED,OAAO,SAAS,CAAC;AACnB,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -13,6 +13,8 @@ export { readBCF } from './reader.js';
|
|
|
13
13
|
export { writeBCF } from './writer.js';
|
|
14
14
|
export type { ViewerCameraState, ViewerSectionPlane, ViewerBounds } from './viewpoint.js';
|
|
15
15
|
export { cameraToPerspective, cameraToOrthogonal, perspectiveToCamera, orthogonalToCamera, sectionPlaneToClippingPlane, clippingPlaneToSectionPlane, createViewpoint, extractViewpointState, } from './viewpoint.js';
|
|
16
|
+
export type { IDSReportInput, IDSSpecResultInput, IDSEntityResultInput, IDSRequirementResultInput, IDSBCFExportOptions, EntityBoundsInput, } from './ids-reporter.js';
|
|
17
|
+
export { createBCFFromIDSReport } from './ids-reporter.js';
|
|
16
18
|
import type { BCFProject, BCFTopic, BCFComment, BCFViewpoint } from './types.js';
|
|
17
19
|
/**
|
|
18
20
|
* Create a new empty BCF project
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAIA;;;;;;;;GAQG;AAGH,YAAY,EAEV,UAAU,EACV,aAAa,EACb,UAAU,EAEV,QAAQ,EACR,UAAU,EACV,aAAa,EACb,oBAAoB,EAEpB,YAAY,EACZ,oBAAoB,EACpB,mBAAmB,EACnB,QAAQ,EACR,YAAY,EAEZ,aAAa,EACb,YAAY,EACZ,aAAa,EACb,WAAW,EACX,iBAAiB,EAEjB,OAAO,EACP,gBAAgB,EAChB,SAAS,EAET,aAAa,GACd,MAAM,YAAY,CAAC;AAGpB,OAAO,EACL,aAAa,EACb,aAAa,EACb,eAAe,EACf,YAAY,EACZ,cAAc,EACd,WAAW,GACZ,MAAM,WAAW,CAAC;AAGnB,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAGtC,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAGvC,YAAY,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC1F,OAAO,EACL,mBAAmB,EACnB,kBAAkB,EAClB,mBAAmB,EACnB,kBAAkB,EAClB,2BAA2B,EAC3B,2BAA2B,EAC3B,eAAe,EACf,qBAAqB,GACtB,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAIA;;;;;;;;GAQG;AAGH,YAAY,EAEV,UAAU,EACV,aAAa,EACb,UAAU,EAEV,QAAQ,EACR,UAAU,EACV,aAAa,EACb,oBAAoB,EAEpB,YAAY,EACZ,oBAAoB,EACpB,mBAAmB,EACnB,QAAQ,EACR,YAAY,EAEZ,aAAa,EACb,YAAY,EACZ,aAAa,EACb,WAAW,EACX,iBAAi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AC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;CACnB,GAAG,QAAQ,CAgBX;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,OAAO,EAAE;IACxC,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB,GAAG,UAAU,CAQb;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,QAAQ,GAAG,IAAI,CAE5E;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,QAAQ,EAAE,OAAO,EAAE,UAAU,GAAG,IAAI,CAG5E;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,YAAY,GAAG,IAAI,CAGlF;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,QAAQ,EACf,MAAM,EAAE,MAAM,EACd,cAAc,EAAE,MAAM,GACrB,IAAI,CAIN;AAED;;;GAGG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG;IAC5C,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;CACX,CAmBA;AAED;;GAEG;AACH,wBAAgB,WAAW,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,SAAM,GAAG,MAAM,CAG5E"}
|
package/dist/index.js
CHANGED
|
@@ -8,6 +8,7 @@ export { readBCF } from './reader.js';
|
|
|
8
8
|
// Writer
|
|
9
9
|
export { writeBCF } from './writer.js';
|
|
10
10
|
export { cameraToPerspective, cameraToOrthogonal, perspectiveToCamera, orthogonalToCamera, sectionPlaneToClippingPlane, clippingPlaneToSectionPlane, createViewpoint, extractViewpointState, } from './viewpoint.js';
|
|
11
|
+
export { createBCFFromIDSReport } from './ids-reporter.js';
|
|
11
12
|
import { generateUuid } from './guid.js';
|
|
12
13
|
/**
|
|
13
14
|
* Create a new empty BCF project
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;+DAE+D;AA2C/D,iBAAiB;AACjB,OAAO,EACL,aAAa,EACb,aAAa,EACb,eAAe,EACf,YAAY,EACZ,cAAc,EACd,WAAW,GACZ,MAAM,WAAW,CAAC;AAEnB,SAAS;AACT,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAEtC,SAAS;AACT,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAIvC,OAAO,EACL,mBAAmB,EACnB,kBAAkB,EAClB,mBAAmB,EACnB,kBAAkB,EAClB,2BAA2B,EAC3B,2BAA2B,EAC3B,eAAe,EACf,qBAAqB,GACtB,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;+DAE+D;AA2C/D,iBAAiB;AACjB,OAAO,EACL,aAAa,EACb,aAAa,EACb,eAAe,EACf,YAAY,EACZ,cAAc,EACd,WAAW,GACZ,MAAM,WAAW,CAAC;AAEnB,SAAS;AACT,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAEtC,SAAS;AACT,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAIvC,OAAO,EACL,mBAAmB,EACnB,kBAAkB,EAClB,mBAAmB,EACnB,kBAAkB,EAClB,2BAA2B,EAC3B,2BAA2B,EAC3B,eAAe,EACf,qBAAqB,GACtB,MAAM,gBAAgB,CAAC;AAWxB,OAAO,EAAE,sBAAsB,EAAE,MAAM,mBAAmB,CAAC;AAO3D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