Merge branch 'future/tsup-renderers-1' into future/tsup-frameworks-1

# Conflicts:
#	frameworks/html-webpack5/package.json
#	frameworks/preact-webpack5/package.json
#	frameworks/react-webpack5/package.json
#	frameworks/server-webpack5/package.json
#	frameworks/svelte-webpack5/package.json
#	frameworks/vue-webpack5/package.json
#	frameworks/vue3-webpack5/package.json
#	frameworks/web-components-webpack5/package.json
#	yarn.lock
This commit is contained in:
Norbert de Langen 2022-06-23 09:56:14 +02:00
commit f871b9c083
No known key found for this signature in database
GPG Key ID: FD0E78AF9A837762
141 changed files with 1743 additions and 1583 deletions

View File

@ -1,3 +1,20 @@
## 7.0.0-alpha.6 (June 21, 2022)
### Bug Fixes
- Interactions: Reset instrumenter state on HMR ([#18516](https://github.com/storybookjs/storybook/pull/18516))
- Interactions: Prevent showing child exception while parent is still playing ([#18518](https://github.com/storybookjs/storybook/pull/18518))
### Maintenance
- Docs2 core: Fetch `index.json` for composition ([#18521](https://github.com/storybookjs/storybook/pull/18521))
- Addon-docs: Switch Meta block to receive all module exports ([#18514](https://github.com/storybookjs/storybook/pull/18514))
- Re-add deprecated fields to lib/api ([#18488](https://github.com/storybookjs/storybook/pull/18488))
- Core: Handle v3 index in composition ([#18498](https://github.com/storybookjs/storybook/pull/18498))
- Story index: Ensure that `extract` script works and SBs can be composed into v6 storybooks ([#18409](https://github.com/storybookjs/storybook/pull/18409))
- Docs2: Handle new docs entries in the preview ([#18099](https://github.com/storybookjs/storybook/pull/18099))
- Docs2: Refactor manager to use new index data ([#18023](https://github.com/storybookjs/storybook/pull/18023))
## 7.0.0-alpha.5 (June 20, 2022)
### Bug Fixes

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-a11y",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Test component compliance with web accessibility standards",
"keywords": [
"a11y",
@ -38,14 +38,14 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/channels": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/channels": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.6",
"axe-core": "^4.2.0",
"core-js": "^3.8.2",
"global": "^4.4.0",
@ -72,7 +72,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Accessibility",
"icon": "https://user-images.githubusercontent.com/263385/101991665-47042f80-3c7c-11eb-8f00-64b5a18f498a.png",

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-actions",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Get UI feedback when an action is performed on an interactive element",
"keywords": [
"storybook",
@ -34,13 +34,13 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"fast-deep-equal": "^3.1.3",
"global": "^4.4.0",
@ -71,7 +71,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Actions",
"unsupportedFrameworks": [

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-backgrounds",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Switch backgrounds to view components in different settings",
"keywords": [
"addon",
@ -38,13 +38,13 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"global": "^4.4.0",
"memoizerific": "^1.11.3",
@ -66,7 +66,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Backgrounds",
"icon": "https://user-images.githubusercontent.com/263385/101991667-479cc600-3c7c-11eb-96d3-410e936252e7.png",

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-controls",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Interact with component inputs dynamically in the Storybook UI",
"keywords": [
"addon",
@ -38,15 +38,15 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/store": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.6",
"@storybook/store": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"lodash": "^4.17.21",
"ts-dedent": "^2.0.0"
@ -66,7 +66,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Controls",
"icon": "https://user-images.githubusercontent.com/263385/101991669-479cc600-3c7c-11eb-93d9-38b67e8371f2.png",

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-docs",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Document component usage and properties in Markdown",
"keywords": [
"addon",
@ -52,21 +52,21 @@
"@babel/preset-env": "^7.12.11",
"@jest/transform": "^26.6.2",
"@mdx-js/react": "^1.6.22",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/csf-tools": "7.0.0-alpha.5",
"@storybook/docs-tools": "7.0.0-alpha.5",
"@storybook/csf-tools": "7.0.0-alpha.6",
"@storybook/docs-tools": "7.0.0-alpha.6",
"@storybook/mdx1-csf": "^0.0.1",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/postinstall": "7.0.0-alpha.5",
"@storybook/preview-web": "7.0.0-alpha.5",
"@storybook/source-loader": "7.0.0-alpha.5",
"@storybook/store": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.6",
"@storybook/postinstall": "7.0.0-alpha.6",
"@storybook/preview-web": "7.0.0-alpha.6",
"@storybook/source-loader": "7.0.0-alpha.6",
"@storybook/store": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"babel-loader": "^8.2.5",
"core-js": "^3.8.2",
"fast-deep-equal": "^3.1.3",
@ -101,7 +101,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Docs",
"icon": "https://user-images.githubusercontent.com/263385/101991672-48355c80-3c7c-11eb-82d9-95fa12438f64.png",

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-essentials",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Curated addons to bring out the best of Storybook",
"keywords": [
"addon",
@ -32,24 +32,24 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-backgrounds": "7.0.0-alpha.5",
"@storybook/addon-controls": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/addon-measure": "7.0.0-alpha.5",
"@storybook/addon-outline": "7.0.0-alpha.5",
"@storybook/addon-toolbars": "7.0.0-alpha.5",
"@storybook/addon-viewport": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-backgrounds": "7.0.0-alpha.6",
"@storybook/addon-controls": "7.0.0-alpha.6",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/addon-measure": "7.0.0-alpha.6",
"@storybook/addon-outline": "7.0.0-alpha.6",
"@storybook/addon-toolbars": "7.0.0-alpha.6",
"@storybook/addon-viewport": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/node-logger": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"ts-dedent": "^2.0.0"
},
"devDependencies": {
"@babel/core": "^7.12.10",
"@storybook/vue": "7.0.0-alpha.5",
"@storybook/vue": "7.0.0-alpha.6",
"@types/jest": "^26.0.16"
},
"peerDependencies": {
@ -96,5 +96,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-interactions",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Automate, test and debug user interactions",
"keywords": [
"storybook-addons",
@ -35,15 +35,15 @@
},
"dependencies": {
"@devtools-ds/object-inspector": "^1.1.2",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/instrumenter": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/instrumenter": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"global": "^4.4.0",
"jest-mock": "^27.0.6",
@ -70,7 +70,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Interactions",
"unsupportedFrameworks": [

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-jest",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "React storybook addon that show component jest report",
"keywords": [
"addon",
@ -40,12 +40,12 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"global": "^4.4.0",
"react-sizeme": "^3.0.1",
@ -66,7 +66,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Jest",
"icon": "https://pbs.twimg.com/profile_images/821713465245102080/mMtKIMax_400x400.jpg",

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-links",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Link stories together to build demos and prototypes with your UI components",
"keywords": [
"addon",
@ -34,11 +34,11 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/router": "7.0.0-alpha.5",
"@storybook/router": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"global": "^4.4.0",
"prop-types": "^15.7.2",
@ -59,7 +59,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Links",
"icon": "https://user-images.githubusercontent.com/263385/101991673-48355c80-3c7c-11eb-9b6e-b627c96a75f6.png",

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-measure",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Inspect layouts by visualizing the box model",
"keywords": [
"storybook-addons",
@ -37,11 +37,11 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"core-js": "^3.8.2",
"global": "^4.4.0"
@ -61,7 +61,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Measure",
"unsupportedFrameworks": [

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-outline",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Outline all elements with CSS to help with layout placement and alignment",
"keywords": [
"storybook-addons",
@ -40,11 +40,11 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"core-js": "^3.8.2",
"global": "^4.4.0",
@ -65,7 +65,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Outline",
"unsupportedFrameworks": [

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-storyshots",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Take a code snapshot of every story automatically with Jest",
"keywords": [
"addon",
@ -38,12 +38,12 @@
},
"dependencies": {
"@jest/transform": "^26.6.2",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/babel-plugin-require-context-hook": "1.0.1",
"@storybook/client-api": "7.0.0-alpha.5",
"@storybook/core-client": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/core-webpack": "7.0.0-alpha.5",
"@storybook/client-api": "7.0.0-alpha.6",
"@storybook/core-client": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/core-webpack": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@types/glob": "^7.1.3",
"@types/jest": "^26.0.16",
@ -62,11 +62,11 @@
"@angular/core": "^13.3.6",
"@angular/platform-browser-dynamic": "^13.3.6",
"@emotion/jest": "^11.8.0",
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/angular": "7.0.0-alpha.5",
"@storybook/react": "7.0.0-alpha.5",
"@storybook/vue": "7.0.0-alpha.5",
"@storybook/vue3": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/angular": "7.0.0-alpha.6",
"@storybook/react": "7.0.0-alpha.6",
"@storybook/vue": "7.0.0-alpha.6",
"@storybook/vue3": "7.0.0-alpha.6",
"babel-loader": "^8.2.5",
"enzyme": "^3.11.0",
"enzyme-to-json": "^3.6.1",
@ -143,7 +143,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Storyshots",
"icon": "https://user-images.githubusercontent.com/263385/101991676-48cdf300-3c7c-11eb-8aa1-944dab6ab29b.png",

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-storyshots-puppeteer",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Image snapshots addition to StoryShots based on puppeteer",
"keywords": [
"addon",
@ -35,7 +35,7 @@
"dependencies": {
"@axe-core/puppeteer": "^4.2.0",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.6",
"@types/jest-image-snapshot": "^4.1.3",
"core-js": "^3.8.2",
"jest-image-snapshot": "^4.3.0"
@ -45,7 +45,7 @@
"@types/puppeteer": "^5.4.0"
},
"peerDependencies": {
"@storybook/addon-storyshots": "7.0.0-alpha.5",
"@storybook/addon-storyshots": "7.0.0-alpha.6",
"puppeteer": "^2.0.0 || ^3.0.0"
},
"peerDependenciesMeta": {
@ -56,5 +56,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-storysource",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "View a storys source code to see how it works and paste into your app",
"keywords": [
"addon",
@ -34,13 +34,13 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/router": "7.0.0-alpha.5",
"@storybook/source-loader": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/router": "7.0.0-alpha.6",
"@storybook/source-loader": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"estraverse": "^5.2.0",
"prop-types": "^15.7.2",
@ -65,7 +65,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Storysource",
"icon": "https://user-images.githubusercontent.com/263385/101991675-48cdf300-3c7c-11eb-9400-58de5ac6daa7.png",

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-toolbars",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Create your own toolbar items that control story rendering",
"keywords": [
"addon",
@ -38,11 +38,11 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"core-js": "^3.8.2"
},
"peerDependencies": {
@ -60,7 +60,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Toolbars",
"icon": "https://user-images.githubusercontent.com/263385/101991677-48cdf300-3c7c-11eb-93b4-19b0e3366959.png",

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-viewport",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Build responsive components by adjusting Storybooks viewport size and orientation",
"keywords": [
"addon",
@ -35,12 +35,12 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"global": "^4.4.0",
"memoizerific": "^1.11.3",
@ -61,7 +61,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7",
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec",
"storybook": {
"displayName": "Viewport",
"icon": "https://user-images.githubusercontent.com/263385/101991678-48cdf300-3c7c-11eb-9764-f8af293c1b28.png",

View File

@ -1,6 +1,6 @@
{
"name": "angular-cli",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"license": "MIT",
"workspaces": {
@ -44,21 +44,21 @@
"@angular/compiler-cli": "^13.3.6",
"@angular/elements": "^13.3.6",
"@compodoc/compodoc": "^1.1.18",
"@storybook/addon-a11y": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-backgrounds": "7.0.0-alpha.5",
"@storybook/addon-controls": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/addon-interactions": "7.0.0-alpha.5",
"@storybook/addon-jest": "7.0.0-alpha.5",
"@storybook/addon-links": "7.0.0-alpha.5",
"@storybook/addon-storyshots": "7.0.0-alpha.5",
"@storybook/addon-storysource": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/angular": "7.0.0-alpha.5",
"@storybook/addon-a11y": "7.0.0-alpha.6",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-backgrounds": "7.0.0-alpha.6",
"@storybook/addon-controls": "7.0.0-alpha.6",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/addon-interactions": "7.0.0-alpha.6",
"@storybook/addon-jest": "7.0.0-alpha.6",
"@storybook/addon-links": "7.0.0-alpha.6",
"@storybook/addon-storyshots": "7.0.0-alpha.6",
"@storybook/addon-storysource": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/angular": "7.0.0-alpha.6",
"@storybook/babel-plugin-require-context-hook": "1.0.1",
"@storybook/jest": "^0.0.5",
"@storybook/source-loader": "7.0.0-alpha.5",
"@storybook/source-loader": "7.0.0-alpha.6",
"@storybook/testing-library": "^0.0.12",
"@types/core-js": "^2.5.4",
"@types/jest": "^26.0.16",
@ -71,7 +71,7 @@
"jest": "^26.6.3",
"jest-preset-angular": "^8.3.2",
"protractor": "~7.0.0",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"storybook-addon-angular-ivy": "^0.0.1",
"ts-jest": "^26.4.4",
"ts-node": "^10.4.0",

View File

@ -1,6 +1,6 @@
{
"name": "cra-kitchen-sink",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"build": "react-scripts build",
@ -11,7 +11,7 @@
"test": "react-scripts test --env=jsdom"
},
"dependencies": {
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.6",
"global": "^4.4.0",
"prop-types": "^15.7.2",
"react": "16.14.0",
@ -21,20 +21,20 @@
},
"devDependencies": {
"@pmmmwh/react-refresh-webpack-plugin": "^0.5.5",
"@storybook/addon-a11y": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-backgrounds": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/addon-jest": "7.0.0-alpha.5",
"@storybook/addon-links": "7.0.0-alpha.5",
"@storybook/addon-storyshots": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/addon-a11y": "7.0.0-alpha.6",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-backgrounds": "7.0.0-alpha.6",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/addon-jest": "7.0.0-alpha.6",
"@storybook/addon-links": "7.0.0-alpha.6",
"@storybook/addon-storyshots": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/preset-create-react-app": "^4.1.0",
"@storybook/react": "7.0.0-alpha.5",
"@storybook/react-webpack5": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.5",
"@storybook/react": "7.0.0-alpha.6",
"@storybook/react-webpack5": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"storybook": "7.0.0-alpha.6",
"webpack": "5"
},
"storybook": {

View File

@ -1,6 +1,6 @@
{
"name": "cra-ts-essentials",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"build": "react-scripts build",
@ -23,8 +23,8 @@
]
},
"dependencies": {
"@storybook/components": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"@types/jest": "^26.0.16",
"@types/node": "^14.14.20 || ^16.0.0",
"@types/react": "^16.14.23",
@ -37,14 +37,14 @@
"typescript": "~4.6.3"
},
"devDependencies": {
"@storybook/addon-essentials": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/addon-essentials": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/preset-create-react-app": "^4.1.0",
"@storybook/react": "7.0.0-alpha.5",
"@storybook/react-webpack5": "7.0.0-alpha.5",
"@storybook/react": "7.0.0-alpha.6",
"@storybook/react-webpack5": "7.0.0-alpha.6",
"@storybook/testing-library": "^0.0.9",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"ts-node": "^10.4.0",
"webpack": "5"
},

View File

@ -1,6 +1,6 @@
{
"name": "cra-ts-kitchen-sink",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"build": "react-scripts build",
@ -34,22 +34,22 @@
"typescript": "~4.6.3"
},
"devDependencies": {
"@storybook/addon-a11y": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/addon-links": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/addon-a11y": "7.0.0-alpha.6",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/addon-links": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/preset-create-react-app": "^4.1.0",
"@storybook/react": "7.0.0-alpha.5",
"@storybook/react-webpack5": "7.0.0-alpha.5",
"@storybook/react": "7.0.0-alpha.6",
"@storybook/react-webpack5": "7.0.0-alpha.6",
"@types/enzyme": "^3.10.8",
"enzyme": "^3.11.0",
"enzyme-adapter-react-16": "^1.9.1",
"enzyme-to-json": "^3.6.1",
"fork-ts-checker-webpack-plugin": "^7.2.6",
"react-moment-proptypes": "^1.7.0",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"ts-node": "^10.4.0",
"webpack": "5"
},

View File

@ -1,6 +1,6 @@
{
"name": "ember-example",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"--build-storybook": "yarn storybook-prebuild && storybook build",
@ -17,18 +17,18 @@
"devDependencies": {
"@babel/core": "^7.12.10",
"@ember/optional-features": "^2.0.0",
"@storybook/addon-a11y": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-backgrounds": "7.0.0-alpha.5",
"@storybook/addon-controls": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/addon-links": "7.0.0-alpha.5",
"@storybook/addon-storysource": "7.0.0-alpha.5",
"@storybook/addon-viewport": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/ember": "7.0.0-alpha.5",
"@storybook/addon-a11y": "7.0.0-alpha.6",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-backgrounds": "7.0.0-alpha.6",
"@storybook/addon-controls": "7.0.0-alpha.6",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/addon-links": "7.0.0-alpha.6",
"@storybook/addon-storysource": "7.0.0-alpha.6",
"@storybook/addon-viewport": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/ember": "7.0.0-alpha.6",
"@storybook/ember-cli-storybook": "^0.2.1",
"@storybook/source-loader": "7.0.0-alpha.5",
"@storybook/source-loader": "7.0.0-alpha.6",
"babel-loader": "^8.2.5",
"broccoli-asset-rev": "^3.0.0",
"browserify-zlib": "^0.2.0",
@ -48,7 +48,7 @@
"loader.js": "^4.7.0",
"os-browserify": "^0.3.0",
"shx": "^0.3.2",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"stream-browserify": "^3.0.0",
"vm-browserify": "^1.1.2",
"webpack": "5",

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/external-docs",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"build": "next build",
@ -11,14 +11,14 @@
"storybook": "cross-env STORYBOOK_DISPLAY_WARNING=true DISPLAY_WARNING=true storybook dev -p 9011 --no-manager-cache -c .storybook"
},
"dependencies": {
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/addon-essentials": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/addon-essentials": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/preview-web": "7.0.0-alpha.5",
"@storybook/react": "7.0.0-alpha.5",
"@storybook/react-webpack5": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/preview-web": "7.0.0-alpha.6",
"@storybook/react": "7.0.0-alpha.6",
"@storybook/react-webpack5": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"formik": "^2.2.9",
"next": "^12.1.0",
"nextra": "^1.1.0",
@ -37,7 +37,7 @@
"cross-env": "^7.0.3",
"eslint": "8.7.0",
"eslint-config-next": "12.0.8",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"typescript": "~4.6.3",
"webpack": "5"
}

View File

@ -1,6 +1,6 @@
{
"name": "html-kitchen-sink",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"description": "",
"keywords": [],
@ -13,30 +13,30 @@
"storybook": "storybook dev -p 9006 --no-manager-cache"
},
"devDependencies": {
"@storybook/addon-a11y": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-backgrounds": "7.0.0-alpha.5",
"@storybook/addon-controls": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/addon-jest": "7.0.0-alpha.5",
"@storybook/addon-links": "7.0.0-alpha.5",
"@storybook/addon-a11y": "7.0.0-alpha.6",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-backgrounds": "7.0.0-alpha.6",
"@storybook/addon-controls": "7.0.0-alpha.6",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/addon-jest": "7.0.0-alpha.6",
"@storybook/addon-links": "7.0.0-alpha.6",
"@storybook/addon-postcss": "^2.0.0",
"@storybook/addon-storyshots": "7.0.0-alpha.5",
"@storybook/addon-storysource": "7.0.0-alpha.5",
"@storybook/addon-viewport": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/client-api": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/html": "7.0.0-alpha.5",
"@storybook/html-webpack5": "7.0.0-alpha.5",
"@storybook/source-loader": "7.0.0-alpha.5",
"@storybook/addon-storyshots": "7.0.0-alpha.6",
"@storybook/addon-storysource": "7.0.0-alpha.6",
"@storybook/addon-viewport": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/client-api": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/html": "7.0.0-alpha.6",
"@storybook/html-webpack5": "7.0.0-alpha.6",
"@storybook/source-loader": "7.0.0-alpha.6",
"autoprefixer": "^10.0.1",
"eventemitter3": "^4.0.7",
"format-json": "^1.0.3",
"global": "^4.4.0",
"postcss": "^8.2.4",
"postcss-color-rebeccapurple": "^6.0.0",
"storybook": "7.0.0-alpha.5"
"storybook": "7.0.0-alpha.6"
},
"storybook": {
"chromatic": {

View File

@ -1,6 +1,6 @@
{
"name": "official-storybook",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"build-storybook": "cross-env STORYBOOK_DISPLAY_WARNING=true DISPLAY_WARNING=true storybook build -c ./",
@ -13,32 +13,32 @@
"devDependencies": {
"@emotion/jest": "^11.8.0",
"@pmmmwh/react-refresh-webpack-plugin": "^0.5.5",
"@storybook/addon-a11y": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-backgrounds": "7.0.0-alpha.5",
"@storybook/addon-controls": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/addon-interactions": "7.0.0-alpha.5",
"@storybook/addon-jest": "7.0.0-alpha.5",
"@storybook/addon-links": "7.0.0-alpha.5",
"@storybook/addon-storyshots": "7.0.0-alpha.5",
"@storybook/addon-storyshots-puppeteer": "7.0.0-alpha.5",
"@storybook/addon-storysource": "7.0.0-alpha.5",
"@storybook/addon-toolbars": "7.0.0-alpha.5",
"@storybook/addon-viewport": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/cli": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addon-a11y": "7.0.0-alpha.6",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-backgrounds": "7.0.0-alpha.6",
"@storybook/addon-controls": "7.0.0-alpha.6",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/addon-interactions": "7.0.0-alpha.6",
"@storybook/addon-jest": "7.0.0-alpha.6",
"@storybook/addon-links": "7.0.0-alpha.6",
"@storybook/addon-storyshots": "7.0.0-alpha.6",
"@storybook/addon-storyshots-puppeteer": "7.0.0-alpha.6",
"@storybook/addon-storysource": "7.0.0-alpha.6",
"@storybook/addon-toolbars": "7.0.0-alpha.6",
"@storybook/addon-viewport": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/cli": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/design-system": "^5.4.7",
"@storybook/jest": "^0.0.5",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/react": "7.0.0-alpha.5",
"@storybook/react-webpack5": "7.0.0-alpha.5",
"@storybook/router": "7.0.0-alpha.5",
"@storybook/source-loader": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.6",
"@storybook/react": "7.0.0-alpha.6",
"@storybook/react-webpack5": "7.0.0-alpha.6",
"@storybook/router": "7.0.0-alpha.6",
"@storybook/source-loader": "7.0.0-alpha.6",
"@storybook/testing-library": "^0.0.12",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.6",
"@testing-library/dom": "^7.31.2",
"@testing-library/user-event": "^13.1.9",
"chromatic": "^6.0.2",
@ -54,7 +54,7 @@
"prop-types": "^15.7.2",
"react": "16.14.0",
"react-dom": "16.14.0",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"terser-webpack-plugin": "^5.3.1",
"uuid-browser": "^3.1.0",
"webpack": "5"

View File

@ -1,6 +1,6 @@
{
"name": "preact-example",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"build": "cross-env NODE_ENV=production webpack --progress --hide-modules",
@ -15,17 +15,17 @@
"devDependencies": {
"@babel/core": "^7.12.10",
"@babel/plugin-transform-runtime": "^7.12.10",
"@storybook/addon-a11y": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-backgrounds": "7.0.0-alpha.5",
"@storybook/addon-links": "7.0.0-alpha.5",
"@storybook/addon-storyshots": "7.0.0-alpha.5",
"@storybook/addon-storysource": "7.0.0-alpha.5",
"@storybook/addon-viewport": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/preact": "7.0.0-alpha.5",
"@storybook/preact-webpack5": "7.0.0-alpha.5",
"@storybook/source-loader": "7.0.0-alpha.5",
"@storybook/addon-a11y": "7.0.0-alpha.6",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-backgrounds": "7.0.0-alpha.6",
"@storybook/addon-links": "7.0.0-alpha.6",
"@storybook/addon-storyshots": "7.0.0-alpha.6",
"@storybook/addon-storysource": "7.0.0-alpha.6",
"@storybook/addon-viewport": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/preact": "7.0.0-alpha.6",
"@storybook/preact-webpack5": "7.0.0-alpha.6",
"@storybook/source-loader": "7.0.0-alpha.6",
"@types/prop-types": "^15.7.3",
"@types/react": "^17",
"@types/react-dom": "^17",
@ -38,7 +38,7 @@
"raw-loader": "^4.0.2",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"svg-url-loader": "^7.1.1",
"webpack": "5",
"webpack-dev-server": "^4.8.1"

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/example-react-ts",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"build-storybook": "cross-env STORYBOOK_DISPLAY_WARNING=true DISPLAY_WARNING=true storybook build",
@ -17,15 +17,15 @@
"@babel/preset-env": "^7.12.11",
"@babel/preset-react": "^7.12.10",
"@babel/preset-typescript": "^7.12.7",
"@storybook/addon-essentials": "7.0.0-alpha.5",
"@storybook/addon-storyshots": "7.0.0-alpha.5",
"@storybook/addon-storysource": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/cli": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/react": "7.0.0-alpha.5",
"@storybook/react-webpack5": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/addon-essentials": "7.0.0-alpha.6",
"@storybook/addon-storyshots": "7.0.0-alpha.6",
"@storybook/addon-storysource": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/cli": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/react": "7.0.0-alpha.6",
"@storybook/react-webpack5": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"@testing-library/dom": "^7.31.2",
"@testing-library/react": "12.1.2",
"@testing-library/user-event": "^13.1.9",
@ -34,7 +34,7 @@
"@types/react-dom": "^16.9.14",
"cross-env": "^7.0.3",
"lodash": "^4.17.21",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"typescript": "~4.6.3",
"webpack": "5"
}

View File

@ -1,6 +1,6 @@
{
"name": "server-kitchen-sink",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"description": "",
"keywords": [],
@ -14,14 +14,14 @@
"storybook": "SERVER_PORT=1137 storybook dev -p 9006 --quiet"
},
"devDependencies": {
"@storybook/addon-a11y": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-backgrounds": "7.0.0-alpha.5",
"@storybook/addon-controls": "7.0.0-alpha.5",
"@storybook/addon-links": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/server": "7.0.0-alpha.5",
"@storybook/server-webpack5": "7.0.0-alpha.5",
"@storybook/addon-a11y": "7.0.0-alpha.6",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-backgrounds": "7.0.0-alpha.6",
"@storybook/addon-controls": "7.0.0-alpha.6",
"@storybook/addon-links": "7.0.0-alpha.6",
"@storybook/node-logger": "7.0.0-alpha.6",
"@storybook/server": "7.0.0-alpha.6",
"@storybook/server-webpack5": "7.0.0-alpha.6",
"concurrently": "^5.3.0",
"cors": "^2.8.5",
"express": "~4.17.1",
@ -29,6 +29,6 @@
"nodemon": "^2.0.7",
"pug": "^3.0.0",
"safe-identifier": "^0.4.1",
"storybook": "7.0.0-alpha.5"
"storybook": "7.0.0-alpha.6"
}
}

View File

@ -1,20 +1,20 @@
{
"name": "standalone-preview",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"storybook": "cross-env STORYBOOK_DISPLAY_WARNING=true DISPLAY_WARNING=true storybook dev -p 9011 -c ../official-storybook --no-manager-cache --preview-url=http://localhost:1337/external-iframe.html",
"storybook-preview": "cross-env PREVIEW_URL=external-iframe.html parcel ./storybook.html --port 1337"
},
"devDependencies": {
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/cli": "7.0.0-alpha.5",
"@storybook/react": "7.0.0-alpha.5",
"@storybook/react-webpack5": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/cli": "7.0.0-alpha.6",
"@storybook/react": "7.0.0-alpha.6",
"@storybook/react-webpack5": "7.0.0-alpha.6",
"cross-env": "^7.0.3",
"parcel": "2.0.1",
"react": "16.14.0",
"react-dom": "16.14.0",
"storybook": "7.0.0-alpha.5"
"storybook": "7.0.0-alpha.6"
}
}

View File

@ -1,6 +1,6 @@
{
"name": "svelte-example",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"build-storybook": "storybook build",
@ -10,23 +10,23 @@
"global": "^4.4.0"
},
"devDependencies": {
"@storybook/addon-a11y": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-backgrounds": "7.0.0-alpha.5",
"@storybook/addon-controls": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/addon-interactions": "7.0.0-alpha.5",
"@storybook/addon-links": "7.0.0-alpha.5",
"@storybook/addon-storyshots": "7.0.0-alpha.5",
"@storybook/addon-storysource": "7.0.0-alpha.5",
"@storybook/addon-viewport": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/addon-a11y": "7.0.0-alpha.6",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-backgrounds": "7.0.0-alpha.6",
"@storybook/addon-controls": "7.0.0-alpha.6",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/addon-interactions": "7.0.0-alpha.6",
"@storybook/addon-links": "7.0.0-alpha.6",
"@storybook/addon-storyshots": "7.0.0-alpha.6",
"@storybook/addon-storysource": "7.0.0-alpha.6",
"@storybook/addon-viewport": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/jest": "^0.0.5",
"@storybook/source-loader": "7.0.0-alpha.5",
"@storybook/svelte": "7.0.0-alpha.5",
"@storybook/svelte-webpack5": "7.0.0-alpha.5",
"@storybook/source-loader": "7.0.0-alpha.6",
"@storybook/svelte": "7.0.0-alpha.6",
"@storybook/svelte-webpack5": "7.0.0-alpha.6",
"@storybook/testing-library": "^0.0.7",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"svelte-jester": "^2.3.2",
"svelte-preprocess": "^4.10.6"
},

View File

@ -1,6 +1,6 @@
{
"name": "vue-3-cli-example",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"build": "vue-cli-service build",
@ -14,21 +14,21 @@
},
"devDependencies": {
"@babel/core": "^7.12.10",
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-essentials": "7.0.0-alpha.5",
"@storybook/addon-interactions": "7.0.0-alpha.5",
"@storybook/addon-links": "7.0.0-alpha.5",
"@storybook/addon-storyshots": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-essentials": "7.0.0-alpha.6",
"@storybook/addon-interactions": "7.0.0-alpha.6",
"@storybook/addon-links": "7.0.0-alpha.6",
"@storybook/addon-storyshots": "7.0.0-alpha.6",
"@storybook/jest": "^0.0.5",
"@storybook/testing-library": "^0.0.12",
"@storybook/vue3": "7.0.0-alpha.5",
"@storybook/vue3-webpack5": "7.0.0-alpha.5",
"@storybook/vue3": "7.0.0-alpha.6",
"@storybook/vue3-webpack5": "7.0.0-alpha.6",
"@vue/cli-plugin-babel": "^5.0.4",
"@vue/cli-plugin-typescript": "^5.0.4",
"@vue/cli-service": "^5.0.4",
"@vue/compiler-sfc": "^3.2.36",
"babel-loader": "^8.2.5",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"typescript": "~4.6.3",
"vue-jest": "^5.0.0-alpha.8",
"vue-loader": "^16.0.0"

View File

@ -1,6 +1,6 @@
{
"name": "vue-cli-example",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"build": "vue-cli-service build",
@ -15,16 +15,16 @@
"vue-property-decorator": "^9.1.2"
},
"devDependencies": {
"@storybook/addon-controls": "7.0.0-alpha.5",
"@storybook/addon-essentials": "7.0.0-alpha.5",
"@storybook/addon-controls": "7.0.0-alpha.6",
"@storybook/addon-essentials": "7.0.0-alpha.6",
"@storybook/preset-scss": "^1.0.3",
"@storybook/source-loader": "7.0.0-alpha.5",
"@storybook/vue": "7.0.0-alpha.5",
"@storybook/vue-webpack5": "7.0.0-alpha.5",
"@storybook/source-loader": "7.0.0-alpha.6",
"@storybook/vue": "7.0.0-alpha.6",
"@storybook/vue-webpack5": "7.0.0-alpha.6",
"@vue/cli-plugin-babel": "^5.0.4",
"@vue/cli-plugin-typescript": "^5.0.4",
"@vue/cli-service": "^5.0.4",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"typescript": "~4.6.3",
"vue-template-compiler": "^2.6.14"
}

View File

@ -1,6 +1,6 @@
{
"name": "vue-example",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"scripts": {
"build": "cross-env NODE_ENV=production webpack --progress --hide-modules",
@ -14,28 +14,28 @@
},
"devDependencies": {
"@babel/core": "^7.12.10",
"@storybook/addon-a11y": "7.0.0-alpha.5",
"@storybook/addon-actions": "7.0.0-alpha.5",
"@storybook/addon-backgrounds": "7.0.0-alpha.5",
"@storybook/addon-controls": "7.0.0-alpha.5",
"@storybook/addon-docs": "7.0.0-alpha.5",
"@storybook/addon-interactions": "7.0.0-alpha.5",
"@storybook/addon-links": "7.0.0-alpha.5",
"@storybook/addon-storyshots": "7.0.0-alpha.5",
"@storybook/addon-storysource": "7.0.0-alpha.5",
"@storybook/addon-viewport": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/addon-a11y": "7.0.0-alpha.6",
"@storybook/addon-actions": "7.0.0-alpha.6",
"@storybook/addon-backgrounds": "7.0.0-alpha.6",
"@storybook/addon-controls": "7.0.0-alpha.6",
"@storybook/addon-docs": "7.0.0-alpha.6",
"@storybook/addon-interactions": "7.0.0-alpha.6",
"@storybook/addon-links": "7.0.0-alpha.6",
"@storybook/addon-storyshots": "7.0.0-alpha.6",
"@storybook/addon-storysource": "7.0.0-alpha.6",
"@storybook/addon-viewport": "7.0.0-alpha.6",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/jest": "^0.0.5",
"@storybook/source-loader": "7.0.0-alpha.5",
"@storybook/source-loader": "7.0.0-alpha.6",
"@storybook/testing-library": "^0.0.12",
"@storybook/vue": "7.0.0-alpha.5",
"@storybook/vue-webpack5": "7.0.0-alpha.5",
"@storybook/vue": "7.0.0-alpha.6",
"@storybook/vue-webpack5": "7.0.0-alpha.6",
"@vue/babel-preset-jsx": "^1.2.4",
"babel-loader": "^8.2.5",
"cross-env": "^7.0.3",
"file-loader": "^6.2.0",
"prop-types": "^15.7.2",
"storybook": "7.0.0-alpha.5",
"storybook": "7.0.0-alpha.6",
"svg-url-loader": "^7.1.1",
"vue-loader": "^15.9.6",
"vue-style-loader": "^4.1.3",

View File

@ -1,6 +1,6 @@
{
"name": "web-components-kitchen-sink",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"private": true,
"description": "",
"keywords": [],

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/angular",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook for Angular: Develop Angular components in isolation with hot reloading.",
"keywords": [
"storybook",
@ -33,19 +33,19 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/core-client": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/core-server": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/core-client": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/core-server": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/docs-tools": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/docs-tools": "7.0.0-alpha.6",
"@storybook/node-logger": "7.0.0-alpha.6",
"@storybook/semver": "^7.3.2",
"@storybook/store": "7.0.0-alpha.5",
"@storybook/store": "7.0.0-alpha.6",
"@types/node": "^14.14.20 || ^16.0.0",
"@types/react": "^16.14.23",
"@types/react-dom": "^16.9.14",
@ -127,5 +127,5 @@
"access": "public"
},
"builders": "dist/types/builders/builders.json",
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/ember",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook for Ember: Develop Ember Component in isolation with Hot Reloading.",
"homepage": "https://github.com/storybookjs/storybook/tree/main/frameworks/ember",
"bugs": {
@ -29,11 +29,11 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/core-client": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/docs-tools": "7.0.0-alpha.5",
"@storybook/store": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/core-client": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/docs-tools": "7.0.0-alpha.6",
"@storybook/store": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"global": "^4.4.0",
"react": "16.14.0",
@ -53,5 +53,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/html-webpack5",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook for HTML: View HTML snippets in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -49,10 +49,10 @@
"prepare": "esrun ../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/html": "7.0.0-alpha.5",
"@storybook/preset-html-webpack": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/html": "7.0.0-alpha.6",
"@storybook/preset-html-webpack": "7.0.0-alpha.6",
"@types/node": "^14.14.20 || ^16.0.0",
"core-js": "^3.8.2",
"global": "^4.4.0",
@ -75,5 +75,5 @@
"./src/index.ts",
"./src/preset.ts"
],
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/preact-webpack5",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook for Preact: Develop Preact Component in isolation.",
"keywords": [
"storybook"
@ -49,10 +49,10 @@
"prepare": "esrun ../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/preact": "7.0.0-alpha.5",
"@storybook/preset-preact-webpack": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/preact": "7.0.0-alpha.6",
"@storybook/preset-preact-webpack": "7.0.0-alpha.6",
"@types/node": "^14.14.20 || ^16.0.0",
"core-js": "^3.8.2",
"react": "16.14.0",
@ -76,5 +76,5 @@
"./src/index.ts",
"./src/preset.ts"
],
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/react-webpack5",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook for React: Develop React Component in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -50,9 +50,9 @@
"prepare": "esrun ../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/preset-react-webpack": "7.0.0-alpha.5",
"@storybook/react": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/preset-react-webpack": "7.0.0-alpha.6",
"@storybook/react": "7.0.0-alpha.6",
"@types/node": "^14.14.20 || ^16.0.0",
"core-js": "^3.8.2"
},
@ -83,5 +83,5 @@
"./src/index.ts",
"./src/preset.ts"
],
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/server-webpack5",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook for Server: View HTML snippets from a server in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -49,10 +49,10 @@
"prepare": "esrun ../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/preset-server-webpack": "7.0.0-alpha.5",
"@storybook/server": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/preset-server-webpack": "7.0.0-alpha.6",
"@storybook/server": "7.0.0-alpha.6",
"@types/node": "^14.14.20 || ^16.0.0",
"core-js": "^3.8.2",
"react": "16.14.0",
@ -71,5 +71,5 @@
"./src/index.ts",
"./src/preset.ts"
],
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/svelte-webpack5",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook for Svelte: Develop Svelte Component in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -50,10 +50,10 @@
"prepare": "esrun ../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/preset-svelte-webpack": "7.0.0-alpha.5",
"@storybook/svelte": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/preset-svelte-webpack": "7.0.0-alpha.6",
"@storybook/svelte": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"react": "16.14.0",
"react-dom": "16.14.0"
@ -78,5 +78,5 @@
"./src/index.ts",
"./src/preset.ts"
],
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/vue-webpack5",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook for Vue: Develop Vue Component in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -49,10 +49,10 @@
"prepare": "esrun ../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/preset-vue-webpack": "7.0.0-alpha.5",
"@storybook/vue": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/preset-vue-webpack": "7.0.0-alpha.6",
"@storybook/vue": "7.0.0-alpha.6",
"@types/node": "^14.14.20 || ^16.0.0",
"core-js": "^3.8.2",
"react": "16.14.0",
@ -82,5 +82,5 @@
"./src/index.ts",
"./src/preset.ts"
],
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/vue3-webpack5",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook for Vue 3: Develop Vue 3 Components in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -49,10 +49,10 @@
"prepare": "esrun ../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/preset-vue3-webpack": "7.0.0-alpha.5",
"@storybook/vue3": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/preset-vue3-webpack": "7.0.0-alpha.6",
"@storybook/vue3": "7.0.0-alpha.6",
"@types/node": "^14.14.20 || ^16.0.0",
"core-js": "^3.8.2",
"react": "16.14.0",
@ -79,5 +79,5 @@
"./src/index.ts",
"./src/preset.ts"
],
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/web-components-webpack5",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook for web-components: View web components snippets in isolation with Hot Reloading.",
"keywords": [
"lit-html",
@ -52,10 +52,10 @@
},
"dependencies": {
"@babel/preset-env": "^7.12.11",
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/preset-web-components-webpack": "7.0.0-alpha.5",
"@storybook/web-components": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/preset-web-components-webpack": "7.0.0-alpha.6",
"@storybook/web-components": "7.0.0-alpha.6",
"@types/node": "^14.14.20 || ^16.0.0",
"core-js": "^3.8.2",
"react": "16.14.0",
@ -78,5 +78,5 @@
"./src/index.ts",
"./src/preset.ts"
],
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -2,5 +2,5 @@
"npmClient": "yarn",
"useWorkspaces": true,
"registry": "https://registry.npmjs.org",
"version": "7.0.0-alpha.5"
"version": "7.0.0-alpha.6"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addons",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook addons store",
"keywords": [
"storybook"
@ -33,13 +33,13 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/api": "7.0.0-alpha.5",
"@storybook/channels": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/channels": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/router": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/router": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"@types/webpack-env": "^1.16.4",
"core-js": "^3.8.2",
"global": "^4.4.0"
@ -51,5 +51,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -12,6 +12,7 @@ import type {
StoryKind,
StoryName,
Args,
ComponentTitle,
} from '@storybook/csf';
import { Addon } from './index';
@ -50,18 +51,29 @@ export interface StorySortObjectParameter {
includeNames?: boolean;
}
interface StoryIndexEntry {
type Path = string;
interface BaseIndexEntry {
id: StoryId;
name: StoryName;
title: string;
importPath: string;
title: ComponentTitle;
importPath: Path;
}
export type StoryIndexEntry = BaseIndexEntry & {
type: 'story';
};
export type DocsIndexEntry = BaseIndexEntry & {
storiesImports: Path[];
type: 'docs';
legacy?: boolean;
};
export type IndexEntry = StoryIndexEntry | DocsIndexEntry;
// The `any` here is the story store's `StoreItem` record. Ideally we should probably only
// pass a defined subset of that full data, but we pass it all so far :shrug:
export type StorySortComparator = Comparator<[StoryId, any, Parameters, Parameters]>;
export type StorySortParameter = StorySortComparator | StorySortObjectParameter;
export type StorySortComparatorV7 = Comparator<StoryIndexEntry>;
export type StorySortComparatorV7 = Comparator<IndexEntry>;
export type StorySortParameterV7 = StorySortComparatorV7 | StorySortObjectParameter;
// TODO: remove all these types, they belong in the renderer and csf-package

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/api",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Core Storybook API & Context",
"keywords": [
"storybook"
@ -31,13 +31,13 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/channels": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/channels": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/router": "7.0.0-alpha.5",
"@storybook/router": "7.0.0-alpha.6",
"@storybook/semver": "^7.3.2",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"fast-deep-equal": "^3.1.3",
"global": "^4.4.0",
@ -63,5 +63,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1 +1 @@
export const version = '7.0.0-alpha.5';
export const version = '7.0.0-alpha.6';

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/builder-webpack5",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook framework-agnostic API",
"keywords": [
"storybook"
@ -33,23 +33,23 @@
},
"dependencies": {
"@babel/core": "^7.12.10",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/api": "7.0.0-alpha.5",
"@storybook/channel-postmessage": "7.0.0-alpha.5",
"@storybook/channel-websocket": "7.0.0-alpha.5",
"@storybook/channels": "7.0.0-alpha.5",
"@storybook/client-api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/components": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/core-webpack": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/preview-web": "7.0.0-alpha.5",
"@storybook/router": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/api": "7.0.0-alpha.6",
"@storybook/channel-postmessage": "7.0.0-alpha.6",
"@storybook/channel-websocket": "7.0.0-alpha.6",
"@storybook/channels": "7.0.0-alpha.6",
"@storybook/client-api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/components": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/core-webpack": "7.0.0-alpha.6",
"@storybook/node-logger": "7.0.0-alpha.6",
"@storybook/preview-web": "7.0.0-alpha.6",
"@storybook/router": "7.0.0-alpha.6",
"@storybook/semver": "^7.3.2",
"@storybook/store": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/store": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"@types/node": "^14.0.10 || ^16.0.0",
"babel-loader": "^8.2.5",
"babel-plugin-named-exports-order": "^0.0.2",
@ -93,5 +93,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/channel-postmessage",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "",
"keywords": [
"storybook"
@ -33,9 +33,9 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/channels": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/channels": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"global": "^4.4.0",
"qs": "^6.10.0",
@ -44,5 +44,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/channel-websocket",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "",
"keywords": [
"storybook"
@ -33,8 +33,8 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/channels": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/channels": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"global": "^4.4.0",
"telejson": "^6.0.8"
@ -42,5 +42,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/channels",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "",
"keywords": [
"storybook"
@ -40,5 +40,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "sb",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook CLI",
"keywords": [
"storybook"
@ -24,10 +24,10 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/cli": "7.0.0-alpha.5"
"@storybook/cli": "7.0.0-alpha.6"
},
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "storybook",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook CLI",
"keywords": [
"storybook"
@ -27,10 +27,10 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/cli": "7.0.0-alpha.5"
"@storybook/cli": "7.0.0-alpha.6"
},
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/cli",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook's CLI - easiest method of adding storybook to your projects",
"keywords": [
"cli",
@ -47,13 +47,13 @@
"dependencies": {
"@babel/core": "^7.12.10",
"@babel/preset-env": "^7.12.11",
"@storybook/codemod": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/core-server": "7.0.0-alpha.5",
"@storybook/csf-tools": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/codemod": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/core-server": "7.0.0-alpha.6",
"@storybook/csf-tools": "7.0.0-alpha.6",
"@storybook/node-logger": "7.0.0-alpha.6",
"@storybook/semver": "^7.3.2",
"@storybook/telemetry": "7.0.0-alpha.5",
"@storybook/telemetry": "7.0.0-alpha.6",
"boxen": "^5.1.2",
"chalk": "^4.1.0",
"commander": "^6.2.1",
@ -78,7 +78,7 @@
"update-notifier": "^5.0.1"
},
"devDependencies": {
"@storybook/client-api": "7.0.0-alpha.5",
"@storybook/client-api": "7.0.0-alpha.6",
"@types/cross-spawn": "^6.0.2",
"@types/prompts": "^2.0.9",
"@types/puppeteer-core": "^2.1.0",
@ -91,5 +91,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,76 +1,76 @@
// auto generated file, do not edit
export default {
'@storybook/addon-a11y': '7.0.0-alpha.5',
'@storybook/addon-actions': '7.0.0-alpha.5',
'@storybook/addon-backgrounds': '7.0.0-alpha.5',
'@storybook/addon-controls': '7.0.0-alpha.5',
'@storybook/addon-docs': '7.0.0-alpha.5',
'@storybook/addon-essentials': '7.0.0-alpha.5',
'@storybook/addon-interactions': '7.0.0-alpha.5',
'@storybook/addon-jest': '7.0.0-alpha.5',
'@storybook/addon-links': '7.0.0-alpha.5',
'@storybook/addon-measure': '7.0.0-alpha.5',
'@storybook/addon-outline': '7.0.0-alpha.5',
'@storybook/addon-storyshots': '7.0.0-alpha.5',
'@storybook/addon-storyshots-puppeteer': '7.0.0-alpha.5',
'@storybook/addon-storysource': '7.0.0-alpha.5',
'@storybook/addon-toolbars': '7.0.0-alpha.5',
'@storybook/addon-viewport': '7.0.0-alpha.5',
'@storybook/addons': '7.0.0-alpha.5',
'@storybook/angular': '7.0.0-alpha.5',
'@storybook/api': '7.0.0-alpha.5',
'@storybook/builder-webpack5': '7.0.0-alpha.5',
'@storybook/channel-postmessage': '7.0.0-alpha.5',
'@storybook/channel-websocket': '7.0.0-alpha.5',
'@storybook/channels': '7.0.0-alpha.5',
'@storybook/cli': '7.0.0-alpha.5',
'@storybook/client-api': '7.0.0-alpha.5',
'@storybook/client-logger': '7.0.0-alpha.5',
'@storybook/codemod': '7.0.0-alpha.5',
'@storybook/components': '7.0.0-alpha.5',
'@storybook/core-client': '7.0.0-alpha.5',
'@storybook/core-common': '7.0.0-alpha.5',
'@storybook/core-events': '7.0.0-alpha.5',
'@storybook/core-server': '7.0.0-alpha.5',
'@storybook/core-webpack': '7.0.0-alpha.5',
'@storybook/csf-tools': '7.0.0-alpha.5',
'@storybook/docs-tools': '7.0.0-alpha.5',
'@storybook/ember': '7.0.0-alpha.5',
'@storybook/html': '7.0.0-alpha.5',
'@storybook/html-webpack5': '7.0.0-alpha.5',
'@storybook/instrumenter': '7.0.0-alpha.5',
'@storybook/manager-webpack5': '7.0.0-alpha.5',
'@storybook/node-logger': '7.0.0-alpha.5',
'@storybook/postinstall': '7.0.0-alpha.5',
'@storybook/preact': '7.0.0-alpha.5',
'@storybook/preact-webpack5': '7.0.0-alpha.5',
'@storybook/preset-html-webpack': '7.0.0-alpha.5',
'@storybook/preset-preact-webpack': '7.0.0-alpha.5',
'@storybook/preset-react-webpack': '7.0.0-alpha.5',
'@storybook/preset-server-webpack': '7.0.0-alpha.5',
'@storybook/preset-svelte-webpack': '7.0.0-alpha.5',
'@storybook/preset-vue-webpack': '7.0.0-alpha.5',
'@storybook/preset-vue3-webpack': '7.0.0-alpha.5',
'@storybook/preset-web-components-webpack': '7.0.0-alpha.5',
'@storybook/preview-web': '7.0.0-alpha.5',
'@storybook/react': '7.0.0-alpha.5',
'@storybook/react-webpack5': '7.0.0-alpha.5',
'@storybook/router': '7.0.0-alpha.5',
'@storybook/server': '7.0.0-alpha.5',
'@storybook/server-webpack5': '7.0.0-alpha.5',
'@storybook/source-loader': '7.0.0-alpha.5',
'@storybook/store': '7.0.0-alpha.5',
'@storybook/svelte': '7.0.0-alpha.5',
'@storybook/svelte-webpack5': '7.0.0-alpha.5',
'@storybook/telemetry': '7.0.0-alpha.5',
'@storybook/theming': '7.0.0-alpha.5',
'@storybook/ui': '7.0.0-alpha.5',
'@storybook/vue': '7.0.0-alpha.5',
'@storybook/vue-webpack5': '7.0.0-alpha.5',
'@storybook/vue3': '7.0.0-alpha.5',
'@storybook/vue3-webpack5': '7.0.0-alpha.5',
'@storybook/web-components': '7.0.0-alpha.5',
'@storybook/web-components-webpack5': '7.0.0-alpha.5',
sb: '7.0.0-alpha.5',
storybook: '7.0.0-alpha.5',
'@storybook/addon-a11y': '7.0.0-alpha.6',
'@storybook/addon-actions': '7.0.0-alpha.6',
'@storybook/addon-backgrounds': '7.0.0-alpha.6',
'@storybook/addon-controls': '7.0.0-alpha.6',
'@storybook/addon-docs': '7.0.0-alpha.6',
'@storybook/addon-essentials': '7.0.0-alpha.6',
'@storybook/addon-interactions': '7.0.0-alpha.6',
'@storybook/addon-jest': '7.0.0-alpha.6',
'@storybook/addon-links': '7.0.0-alpha.6',
'@storybook/addon-measure': '7.0.0-alpha.6',
'@storybook/addon-outline': '7.0.0-alpha.6',
'@storybook/addon-storyshots': '7.0.0-alpha.6',
'@storybook/addon-storyshots-puppeteer': '7.0.0-alpha.6',
'@storybook/addon-storysource': '7.0.0-alpha.6',
'@storybook/addon-toolbars': '7.0.0-alpha.6',
'@storybook/addon-viewport': '7.0.0-alpha.6',
'@storybook/addons': '7.0.0-alpha.6',
'@storybook/angular': '7.0.0-alpha.6',
'@storybook/api': '7.0.0-alpha.6',
'@storybook/builder-webpack5': '7.0.0-alpha.6',
'@storybook/channel-postmessage': '7.0.0-alpha.6',
'@storybook/channel-websocket': '7.0.0-alpha.6',
'@storybook/channels': '7.0.0-alpha.6',
'@storybook/cli': '7.0.0-alpha.6',
'@storybook/client-api': '7.0.0-alpha.6',
'@storybook/client-logger': '7.0.0-alpha.6',
'@storybook/codemod': '7.0.0-alpha.6',
'@storybook/components': '7.0.0-alpha.6',
'@storybook/core-client': '7.0.0-alpha.6',
'@storybook/core-common': '7.0.0-alpha.6',
'@storybook/core-events': '7.0.0-alpha.6',
'@storybook/core-server': '7.0.0-alpha.6',
'@storybook/core-webpack': '7.0.0-alpha.6',
'@storybook/csf-tools': '7.0.0-alpha.6',
'@storybook/docs-tools': '7.0.0-alpha.6',
'@storybook/ember': '7.0.0-alpha.6',
'@storybook/html': '7.0.0-alpha.6',
'@storybook/html-webpack5': '7.0.0-alpha.6',
'@storybook/instrumenter': '7.0.0-alpha.6',
'@storybook/manager-webpack5': '7.0.0-alpha.6',
'@storybook/node-logger': '7.0.0-alpha.6',
'@storybook/postinstall': '7.0.0-alpha.6',
'@storybook/preact': '7.0.0-alpha.6',
'@storybook/preact-webpack5': '7.0.0-alpha.6',
'@storybook/preset-html-webpack': '7.0.0-alpha.6',
'@storybook/preset-preact-webpack': '7.0.0-alpha.6',
'@storybook/preset-react-webpack': '7.0.0-alpha.6',
'@storybook/preset-server-webpack': '7.0.0-alpha.6',
'@storybook/preset-svelte-webpack': '7.0.0-alpha.6',
'@storybook/preset-vue-webpack': '7.0.0-alpha.6',
'@storybook/preset-vue3-webpack': '7.0.0-alpha.6',
'@storybook/preset-web-components-webpack': '7.0.0-alpha.6',
'@storybook/preview-web': '7.0.0-alpha.6',
'@storybook/react': '7.0.0-alpha.6',
'@storybook/react-webpack5': '7.0.0-alpha.6',
'@storybook/router': '7.0.0-alpha.6',
'@storybook/server': '7.0.0-alpha.6',
'@storybook/server-webpack5': '7.0.0-alpha.6',
'@storybook/source-loader': '7.0.0-alpha.6',
'@storybook/store': '7.0.0-alpha.6',
'@storybook/svelte': '7.0.0-alpha.6',
'@storybook/svelte-webpack5': '7.0.0-alpha.6',
'@storybook/telemetry': '7.0.0-alpha.6',
'@storybook/theming': '7.0.0-alpha.6',
'@storybook/ui': '7.0.0-alpha.6',
'@storybook/vue': '7.0.0-alpha.6',
'@storybook/vue-webpack5': '7.0.0-alpha.6',
'@storybook/vue3': '7.0.0-alpha.6',
'@storybook/vue3-webpack5': '7.0.0-alpha.6',
'@storybook/web-components': '7.0.0-alpha.6',
'@storybook/web-components-webpack5': '7.0.0-alpha.6',
sb: '7.0.0-alpha.6',
storybook: '7.0.0-alpha.6',
};

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/client-api",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook Client API",
"keywords": [
"storybook"
@ -33,13 +33,13 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/channel-postmessage": "7.0.0-alpha.5",
"@storybook/channels": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/channel-postmessage": "7.0.0-alpha.6",
"@storybook/channels": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/store": "7.0.0-alpha.5",
"@storybook/store": "7.0.0-alpha.6",
"@types/qs": "^6.9.5",
"@types/webpack-env": "^1.16.4",
"core-js": "^3.8.2",
@ -60,5 +60,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/client-logger",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "",
"keywords": [
"storybook"
@ -39,5 +39,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/codemod",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "A collection of codemod scripts written with JSCodeshift",
"keywords": [
"storybook"
@ -44,8 +44,8 @@
"@babel/types": "^7.12.11",
"@mdx-js/mdx": "^1.6.22",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/csf-tools": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/csf-tools": "7.0.0-alpha.6",
"@storybook/node-logger": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"cross-spawn": "^7.0.3",
"globby": "^11.0.2",
@ -61,5 +61,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/components",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Core Storybook Components",
"keywords": [
"storybook"
@ -50,9 +50,9 @@
"prepare": "esrun ../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"memoizerific": "^1.11.3",
"qs": "^6.10.0",
@ -92,5 +92,5 @@
"./src/index.ts",
"./src/html.tsx"
],
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/core-client",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook framework-agnostic API",
"keywords": [
"storybook"
@ -33,16 +33,16 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/channel-postmessage": "7.0.0-alpha.5",
"@storybook/channel-websocket": "7.0.0-alpha.5",
"@storybook/client-api": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/channel-postmessage": "7.0.0-alpha.6",
"@storybook/channel-websocket": "7.0.0-alpha.6",
"@storybook/client-api": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/preview-web": "7.0.0-alpha.5",
"@storybook/store": "7.0.0-alpha.5",
"@storybook/ui": "7.0.0-alpha.5",
"@storybook/preview-web": "7.0.0-alpha.6",
"@storybook/store": "7.0.0-alpha.6",
"@storybook/ui": "7.0.0-alpha.6",
"ansi-to-html": "^0.6.11",
"core-js": "^3.8.2",
"global": "^4.4.0",
@ -60,5 +60,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -16,6 +16,7 @@ import { start } from './start';
jest.mock('@storybook/preview-web/dist/cjs/WebView');
jest.spyOn(WebView.prototype, 'prepareForDocs').mockReturnValue('docs-root');
jest.spyOn(WebView.prototype, 'prepareForStory').mockReturnValue('story-root');
jest.mock('global', () => ({
// @ts-ignore
@ -156,7 +157,7 @@ describe('start', () => {
expect.objectContaining({
id: 'component-a--story-one',
}),
undefined
'story-root'
);
});
@ -328,7 +329,7 @@ describe('start', () => {
}),
}),
}),
undefined
'story-root'
);
});
@ -365,7 +366,7 @@ describe('start', () => {
},
}),
}),
undefined
'story-root'
);
expect((window as any).IS_STORYBOOK).toBe(true);
@ -707,7 +708,7 @@ describe('start', () => {
expect.objectContaining({
id: 'component-c--story-one',
}),
undefined
'story-root'
);
});
@ -1184,7 +1185,7 @@ describe('start', () => {
expect.objectContaining({
id: 'component-a--story-one',
}),
undefined
'story-root'
);
});
});

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/core-common",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook framework-agnostic API",
"keywords": [
"storybook"
@ -56,7 +56,7 @@
"@babel/preset-typescript": "^7.12.7",
"@babel/register": "^7.12.1",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.6",
"@storybook/semver": "^7.3.2",
"@types/babel__core": "^7.0.0",
"@types/express": "^4.7.0",
@ -104,5 +104,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/core-events",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Event names used in storybook core",
"keywords": [
"storybook"
@ -38,5 +38,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/core-server",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook framework-agnostic API",
"keywords": [
"storybook"
@ -33,17 +33,17 @@
},
"dependencies": {
"@discoveryjs/json-ext": "^0.5.3",
"@storybook/core-client": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/core-client": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/csf-tools": "7.0.0-alpha.5",
"@storybook/csf-tools": "7.0.0-alpha.6",
"@storybook/docs-mdx": "0.0.1-canary.1.4bea5cc.0",
"@storybook/manager-webpack5": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/manager-webpack5": "7.0.0-alpha.6",
"@storybook/node-logger": "7.0.0-alpha.6",
"@storybook/semver": "^7.3.2",
"@storybook/store": "7.0.0-alpha.5",
"@storybook/telemetry": "7.0.0-alpha.5",
"@storybook/store": "7.0.0-alpha.6",
"@storybook/telemetry": "7.0.0-alpha.6",
"@types/node": "^14.0.10 || ^16.0.0",
"@types/node-fetch": "^2.5.7",
"@types/pretty-hrtime": "^1.0.0",
@ -78,7 +78,7 @@
"x-default-browser": "^0.4.0"
},
"devDependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.5",
"@storybook/builder-webpack5": "7.0.0-alpha.6",
"@types/compression": "^1.7.0",
"@types/ip": "^1.1.0",
"@types/serve-favicon": "^2.5.2",
@ -103,5 +103,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/core-webpack",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook framework-agnostic API",
"keywords": [
"storybook"
@ -33,8 +33,8 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/node-logger": "7.0.0-alpha.6",
"@types/node": "^14.0.10 || ^16.0.0",
"core-js": "^3.8.2",
"ts-dedent": "^2.0.0"
@ -42,5 +42,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/csf-tools",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "",
"keywords": [
"storybook"
@ -54,5 +54,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/docs-tools",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Shared utility functions for frameworks to implement docs",
"keywords": [
"storybook"
@ -35,7 +35,7 @@
"dependencies": {
"@babel/core": "^7.12.10",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/store": "7.0.0-alpha.5",
"@storybook/store": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"doctrine": "^3.0.0",
"lodash": "^4.17.21"
@ -47,5 +47,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/instrumenter",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "",
"keywords": [
"storybook"
@ -40,14 +40,14 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"global": "^4.4.0"
},
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/manager-webpack5",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook framework-agnostic API",
"keywords": [
"storybook"
@ -38,13 +38,13 @@
"@babel/core": "^7.12.10",
"@babel/plugin-transform-template-literals": "^7.12.1",
"@babel/preset-react": "^7.12.10",
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/core-client": "7.0.0-alpha.5",
"@storybook/core-common": "7.0.0-alpha.5",
"@storybook/core-webpack": "7.0.0-alpha.5",
"@storybook/node-logger": "7.0.0-alpha.5",
"@storybook/theming": "7.0.0-alpha.5",
"@storybook/ui": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/core-client": "7.0.0-alpha.6",
"@storybook/core-common": "7.0.0-alpha.6",
"@storybook/core-webpack": "7.0.0-alpha.6",
"@storybook/node-logger": "7.0.0-alpha.6",
"@storybook/theming": "7.0.0-alpha.6",
"@storybook/ui": "7.0.0-alpha.6",
"@types/node": "^14.0.10 || ^16.0.0",
"babel-loader": "^8.2.5",
"case-sensitive-paths-webpack-plugin": "^2.4.0",
@ -82,5 +82,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/node-logger",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "",
"keywords": [
"storybook"
@ -45,5 +45,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/postinstall",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Storybook addons postinstall utilities",
"keywords": [
"api",
@ -44,5 +44,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/preview-web",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "",
"keywords": [
"storybook"
@ -40,12 +40,12 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/channel-postmessage": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/channel-postmessage": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"@storybook/store": "7.0.0-alpha.5",
"@storybook/store": "7.0.0-alpha.6",
"ansi-to-html": "^0.6.11",
"core-js": "^3.8.2",
"global": "^4.4.0",
@ -58,5 +58,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -34,7 +34,9 @@ export class DocsRender<TFramework extends AnyFramework> implements Render<TFram
public disableKeyListeners = false;
public teardown: (options: { viewModeChanged?: boolean }) => Promise<void>;
public teardown?: (options: { viewModeChanged?: boolean }) => Promise<void>;
public torndown = false;
constructor(
private channel: Channel,
@ -42,7 +44,7 @@ export class DocsRender<TFramework extends AnyFramework> implements Render<TFram
public entry: IndexEntry
) {
this.id = entry.id;
this.legacy = entry.type !== 'docs' || entry.legacy;
this.legacy = entry.type !== 'docs' || !!entry.legacy;
}
// The two story "renders" are equal and have both loaded the same story
@ -105,6 +107,8 @@ export class DocsRender<TFramework extends AnyFramework> implements Render<TFram
};
}
if (!this.csfFiles) throw new Error('getDocsContext called before prepare');
let metaCsfFile: ModuleExports;
const exportToStoryId = new Map<ModuleExport, StoryId>();
const storyIdToCSFFile = new Map<StoryId, CSFFile<TFramework>>();
@ -126,16 +130,18 @@ export class DocsRender<TFramework extends AnyFramework> implements Render<TFram
return {
...base,
storyIdByModuleExport: (moduleExport) => {
if (exportToStoryId.has(moduleExport)) return exportToStoryId.get(moduleExport);
const storyId = exportToStoryId.get(moduleExport);
if (storyId) return storyId;
throw new Error(`No story found with that export: ${moduleExport}`);
},
storyById,
componentStories: () => {
return Object.entries(metaCsfFile)
.map(([_, moduleExport]) => exportToStoryId.get(moduleExport))
.filter(Boolean)
.map(storyById);
return (
Object.entries(metaCsfFile)
.map(([_, moduleExport]) => exportToStoryId.get(moduleExport))
.filter(Boolean) as StoryId[]
).map(storyById);
},
setMeta(m: ModuleExports) {
metaCsfFile = m;
@ -154,10 +160,15 @@ export class DocsRender<TFramework extends AnyFramework> implements Render<TFram
}
async render() {
if (!(this.story || this.exports) || !this.docsContext || !this.canvasElement)
if (
!(this.story || this.exports) ||
!this.docsContext ||
!this.canvasElement ||
!this.store.projectAnnotations
)
throw new Error('DocsRender not ready to render');
const { docs } = this.story?.parameters || this.store.projectAnnotations.parameters;
const { docs } = this.story?.parameters || this.store.projectAnnotations.parameters || {};
if (!docs) {
throw new Error(
@ -170,7 +181,8 @@ export class DocsRender<TFramework extends AnyFramework> implements Render<TFram
this.docsContext,
{
...docs,
...(!this.legacy && { page: this.exports.default }),
// exports must be defined in non-legacy mode (see check at top)
...(!this.legacy && { page: this.exports!.default }),
},
this.canvasElement,
() => this.channel.emit(DOCS_RENDERED, this.id)
@ -178,6 +190,7 @@ export class DocsRender<TFramework extends AnyFramework> implements Render<TFram
this.teardown = async ({ viewModeChanged }: { viewModeChanged?: boolean } = {}) => {
if (!viewModeChanged || !this.canvasElement) return;
renderer.unmount(this.canvasElement);
this.torndown = true;
};
}

View File

@ -46,7 +46,7 @@ export class Preview<TFramework extends AnyFramework> {
importFn?: ModuleImportFn;
renderToDOM: RenderToDOM<TFramework>;
renderToDOM?: RenderToDOM<TFramework>;
storyRenders: StoryRender<TFramework>[] = [];
@ -156,6 +156,8 @@ export class Preview<TFramework extends AnyFramework> {
}
emitGlobals() {
if (!this.storyStore.globals || !this.storyStore.projectAnnotations)
throw new Error(`Cannot emit before initialization`);
this.channel.emit(SET_GLOBALS, {
globals: this.storyStore.globals.get() || {},
globalTypes: this.storyStore.projectAnnotations.globalTypes || {},
@ -171,6 +173,9 @@ export class Preview<TFramework extends AnyFramework> {
// If initialization gets as far as the story index, this function runs.
initializeWithStoryIndex(storyIndex: StoryIndex): PromiseLike<void> {
if (!this.importFn)
throw new Error(`Cannot call initializeWithStoryIndex before initialization`);
return this.storyStore.initialize({
storyIndex,
importFn: this.importFn,
@ -218,7 +223,7 @@ export class Preview<TFramework extends AnyFramework> {
// Update the store with the new stories.
await this.onStoriesChanged({ storyIndex });
} catch (err) {
this.renderPreviewEntryError('Error loading story index:', err);
this.renderPreviewEntryError('Error loading story index:', err as Error);
throw err;
}
}
@ -235,6 +240,8 @@ export class Preview<TFramework extends AnyFramework> {
}
async onUpdateGlobals({ globals }: { globals: Globals }) {
if (!this.storyStore.globals)
throw new Error(`Cannot call onUpdateGlobals before initialization`);
this.storyStore.globals.update(globals);
await Promise.all(this.storyRenders.map((r) => r.rerender()));
@ -295,6 +302,9 @@ export class Preview<TFramework extends AnyFramework> {
// we will change it to go ahead and load the story, which will end up being
// "instant", although async.
renderStoryToElement(story: Story<TFramework>, element: HTMLElement) {
if (!this.renderToDOM)
throw new Error(`Cannot call renderStoryToElement before initialization`);
const render = new StoryRender<TFramework>(
this.channel,
this.storyStore,
@ -318,7 +328,7 @@ export class Preview<TFramework extends AnyFramework> {
{ viewModeChanged }: { viewModeChanged?: boolean } = {}
) {
this.storyRenders = this.storyRenders.filter((r) => r !== render);
await render?.teardown({ viewModeChanged });
await render?.teardown?.({ viewModeChanged });
}
// API

View File

@ -3,8 +3,11 @@ import global from 'global';
import { RenderContext } from '@storybook/store';
import addons, { mockChannel as createMockChannel } from '@storybook/addons';
import { DocsRenderer } from '@storybook/addon-docs';
import { mocked } from 'ts-jest/utils';
import { expect } from '@jest/globals';
import { PreviewWeb } from './PreviewWeb';
import { WebView } from './WebView';
import {
componentOneExports,
importFn,
@ -56,6 +59,9 @@ beforeEach(() => {
addons.setChannel(mockChannel as any);
addons.setServerChannel(createMockChannel());
mocked(WebView.prototype).prepareForDocs.mockReturnValue('docs-element' as any);
mocked(WebView.prototype).prepareForStory.mockReturnValue('story-element' as any);
});
describe('PreviewWeb', () => {

View File

@ -28,6 +28,8 @@ import { logger } from '@storybook/client-logger';
import { addons, mockChannel as createMockChannel } from '@storybook/addons';
import type { AnyFramework } from '@storybook/csf';
import type { ModuleImportFn, WebProjectAnnotations } from '@storybook/store';
import { expect } from '@jest/globals';
import { mocked } from 'ts-jest/utils';
import { PreviewWeb } from './PreviewWeb';
import {
@ -48,8 +50,8 @@ import {
modernDocsExports,
teardownRenderToDOM,
} from './PreviewWeb.mockdata';
import { WebView } from './WebView';
jest.mock('./WebView');
const { history, document } = global;
const mockStoryIndex = jest.fn(() => storyIndex);
@ -79,6 +81,7 @@ jest.mock('global', () => ({
jest.mock('@storybook/client-logger');
jest.mock('react-dom');
jest.mock('./WebView');
const createGate = (): [Promise<any | undefined>, (_?: any) => void] => {
let openGate = (_?: any) => {};
@ -104,9 +107,6 @@ async function createAndRenderPreview({
getProjectAnnotations?: () => WebProjectAnnotations<AnyFramework>;
} = {}) {
const preview = new PreviewWeb();
(
preview.view.prepareForDocs as jest.MockedFunction<typeof preview.view.prepareForDocs>
).mockReturnValue('docs-element' as any);
await preview.initialize({
importFn: inputImportFn,
getProjectAnnotations: inputGetProjectAnnotations,
@ -134,6 +134,9 @@ beforeEach(() => {
addons.setChannel(mockChannel as any);
addons.setServerChannel(createMockChannel());
mockFetchResult = { status: 200, json: mockStoryIndex, text: () => 'error text' };
mocked(WebView.prototype).prepareForDocs.mockReturnValue('docs-element' as any);
mocked(WebView.prototype).prepareForStory.mockReturnValue('story-element' as any);
});
describe('PreviewWeb', () => {
@ -172,7 +175,7 @@ describe('PreviewWeb', () => {
const preview = await createAndRenderPreview();
expect(preview.storyStore.globals.get()).toEqual({ a: 'c' });
expect(preview.storyStore.globals!.get()).toEqual({ a: 'c' });
});
it('emits the SET_GLOBALS event', async () => {
@ -233,7 +236,7 @@ describe('PreviewWeb', () => {
},
});
expect(preview.storyStore.globals.get()).toEqual({ a: 'b' });
expect(preview.storyStore.globals!.get()).toEqual({ a: 'b' });
});
});
@ -456,7 +459,7 @@ describe('PreviewWeb', () => {
loaded: { l: 7 },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -487,26 +490,27 @@ describe('PreviewWeb', () => {
});
it('renders helpful message if renderToDOM is undefined', async () => {
const originalRenderToDOM = projectAnnotations.renderToDOM;
try {
projectAnnotations.renderToDOM = undefined;
document.location.search = '?id=component-one--a';
const preview = new PreviewWeb();
await expect(
preview.initialize({
importFn,
getProjectAnnotations: () => ({
...getProjectAnnotations,
renderToDOM: undefined,
}),
})
).rejects.toThrow();
document.location.search = '?id=component-one--a';
const preview = new PreviewWeb();
await expect(preview.initialize({ importFn, getProjectAnnotations })).rejects.toThrow();
expect(preview.view.showErrorDisplay).toHaveBeenCalled();
expect((preview.view.showErrorDisplay as jest.Mock).mock.calls[0][0])
.toMatchInlineSnapshot(`
expect(preview.view.showErrorDisplay).toHaveBeenCalled();
expect((preview.view.showErrorDisplay as jest.Mock).mock.calls[0][0])
.toMatchInlineSnapshot(`
[Error: Expected your framework's preset to export a \`renderToDOM\` field.
Perhaps it needs to be upgraded for Storybook 6.4?
More info: https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#mainjs-framework-field ]
`);
} finally {
projectAnnotations.renderToDOM = originalRenderToDOM;
}
});
it('renders exception if the play function throws', async () => {
@ -705,7 +709,7 @@ describe('PreviewWeb', () => {
emitter.emit(UPDATE_GLOBALS, { globals: { foo: 'bar' } });
expect(preview.storyStore.globals.get()).toEqual({ a: 'b', foo: 'bar' });
expect(preview.storyStore.globals!.get()).toEqual({ a: 'b', foo: 'bar' });
});
it('passes new globals in context to renderToDOM', async () => {
@ -724,7 +728,7 @@ describe('PreviewWeb', () => {
globals: { a: 'b', foo: 'bar' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -807,7 +811,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a', new: 'arg' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -864,7 +868,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a', new: 'arg' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
// Now let the first loader call resolve
@ -883,7 +887,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a', new: 'arg' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -914,7 +918,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
expect(projectAnnotations.renderToDOM).toHaveBeenCalledWith(
expect.objectContaining({
@ -924,7 +928,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a', new: 'arg' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -947,7 +951,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
expect(projectAnnotations.renderToDOM).toHaveBeenCalledWith(
expect.objectContaining({
@ -957,7 +961,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a', new: 'arg' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -985,7 +989,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
emitter.emit(UPDATE_STORY_ARGS, {
@ -1005,7 +1009,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a', new: 'arg' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
// Now let the playFunction call resolve
@ -1172,7 +1176,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a', new: 'value' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
await waitForEvents([STORY_ARGS_UPDATED]);
@ -1213,7 +1217,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
await waitForEvents([STORY_ARGS_UPDATED]);
@ -1254,7 +1258,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
await waitForEvents([STORY_ARGS_UPDATED]);
@ -1295,7 +1299,7 @@ describe('PreviewWeb', () => {
args: { foo: 'a' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
await waitForEvents([STORY_ARGS_UPDATED]);
@ -1323,7 +1327,7 @@ describe('PreviewWeb', () => {
expect(projectAnnotations.renderToDOM).toHaveBeenCalledWith(
expect.objectContaining({ forceRemount: false }),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
});
@ -1347,7 +1351,7 @@ describe('PreviewWeb', () => {
expect(projectAnnotations.renderToDOM).toHaveBeenCalledWith(
expect.objectContaining({ forceRemount: true }),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -1367,7 +1371,7 @@ describe('PreviewWeb', () => {
loaded: { l: 7 },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
mockChannel.emit.mockClear();
@ -1723,7 +1727,7 @@ describe('PreviewWeb', () => {
loaded: { l: 7 },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -1888,7 +1892,7 @@ describe('PreviewWeb', () => {
loaded: { l: 7 },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -1942,7 +1946,7 @@ describe('PreviewWeb', () => {
loaded: { l: 7 },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
mockChannel.emit.mockClear();
@ -1967,7 +1971,7 @@ describe('PreviewWeb', () => {
loaded: { l: 7 },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
await waitForRenderPhase('playing');
@ -1995,7 +1999,7 @@ describe('PreviewWeb', () => {
loaded: { l: 7 },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
mockChannel.emit.mockClear();
@ -2284,7 +2288,7 @@ describe('PreviewWeb', () => {
loaded: { l: 7 },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -2557,7 +2561,7 @@ describe('PreviewWeb', () => {
loaded: { l: 7 },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -2585,7 +2589,7 @@ describe('PreviewWeb', () => {
args: { foo: 'updated' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
@ -2846,7 +2850,7 @@ describe('PreviewWeb', () => {
args: { foo: 'updated', bar: 'edited' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
});
@ -3071,7 +3075,7 @@ describe('PreviewWeb', () => {
globals: { a: 'edited' },
}),
}),
undefined // this is coming from view.prepareForStory, not super important
'story-element'
);
});
});

View File

@ -20,7 +20,7 @@ import {
UPDATE_QUERY_PARAMS,
} from '@storybook/core-events';
import { logger } from '@storybook/client-logger';
import { AnyFramework, StoryId, ProjectAnnotations, Args, Globals } from '@storybook/csf';
import { AnyFramework, StoryId, ProjectAnnotations, Args, Globals, ViewMode } from '@storybook/csf';
import type {
ModuleImportFn,
Selection,
@ -54,9 +54,9 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
previewEntryError?: Error;
currentSelection: Selection;
currentSelection?: Selection;
currentRender: StoryRender<TFramework> | DocsRender<TFramework>;
currentRender?: StoryRender<TFramework> | DocsRender<TFramework>;
constructor() {
super();
@ -93,6 +93,9 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
}
async setInitialGlobals() {
if (!this.storyStore.globals)
throw new Error(`Cannot call setInitialGlobals before initialization`);
const { globals } = this.urlStore.selectionSpecifier || {};
if (globals) {
this.storyStore.globals.updateFromPersisted(globals);
@ -113,6 +116,9 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
// Use the selection specifier to choose a story, then render it
async selectSpecifiedStory() {
if (!this.storyStore.storyIndex)
throw new Error(`Cannot call selectSpecifiedStory before initialization`);
if (!this.urlStore.selectionSpecifier) {
this.renderMissingStory();
return;
@ -199,7 +205,7 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
}
}
onSetCurrentStory(selection: Selection) {
onSetCurrentStory(selection: { storyId: StoryId; viewMode?: ViewMode }) {
this.urlStore.setSelection({ viewMode: 'story', ...selection });
this.channel.emit(CURRENT_STORY_WAS_SET, this.urlStore.selection);
this.renderSelection();
@ -240,18 +246,19 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
// - a story selected in "docs" viewMode,
// in which case we render the docsPage for that story
async renderSelection({ persistedArgs }: { persistedArgs?: Args } = {}) {
const { renderToDOM } = this;
if (!renderToDOM) throw new Error('Cannot call renderSelection before initialization');
const { selection } = this.urlStore;
if (!selection) {
throw new Error('Cannot render story as no selection was made');
}
if (!selection) throw new Error('Cannot call renderSelection as no selection was made');
const { storyId } = selection;
let entry;
try {
entry = await this.storyStore.storyIdToEntry(storyId);
} catch (err) {
await this.teardownRender(this.currentRender);
this.renderStoryLoadingException(storyId, err);
if (this.currentRender) await this.teardownRender(this.currentRender);
this.renderStoryLoadingException(storyId, err as Error);
return;
}
// Docs entries cannot be rendered in 'story' viewMode.
@ -268,18 +275,14 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
this.view.showPreparingDocs();
}
const lastSelection = this.currentSelection;
let lastRender = this.currentRender;
// If the last render is still preparing, let's drop it right now. Either
// (a) it is a different story, which means we would drop it later, OR
// (b) it is the *same* story, in which case we will resolve our own .prepare() at the
// same moment anyway, and we should just "take over" the rendering.
// (We can't tell which it is yet, because it is possible that an HMR is going on and
// even though the storyId is the same, the story itself is not).
if (lastRender?.isPreparing()) {
await this.teardownRender(lastRender);
lastRender = null;
if (this.currentRender?.isPreparing()) {
await this.teardownRender(this.currentRender);
}
let render;
@ -290,7 +293,7 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
(...args) => {
// At the start of renderToDOM we make the story visible (see note in WebView)
this.view.showStoryDuringRender();
return this.renderToDOM(...args);
return renderToDOM(...args);
},
this.mainStoryCallbacks(storyId),
storyId,
@ -302,7 +305,10 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
// We need to store this right away, so if the story changes during
// the async `.prepare()` below, we can (potentially) cancel it
const lastSelection = this.currentSelection;
this.currentSelection = selection;
const lastRender = this.currentRender;
this.currentRender = render;
try {
@ -311,18 +317,26 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
if (err !== PREPARE_ABORTED) {
// We are about to render an error so make sure the previous story is
// no longer rendered.
await this.teardownRender(lastRender);
this.renderStoryLoadingException(storyId, err);
if (lastRender) await this.teardownRender(lastRender);
this.renderStoryLoadingException(storyId, err as Error);
}
return;
}
const implementationChanged = !storyIdChanged && !render.isEqual(lastRender);
const implementationChanged = !storyIdChanged && lastRender && !render.isEqual(lastRender);
if (persistedArgs && entry.type !== 'docs')
if (persistedArgs && entry.type !== 'docs') {
if (!render.story) throw new Error('Render has not been prepared!');
this.storyStore.args.updateFromPersisted(render.story, persistedArgs);
}
// Don't re-render the story if nothing has changed to justify it
if (lastRender && !storyIdChanged && !implementationChanged && !viewModeChanged) {
if (
lastRender &&
!lastRender.torndown &&
!storyIdChanged &&
!implementationChanged &&
!viewModeChanged
) {
this.currentRender = lastRender;
this.channel.emit(STORY_UNCHANGED, storyId);
this.view.showMain();
@ -331,7 +345,7 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
// Wait for the previous render to leave the page. NOTE: this will wait to ensure anything async
// is properly aborted, which (in some cases) can lead to the whole screen being refreshed.
await this.teardownRender(lastRender, { viewModeChanged });
if (lastRender) await this.teardownRender(lastRender, { viewModeChanged });
// If we are rendering something new (as opposed to re-rendering the same or first story), emit
if (lastSelection && (storyIdChanged || viewModeChanged)) {
@ -339,6 +353,7 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
}
if (entry.type !== 'docs') {
if (!render.story) throw new Error('Render has not been prepared!');
const { parameters, initialArgs, argTypes, args } = this.storyStore.getStoryContext(
render.story
);
@ -367,6 +382,7 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
this.renderStoryToElement.bind(this)
);
} else {
if (!render.story) throw new Error('Render has not been prepared!');
this.storyRenders.push(render as StoryRender<TFramework>);
(this.currentRender as StoryRender<TFramework>).renderToElement(
this.view.prepareForStory(render.story)
@ -380,6 +396,9 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
// we will change it to go ahead and load the story, which will end up being
// "instant", although async.
renderStoryToElement(story: Story<TFramework>, element: HTMLElement) {
if (!this.renderToDOM)
throw new Error(`Cannot call renderStoryToElement before initialization`);
const render = new StoryRender<TFramework>(
this.channel,
this.storyStore,
@ -400,10 +419,10 @@ export class PreviewWeb<TFramework extends AnyFramework> extends Preview<TFramew
async teardownRender(
render: Render<TFramework>,
{ viewModeChanged }: { viewModeChanged?: boolean } = {}
{ viewModeChanged = false }: { viewModeChanged?: boolean } = {}
) {
this.storyRenders = this.storyRenders.filter((r) => r !== render);
await render?.teardown({ viewModeChanged });
await render?.teardown?.({ viewModeChanged });
}
// API

View File

@ -54,7 +54,8 @@ export interface Render<TFramework extends AnyFramework> {
story?: Story<TFramework>;
isPreparing: () => boolean;
disableKeyListeners: boolean;
teardown: (options: { viewModeChanged: boolean }) => Promise<void>;
teardown?: (options: { viewModeChanged: boolean }) => Promise<void>;
torndown: boolean;
renderToElement: (canvasElement: HTMLElement, renderStoryToElement?: any) => Promise<void>;
}
@ -75,6 +76,8 @@ export class StoryRender<TFramework extends AnyFramework> implements Render<TFra
private teardownRender: TeardownRenderToDOM = () => {};
public torndown = false;
constructor(
public channel: Channel,
public store: StoryStore<TFramework>,
@ -143,6 +146,7 @@ export class StoryRender<TFramework extends AnyFramework> implements Render<TFra
}
private storyContext() {
if (!this.story) throw new Error(`Cannot call storyContext before preparing`);
return this.store.getStoryContext(this.story);
}
@ -153,7 +157,10 @@ export class StoryRender<TFramework extends AnyFramework> implements Render<TFra
initial?: boolean;
forceRemount?: boolean;
} = {}) {
const { canvasElement } = this;
if (!this.story) throw new Error('cannot render when not prepared');
if (!canvasElement) throw new Error('cannot render when canvasElement is unset');
const { id, componentId, title, name, applyLoaders, unboundStoryFn, playFunction } = this.story;
if (forceRemount && !initial) {
@ -169,7 +176,7 @@ export class StoryRender<TFramework extends AnyFramework> implements Render<TFra
const abortSignal = (this.abortController as AbortController).signal;
try {
let loadedContext: StoryContext<TFramework>;
let loadedContext: Awaited<ReturnType<typeof applyLoaders>>;
await this.runPhase(abortSignal, 'loading', async () => {
loadedContext = await applyLoaders({
...this.storyContext(),
@ -181,13 +188,12 @@ export class StoryRender<TFramework extends AnyFramework> implements Render<TFra
}
const renderStoryContext: StoryContext<TFramework> = {
// @ts-ignore
...loadedContext,
...loadedContext!,
// By this stage, it is possible that new args/globals have been received for this story
// and we need to ensure we render it with the new values
...this.storyContext(),
abortSignal,
canvasElement: this.canvasElement as HTMLElement,
canvasElement,
};
const renderContext: RenderContext<TFramework> = {
componentId,
@ -205,7 +211,7 @@ export class StoryRender<TFramework extends AnyFramework> implements Render<TFra
await this.runPhase(abortSignal, 'rendering', async () => {
this.teardownRender =
(await this.renderToScreen(renderContext, this.canvasElement)) || (() => {});
(await this.renderToScreen(renderContext, canvasElement)) || (() => {});
});
this.notYetRendered = false;
if (abortSignal.aborted) return;
@ -242,12 +248,11 @@ export class StoryRender<TFramework extends AnyFramework> implements Render<TFra
// as a method to abort them, ASAP, but this is not foolproof as we cannot control what
// happens inside the user's code.
cancelRender() {
if (this.abortController) {
this.abortController.abort();
}
this.abortController?.abort();
}
async teardown(options: {} = {}) {
this.torndown = true;
this.cancelRender();
// If the story has loaded, we need to cleanup

View File

@ -61,8 +61,7 @@ const getFirstString = (v: ValueOf<qs.ParsedQs>): string | void => {
return getFirstString(v[0]);
}
if (isObject(v)) {
// @ts-ignore
return getFirstString(Object.values(v));
return getFirstString(Object.values(v).filter(Boolean) as string[]);
}
return undefined;
};
@ -74,7 +73,7 @@ Use \`id=$storyId\` instead.
See https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#new-url-structure`
);
export const getSelectionSpecifierFromPath: () => SelectionSpecifier = () => {
export const getSelectionSpecifierFromPath: () => SelectionSpecifier | null = () => {
const query = qs.parse(document.location.search, { ignoreQueryPrefix: true });
const args = typeof query.args === 'string' ? parseArgsParam(query.args) : undefined;
const globals = typeof query.globals === 'string' ? parseArgsParam(query.globals) : undefined;
@ -103,9 +102,9 @@ export const getSelectionSpecifierFromPath: () => SelectionSpecifier = () => {
};
export class UrlStore {
selectionSpecifier: SelectionSpecifier;
selectionSpecifier: SelectionSpecifier | null;
selection: Selection;
selection?: Selection;
constructor() {
this.selectionSpecifier = getSelectionSpecifierFromPath();

View File

@ -41,7 +41,7 @@ export class WebView {
testing = false;
preparingTimeout: ReturnType<typeof setTimeout> = null;
preparingTimeout?: ReturnType<typeof setTimeout>;
constructor() {
// Special code for testing situations

View File

@ -25,7 +25,8 @@ const validateArgs = (key = '', value: unknown): boolean => {
);
}
if (Array.isArray(value)) return value.every((v) => validateArgs(key, v));
if (isPlainObject(value)) return Object.entries(value).every(([k, v]) => validateArgs(k, v));
if (isPlainObject(value))
return Object.entries(value as object).every(([k, v]) => validateArgs(k, v));
return false;
};

View File

@ -1,6 +1,7 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"strict": true
},
"include": [
"src/**/*"

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/router",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Core Storybook Router",
"keywords": [
"storybook"
@ -33,7 +33,7 @@
"prepare": "ts-node ../../scripts/prebundle.ts"
},
"dependencies": {
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.6",
"core-js": "^3.8.2",
"memoizerific": "^1.11.3",
"qs": "^6.10.0"
@ -56,5 +56,5 @@
"access": "public"
},
"bundlerEntrypoint": "./src/index.ts",
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/source-loader",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "Source loader",
"keywords": [
"lib",
@ -34,8 +34,8 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"core-js": "^3.8.2",
"estraverse": "^5.2.0",
@ -50,5 +50,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/store",
"version": "7.0.0-alpha.5",
"version": "7.0.0-alpha.6",
"description": "",
"keywords": [
"storybook"
@ -40,9 +40,9 @@
"prepare": "node ../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.5",
"@storybook/client-logger": "7.0.0-alpha.5",
"@storybook/core-events": "7.0.0-alpha.5",
"@storybook/addons": "7.0.0-alpha.6",
"@storybook/client-logger": "7.0.0-alpha.6",
"@storybook/core-events": "7.0.0-alpha.6",
"@storybook/csf": "0.0.2--canary.4566f4d.1",
"core-js": "^3.8.2",
"fast-deep-equal": "^3.1.3",
@ -62,5 +62,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "3dd46982823b34d9f37be917b6247631081feff7"
"gitHead": "a88dcca40ba169a373bad33dd76e9a4bd4f1f5ec"
}

View File

@ -1,3 +1,5 @@
import { expect } from '@jest/globals';
import { ArgsStore } from './ArgsStore';
jest.mock('@storybook/client-logger');

View File

@ -1,9 +1,9 @@
import { expect } from '@jest/globals';
import { GlobalsStore } from './GlobalsStore';
describe('GlobalsStore', () => {
it('is initialized to the value in globals', () => {
const store = new GlobalsStore();
store.set({
const store = new GlobalsStore({
globals: {
arg1: 'arg1',
arg2: 2,
@ -20,8 +20,7 @@ describe('GlobalsStore', () => {
});
it('is initialized to the default values from globalTypes if global is unset', () => {
const store = new GlobalsStore();
store.set({
const store = new GlobalsStore({
globals: {
arg1: 'arg1',
arg2: 2,
@ -42,8 +41,7 @@ describe('GlobalsStore', () => {
describe('update', () => {
it('changes the global args', () => {
const store = new GlobalsStore();
store.set({ globals: { foo: 'old' }, globalTypes: { baz: {} } });
const store = new GlobalsStore({ globals: { foo: 'old' }, globalTypes: { baz: {} } });
store.update({ foo: 'bar' });
expect(store.get()).toEqual({ foo: 'bar' });
@ -57,8 +55,7 @@ describe('GlobalsStore', () => {
});
it('does not merge objects', () => {
const store = new GlobalsStore();
store.set({ globals: {}, globalTypes: {} });
const store = new GlobalsStore({ globals: {}, globalTypes: {} });
store.update({ obj: { foo: 'bar' } });
expect(store.get()).toEqual({ obj: { foo: 'bar' } });
@ -70,8 +67,7 @@ describe('GlobalsStore', () => {
describe('updateFromPersisted', () => {
it('only sets values for which globals or globalArgs exist', () => {
const store = new GlobalsStore();
store.set({
const store = new GlobalsStore({
globals: {
arg1: 'arg1',
},
@ -92,8 +88,7 @@ describe('GlobalsStore', () => {
describe('second call to set', () => {
it('is initialized to the (new) default values from globalTypes if the (new) global is unset', () => {
const store = new GlobalsStore();
store.set({ globals: {}, globalTypes: {} });
const store = new GlobalsStore({ globals: {}, globalTypes: {} });
expect(store.get()).toEqual({});
@ -118,8 +113,7 @@ describe('GlobalsStore', () => {
describe('when underlying globals have not changed', () => {
it('retains updated values, but not if they are undeclared', () => {
const store = new GlobalsStore();
store.set({
const store = new GlobalsStore({
globals: {
arg1: 'arg1',
},
@ -152,8 +146,7 @@ describe('GlobalsStore', () => {
describe('when underlying globals have changed', () => {
it('retains a the same delta', () => {
const store = new GlobalsStore();
store.set({
const store = new GlobalsStore({
globals: {
arg1: 'arg1',
arg4: 'arg4',

View File

@ -14,11 +14,22 @@ const setUndeclaredWarning = deprecate(
);
export class GlobalsStore {
allowedGlobalNames: Set<string>;
// We use ! here because TS doesn't analyse the .set() function to see if it actually get set
allowedGlobalNames!: Set<string>;
initialGlobals: Globals;
initialGlobals!: Globals;
globals: Globals = {};
globals!: Globals;
constructor({
globals = {},
globalTypes = {},
}: {
globals?: Globals;
globalTypes?: GlobalTypes;
}) {
this.set({ globals, globalTypes });
}
set({ globals = {}, globalTypes = {} }: { globals?: Globals; globalTypes?: GlobalTypes }) {
const delta = this.initialGlobals && deepDiff(this.initialGlobals, this.globals);

View File

@ -1,3 +1,5 @@
import { expect } from '@jest/globals';
import { StoryIndexStore } from './StoryIndexStore';
import { StoryIndex } from './types';
@ -7,18 +9,21 @@ const storyIndex: StoryIndex = {
v: 4,
entries: {
'component-one--a': {
type: 'story',
id: 'component-one--a',
title: 'Component One',
name: 'A',
importPath: './src/ComponentOne.stories.js',
},
'component-one--b': {
type: 'story',
id: 'component-one--b',
title: 'Component One',
name: 'B',
importPath: './src/ComponentOne.stories.js',
},
'component-two--c': {
type: 'story',
id: 'component-one--c',
title: 'Component Two',
name: 'C',

View File

@ -1,5 +1,4 @@
import dedent from 'ts-dedent';
import { Channel } from '@storybook/addons';
import type { StoryId } from '@storybook/csf';
import memoize from 'memoizerific';
@ -13,8 +12,6 @@ const getImportPathMap = memoize(1)((entries: StoryIndex['entries']) =>
);
export class StoryIndexStore {
channel: Channel;
entries: StoryIndex['entries'];
constructor({ entries }: StoryIndex = { v: 4, entries: {} }) {

View File

@ -1,5 +1,6 @@
import type { AnyFramework, ProjectAnnotations } from '@storybook/csf';
import global from 'global';
import { expect } from '@jest/globals';
import { prepareStory } from './csf/prepareStory';
import { processCSFFile } from './csf/processCSFFile';
@ -76,10 +77,10 @@ describe('StoryStore', () => {
store.setProjectAnnotations(projectAnnotations);
store.initialize({ storyIndex, importFn, cache: false });
expect(store.projectAnnotations.globalTypes).toEqual({
expect(store.projectAnnotations!.globalTypes).toEqual({
a: { name: 'a', type: { name: 'string' } },
});
expect(store.projectAnnotations.argTypes).toEqual({
expect(store.projectAnnotations!.argTypes).toEqual({
a: { name: 'a', type: { name: 'string' } },
});
});
@ -90,10 +91,10 @@ describe('StoryStore', () => {
store.initialize({ storyIndex, importFn, cache: false });
store.setProjectAnnotations(projectAnnotations);
expect(store.projectAnnotations.globalTypes).toEqual({
expect(store.projectAnnotations!.globalTypes).toEqual({
a: { name: 'a', type: { name: 'string' } },
});
expect(store.projectAnnotations.argTypes).toEqual({
expect(store.projectAnnotations!.argTypes).toEqual({
a: { name: 'a', type: { name: 'string' } },
});
});
@ -408,7 +409,7 @@ describe('StoryStore', () => {
const story = await store.loadStory({ storyId: 'component-one--a' });
store.args.update(story.id, { foo: 'bar' });
store.globals.update({ a: 'c' });
store.globals!.update({ a: 'c' });
expect(store.getStoryContext(story)).toMatchObject({
args: { foo: 'bar' },
@ -455,8 +456,9 @@ describe('StoryStore', () => {
importFn.mockClear();
const csfFiles = await store.loadAllCSFFiles();
expect(csfFiles).not.toBeUndefined();
expect(Object.keys(csfFiles)).toEqual([
expect(Object.keys(csfFiles!)).toEqual([
'./src/ComponentOne.stories.js',
'./src/ComponentTwo.stories.js',
]);

View File

@ -38,13 +38,13 @@ const CSF_CACHE_SIZE = 1000;
const STORY_CACHE_SIZE = 10000;
export class StoryStore<TFramework extends AnyFramework> {
storyIndex: StoryIndexStore;
storyIndex?: StoryIndexStore;
importFn: ModuleImportFn;
importFn?: ModuleImportFn;
projectAnnotations: NormalizedProjectAnnotations<TFramework>;
projectAnnotations?: NormalizedProjectAnnotations<TFramework>;
globals: GlobalsStore;
globals?: GlobalsStore;
args: ArgsStore;
@ -58,10 +58,10 @@ export class StoryStore<TFramework extends AnyFramework> {
initializationPromise: SynchronousPromise<void>;
resolveInitializationPromise: () => void;
// This *does* get set in the constructor but the semantics of `new SynchronousPromise` trip up TS
resolveInitializationPromise!: () => void;
constructor() {
this.globals = new GlobalsStore();
this.args = new ArgsStore();
this.hooks = {};
@ -82,7 +82,11 @@ export class StoryStore<TFramework extends AnyFramework> {
this.projectAnnotations = normalizeProjectAnnotations(projectAnnotations);
const { globals, globalTypes } = projectAnnotations;
this.globals.set({ globals, globalTypes });
if (this.globals) {
this.globals.set({ globals, globalTypes });
} else {
this.globals = new GlobalsStore({ globals, globalTypes });
}
}
initialize({
@ -114,6 +118,8 @@ export class StoryStore<TFramework extends AnyFramework> {
importFn?: ModuleImportFn;
storyIndex?: StoryIndex;
}) {
if (!this.storyIndex) throw new Error(`onStoriesChanged called before initialization`);
if (importFn) this.importFn = importFn;
if (storyIndex) this.storyIndex.entries = storyIndex.entries;
if (this.cachedCSFFiles) await this.cacheAllCSFFiles();
@ -122,11 +128,15 @@ export class StoryStore<TFramework extends AnyFramework> {
// Get an entry from the index, waiting on initialization if necessary
async storyIdToEntry(storyId: StoryId) {
await this.initializationPromise;
return this.storyIndex.storyIdToEntry(storyId);
// The index will always be set before the initialization promise returns
return this.storyIndex!.storyIdToEntry(storyId);
}
// To load a single CSF file to service a story we need to look up the importPath in the index
loadCSFFileByStoryId(storyId: StoryId): PromiseLike<CSFFile<TFramework>> {
if (!this.storyIndex || !this.importFn)
throw new Error(`loadCSFFileByStoryId called before initialization`);
const { importPath, title } = this.storyIndex.storyIdToEntry(storyId);
return this.importFn(importPath).then((moduleExports) =>
// We pass the title in here as it may have been generated by autoTitle on the server.
@ -135,6 +145,8 @@ export class StoryStore<TFramework extends AnyFramework> {
}
loadAllCSFFiles(): PromiseLike<StoryStore<TFramework>['cachedCSFFiles']> {
if (!this.storyIndex) throw new Error(`loadAllCSFFiles called before initialization`);
const importPaths: Record<Path, StoryId> = {};
Object.entries(this.storyIndex.entries).forEach(([storyId, { importPath }]) => {
importPaths[importPath] = storyId;
@ -179,6 +191,8 @@ export class StoryStore<TFramework extends AnyFramework> {
storyId: StoryId;
csfFile: CSFFile<TFramework>;
}): Story<TFramework> {
if (!this.projectAnnotations) throw new Error(`storyFromCSFFile called before initialization`);
const storyAnnotations = csfFile.stories[storyId];
if (!storyAnnotations) {
throw new Error(`Didn't find '${storyId}' in CSF file, this is unexpected`);
@ -197,6 +211,9 @@ export class StoryStore<TFramework extends AnyFramework> {
// If we have a CSF file we can get all the stories from it synchronously
componentStoriesFromCSFFile({ csfFile }: { csfFile: CSFFile<TFramework> }): Story<TFramework>[] {
if (!this.storyIndex)
throw new Error(`componentStoriesFromCSFFile called before initialization`);
return Object.keys(this.storyIndex.entries)
.filter((storyId: StoryId) => !!csfFile.stories[storyId])
.map((storyId: StoryId) => this.storyFromCSFFile({ storyId, csfFile }));
@ -205,6 +222,10 @@ export class StoryStore<TFramework extends AnyFramework> {
async loadDocsFileById(
docsId: StoryId
): Promise<{ docsExports: ModuleExports; csfFiles: CSFFile<TFramework>[] }> {
const { storyIndex } = this;
if (!storyIndex || !this.importFn)
throw new Error(`componentStoriesFromCSFFile called before initialization`);
const entry = await this.storyIdToEntry(docsId);
if (entry.type !== 'docs') throw new Error(`Cannot load docs file for id ${docsId}`);
@ -213,7 +234,7 @@ export class StoryStore<TFramework extends AnyFramework> {
const [docsExports, ...csfFiles] = (await Promise.all([
this.importFn(importPath),
...storiesImports.map((storyImportPath) => {
const firstStoryEntry = this.storyIndex.importPathToEntry(storyImportPath);
const firstStoryEntry = storyIndex.importPathToEntry(storyImportPath);
return this.loadCSFFileByStoryId(firstStoryEntry.id);
}),
])) as [ModuleExports, ...CSFFile<TFramework>[]];
@ -232,6 +253,8 @@ export class StoryStore<TFramework extends AnyFramework> {
// A prepared story does not include args, globals or hooks. These are stored in the story store
// and updated separtely to the (immutable) story.
getStoryContext(story: Story<TFramework>): Omit<StoryContextForLoaders<TFramework>, 'viewMode'> {
if (!this.globals) throw new Error(`getStoryContext called before initialization`);
return {
...story,
args: this.args.get(story.id),
@ -247,15 +270,17 @@ export class StoryStore<TFramework extends AnyFramework> {
extract(
options: ExtractOptions = { includeDocsOnly: false }
): Record<StoryId, StoryContextForEnhancers<TFramework>> {
if (!this.cachedCSFFiles) {
if (!this.storyIndex) throw new Error(`extract called before initialization`);
const { cachedCSFFiles } = this;
if (!cachedCSFFiles)
throw new Error('Cannot call extract() unless you call cacheAllCSFFiles() first.');
}
return Object.entries(this.storyIndex.entries).reduce(
(acc, [storyId, { type, importPath }]) => {
if (type === 'docs') return acc;
const csfFile = this.cachedCSFFiles[importPath];
const csfFile = cachedCSFFiles[importPath];
const story = this.storyFromCSFFile({ storyId, csfFile });
if (!options.includeDocsOnly && story.parameters.docsOnly) {
@ -282,6 +307,8 @@ export class StoryStore<TFramework extends AnyFramework> {
}
getSetStoriesPayload() {
if (!this.globals) throw new Error(`getSetStoriesPayload called before initialization`);
const stories = this.extract({ includeDocsOnly: true });
const kindParameters: Parameters = Object.values(stories).reduce(
@ -305,11 +332,14 @@ export class StoryStore<TFramework extends AnyFramework> {
// It is used to allow v7 Storybooks to be composed in v6 Storybooks, which expect a
// `stories.json` file with legacy fields (`kind` etc).
getStoriesJsonData = (): StoryIndexV3 => {
const { storyIndex } = this;
if (!storyIndex) throw new Error(`getStoriesJsonData called before initialization`);
const value = this.getSetStoriesPayload();
const allowedParameters = ['fileName', 'docsOnly', 'framework', '__id', '__isArgsStory'];
const stories: Record<StoryId, V2CompatIndexEntry> = mapValues(value.stories, (story) => {
const { importPath } = this.storyIndex.entries[story.id];
const { importPath } = storyIndex.entries[story.id];
return {
...pick(story, ['id', 'name', 'title']),
importPath,
@ -332,13 +362,16 @@ export class StoryStore<TFramework extends AnyFramework> {
};
raw(): BoundStory<TFramework>[] {
return Object.values(this.extract()).map(({ id }: { id: StoryId }) => this.fromId(id));
return Object.values(this.extract())
.map(({ id }: { id: StoryId }) => this.fromId(id))
.filter(Boolean) as BoundStory<TFramework>[];
}
fromId(storyId: StoryId): BoundStory<TFramework> {
if (!this.cachedCSFFiles) {
fromId(storyId: StoryId): BoundStory<TFramework> | null {
if (!this.storyIndex) throw new Error(`fromId called before initialization`);
if (!this.cachedCSFFiles)
throw new Error('Cannot call fromId/raw() unless you call cacheAllCSFFiles() first.');
}
let importPath;
try {

View File

@ -1,4 +1,7 @@
import { once } from '@storybook/client-logger';
import { expect } from '@jest/globals';
import { SBType } from '@storybook/csf';
import {
combineArgs,
groupArgsByTarget,
@ -7,13 +10,13 @@ import {
validateOptions,
} from './args';
const stringType = { name: 'string' };
const numberType = { name: 'number' };
const booleanType = { name: 'boolean' };
const enumType = { name: 'enum' };
const functionType = { name: 'function' };
const numArrayType = { name: 'array', value: numberType };
const boolObjectType = { name: 'object', value: { bool: booleanType } };
const stringType: SBType = { name: 'string' };
const numberType: SBType = { name: 'number' };
const booleanType: SBType = { name: 'boolean' };
const enumType: SBType = { name: 'enum', value: [1, 2, 3] };
const functionType: SBType = { name: 'function' };
const numArrayType: SBType = { name: 'array', value: numberType };
const boolObjectType: SBType = { name: 'object', value: { bool: booleanType } };
jest.mock('@storybook/client-logger');

View File

@ -151,7 +151,7 @@ export function groupArgsByTarget<TArgs = Args>({
}: StoryContext<AnyFramework, TArgs>) {
const groupedArgs: Record<string, Partial<TArgs>> = {};
(Object.entries(args) as [keyof TArgs, any][]).forEach(([name, value]) => {
const { target = NO_TARGET_NAME } = (argTypes[name] || {}) as { target: string };
const { target = NO_TARGET_NAME } = (argTypes[name] || {}) as { target?: string };
groupedArgs[target] = groupedArgs[target] || {};
groupedArgs[target][name] = value;

View File

@ -1,4 +1,5 @@
import { normalizeStoriesEntry } from '@storybook/core-common';
import { expect } from '@jest/globals';
import { userOrAutoTitleFromSpecifier as userOrAuto } from './autoTitle';

View File

@ -1,3 +1,5 @@
import { expect } from '@jest/globals';
import { composeConfigs } from './composeConfigs';
describe('composeConfigs', () => {

View File

@ -1,3 +1,5 @@
import { expect } from '@jest/globals';
import { normalizeInputType, normalizeInputTypes } from './normalizeInputTypes';
describe('normalizeInputType', () => {

View File

@ -1,4 +1,4 @@
import type { AnyFramework, ProjectAnnotations } from '@storybook/csf';
import type { AnyFramework, ArgTypes, ProjectAnnotations } from '@storybook/csf';
import { inferArgTypes } from '../inferArgTypes';
import { inferControls } from '../inferControls';
@ -12,7 +12,7 @@ export function normalizeProjectAnnotations<TFramework extends AnyFramework>({
...annotations
}: ProjectAnnotations<TFramework>): NormalizedProjectAnnotations<TFramework> {
return {
...(argTypes && { argTypes: normalizeInputTypes(argTypes) }),
...(argTypes && { argTypes: normalizeInputTypes(argTypes as ArgTypes) }),
...(globalTypes && { globalTypes: normalizeInputTypes(globalTypes) }),
argTypesEnhancers: [
...(argTypesEnhancers || []),

Some files were not shown because too many files have changed in this diff Show More