Skip to content

Commit

Permalink
Release packages [publish docs] (#801)
Browse files Browse the repository at this point in the history
Co-authored-by: imodeljs-admin <[email protected]>
  • Loading branch information
imodeljs-admin and imodeljs-admin authored Dec 16, 2024
1 parent 2ec959c commit 6150d75
Show file tree
Hide file tree
Showing 16 changed files with 173 additions and 88 deletions.
8 changes: 0 additions & 8 deletions .changeset/chatty-dolphins-type.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/clean-weeks-itch.md

This file was deleted.

7 changes: 0 additions & 7 deletions .changeset/mighty-houses-warn.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/mighty-shoes-destroy.md

This file was deleted.

30 changes: 0 additions & 30 deletions .changeset/selfish-toes-promise.md

This file was deleted.

28 changes: 0 additions & 28 deletions .changeset/violet-years-thank.md

This file was deleted.

31 changes: 31 additions & 0 deletions packages/components/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,36 @@
# Change Log - @itwin/presentation-components

## 5.7.0

### Minor Changes

- [#804](https://github.com/iTwin/presentation/pull/804): Deprecated all tree-related APIs.

As the new generation hierarchy building APIs are now available, the old tree-related APIs are now deprecated. See reasoning and migration guide [here](https://github.com/iTwin/presentation/blob/33e79ee8d77f30580a9bab81a72884bda008db25/packages/hierarchies/learning/PresentationRulesMigrationGuide.md).

- [#800](https://github.com/iTwin/presentation/pull/800): Deprecate `viewWithUnifiedSelection` in favor of `enableUnifiedSelectionSyncWithIModel` from `@itwin/unified-selection` package.
- [#802](https://github.com/iTwin/presentation/pull/802): Prefer `Symbol.dispose` over `dispose` for disposable objects.

The package contained a number of types for disposable objects, that had a requirement of `dispose` method being called on them after they are no longer needed. In conjunction with the `using` utility from `@itwin/core-bentley`, usage of such objects looked like this:

```ts
class MyDisposable() {
dispose() {
// do some cleanup
}
}
using(new MyDisposable(), (obj) => {
// do something with obj, it'll get disposed when the callback returns
});
```

In version `5.2`, TypeScript [introduced](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-5-2.html#using-declarations-and-explicit-resource-management) `Disposable` type and `using` declarations (from the upcoming [Explicit Resource Management](https://github.com/tc39/proposal-explicit-resource-management) feature in ECMAScript). Now we're making use of those new utilities in this package (while still supporting the old `dispose` method), which allows using `MyDisposable` from the above snippet like this:

```ts
using obj = new MyDisposable();
// do something with obj, it'll get disposed when it goes out of scope
```

## 5.6.1

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/components/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@itwin/presentation-components",
"version": "5.6.1",
"version": "5.7.0",
"description": "React components based on iTwin.js Presentation library",
"license": "MIT",
"repository": {
Expand Down
67 changes: 67 additions & 0 deletions packages/hierarchies-react/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,72 @@
# @itwin/presentation-hierarchies-react

## 1.3.0

### Minor Changes

- [#807](https://github.com/iTwin/presentation/pull/807): Added `getNode` function to tree state hooks to allow getting a node by id.

Example usage:

```tsx
function MyTreeComponentInternal({ imodelAccess }: { imodelAccess: IModelAccess }) {
const {
rootNodes,
getNode,
expandNode: doExpandNode,
...state
} = useTree({
// tree props
});

// enhance the default `expandNode` handler to log the action to console
const expandNode = React.useCallback(
async (nodeId: string, isExpanded: boolean) => {
const node = getNode(nodeId);
if (node) {
console.log(`${isExpanded ? "Expanding" : "Collapsing"} node: ${node.label}`);
}
doExpandNode(nodeId, isExpanded);
},
[getNode, doExpandNode],
);

// render the tree
if (!rootNodes || !rootNodes.length) {
return "No data to display";
}
return <TreeRenderer {...state} expandNode={expandNode} rootNodes={rootNodes} />;
}
```

- [#802](https://github.com/iTwin/presentation/pull/802): Prefer `Symbol.dispose` over `dispose` for disposable objects.

The package contained a number of types for disposable objects, that had a requirement of `dispose` method being called on them after they are no longer needed. In conjunction with the `using` utility from `@itwin/core-bentley`, usage of such objects looked like this:

```ts
class MyDisposable() {
dispose() {
// do some cleanup
}
}
using(new MyDisposable(), (obj) => {
// do something with obj, it'll get disposed when the callback returns
});
```

In version `5.2`, TypeScript [introduced](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-5-2.html#using-declarations-and-explicit-resource-management) `Disposable` type and `using` declarations (from the upcoming [Explicit Resource Management](https://github.com/tc39/proposal-explicit-resource-management) feature in ECMAScript). Now we're making use of those new utilities in this package (while still supporting the old `dispose` method), which allows using `MyDisposable` from the above snippet like this:

```ts
using obj = new MyDisposable();
// do something with obj, it'll get disposed when it goes out of scope
```

### Patch Changes

- Updated dependencies:
- @itwin/unified-selection@1.2.0
- @itwin/presentation-hierarchies@1.4.0

## 1.2.0

### Minor Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/hierarchies-react/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@itwin/presentation-hierarchies-react",
"version": "1.2.0",
"version": "1.3.0",
"description": "React components based on `@itwin/presentation-hierarchies`",
"license": "MIT",
"author": {
Expand Down
26 changes: 26 additions & 0 deletions packages/hierarchies/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,31 @@
# @itwin/presentation-hierarchies

## 1.4.0

### Minor Changes

- [#802](https://github.com/iTwin/presentation/pull/802): Prefer `Symbol.dispose` over `dispose` for disposable objects.

The package contained a number of types for disposable objects, that had a requirement of `dispose` method being called on them after they are no longer needed. In conjunction with the `using` utility from `@itwin/core-bentley`, usage of such objects looked like this:

```ts
class MyDisposable() {
dispose() {
// do some cleanup
}
}
using(new MyDisposable(), (obj) => {
// do something with obj, it'll get disposed when the callback returns
});
```

In version `5.2`, TypeScript [introduced](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-5-2.html#using-declarations-and-explicit-resource-management) `Disposable` type and `using` declarations (from the upcoming [Explicit Resource Management](https://github.com/tc39/proposal-explicit-resource-management) feature in ECMAScript). Now we're making use of those new utilities in this package (while still supporting the old `dispose` method), which allows using `MyDisposable` from the above snippet like this:

```ts
using obj = new MyDisposable();
// do something with obj, it'll get disposed when it goes out of scope
```

## 1.3.0

### Minor Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/hierarchies/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@itwin/presentation-hierarchies",
"version": "1.3.0",
"version": "1.4.0",
"description": "A package for creating hierarchies based on data in iTwin.js iModels.",
"license": "MIT",
"author": {
Expand Down
13 changes: 13 additions & 0 deletions packages/testing/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
# Change Log - @itwin/presentation-testing

## 5.2.0

### Minor Changes

- [#804](https://github.com/iTwin/presentation/pull/804): Deprecated all tree-related APIs.

As the new generation hierarchy building APIs are now available, the old tree-related APIs are now deprecated. See reasoning and migration guide [here](https://github.com/iTwin/presentation/blob/33e79ee8d77f30580a9bab81a72884bda008db25/packages/hierarchies/learning/PresentationRulesMigrationGuide.md).

### Patch Changes

- Updated dependencies:
- @itwin/presentation-components@5.7.0

## 5.1.2

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/testing/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@itwin/presentation-testing",
"version": "5.1.2",
"version": "5.2.0",
"description": "Testing utilities for iTwin.js Presentation library",
"license": "MIT",
"repository": {
Expand Down
31 changes: 31 additions & 0 deletions packages/unified-selection/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,36 @@
# @itwin/unified-selection

## 1.2.0

### Minor Changes

- [#800](https://github.com/iTwin/presentation/pull/800): Add support for Models and SubCategories selection that's going to be available in `@itwin/core-frontend` version `5`.

The changes in `@itwin/core-frontend` allow us to stop manually syncing `HiliteSet` with `SelectionSet` and rely on automatic syncing instead.

- [#800](https://github.com/iTwin/presentation/pull/800): `computeSelection`: Broadened the type of `elementIds` prop from `Id64String[]` to `Id64Arg`.
- [#802](https://github.com/iTwin/presentation/pull/802): Prefer `Symbol.dispose` over `dispose` for disposable objects.

The package contained a number of types for disposable objects, that had a requirement of `dispose` method being called on them after they are no longer needed. In conjunction with the `using` utility from `@itwin/core-bentley`, usage of such objects looked like this:

```ts
class MyDisposable() {
dispose() {
// do some cleanup
}
}
using(new MyDisposable(), (obj) => {
// do something with obj, it'll get disposed when the callback returns
});
```

In version `5.2`, TypeScript [introduced](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-5-2.html#using-declarations-and-explicit-resource-management) `Disposable` type and `using` declarations (from the upcoming [Explicit Resource Management](https://github.com/tc39/proposal-explicit-resource-management) feature in ECMAScript). Now we're making use of those new utilities in this package (while still supporting the old `dispose` method), which allows using `MyDisposable` from the above snippet like this:

```ts
using obj = new MyDisposable();
// do something with obj, it'll get disposed when it goes out of scope
```

## 1.1.2

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/unified-selection/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@itwin/unified-selection",
"version": "1.1.2",
"version": "1.2.0",
"description": "Package for managing unified selection in iTwin.js applications.",
"license": "MIT",
"repository": {
Expand Down

0 comments on commit 6150d75

Please sign in to comment.