storybook-addon-colab 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +56 -1
- package/README.md +350 -199
- package/dist/chunk-T3VJLPBO.js +6237 -0
- package/dist/index.js +1 -1
- package/dist/manager.js +285 -255
- package/dist/preset.js +1401 -722
- package/dist/preview.js +1 -1
- package/package.json +12 -11
- package/dist/chunk-YW76V5AU.js +0 -5007
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,60 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
-
All notable changes to `storybook-addon-colab` are recorded here. The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and the project uses [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
3
|
+
All notable changes to `storybook-addon-colab` are recorded here. The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and the project uses [Semantic Versioning](https://semver.org/spec/v2.0.0.html). Releases are published under npm's default dist-tag, `latest`; only a pre-release version (one with a `-`, such as `1.0.0-rc.1`) goes to `next`.
|
|
4
|
+
|
|
5
|
+
## [0.2.0] - 2026-12-03
|
|
6
|
+
|
|
7
|
+
What 0.1.0 called a canvas is now a **collection**: stories to review and discuss together, shown as a grid, as rows, as columns or on a canvas. The 0.1.0 board (free-size frames and drawing) and the Chrome 157 requirement are gone; "canvas" is now the name of one view of a collection. Install it with `npm install -D storybook-addon-colab`.
|
|
8
|
+
|
|
9
|
+
### Breaking: renamed from canvas to collection
|
|
10
|
+
|
|
11
|
+
There are no aliases for the old names, and older files are not upgraded.
|
|
12
|
+
|
|
13
|
+
- **Files from 0.1.0 and from 0.2.0 pre-releases cannot be opened. Recreate them.** The collection file is now `schemaVersion: 3`. A file written by an older version (`schemaVersion` 1 or 2, or a thread anchored to `{ "type": "canvas" }`) is listed as a broken collection with an error that names the file and says it was written by an older version. The addon never upgrades, overwrites or deletes it.
|
|
14
|
+
- **Move the folder.** Collections live in `.storybook/collections/`; `.storybook/canvases/` is no longer read. Move your files there (`git mv .storybook/canvases .storybook/collections`) and recreate them in the new format. The addon option `canvasDir` is now `collectionDir`.
|
|
15
|
+
- **New agent tool names.** `list_canvases`, `get_canvas`, `create_canvas` and `update_canvas` are now `list_collections`, `get_collection`, `create_collection` and `update_collection`. Every tool takes `collectionId` instead of `canvasId`; results say `collections`, `collectionId`, `alreadyInCollection` and `location.inCollection` (was `onCanvas`); a thread on the whole collection is `{ "type": "collection" }` (was `"canvas"`). Reconnect or restart your agent so it picks up the new tool list.
|
|
16
|
+
- **New URLs.** A collection's page is `?path=/story/colab-collection-<id>--collection` (was `colab-canvas-<id>--canvas`), under **Collections** in the sidebar. The toolbar menu is **Collections**, and **Add to collection** replaces **Add to canvas**.
|
|
17
|
+
|
|
18
|
+
### Added
|
|
19
|
+
|
|
20
|
+
- **The display name is CoLab** (was Colab Canvas), in Storybook's addon catalogue and as the MCP server's title. The package name, the `/colab/mcp` endpoint and every id stay the same.
|
|
21
|
+
- **Views: Grid, Rows and Columns.** Grid shows every story as an equal card, laid out at a desktop size and scaled to fit. Rows shows one story per row at full width and its own height. Columns shows stories side by side at full size, in one row that scrolls sideways. Switch views from the collection toolbar; the choice is saved in the collection file.
|
|
22
|
+
- **Canvas view.** Full-size stories on a surface you pan (drag the background, wheel, <kbd>Space</kbd>+drag) and zoom (pinch, <kbd>⌘</kbd>/<kbd>Ctrl</kbd>+wheel, the zoom panel in the canvas's bottom-right corner, fit and 100%; the collection toolbar is the same in every view). Move a story by its title bar or with the arrow keys on its grip; try it at another width with the handle on its right edge, which snaps to your viewports (hold <kbd>Alt</kbd> to drag freely; <kbd>Page Up</kbd>/<kbd>Page Down</kbd> jump to the next viewport). That width is temporary: it stays in your browser tab (across view switches and reloads, like pan and zoom), applies in the Canvas view only, is marked in the story's title bar with a reset button, and is never saved; a viewport menu saves a width and clears it (and so does a viewport an agent or another tab saves), and **Reset temporary widths** in the toolbar's viewport menu resets every story. A story is the same as in Rows or Columns: same frame, Live switch, note, menu and comment pins. Only positions are saved, and only when you move a story; panning, zooming and the width handle write nothing. In the Canvas view, Storybook's own zoom buttons are hidden and its zoom set to 100%, so there is one zoom. Agents switch to it with `update_collection { view: "canvas" }` and place stories with `set_story_positions`.
|
|
23
|
+
- **One iframe per story.** Each story renders in its own iframe, like on its own Storybook page, so global CSS and `100vh` behave as they do there. Stories are frozen (animations paused) until you turn on **Live** in a story's header, and only stories near the viewport are loaded.
|
|
24
|
+
- **Viewports.** Render every story at one of your project's Storybook viewports or at a custom width (the collection toolbar), or set one story apart (its header). A story that sets its own viewport keeps it. A choice in the toolbar menu applies to every story: it clears each story's own choice in the same write (only a viewport set in a story file still wins, and the menu says how many do). A story's header menu then sets that story apart again, marks it, and offers **Use collection viewport**. Agents get the same with `update_collection { viewport, applyToAll: true }`. Order of precedence: on the canvas, a temporary width from the width handle; then a viewport chosen for that story in the collection, then the story's own viewport, then the collection-wide setting, then the view's default size.
|
|
25
|
+
- **Threads.** Comment on an element inside a story, a whole story, or (from an agent) the collection as a whole. In comment mode (<kbd>C</kbd>) the element under the pointer is highlighted; click to start a thread on it, or press <kbd>Enter</kbd> or <kbd>Space</kbd> on a focused story to start one on the whole story. Threads have replies and are open or resolved.
|
|
26
|
+
- **Thread sidebar.** Lists every thread by story, with filters (Open, Waiting on me, Resolved, All) and counts. Opening a thread scrolls its story and element into view. <kbd>J</kbd>/<kbd>K</kbd> move to the next or previous open thread. Agent replies are marked, and threads waiting on you say "Agent replied", or "Agent asked" when the agent started the thread. The sidebar stays usable while you write a new comment, and the text you typed is kept.
|
|
27
|
+
- **Notes on stories.** Each story in a collection can have a short note (what to look at), shown in its header. Agents set them with `set_story_note`.
|
|
28
|
+
- **Collection description**, shown next to the collection name.
|
|
29
|
+
- **Reorder and remove.** Drag a story's grip, or use its arrow keys, to reorder. Remove a story from its header, with Undo. Drop a story from the sidebar where it should go.
|
|
30
|
+
- **Agent tools for building collections:** `find_stories`, `create_collection`, `add_stories`, `remove_story`, `set_story_note`, `set_story_viewport`, `reorder_stories`, `update_collection` and `set_story_positions`. Every result includes the collection link (`url`). Story ids are checked against Storybook's index, and viewport names against the project's viewport list.
|
|
31
|
+
- **Agent tools for threads:** `list_threads` (with `waitingOn` to find threads waiting on the agent or the user), `start_thread`, `reply_to_thread`, `resolve_thread` and `reopen_thread`. Each thread says who spoke last (`lastAuthor`) and who is expected to answer (`waitingOn`), and an element thread says whether the collection page found its element (`location.match`: matched, ambiguous with the number of matches, missing, or unchecked), so an agent whose selector matched several elements knows to use a more specific one.
|
|
32
|
+
- **A limit on message length:** a comment or reply is at most 10,000 characters, in the file, from the page and from the agent tools. The comment and reply boxes count characters near the limit and won't send past it (the text is kept); the agent tools return an error that says the limit.
|
|
33
|
+
|
|
34
|
+
### Changed
|
|
35
|
+
|
|
36
|
+
- **Collection file version 3.** Collections are an ordered list of stories (`items`) with a `view`, an optional `description` and `viewport`, and `threads`. It is the only version read; see **Breaking** above. Sizes and drawings are gone from the format; an item's optional `position` is its place in the Canvas view.
|
|
37
|
+
- **Agent tool names.** The 0.1.0 comment tools (`list_canvas_comments`, `add_canvas_comment`, `reply_to_canvas_comment`, `resolve_canvas_comment`, `reopen_canvas_comment`) are replaced by the thread tools above. Results use `itemId`, `stories` and `threadId` instead of frames and comments.
|
|
38
|
+
- **Storybook 11 stable.** The peer dependency is `storybook: ^11.0.0`; the addon is built and tested against 11.0.1.
|
|
39
|
+
- **Published under `latest`**, no longer under `next`.
|
|
40
|
+
- **Storybook's toolbar zoom** is shown on collection pages and zooms the stories; pins and highlights stay on their elements at any zoom, and the thread sidebar keeps its size. The Canvas view uses its own zoom instead.
|
|
41
|
+
- Saving a collection, or creating, renaming or deleting another one, no longer reloads the stories on an open collection page.
|
|
42
|
+
|
|
43
|
+
### Removed
|
|
44
|
+
|
|
45
|
+
- The free-form board: positions, resizing, pan and zoom, and the 0.1.0 renderer built on HTML-in-Canvas. The Chrome 157 requirement goes with it; collections work in any browser Storybook supports.
|
|
46
|
+
- Freehand drawing and the eraser.
|
|
47
|
+
- Undo and redo (<kbd>⌘</kbd>/<kbd>Ctrl</kbd>+<kbd>Z</kbd>). Removing a story shows an **Undo** button instead.
|
|
48
|
+
|
|
49
|
+
### Known limitations
|
|
50
|
+
|
|
51
|
+
- Comment mode needs a pointer to pick an element; from the keyboard you can start a thread on a whole story only. Elements inside a shadow root or a nested iframe can't be picked.
|
|
52
|
+
- A comment pin can detach from its element when the element's text or accessible name changes and it has no test id or id, and in rare cases attach to an identical look-alike.
|
|
53
|
+
- People can't start a thread in the collection as a whole or edit a story's note from the page; agents can (`start_thread`, `set_story_note`), or edit the file.
|
|
54
|
+
- After a reorder, <kbd>Tab</kbd> follows the order stories were added in until the page reloads.
|
|
55
|
+
- The MCP endpoint has no authentication, like the rest of Storybook's dev server.
|
|
56
|
+
|
|
57
|
+
See the README for the full list.
|
|
4
58
|
|
|
5
59
|
## [0.1.0] - 2026-11-25
|
|
6
60
|
|
|
@@ -33,4 +87,5 @@ The first pre-release. Install it with `npm install -D storybook-addon-colab@nex
|
|
|
33
87
|
|
|
34
88
|
See [Known limitations](https://github.com/winkerVSbecks/addon-colab#known-limitations) and [How comment pins find their element](https://github.com/winkerVSbecks/addon-colab#how-comment-pins-find-their-element-and-when-they-dont) in the README for the full list.
|
|
35
89
|
|
|
90
|
+
[0.2.0]: https://github.com/winkerVSbecks/addon-colab/compare/v0.1.0...v0.2.0
|
|
36
91
|
[0.1.0]: https://github.com/winkerVSbecks/addon-colab/releases/tag/v0.1.0
|