From f0384920b1870f8b0d1fe70eae42f49094ab70a6 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 5 Oct 2026 03:39:49 +0000 Subject: [PATCH] Version Packages --- .changeset/v2-core.md | 27 ----------------------- .changeset/v2-react.md | 32 --------------------------- .changeset/v2-solid.md | 20 ----------------- examples/react/CHANGELOG.md | 8 +++++++ examples/react/package.json | 2 +- examples/solidstart/CHANGELOG.md | 8 +++++++ examples/solidstart/package.json | 2 +- packages/core/CHANGELOG.md | 28 +++++++++++++++++++++++ packages/core/package.json | 2 +- packages/react/CHANGELOG.md | 38 ++++++++++++++++++++++++++++++++ packages/react/package.json | 2 +- packages/solid/CHANGELOG.md | 26 ++++++++++++++++++++++ packages/solid/package.json | 2 +- 13 files changed, 113 insertions(+), 84 deletions(-) delete mode 100644 .changeset/v2-core.md delete mode 100644 .changeset/v2-react.md delete mode 100644 .changeset/v2-solid.md diff --git a/.changeset/v2-core.md b/.changeset/v2-core.md deleted file mode 100644 index 16be852..0000000 --- a/.changeset/v2-core.md +++ /dev/null @@ -1,27 +0,0 @@ ---- -'@dynamix-layout/core': major ---- - -**v2: an instance-based, pure layout engine.** See the migration guide for every rename. - -- **`createLayout(options)` replaces `new DynamixLayoutCore()`.** Each instance is independent: there is no module-level state, no static caches, no timers, and nothing touches the DOM. Two layouts on a page, or one per server request, no longer interfere. -- **Immutable snapshots** (`getSnapshot()` / `subscribe()`) share unchanged parts by reference: `tabsets`, `tabs`, `splitters`, `rects` and `drag`. -- **Typed actions** that return whether anything changed and never throw: `moveTab`, `moveTabset`, `selectTab`, `addTab`, `removeTab`, `setTabs`, `resizeSplitter`, `moveSplitterBy`, `maximize`/`restore`, `fold`/`unfold`, plus one drag model for tabs and splitters (`startDrag`, `updateDrag`, `endDrag`, `cancelDrag`) and hit testing (`getDropTarget`, `listDropTargets`). -- **`onLayoutChange(layout, reason)`** reports committed changes. -- **New saved format, `LayoutJSON`** (`version: 2`): readable names, explicit directions, and tab ids as the stable identity. -- **Old layouts:** v1 trees load automatically, or convert them with `migrateLayoutFromV1`. They render pixel-identically, as checked against layouts recorded from v1. -- **Deterministic ids**, safe for server rendering; no `crypto.randomUUID()`, which threw outside secure contexts. -- **Rects are relative to the layout root.** v1 misplaced layouts that weren't at the viewport's top-left. -- **No import-time side effects:** the console banner and `window.__DYNAMIX_LAYOUT__` are gone. Use `version` instead. -- **Fixed:** - - nested rows left behind after some moves; - - stale sizes when every open panel had weight 0; - - a row stuck at its minimum next to a folded tabset; - - the root staying oversized after the container shrank; - - center drops inserting before the last tab (they now append). -- **Packaging:** the CommonJS build loads with `require()` (it was ESM under a `.cjs.js` name), exports maps give each condition its own types, and the package installs on Node 18 and later (it required Node 22). - -**Breaking:** -- `DynamixLayoutCore`, `Node`, `Bond`, `Node.cache`, `Queue`, `createReactiveState`, the comparators, the drop-preview and DOM helpers, and the `LayoutTree`/`NodeOptions` types are removed. -- `updateTree(src, des, area)` becomes `moveTab`/`moveTabset(id, target)`, with `'contain'` renamed to `'center'`. -- `updateDimension` becomes `setContainerRect`, and the debounce arguments are gone; throttle in the adapter instead. diff --git a/.changeset/v2-react.md b/.changeset/v2-react.md deleted file mode 100644 index 2aafe28..0000000 --- a/.changeset/v2-react.md +++ /dev/null @@ -1,32 +0,0 @@ ---- -'@dynamix-layout/react': major ---- - -**v2: a small component API, headless hooks, accessibility and SSR.** See the migration guide for every rename. - -- **``**: - - `tabs` is a list of objects (`{ id, title, content, closable, target }`); - - `defaultLayout` (uncontrolled) or `layout` (controlled) takes v1 or v2 JSON, and `onLayoutChange(layout, { reason })` reports changes; - - `components`, `classNames` and `styles` replace the wrapper and styling props; - - `ref` gives an imperative handle. -- **The engine is created once and never rebuilt by prop changes.** An inline `tabs` array with unchanged ids does no engine work and remounts nothing, and moving a tab never remounts its content. -- **Headless API:** `useDynamixLayout` + `DynamixLayoutProvider`, `useTabset`, `useTab`, `useSplitter`, `useLayoutState` (re-renders only for the selected value), `useLayoutActions` and `useDragState`. Prop getters merge your refs, classes, styles and handlers. -- **Pointer-event dragging** for tabs, tabsets and splitters: touch long-press, Escape cancels, and it works over iframes. Drags and resizes never re-render React. -- **ResizeObserver** follows the container, so sidebars and flex parents resize the layout. -- **Accessibility:** WAI-ARIA tabs and window splitter patterns, keyboard resizing, keyboard move mode (Mod+Shift+M), and a live region. -- **SSR-safe and deterministic**, with a `'use client'` entry for the Next.js App Router. Works with React 18 and 19; the bundle no longer inlines React 19's JSX runtime. -- **Fixed:** callback refs are honoured, `layoutTree` changes are no longer ignored, and duplicate DOM ids are gone. - -- **Installs on Node 18 and later** (1.x required Node 22). - -**Breaking:** -- Removed: - - the v1 props and wrapper components (`WrapTab*`, `SliderElement`, `HoverElement`, `RootSplitterHoverEl`); - - `getTabOutput`; - - the v1 `useDynamixLayout` return shape. -- `updateJSON` becomes `onLayoutChange`, which receives v2 JSON and is not called on mount. -- `ref` returns a `DynamixLayoutHandle` (`handle.element` is the root). -- Keyboard shortcuts only act when focus is inside the layout. -- Default classes are `.dx-*`, and data attributes are `data-dx-*`. -- The stylesheet is `@dynamix-layout/react/styles.css` (`style.css` still works). -- React 17 is no longer supported. diff --git a/.changeset/v2-solid.md b/.changeset/v2-solid.md deleted file mode 100644 index 396c215..0000000 --- a/.changeset/v2-solid.md +++ /dev/null @@ -1,20 +0,0 @@ ---- -'@dynamix-layout/solid': major ---- - -**Runs on the v2 core.** `` keeps its props, default components and drag-and-drop, but each component now has its own engine instance. Two Solid layouts on a page no longer share state, and a layout away from the viewport's top-left is placed correctly. - -- **Installs on Node 18 and later** (1.x required Node 22). - -**New:** -- `tabs` is reactive: add an entry to open a tab, remove it to close one. Existing tabs keep their content mounted. -- Closable tabs: a third tuple element `{ title, closable }` and an `onTabClose` prop. -- `onReady(layout)` gives the engine for actions from code (`maximize`, `fold`, `selectTab`, `moveTab`, `reset`, `toJSON`, …). -- `updateJSON(layout, reason)` also says why it was called: `'move'`, `'resize'`, `'select'`, `'fold'`, `'maximize'`, `'tabs'`, `'reset'`, or `'mount'` for the first call (type `LayoutUpdateReason`). - -**Breaking:** -- `layoutTree` accepts v2 JSON (v1 trees are migrated automatically), and `updateJSON` receives v2 `LayoutJSON`. -- `getTabOutput` and the `TabEntry`/`TabInput`/`TabOutput` types are removed, and tab ids are the tab labels. -- `useDynamixLayout` returns a new shape. -- The slider timeout options no longer apply; splitters update once per frame. -- `solid-js` is a peer dependency. diff --git a/examples/react/CHANGELOG.md b/examples/react/CHANGELOG.md index 60013d2..d89023b 100644 --- a/examples/react/CHANGELOG.md +++ b/examples/react/CHANGELOG.md @@ -1,5 +1,13 @@ # shadcn +## 0.0.7 + +### Patch Changes + +- Updated dependencies [[`a31dc4c`](https://github.com/xcode-studio/dynamix-layout/commit/a31dc4c2aef4facb8b80f94b9e3d97c36e148ccc), [`a31dc4c`](https://github.com/xcode-studio/dynamix-layout/commit/a31dc4c2aef4facb8b80f94b9e3d97c36e148ccc)]: + - @dynamix-layout/core@2.0.0 + - @dynamix-layout/react@2.0.0 + ## 0.0.6 ### Patch Changes diff --git a/examples/react/package.json b/examples/react/package.json index ad40c0c..7a0e9e8 100644 --- a/examples/react/package.json +++ b/examples/react/package.json @@ -1,7 +1,7 @@ { "name": "@repo/react-example", "private": true, - "version": "0.0.6", + "version": "0.0.7", "type": "module", "scripts": { "dev": "vite", diff --git a/examples/solidstart/CHANGELOG.md b/examples/solidstart/CHANGELOG.md index d6c7b65..e289bda 100644 --- a/examples/solidstart/CHANGELOG.md +++ b/examples/solidstart/CHANGELOG.md @@ -1,5 +1,13 @@ # solidstart +## 0.0.7 + +### Patch Changes + +- Updated dependencies [[`a31dc4c`](https://github.com/xcode-studio/dynamix-layout/commit/a31dc4c2aef4facb8b80f94b9e3d97c36e148ccc), [`a31dc4c`](https://github.com/xcode-studio/dynamix-layout/commit/a31dc4c2aef4facb8b80f94b9e3d97c36e148ccc)]: + - @dynamix-layout/core@2.0.0 + - @dynamix-layout/solid@2.0.0 + ## 0.0.6 ### Patch Changes diff --git a/examples/solidstart/package.json b/examples/solidstart/package.json index 3892b12..4749dfa 100644 --- a/examples/solidstart/package.json +++ b/examples/solidstart/package.json @@ -2,7 +2,7 @@ "name": "@repo/solidstart-example", "type": "module", "private": true, - "version": "0.0.6", + "version": "0.0.7", "scripts": { "dev": "vinxi dev", "build": "vinxi build", diff --git a/packages/core/CHANGELOG.md b/packages/core/CHANGELOG.md index 1235e13..e137031 100644 --- a/packages/core/CHANGELOG.md +++ b/packages/core/CHANGELOG.md @@ -1,5 +1,33 @@ # @dynamix-layout/core +## 2.0.0 + +### Major Changes + +- [#87](https://github.com/xcode-studio/dynamix-layout/pull/87) [`a31dc4c`](https://github.com/xcode-studio/dynamix-layout/commit/a31dc4c2aef4facb8b80f94b9e3d97c36e148ccc) Thanks [@akash-aman](https://github.com/akash-aman)! - **v2: an instance-based, pure layout engine.** See the migration guide for every rename. + + - **`createLayout(options)` replaces `new DynamixLayoutCore()`.** Each instance is independent: there is no module-level state, no static caches, no timers, and nothing touches the DOM. Two layouts on a page, or one per server request, no longer interfere. + - **Immutable snapshots** (`getSnapshot()` / `subscribe()`) share unchanged parts by reference: `tabsets`, `tabs`, `splitters`, `rects` and `drag`. + - **Typed actions** that return whether anything changed and never throw: `moveTab`, `moveTabset`, `selectTab`, `addTab`, `removeTab`, `setTabs`, `resizeSplitter`, `moveSplitterBy`, `maximize`/`restore`, `fold`/`unfold`, plus one drag model for tabs and splitters (`startDrag`, `updateDrag`, `endDrag`, `cancelDrag`) and hit testing (`getDropTarget`, `listDropTargets`). + - **`onLayoutChange(layout, reason)`** reports committed changes. + - **New saved format, `LayoutJSON`** (`version: 2`): readable names, explicit directions, and tab ids as the stable identity. + - **Old layouts:** v1 trees load automatically, or convert them with `migrateLayoutFromV1`. They render pixel-identically, as checked against layouts recorded from v1. + - **Deterministic ids**, safe for server rendering; no `crypto.randomUUID()`, which threw outside secure contexts. + - **Rects are relative to the layout root.** v1 misplaced layouts that weren't at the viewport's top-left. + - **No import-time side effects:** the console banner and `window.__DYNAMIX_LAYOUT__` are gone. Use `version` instead. + - **Fixed:** + - nested rows left behind after some moves; + - stale sizes when every open panel had weight 0; + - a row stuck at its minimum next to a folded tabset; + - the root staying oversized after the container shrank; + - center drops inserting before the last tab (they now append). + - **Packaging:** the CommonJS build loads with `require()` (it was ESM under a `.cjs.js` name), exports maps give each condition its own types, and the package installs on Node 18 and later (it required Node 22). + + **Breaking:** + - `DynamixLayoutCore`, `Node`, `Bond`, `Node.cache`, `Queue`, `createReactiveState`, the comparators, the drop-preview and DOM helpers, and the `LayoutTree`/`NodeOptions` types are removed. + - `updateTree(src, des, area)` becomes `moveTab`/`moveTabset(id, target)`, with `'contain'` renamed to `'center'`. + - `updateDimension` becomes `setContainerRect`, and the debounce arguments are gone; throttle in the adapter instead. + ## 1.2.0 ### Minor Changes diff --git a/packages/core/package.json b/packages/core/package.json index ab1326a..9df5bd9 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@dynamix-layout/core", - "version": "1.2.0", + "version": "2.0.0", "description": "Dynamix Layout/Core is a JavaScript package for creating dynamic layouts with ease.", "keywords": [ "dynamix-layout", diff --git a/packages/react/CHANGELOG.md b/packages/react/CHANGELOG.md index a86e343..3223cb8 100644 --- a/packages/react/CHANGELOG.md +++ b/packages/react/CHANGELOG.md @@ -1,5 +1,43 @@ # @dynamix-layout/react +## 2.0.0 + +### Major Changes + +- [#87](https://github.com/xcode-studio/dynamix-layout/pull/87) [`a31dc4c`](https://github.com/xcode-studio/dynamix-layout/commit/a31dc4c2aef4facb8b80f94b9e3d97c36e148ccc) Thanks [@akash-aman](https://github.com/akash-aman)! - **v2: a small component API, headless hooks, accessibility and SSR.** See the migration guide for every rename. + + - **``**: + - `tabs` is a list of objects (`{ id, title, content, closable, target }`); + - `defaultLayout` (uncontrolled) or `layout` (controlled) takes v1 or v2 JSON, and `onLayoutChange(layout, { reason })` reports changes; + - `components`, `classNames` and `styles` replace the wrapper and styling props; + - `ref` gives an imperative handle. + - **The engine is created once and never rebuilt by prop changes.** An inline `tabs` array with unchanged ids does no engine work and remounts nothing, and moving a tab never remounts its content. + - **Headless API:** `useDynamixLayout` + `DynamixLayoutProvider`, `useTabset`, `useTab`, `useSplitter`, `useLayoutState` (re-renders only for the selected value), `useLayoutActions` and `useDragState`. Prop getters merge your refs, classes, styles and handlers. + - **Pointer-event dragging** for tabs, tabsets and splitters: touch long-press, Escape cancels, and it works over iframes. Drags and resizes never re-render React. + - **ResizeObserver** follows the container, so sidebars and flex parents resize the layout. + - **Accessibility:** WAI-ARIA tabs and window splitter patterns, keyboard resizing, keyboard move mode (Mod+Shift+M), and a live region. + - **SSR-safe and deterministic**, with a `'use client'` entry for the Next.js App Router. Works with React 18 and 19; the bundle no longer inlines React 19's JSX runtime. + - **Fixed:** callback refs are honoured, `layoutTree` changes are no longer ignored, and duplicate DOM ids are gone. + + - **Installs on Node 18 and later** (1.x required Node 22). + + **Breaking:** + - Removed: + - the v1 props and wrapper components (`WrapTab*`, `SliderElement`, `HoverElement`, `RootSplitterHoverEl`); + - `getTabOutput`; + - the v1 `useDynamixLayout` return shape. + - `updateJSON` becomes `onLayoutChange`, which receives v2 JSON and is not called on mount. + - `ref` returns a `DynamixLayoutHandle` (`handle.element` is the root). + - Keyboard shortcuts only act when focus is inside the layout. + - Default classes are `.dx-*`, and data attributes are `data-dx-*`. + - The stylesheet is `@dynamix-layout/react/styles.css` (`style.css` still works). + - React 17 is no longer supported. + +### Patch Changes + +- Updated dependencies [[`a31dc4c`](https://github.com/xcode-studio/dynamix-layout/commit/a31dc4c2aef4facb8b80f94b9e3d97c36e148ccc)]: + - @dynamix-layout/core@2.0.0 + ## 1.1.0 ### Minor Changes diff --git a/packages/react/package.json b/packages/react/package.json index ba0d8b8..522407c 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,6 +1,6 @@ { "name": "@dynamix-layout/react", - "version": "1.1.0", + "version": "2.0.0", "description": "A powerful React component for creating dynamic, resizable, and draggable layouts.", "keywords": [ "react", diff --git a/packages/solid/CHANGELOG.md b/packages/solid/CHANGELOG.md index dedac5d..8341972 100644 --- a/packages/solid/CHANGELOG.md +++ b/packages/solid/CHANGELOG.md @@ -1,5 +1,31 @@ # @dynamix-layout/solid +## 2.0.0 + +### Major Changes + +- [#87](https://github.com/xcode-studio/dynamix-layout/pull/87) [`a31dc4c`](https://github.com/xcode-studio/dynamix-layout/commit/a31dc4c2aef4facb8b80f94b9e3d97c36e148ccc) Thanks [@akash-aman](https://github.com/akash-aman)! - **Runs on the v2 core.** `` keeps its props, default components and drag-and-drop, but each component now has its own engine instance. Two Solid layouts on a page no longer share state, and a layout away from the viewport's top-left is placed correctly. + + - **Installs on Node 18 and later** (1.x required Node 22). + + **New:** + - `tabs` is reactive: add an entry to open a tab, remove it to close one. Existing tabs keep their content mounted. + - Closable tabs: a third tuple element `{ title, closable }` and an `onTabClose` prop. + - `onReady(layout)` gives the engine for actions from code (`maximize`, `fold`, `selectTab`, `moveTab`, `reset`, `toJSON`, …). + - `updateJSON(layout, reason)` also says why it was called: `'move'`, `'resize'`, `'select'`, `'fold'`, `'maximize'`, `'tabs'`, `'reset'`, or `'mount'` for the first call (type `LayoutUpdateReason`). + + **Breaking:** + - `layoutTree` accepts v2 JSON (v1 trees are migrated automatically), and `updateJSON` receives v2 `LayoutJSON`. + - `getTabOutput` and the `TabEntry`/`TabInput`/`TabOutput` types are removed, and tab ids are the tab labels. + - `useDynamixLayout` returns a new shape. + - The slider timeout options no longer apply; splitters update once per frame. + - `solid-js` is a peer dependency. + +### Patch Changes + +- Updated dependencies [[`a31dc4c`](https://github.com/xcode-studio/dynamix-layout/commit/a31dc4c2aef4facb8b80f94b9e3d97c36e148ccc)]: + - @dynamix-layout/core@2.0.0 + ## 1.1.0 ### Minor Changes diff --git a/packages/solid/package.json b/packages/solid/package.json index d573738..f0343c1 100644 --- a/packages/solid/package.json +++ b/packages/solid/package.json @@ -1,6 +1,6 @@ { "name": "@dynamix-layout/solid", - "version": "1.1.0", + "version": "2.0.0", "description": "A powerful SolidJS component for creating dynamic, resizable, and draggable layouts.", "keywords": [ "solid",