diff --git a/.changeset/bright-machines-remember.md b/.changeset/bright-machines-remember.md deleted file mode 100644 index 3955e10..0000000 --- a/.changeset/bright-machines-remember.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@typeonce/effect-machine": minor ---- - -Add fully typed shallow and deep history states. History targets restore schema-validated state values, support typed defaults before the first capture, require only the initializers needed by shallow restoration, preserve parallel configurations, and round-trip through snapshot encoding and decoding. diff --git a/.changeset/calm-machines-construct.md b/.changeset/calm-machines-construct.md deleted file mode 100644 index a5ee3ea..0000000 --- a/.changeset/calm-machines-construct.md +++ /dev/null @@ -1,8 +0,0 @@ ---- -"@typeonce/effect-machine": minor ---- - -Add safe `.from` state construction to initial and transition target builders. -Constructor inputs are resolved through the selected state schema during -planning, preserving defaults and class identity while reporting validation -failures as `MachineSchemaDecodeError` values. diff --git a/.changeset/calm-machines-enter.md b/.changeset/calm-machines-enter.md deleted file mode 100644 index 5219390..0000000 --- a/.changeset/calm-machines-enter.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -"@typeonce/effect-machine": patch ---- - -Allow local and branch targets to enter inactive nested parallel states. These -targets now require a complete selection for every parallel region while -preserving partial updates for parallel states that are already active. diff --git a/.changeset/clear-machines-diagnose.md b/.changeset/clear-machines-diagnose.md deleted file mode 100644 index d8ea753..0000000 --- a/.changeset/clear-machines-diagnose.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -"@typeonce/effect-machine": patch ---- - -Improve compile-time diagnostics for invalid state definitions, event protocols, -and handler configurations. Errors now retain the relevant configuration shape -and state path while preserving existing inference and type safety. diff --git a/.changeset/steady-machines-bind.md b/.changeset/steady-machines-bind.md deleted file mode 100644 index 6f591a7..0000000 --- a/.changeset/steady-machines-bind.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@typeonce/effect-machine": patch ---- - -Preserve every machine protocol channel when creating bound AtomMachine bridges from deeply composed handled machines. Inline invoked children also retain their exact error, service, event, and output types instead of inheriting erased contextual `any` channels. diff --git a/.changeset/tidy-states-omit-input.md b/.changeset/tidy-states-omit-input.md deleted file mode 100644 index 2b2b9de..0000000 --- a/.changeset/tidy-states-omit-input.md +++ /dev/null @@ -1,8 +0,0 @@ ---- -"@typeonce/effect-machine": minor ---- - -Allow state builder `.from()` calls to omit the constructor input when the -selected schema accepts `{}`. Required fields and compound or parallel child -selection remain type-safe, and omitted inputs still run through schema -construction during planning. diff --git a/CHANGELOG.md b/CHANGELOG.md index 2fd696a..4ffba62 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,29 @@ # @typeonce/effect-machine +## 0.3.0 + +### Minor Changes + +- 1d1f35f: Add fully typed shallow and deep history states. History targets restore schema-validated state values, support typed defaults before the first capture, require only the initializers needed by shallow restoration, preserve parallel configurations, and round-trip through snapshot encoding and decoding. +- e556e63: Add safe `.from` state construction to initial and transition target builders. + Constructor inputs are resolved through the selected state schema during + planning, preserving defaults and class identity while reporting validation + failures as `MachineSchemaDecodeError` values. +- 3646067: Allow state builder `.from()` calls to omit the constructor input when the + selected schema accepts `{}`. Required fields and compound or parallel child + selection remain type-safe, and omitted inputs still run through schema + construction during planning. + +### Patch Changes + +- 607a0c4: Allow local and branch targets to enter inactive nested parallel states. These + targets now require a complete selection for every parallel region while + preserving partial updates for parallel states that are already active. +- ea8e165: Improve compile-time diagnostics for invalid state definitions, event protocols, + and handler configurations. Errors now retain the relevant configuration shape + and state path while preserving existing inference and type safety. +- 955663f: Preserve every machine protocol channel when creating bound AtomMachine bridges from deeply composed handled machines. Inline invoked children also retain their exact error, service, event, and output types instead of inheriting erased contextual `any` channels. + ## 0.2.0 ### Minor Changes diff --git a/package.json b/package.json index 4f41cae..6c43100 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@typeonce/effect-machine", - "version": "0.2.0", + "version": "0.3.0", "description": "Schema-first state machines and statecharts for Effect", "author": "Sandro Maglione", "repository": {