1.5.0 Change Notes
Upgrade to TypeScript 3.6.2
- This version now uses TypeScript version 3.6.2. It is recommended that consumers of iModel.js packages upgrade to that version too.
Display system enhancements
Performance enhancements
- Made display system enhancement for rendering directly to screen. This significantly improves performance on iOS and some non-Chrome browsers. For models that aren't bound by primitive count, this can be a more than doubling of FPS.
- To enable this enhancement, see
RenderSystem.Options.directScreenRendering.
- To enable this enhancement, see
Blank IModelConnections
- The new method
IModelConnection.createBlankprovides a way for applications to create anIModelConnectionthat is not connected to an iModel or a backend. This is useful for using iModel.js to show just Reality data (reality meshes, point clouds, terrain, etc.), background maps, and other non-iModel-based graphics without requiring a backend server. - There is also a new convenience method SpatialViewState.createBlank to create a blank spatial view appropriate for these non-iModel based visualizations. See the Blank Connection learning article for further details.
Favorite Properties
Summary
- Favorite properties manager stores favorite properties and determines whether a given field should be displayed as favorite.
PresentationPropertyDataProviderputs all favorite properties into an additional 'Favorite' category that's displayed at the top and is auto-expanded.
Details
FavoritePropertyManager(accessed through singletonPresentation.favoriteProperties) in@itwin/presentation-frontendadd(field: Field): void- For
PropertiesFieldandNestedContentField- marks all properties in the field as favorite. - For other types of fields - marks the field as favorite by its name.
- For
remove(field: Field): void- For
PropertiesFieldandNestedContentField- removes all properties in the field from favorites list. - For other types of fields - removes the field from favorites list.
- For
has(field: Field): boolean- For
PropertiesFieldandNestedContentField- returns true if field contains at least one favorite property. - For other types of fields - returns true if field's name is in the favorites list.
- For
onFavoritesChanged: BeEvent<() => void>- Event that's raised when favorite properties change.
ContentDataProvider(base ofPresentationPropertyDataProviderandPresentationTableDataProvider) in@itwin/presentation-componentsgetFieldByPropertyRecord(propertyRecord: PropertyRecord): Promise<Field | undefined>- Returns a field object that was used to create the given
PropertyRecord. The field contains meta-data about the properties whose values are stored in thePropertyRecord.
- Returns a field object that was used to create the given
Usage example
// needs to be called once before working with `Presentation` API
Presentation.initialize();
<...>
private _onAddFavorite = (propertyField: Field) => {
Presentation.favoriteProperties.add(propertyField);
this.setState({ contextMenu: undefined });
}
private _onRemoveFavorite = (propertyField: Field) => {
Presentation.favoriteProperties.remove(propertyField);
this.setState({ contextMenu: undefined });
}
private async buildContextMenu(args: PropertyGridContextMenuArgs) {
const field = await this.state.dataProvider.getFieldByPropertyRecord(args.propertyRecord);
const items: ContextMenuItemInfo[] = [];
if (field !== undefined) {
if (Presentation.favoriteProperties.has(field)) {
items.push({
key: "remove-favorite",
onSelect: () => this._onRemoveFavorite(field),
title: "Add this property to Favorite category",
label: "Add to Favorite",
});
} else {
items.push({
key: "add-favorite",
onSelect: () => this._onAddFavorite(field),
title: "Remove this property from Favorite category",
label: "Remove from Favorite",
});
}
}
}
Geometry
Summary
- PolyfaceQuery method to partition by connectivity
- Optimize triangle flipping
PolyfaceQuery.cutFilluses GriddedRaggedRange2dSet (rather than priorLinearSearchRange2dGrid)
Details
PolyfaceQuerymethods- (static)
PolyfaceQuery.partitionFacetIndicesByEdgeConnectedComponent(polyface: Polyface | PolyfaceVisitor): number[][]- Return arrays of facet indices
- Within each array, each facet has an edge in common with others in the same array.
- (static)
PolyfaceQuery.partitionFacetIndicesByVertexConnectedComponent(polyface: Polyface | PolyfaceVisitor): number[][]- Return arrays of facet indices
- Within each array, each facet has (at least) a vertex in common with others in the same array.
- (static)
PolyfaceQuery.clonePartitions(polyface: Polyface | PolyfaceVisitor, partitions: number[][]): Polyface[]- Return an array of polyfaces
- Each polyface has all the facets from one of the input facet index arrays.
PolyfaceVisitormyVisitor.setNumWrap (numWrap: number)- set numWrap for subsequent visits.
PolyfaceBuildermyBuilder.reversed: boolean- read property to query the state controlled by
myBuilder.toggleReversedFlag - Carry
twoSidedflag through polyface builder actions.
- read property to query the state controlled by
PolyfaceQuery- (static)
PolyfaceQuery.partitionFacetIndicesByVertexConnectedComponent(polyface: Polyface | PolyfaceVisitor): number[][]
- (static)
UnionFindContext- New class to implement the UnionFind algorithm on a set of integers.
- Classes for 2d range searching.
RangeLengthData, UsageSums-- carrier interface for computing average range sizes.LinearSearchRange2dArray-- array of Range2d for linear search.GriddedRaggedRange2dSet-- grid of LinearSearchRange2dArrayGriddedRaggedRange2dSetWithOverflow-- GriddedRaggedRange2dSet for typical ranges,LinearSearchRange2dArrayfor larger overflow ranges.
- (static)
Last Updated: 11 June, 2025
Found something wrong, missing, or unclear on this page? Raise an issue in our repo.