@thatopen/components 3.2.1 → 3.2.3

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/dist/index.cjs CHANGED
@@ -3328,6 +3328,10 @@ const _FragmentsManager = class _FragmentsManager extends Component {
3328
3328
  const model = this.list.get(modelId);
3329
3329
  if (!model)
3330
3330
  continue;
3331
+ if (localIds.size === 0) {
3332
+ result[modelId] = [];
3333
+ continue;
3334
+ }
3331
3335
  const data = await model.getItemsData([...localIds], config);
3332
3336
  result[modelId] = data;
3333
3337
  }
@@ -3499,6 +3503,10 @@ const _IfcLoader = class _IfcLoader extends Component {
3499
3503
  * An event triggered when the IFC file starts loading.
3500
3504
  */
3501
3505
  __publicField(this, "onIfcStartedLoading", new Event());
3506
+ /**
3507
+ * An event triggered when the IFC importer is initialized.
3508
+ */
3509
+ __publicField(this, "onIfcImporterInitialized", new Event());
3502
3510
  /**
3503
3511
  * An event triggered when the setup process is completed.
3504
3512
  */
@@ -3576,6 +3584,7 @@ const _IfcLoader = class _IfcLoader extends Component {
3576
3584
  serializer.wasm.path = this.settings.wasm.path;
3577
3585
  serializer.wasm.absolute = this.settings.wasm.absolute;
3578
3586
  serializer.webIfcSettings = this.settings.webIfc;
3587
+ this.onIfcImporterInitialized.trigger(serializer);
3579
3588
  if (config == null ? void 0 : config.instanceCallback)
3580
3589
  config.instanceCallback(serializer);
3581
3590
  const bytes = await serializer.process({
@@ -20982,6 +20991,7 @@ const _IDSSpecifications = class _IDSSpecifications extends Component {
20982
20991
  constructor(components) {
20983
20992
  super(components);
20984
20993
  __publicField(this, "enabled", true);
20994
+ __publicField(this, "IDSInfo");
20985
20995
  __publicField(this, "list", new DataMap());
20986
20996
  components.add(_IDSSpecifications.uuid, this);
20987
20997
  }
@@ -21037,7 +21047,8 @@ const _IDSSpecifications = class _IDSSpecifications extends Component {
21037
21047
  load(data, config = { parseNumericString: true }) {
21038
21048
  const result = [];
21039
21049
  const ids = _IDSSpecifications.xmlParser.parse(data).ids;
21040
- const { specifications } = ids;
21050
+ const { specifications, info } = ids;
21051
+ this.IDSInfo = { ...info };
21041
21052
  if (specifications && specifications.specification) {
21042
21053
  const specs = Array.isArray(specifications.specification) ? specifications.specification : [specifications.specification];
21043
21054
  for (const spec of specs) {
package/dist/index.d.ts CHANGED
@@ -2153,6 +2153,7 @@ export declare class IDSSpecifications extends Component {
2153
2153
  static uuid: "9f0b9f78-9b2e-481a-b766-2fbfd01f342c";
2154
2154
  enabled: boolean;
2155
2155
  static xmlParser: XMLParser;
2156
+ IDSInfo?: IDSInfo;
2156
2157
  constructor(components: Components);
2157
2158
  readonly list: DataMap<string, IDSSpecification>;
2158
2159
  /**
@@ -2243,6 +2244,10 @@ export declare class IfcLoader extends Component implements Disposable_2 {
2243
2244
  * An event triggered when the IFC file starts loading.
2244
2245
  */
2245
2246
  readonly onIfcStartedLoading: Event_2<void>;
2247
+ /**
2248
+ * An event triggered when the IFC importer is initialized.
2249
+ */
2250
+ readonly onIfcImporterInitialized: Event_2<FRAGS.IfcImporter>;
2246
2251
  /**
2247
2252
  * An event triggered when the setup process is completed.
2248
2253
  */