diff --git a/.changeset/brave-llamas-hammer.md b/.changeset/brave-llamas-hammer.md deleted file mode 100644 index 188c6aa498..0000000000 --- a/.changeset/brave-llamas-hammer.md +++ /dev/null @@ -1,9 +0,0 @@ ---- -'xstate': patch ---- - -State IDs that have periods in them are now supported if those periods are escaped. - -The motivation is that external tools, such as [Stately Studio](https://stately.ai/studio), may allow users to enter any text into the state ID field. This change allows those tools to escape periods in state IDs, so that they don't conflict with the internal path-based state IDs. - -E.g. if a state ID of `"Loading..."` is entered into the state ID field, instead of crashing either the external tool and/or the XState state machine, it should be converted by the tool to `"Loading\\.\\.\\."`, and those periods will be ignored by XState. diff --git a/.changeset/honest-spoons-drum.md b/.changeset/honest-spoons-drum.md deleted file mode 100644 index 16164c6979..0000000000 --- a/.changeset/honest-spoons-drum.md +++ /dev/null @@ -1,18 +0,0 @@ ---- -'@xstate/react': patch ---- - -Options in `createActorContext` are now properly merged with provider options. Previously, provider options replaced the actor options. - -```tsx -const { inspect } = createBrowserInspector(); - -const SomeContext = createActorContext(someMachine, { inspect }); - -// ... -// Options are now merged: -// { inspect: inspect, input: 10 } - - {/* ... */} -; -``` diff --git a/packages/core/CHANGELOG.md b/packages/core/CHANGELOG.md index 1793128a47..2193efecb5 100644 --- a/packages/core/CHANGELOG.md +++ b/packages/core/CHANGELOG.md @@ -1,5 +1,15 @@ # xstate +## 5.5.2 + +### Patch Changes + +- [#4685](https://github.com/statelyai/xstate/pull/4685) [`e43eab144`](https://github.com/statelyai/xstate/commit/e43eab14498356daf859d0f59d02820ec4e6a040) Thanks [@davidkpiano](https://github.com/davidkpiano)! - State IDs that have periods in them are now supported if those periods are escaped. + + The motivation is that external tools, such as [Stately Studio](https://stately.ai/studio), may allow users to enter any text into the state ID field. This change allows those tools to escape periods in state IDs, so that they don't conflict with the internal path-based state IDs. + + E.g. if a state ID of `"Loading..."` is entered into the state ID field, instead of crashing either the external tool and/or the XState state machine, it should be converted by the tool to `"Loading\\.\\.\\."`, and those periods will be ignored by XState. + ## 5.5.1 ### Patch Changes diff --git a/packages/core/package.json b/packages/core/package.json index 9b07626708..410ee19275 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "xstate", - "version": "5.5.1", + "version": "5.5.2", "description": "Finite State Machines and Statecharts for the Modern Web.", "main": "dist/xstate.cjs.js", "module": "dist/xstate.esm.js", diff --git a/packages/xstate-graph/package.json b/packages/xstate-graph/package.json index ba1f7fec02..c692414891 100644 --- a/packages/xstate-graph/package.json +++ b/packages/xstate-graph/package.json @@ -40,10 +40,10 @@ "url": "https://github.com/statelyai/xstate/issues" }, "peerDependencies": { - "xstate": "^5.5.1" + "xstate": "^5.5.2" }, "devDependencies": { - "xstate": "5.5.1" + "xstate": "5.5.2" }, "dependencies": {} } diff --git a/packages/xstate-immer/package.json b/packages/xstate-immer/package.json index 363723f93c..b96c831f17 100644 --- a/packages/xstate-immer/package.json +++ b/packages/xstate-immer/package.json @@ -41,10 +41,10 @@ "dependencies": {}, "peerDependencies": { "immer": "^9.0.6 || ^10", - "xstate": "^5.5.1" + "xstate": "^5.5.2" }, "devDependencies": { "immer": "^10.0.2", - "xstate": "5.5.1" + "xstate": "5.5.2" } } diff --git a/packages/xstate-inspect/package.json b/packages/xstate-inspect/package.json index a4fcbf8c3f..253979366c 100644 --- a/packages/xstate-inspect/package.json +++ b/packages/xstate-inspect/package.json @@ -53,12 +53,12 @@ "devDependencies": { "@types/ws": "^8.2.2", "ws": "^8.4.0", - "xstate": "5.5.1" + "xstate": "5.5.2" }, "peerDependencies": { "@types/ws": "^8.0.0", "ws": "^8.0.0", - "xstate": "^5.5.1" + "xstate": "^5.5.2" }, "peerDependenciesMeta": { "@types/ws": { diff --git a/packages/xstate-react/CHANGELOG.md b/packages/xstate-react/CHANGELOG.md index 6fcf67e7df..68e7f66737 100644 --- a/packages/xstate-react/CHANGELOG.md +++ b/packages/xstate-react/CHANGELOG.md @@ -1,5 +1,24 @@ # Changelog +## 4.0.3 + +### Patch Changes + +- [#4695](https://github.com/statelyai/xstate/pull/4695) [`52900a084`](https://github.com/statelyai/xstate/commit/52900a084712755b00e6c38eb9aa2c3b290259b5) Thanks [@davidkpiano](https://github.com/davidkpiano)! - Options in `createActorContext` are now properly merged with provider options. Previously, provider options replaced the actor options. + + ```tsx + const { inspect } = createBrowserInspector(); + + const SomeContext = createActorContext(someMachine, { inspect }); + + // ... + // Options are now merged: + // { inspect: inspect, input: 10 } + + {/* ... */} + ; + ``` + ## 4.0.2 ### Patch Changes diff --git a/packages/xstate-react/package.json b/packages/xstate-react/package.json index 7ed21b9f44..2b7fe59579 100644 --- a/packages/xstate-react/package.json +++ b/packages/xstate-react/package.json @@ -1,6 +1,6 @@ { "name": "@xstate/react", - "version": "4.0.2", + "version": "4.0.3", "description": "XState tools for React", "keywords": [ "state", @@ -55,7 +55,7 @@ }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0 || ^18.0.0", - "xstate": "^5.5.1" + "xstate": "^5.5.2" }, "peerDependenciesMeta": { "xstate": { @@ -76,6 +76,6 @@ "jsdom-global": "^3.0.2", "react": "^18.0.0", "react-dom": "^18.0.0", - "xstate": "5.5.1" + "xstate": "5.5.2" } } diff --git a/packages/xstate-solid/package.json b/packages/xstate-solid/package.json index 5f2218faae..5b6f23cd9a 100644 --- a/packages/xstate-solid/package.json +++ b/packages/xstate-solid/package.json @@ -43,7 +43,7 @@ }, "peerDependencies": { "solid-js": "^1.6.0", - "xstate": "^5.5.1" + "xstate": "^5.5.2" }, "peerDependenciesMeta": { "xstate": { @@ -53,6 +53,6 @@ "devDependencies": { "solid-js": "^1.7.6", "solid-testing-library": "^0.3.0", - "xstate": "5.5.1" + "xstate": "5.5.2" } } diff --git a/packages/xstate-svelte/package.json b/packages/xstate-svelte/package.json index 8c0979e404..b7227e195b 100644 --- a/packages/xstate-svelte/package.json +++ b/packages/xstate-svelte/package.json @@ -45,7 +45,7 @@ }, "peerDependencies": { "svelte": "^3.24.1 || ^4", - "xstate": "^5.5.1" + "xstate": "^5.5.2" }, "peerDependenciesMeta": { "xstate": { @@ -60,6 +60,6 @@ "svelte-check": "^3.2.0", "svelte-jester": "^2.3.2", "svelte-preprocess": "^5.0.0", - "xstate": "5.5.1" + "xstate": "5.5.2" } } diff --git a/packages/xstate-test/package.json b/packages/xstate-test/package.json index 8e55b1abf5..68c0a68095 100644 --- a/packages/xstate-test/package.json +++ b/packages/xstate-test/package.json @@ -46,11 +46,11 @@ "url": "https://github.com/statelyai/xstate/issues" }, "peerDependencies": { - "xstate": "^5.5.1" + "xstate": "^5.5.2" }, "devDependencies": { "strip-ansi": "^5.2.0", - "xstate": "5.5.1" + "xstate": "5.5.2" }, "dependencies": { "@xstate/graph": "2.0.0-beta.6" diff --git a/packages/xstate-vue/package.json b/packages/xstate-vue/package.json index 42d06a1761..134521a05d 100644 --- a/packages/xstate-vue/package.json +++ b/packages/xstate-vue/package.json @@ -54,7 +54,7 @@ }, "peerDependencies": { "vue": "^3.0.0", - "xstate": "^5.5.1" + "xstate": "^5.5.2" }, "peerDependenciesMeta": { "xstate": { @@ -66,6 +66,6 @@ "@testing-library/vue": "^6.6.1", "@vue/compiler-sfc": "^3.0.11", "vue": "^3.0.11", - "xstate": "5.5.1" + "xstate": "5.5.2" } }