Merge branch 'next' into jeppe/sb-544-svelte-example

This commit is contained in:
Jeppe Reinhold 2022-10-19 22:33:57 +02:00
commit 0f2702dbe3
122 changed files with 1332 additions and 2088 deletions

View File

@ -229,7 +229,7 @@ jobs:
name: Run @storybook/bench on repro
command: |
cd ../cra-bench
npx -p @storybook/bench@1.0.0--canary.12.7cccdee.0 sb-bench 'echo noop' --label cra
npx -p @storybook/bench@0.7.6--canary.760ff01.0 sb-bench 'echo noop' --label cra
- run:
name: prep artifacts
when: always

View File

@ -1,3 +1,25 @@
## 7.0.0-alpha.40 (October 20, 2022)
#### Breaking Changes
- Addon-docs: Upgrade to MDXv2 [#19495](https://github.com/storybooks/storybook/pull/19495)
#### Bug Fixes
- Addon-docs: Don't generate docs page entries for CSF files with no stories [#19529](https://github.com/storybooks/storybook/pull/19529)
#### Maintenance
- Remove deprecate features from preview-web [#19540](https://github.com/storybooks/storybook/pull/19540)
- Remove deprecated features in lib/api [#19539](https://github.com/storybooks/storybook/pull/19539)
- Remove default selection in docblocks [#19537](https://github.com/storybooks/storybook/pull/19537)
#### Build
- Remove .git folder when generating repros [#19535](https://github.com/storybooks/storybook/pull/19535)
- Some task runner tweaks + move test-runner into sandbox task. [#19505](https://github.com/storybooks/storybook/pull/19505)
- Build builder-webpack5 with ts-up [#19435](https://github.com/storybooks/storybook/pull/19435)
## 7.0.0-alpha.39 (October 19, 2022)
#### Breaking Changes

View File

@ -36,6 +36,8 @@
- [Docs Page](#docs-page)
- [Configuring the Docs Container](#configuring-the-docs-container)
- [External Docs](#external-docs)
- [MDX2 upgrade](#mdx2-upgrade)
- [Dropped addon-docs manual configuration](#dropped-addon-docs-manual-configuration)
- [From version 6.4.x to 6.5.0](#from-version-64x-to-650)
- [Vue 3 upgrade](#vue-3-upgrade)
- [React18 new root API](#react18-new-root-api)
@ -735,6 +737,20 @@ export default function App({ Component, pageProps }) {
}
```
#### MDX2 upgrade
Storybook 7 Docs uses MDXv2 instead of MDXv1. This means an improved syntax, support for inline JS expression, and improved performance among [other benefits](https://mdxjs.com/blog/v2/).
If you use `.stories.mdx` files in your project, you may need to edit them since MDX2 contains [breaking changes](https://mdxjs.com/migrating/v2/#update-mdx-files).
We will update this section with specific pointers based on user feedback during the prerelease period and probably add an codemod to help streamline the upgrade before final 7.0 release.
As part of the upgrade we deleted the codemod `mdx-to-csf` and will be replacing it with a more sophisticated version prior to release.
#### Dropped addon-docs manual configuration
Storybook Docs 5.x shipped with instructions for how to manually configure webpack and storybook without the use of Storybook's "presets" feature. Over time, these docs went out of sync. Now in Storybook 7 we have removed support for manual configuration entirely.
## From version 6.4.x to 6.5.0
### Vue 3 upgrade

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-a11y",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Test component compliance with web accessibility standards",
"keywords": [
"a11y",
@ -62,15 +62,15 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addon-highlight": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/channels": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addon-highlight": "7.0.0-alpha.40",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/channels": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.40",
"axe-core": "^4.2.0",
"global": "^4.4.0",
"lodash": "^4.17.21",
@ -102,7 +102,7 @@
"./src/preview.tsx"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"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.39",
"version": "7.0.0-alpha.40",
"description": "Get UI feedback when an action is performed on an interactive element",
"keywords": [
"storybook",
@ -58,13 +58,13 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.40",
"dequal": "^2.0.2",
"global": "^4.4.0",
"lodash": "^4.17.21",
@ -102,7 +102,7 @@
"./src/preview.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"storybook": {
"displayName": "Actions",
"unsupportedFrameworks": [

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-backgrounds",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Switch backgrounds to view components in different settings",
"keywords": [
"addon",
@ -62,13 +62,13 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.40",
"global": "^4.4.0",
"memoizerific": "^1.11.3",
"ts-dedent": "^2.0.0"
@ -98,7 +98,7 @@
"./src/preview.tsx"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"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.39",
"version": "7.0.0-alpha.40",
"description": "Interact with component inputs dynamically in the Storybook UI",
"keywords": [
"addon",
@ -57,16 +57,16 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/blocks": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/blocks": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/store": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.40",
"@storybook/store": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"lodash": "^4.17.21",
"ts-dedent": "^2.0.0"
},
@ -92,7 +92,7 @@
],
"platform": "browser"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"storybook": {
"displayName": "Controls",
"icon": "https://user-images.githubusercontent.com/263385/101991669-479cc600-3c7c-11eb-93d9-38b67e8371f2.png",

View File

@ -23,7 +23,6 @@ Read on to learn more:
- [Installation](#installation)
- [Be sure to check framework specific installation needs](#be-sure-to-check-framework-specific-installation-needs)
- [Preset options](#preset-options)
- [Manual configuration](#manual-configuration)
- [TypeScript configuration](#typescript-configuration)
- [More resources](#more-resources)
@ -166,67 +165,6 @@ import Changelog from '../CHANGELOG.md';
<Changelog />
```
## Manual configuration
We recommend using the preset, which should work out of the box. If you don't want to use the preset, and prefer to configure "the long way" add the following configuration to `.storybook/main.js` (see comments inline for explanation):
```js
const createCompiler = require('@storybook/addon-docs/mdx-compiler-plugin');
module.exports = {
// 1. register the docs panel (as opposed to '@storybook/addon-docs' which
// will configure everything with a preset)
addons: ['@storybook/addon-docs/register'],
// 2. manually configure webpack, since you're not using the preset
webpackFinal: async (config) => {
config.module.rules.push({
// 2a. Load `.stories.mdx` / `.story.mdx` files as CSF and generate
// the docs page from the markdown
test: /\.(stories|story)\.mdx$/,
use: [
{
// Need to add babel-loader as dependency: `yarn add -D babel-loader`
loader: require.resolve('babel-loader'),
// may or may not need this line depending on your app's setup
options: {
plugins: ['@babel/plugin-transform-react-jsx'],
},
},
{
loader: '@mdx-js/loader',
options: {
compilers: [createCompiler({})],
},
},
],
});
// 2b. Run `source-loader` on story files to show their source code
// automatically in `DocsPage` or the `Source` doc block.
config.module.rules.push({
test: /\.(stories|story)\.[tj]sx?$/,
loader: require.resolve('@storybook/source-loader'),
exclude: [/node_modules/],
enforce: 'pre',
});
return config;
},
};
```
You'll also need to set up the docs parameter in `.storybook/preview.js`. This includes the `DocsPage` for rendering the page, a container, and various configuration options, such as `extractComponentDescription` for manually extracting a component description:
```js
import { addParameters } from '@storybook/react';
import { DocsPage, DocsContainer } from '@storybook/addon-docs';
addParameters({
docs: {
container: DocsContainer,
page: DocsPage,
},
});
```
## TypeScript configuration
As of SB6 [TypeScript is zero-config](https://storybook.js.org/docs/react/configure/typescript) and should work with SB Docs out of the box. For advanced configuration options, refer to the [Props documentation](https://github.com/storybookjs/storybook/tree/next/code/addons/docs/docs/props-tables.md).

View File

@ -4,7 +4,6 @@
- [Component Story Format (CSF) with DocsPage](#component-story-format-csf-with-docspage)
- [Pure MDX Stories](#pure-mdx-stories)
- [Mixed CSF / MDX Stories](#mixed-csf--mdx-stories)
- [CSF Stories with MDX Docs](#csf-stories-with-mdx-docs)
- [CSF Stories with arbitrary MDX](#csf-stories-with-arbitrary-mdx)
- [Mixing storiesOf with CSF/MDX](#mixing-storiesof-with-csfmdx)
@ -30,12 +29,6 @@ If you want to intersperse longform documentation in your Storybook, for example
[MDX](mdx.md) is an alternative syntax to CSF that allows you to co-locate your stories and your documentation. Everything you can do in CSF, you can do in MDX. And if you're consuming it in [Webpack](https://webpack.js.org/), it exposes an _identical_ interface, so the two files are interchangeable. Some teams will choose to write all of their Storybook in MDX and never look back.
## Mixed CSF / MDX Stories
Can't decide between CSF and MDX? In transition? Or have you found that each format has its own use? There's nothing stopping you from keeping some of your stories in CSF and some in MDX. And if you want to migrate one way or another, the [csf-to-mdx and mdx-to-csf codemod migrations](https://github.com/storybookjs/storybook/blob/next/code/lib/codemod/README.md) can help.
The only limitation is that your exported titles (CSF: `default.title`, MDX `Meta.title`) should be unique across files. Loading will fail if there are duplicate titles.
## CSF Stories with MDX Docs
Perhaps you want to write your stories in CSF, but document them in MDX? Here's how to do that:

View File

@ -2,15 +2,16 @@ const path = require('path');
const { ScriptTransformer } = require('@jest/transform');
const { dedent } = require('ts-dedent');
const { compileSync } = require('@storybook/mdx1-csf');
const { compileAsync } = require('@storybook/mdx2-csf');
module.exports = {
process(src, filename, config, { instrument }) {
async processAsync(src, filename, config, { instrument }) {
const code = await compileAsync(src, { skipCsf: false });
const result = dedent`
/* @jsx mdx */
import React from 'react'
import { mdx } from '@mdx-js/react'
${compileSync(src, { filepath: filename })}
${code}
`;
const extension = path.extname(filename);

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-docs",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Document component usage and properties in Markdown",
"keywords": [
"addon",
@ -51,23 +51,23 @@
"dependencies": {
"@babel/plugin-transform-react-jsx": "^7.12.12",
"@jest/transform": "^26.6.2",
"@mdx-js/react": "^1.6.22",
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/blocks": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@mdx-js/react": "^2.1.5",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/blocks": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/csf-tools": "7.0.0-alpha.39",
"@storybook/docs-tools": "7.0.0-alpha.39",
"@storybook/mdx1-csf": "0.0.5-canary.13.9ce928a.0",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/postinstall": "7.0.0-alpha.39",
"@storybook/preview-web": "7.0.0-alpha.39",
"@storybook/source-loader": "7.0.0-alpha.39",
"@storybook/store": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/csf-tools": "7.0.0-alpha.40",
"@storybook/docs-tools": "7.0.0-alpha.40",
"@storybook/mdx2-csf": "0.1.0-next.0",
"@storybook/node-logger": "7.0.0-alpha.40",
"@storybook/postinstall": "7.0.0-alpha.40",
"@storybook/preview-web": "7.0.0-alpha.40",
"@storybook/source-loader": "7.0.0-alpha.40",
"@storybook/store": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"dequal": "^2.0.2",
"fs-extra": "^9.0.1",
"global": "^4.4.0",
@ -77,18 +77,13 @@
},
"devDependencies": {
"@babel/core": "^7.12.10",
"@storybook/mdx2-csf": "0.0.4-canary.14.04ffbe8.0",
"typescript": "~4.6.3"
},
"peerDependencies": {
"@storybook/mdx2-csf": "0.0.4-canary.14.04ffbe8.0",
"react": "^16.8.0 || ^17.0.0 || ^18.0.0",
"react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0"
},
"peerDependenciesMeta": {
"@storybook/mdx2-csf": {
"optional": true
},
"react": {
"optional": true
},
@ -99,7 +94,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"storybook": {
"displayName": "Docs",
"icon": "https://user-images.githubusercontent.com/263385/101991672-48355c80-3c7c-11eb-82d9-95fa12438f64.png",

View File

@ -29,8 +29,12 @@ export class DocsRenderer<TFramework extends AnyFramework> {
// Use a random key to force the container to re-render each time we call `renderDocs`
// TODO: do we still need this? It was needed for angular (legacy) inline rendering:
// https://github.com/storybookjs/storybook/pull/16149
const components = {
...defaultComponents,
...docsParameter?.components,
};
ReactDOM.render(
<MDXProvider components={defaultComponents}>
<MDXProvider components={components}>
<Docs key={Math.random()} context={context} docsParameter={docsParameter} />
</MDXProvider>,
element,

View File

@ -1,7 +1,6 @@
import fs from 'fs-extra';
import remarkSlug from 'remark-slug';
import remarkExternalLinks from 'remark-external-links';
import global from 'global';
import type { DocsOptions, IndexerOptions, Options, StoryIndexer } from '@storybook/core-common';
import { logger } from '@storybook/node-logger';
@ -68,12 +67,9 @@ export async function webpack(
remarkPlugins: [remarkSlug, remarkExternalLinks],
};
const mdxVersion = global.FEATURES?.previewMdx2 ? 'MDX2' : 'MDX1';
logger.info(`Addon-docs: using ${mdxVersion}`);
logger.info(`Addon-docs: using MDX2`);
const mdxLoader = global.FEATURES?.previewMdx2
? require.resolve('@storybook/mdx2-csf/loader')
: require.resolve('@storybook/mdx1-csf/loader');
const mdxLoader = require.resolve('@storybook/mdx2-csf/loader');
// set `sourceLoaderOptions` to `null` to disable for manual configuration
const sourceLoader = sourceLoaderOptions
@ -155,9 +151,7 @@ export const storyIndexers = async (indexers: StoryIndexer[] | null) => {
const mdxIndexer = async (fileName: string, opts: IndexerOptions) => {
let code = (await fs.readFile(fileName, 'utf-8')).toString();
// @ts-expect-error (Converted from ts-ignore)
const { compile } = global.FEATURES?.previewMdx2
? await import('@storybook/mdx2-csf')
: await import('@storybook/mdx1-csf');
const { compile } = await import('@storybook/mdx2-csf');
code = await compile(code, {});
return loadCsf(code, { ...opts, fileName }).parse();
};

View File

@ -1,4 +1,3 @@
declare module '@mdx-js/react';
declare module 'global';
declare module '@egoist/vue-to-react';
declare module 'remark-slug';

View File

@ -4,7 +4,6 @@ import globalThis from 'global';
<Meta
title="addons/docs/stories-mdx/play functions"
component={globalThis.Components.Button}
// FIXME: this is currently broken in the MDX compiler
play={() => console.log('component play')}
/>
@ -13,16 +12,9 @@ import globalThis from 'global';
This file demonstrates defining stories inside MDX.
<Canvas>
<Story
name="Component Play"
args={{ label: 'Component Play' }}
/>
<Story name="Component Play" args={{ label: 'Component Play' }} />
</Canvas>
<Canvas>
<Story
name="Story Play"
args={{ label: 'Story Play' }}
play={() => console.log('story play')}
/>
<Story name="Story Play" args={{ label: 'Story Play' }} play={() => console.log('story play')} />
</Canvas>

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-essentials",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Curated addons to bring out the best of Storybook",
"keywords": [
"addon",
@ -41,24 +41,24 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addon-actions": "7.0.0-alpha.39",
"@storybook/addon-backgrounds": "7.0.0-alpha.39",
"@storybook/addon-controls": "7.0.0-alpha.39",
"@storybook/addon-docs": "7.0.0-alpha.39",
"@storybook/addon-highlight": "7.0.0-alpha.39",
"@storybook/addon-measure": "7.0.0-alpha.39",
"@storybook/addon-outline": "7.0.0-alpha.39",
"@storybook/addon-toolbars": "7.0.0-alpha.39",
"@storybook/addon-viewport": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/addon-actions": "7.0.0-alpha.40",
"@storybook/addon-backgrounds": "7.0.0-alpha.40",
"@storybook/addon-controls": "7.0.0-alpha.40",
"@storybook/addon-docs": "7.0.0-alpha.40",
"@storybook/addon-highlight": "7.0.0-alpha.40",
"@storybook/addon-measure": "7.0.0-alpha.40",
"@storybook/addon-outline": "7.0.0-alpha.40",
"@storybook/addon-toolbars": "7.0.0-alpha.40",
"@storybook/addon-viewport": "7.0.0-alpha.40",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/node-logger": "7.0.0-alpha.40",
"ts-dedent": "^2.0.0"
},
"devDependencies": {
"@babel/core": "^7.12.10",
"@storybook/vue": "7.0.0-alpha.39",
"@storybook/vue": "7.0.0-alpha.40",
"@types/jest": "^26.0.16",
"typescript": "~4.6.3"
},
@ -112,5 +112,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-highlight",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Highlight DOM nodes within your stories",
"keywords": [
"storybook-addons",
@ -50,8 +50,8 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"global": "^4.4.0"
},
"devDependencies": {
@ -67,7 +67,7 @@
"./src/highlight.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"sbmodern": "dist/modern/index.js",
"storybook": {
"displayName": "Highlight",

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-interactions",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Automate, test and debug user interactions",
"keywords": [
"storybook-addons",
@ -59,15 +59,15 @@
},
"dependencies": {
"@devtools-ds/object-inspector": "^1.1.2",
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/instrumenter": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/instrumenter": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"global": "^4.4.0",
"jest-mock": "^27.0.6",
"polished": "^4.2.2",
@ -104,7 +104,7 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"storybook": {
"displayName": "Interactions",
"unsupportedFrameworks": [

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-jest",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "React storybook addon that show component jest report",
"keywords": [
"addon",
@ -59,12 +59,12 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"global": "^4.4.0",
"react-sizeme": "^3.0.1",
"upath": "^1.2.0"
@ -94,7 +94,7 @@
],
"platform": "browser"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"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.39",
"version": "7.0.0-alpha.40",
"description": "Link stories together to build demos and prototypes with your UI components",
"keywords": [
"addon",
@ -63,11 +63,11 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/router": "7.0.0-alpha.39",
"@storybook/router": "7.0.0-alpha.40",
"global": "^4.4.0",
"prop-types": "^15.7.2",
"ts-dedent": "^2.0.0"
@ -98,7 +98,7 @@
"./src/react/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"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.39",
"version": "7.0.0-alpha.40",
"description": "Inspect layouts by visualizing the box model",
"keywords": [
"storybook-addons",
@ -61,11 +61,11 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"global": "^4.4.0"
},
@ -94,7 +94,7 @@
"./src/preview.tsx"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"storybook": {
"displayName": "Measure",
"unsupportedFrameworks": [

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-outline",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Outline all elements with CSS to help with layout placement and alignment",
"keywords": [
"storybook-addons",
@ -64,11 +64,11 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"global": "^4.4.0",
"ts-dedent": "^2.0.0"
@ -98,7 +98,7 @@
"./src/preset/preview.tsx"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"storybook": {
"displayName": "Outline",
"unsupportedFrameworks": [

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-storyshots",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"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.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/babel-plugin-require-context-hook": "1.0.1",
"@storybook/client-api": "7.0.0-alpha.39",
"@storybook/core-client": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/core-webpack": "7.0.0-alpha.39",
"@storybook/client-api": "7.0.0-alpha.40",
"@storybook/core-client": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/core-webpack": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@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.39",
"@storybook/angular": "7.0.0-alpha.39",
"@storybook/react": "7.0.0-alpha.39",
"@storybook/vue": "7.0.0-alpha.39",
"@storybook/vue3": "7.0.0-alpha.39",
"@storybook/addon-docs": "7.0.0-alpha.40",
"@storybook/angular": "7.0.0-alpha.40",
"@storybook/react": "7.0.0-alpha.40",
"@storybook/vue": "7.0.0-alpha.40",
"@storybook/vue3": "7.0.0-alpha.40",
"babel-loader": "^8.2.5",
"enzyme": "^3.11.0",
"enzyme-to-json": "^3.6.1",
@ -144,7 +144,7 @@
"publishConfig": {
"access": "public"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"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.39",
"version": "7.0.0-alpha.40",
"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.49.258942b.0",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.40",
"@types/jest-image-snapshot": "^4.1.3",
"jest-image-snapshot": "^4.3.0"
},
@ -44,7 +44,7 @@
"puppeteer": "^2.0.0 || ^3.0.0"
},
"peerDependencies": {
"@storybook/addon-storyshots": "7.0.0-alpha.39",
"@storybook/addon-storyshots": "7.0.0-alpha.40",
"puppeteer": ">=2.0.0"
},
"peerDependenciesMeta": {
@ -55,5 +55,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addon-storysource",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "View a storys source code to see how it works and paste into your app",
"keywords": [
"addon",
@ -53,13 +53,13 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/router": "7.0.0-alpha.39",
"@storybook/source-loader": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/router": "7.0.0-alpha.40",
"@storybook/source-loader": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"estraverse": "^5.2.0",
"prop-types": "^15.7.2",
"react-syntax-highlighter": "^15.5.0"
@ -91,7 +91,7 @@
"./src/preset.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"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.39",
"version": "7.0.0-alpha.40",
"description": "Create your own toolbar items that control story rendering",
"keywords": [
"addon",
@ -57,11 +57,11 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39"
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40"
},
"devDependencies": {
"typescript": "~4.6.3"
@ -88,7 +88,7 @@
],
"platform": "browser"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"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.39",
"version": "7.0.0-alpha.40",
"description": "Build responsive components by adjusting Storybooks viewport size and orientation",
"keywords": [
"addon",
@ -59,12 +59,12 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"global": "^4.4.0",
"memoizerific": "^1.11.3",
"prop-types": "^15.7.2"
@ -95,7 +95,7 @@
"./src/preview.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9",
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c",
"storybook": {
"displayName": "Viewport",
"icon": "https://user-images.githubusercontent.com/263385/101991678-48cdf300-3c7c-11eb-9764-f8af293c1b28.png",

View File

@ -14,7 +14,6 @@ const config: StorybookConfig = {
buildStoriesJson: true,
babelModeV7: true,
warnOnLegacyHierarchySeparator: false,
previewMdx2: true,
breakingChangesV7: true,
},
framework: '@storybook/react-webpack5',

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/example-doc-blocks",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"private": true,
"scripts": {
"build-storybook": "cross-env STORYBOOK_DISPLAY_WARNING=true DISPLAY_WARNING=true sb build",
@ -15,20 +15,20 @@
"@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.39",
"@storybook/addon-storyshots": "7.0.0-alpha.39",
"@storybook/addon-storysource": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/cli": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/react-webpack5": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/addon-essentials": "7.0.0-alpha.40",
"@storybook/addon-storyshots": "7.0.0-alpha.40",
"@storybook/addon-storysource": "7.0.0-alpha.40",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/cli": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/react-webpack5": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"@types/babel__preset-env": "^7",
"@types/react": "^16.14.23",
"@types/react-dom": "^16.9.14",
"cross-env": "^7.0.3",
"lodash": "^4.17.21",
"sb": "7.0.0-alpha.39",
"sb": "7.0.0-alpha.40",
"typescript": "~4.6.3",
"webpack": "5"
},

View File

@ -1,6 +1,6 @@
{
"name": "ember-example",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"private": true,
"scripts": {
"--build-storybook": "yarn storybook-prebuild && storybook build",
@ -17,19 +17,19 @@
"devDependencies": {
"@babel/core": "^7.12.10",
"@ember/optional-features": "^2.0.0",
"@storybook/addon-a11y": "7.0.0-alpha.39",
"@storybook/addon-actions": "7.0.0-alpha.39",
"@storybook/addon-backgrounds": "7.0.0-alpha.39",
"@storybook/addon-controls": "7.0.0-alpha.39",
"@storybook/addon-docs": "7.0.0-alpha.39",
"@storybook/addon-highlight": "7.0.0-alpha.39",
"@storybook/addon-links": "7.0.0-alpha.39",
"@storybook/addon-storysource": "7.0.0-alpha.39",
"@storybook/addon-viewport": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/ember": "7.0.0-alpha.39",
"@storybook/addon-a11y": "7.0.0-alpha.40",
"@storybook/addon-actions": "7.0.0-alpha.40",
"@storybook/addon-backgrounds": "7.0.0-alpha.40",
"@storybook/addon-controls": "7.0.0-alpha.40",
"@storybook/addon-docs": "7.0.0-alpha.40",
"@storybook/addon-highlight": "7.0.0-alpha.40",
"@storybook/addon-links": "7.0.0-alpha.40",
"@storybook/addon-storysource": "7.0.0-alpha.40",
"@storybook/addon-viewport": "7.0.0-alpha.40",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/ember": "7.0.0-alpha.40",
"@storybook/ember-cli-storybook": "^0.2.1",
"@storybook/source-loader": "7.0.0-alpha.39",
"@storybook/source-loader": "7.0.0-alpha.40",
"babel-loader": "^8.2.5",
"broccoli-asset-rev": "^3.0.0",
"browserify-zlib": "^0.2.0",
@ -49,7 +49,7 @@
"loader.js": "^4.7.0",
"os-browserify": "^0.3.0",
"shx": "^0.3.2",
"storybook": "7.0.0-alpha.39",
"storybook": "7.0.0-alpha.40",
"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.39",
"version": "7.0.0-alpha.40",
"private": true,
"scripts": {
"build": "next build",
@ -11,15 +11,15 @@
"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.39",
"@storybook/addon-essentials": "7.0.0-alpha.39",
"@storybook/blocks": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/addon-docs": "7.0.0-alpha.40",
"@storybook/addon-essentials": "7.0.0-alpha.40",
"@storybook/blocks": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/preview-web": "7.0.0-alpha.39",
"@storybook/react": "7.0.0-alpha.39",
"@storybook/react-webpack5": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/preview-web": "7.0.0-alpha.40",
"@storybook/react": "7.0.0-alpha.40",
"@storybook/react-webpack5": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"formik": "^2.2.9",
"next": "^12.1.0",
"nextra": "^1.1.0",
@ -38,7 +38,7 @@
"cross-env": "^7.0.3",
"eslint": "8.7.0",
"eslint-config-next": "12.0.8",
"storybook": "7.0.0-alpha.39",
"storybook": "7.0.0-alpha.40",
"typescript": "~4.6.3",
"webpack": "5"
}

View File

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

View File

@ -1,20 +1,20 @@
{
"name": "standalone-preview",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"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.39",
"@storybook/cli": "7.0.0-alpha.39",
"@storybook/react": "7.0.0-alpha.39",
"@storybook/react-webpack5": "7.0.0-alpha.39",
"@storybook/addon-docs": "7.0.0-alpha.40",
"@storybook/cli": "7.0.0-alpha.40",
"@storybook/react": "7.0.0-alpha.40",
"@storybook/react-webpack5": "7.0.0-alpha.40",
"cross-env": "^7.0.3",
"parcel": "2.0.1",
"react": "16.14.0",
"react-dom": "16.14.0",
"storybook": "7.0.0-alpha.39"
"storybook": "7.0.0-alpha.40"
}
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/angular",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for Angular: Develop Angular components in isolation with hot reloading.",
"keywords": [
"storybook",
@ -34,19 +34,19 @@
"prep": "node ../../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/builder-webpack5": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/core-client": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/core-server": "7.0.0-alpha.39",
"@storybook/core-webpack": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/builder-webpack5": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/core-client": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/core-server": "7.0.0-alpha.40",
"@storybook/core-webpack": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/docs-tools": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/store": "7.0.0-alpha.39",
"@storybook/docs-tools": "7.0.0-alpha.40",
"@storybook/node-logger": "7.0.0-alpha.40",
"@storybook/store": "7.0.0-alpha.40",
"@types/node": "^16.0.0",
"@types/react": "^16.14.23",
"@types/react-dom": "^16.9.14",
@ -120,5 +120,5 @@
"access": "public"
},
"builders": "dist/types/builders/builders.json",
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/ember",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for Ember: Develop Ember Component in isolation with Hot Reloading.",
"homepage": "https://github.com/storybookjs/storybook/tree/main/frameworks/ember",
"bugs": {
@ -30,11 +30,11 @@
"prep": "node ../../../scripts/prepare.js"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.39",
"@storybook/core-client": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/docs-tools": "7.0.0-alpha.39",
"@storybook/store": "7.0.0-alpha.39",
"@storybook/builder-webpack5": "7.0.0-alpha.40",
"@storybook/core-client": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/docs-tools": "7.0.0-alpha.40",
"@storybook/store": "7.0.0-alpha.40",
"global": "^4.4.0",
"react": "16.14.0",
"react-dom": "16.14.0",
@ -57,5 +57,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/html-webpack5",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for HTML: View HTML snippets in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -50,10 +50,10 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/html": "7.0.0-alpha.39",
"@storybook/preset-html-webpack": "7.0.0-alpha.39",
"@storybook/builder-webpack5": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/html": "7.0.0-alpha.40",
"@storybook/preset-html-webpack": "7.0.0-alpha.40",
"@types/node": "^16.0.0",
"global": "^4.4.0",
"react": "16.14.0",
@ -78,5 +78,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/preact-webpack5",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for Preact: Develop Preact Component in isolation.",
"keywords": [
"storybook"
@ -50,10 +50,10 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/preact": "7.0.0-alpha.39",
"@storybook/preset-preact-webpack": "7.0.0-alpha.39",
"@storybook/builder-webpack5": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/preact": "7.0.0-alpha.40",
"@storybook/preset-preact-webpack": "7.0.0-alpha.40",
"@types/node": "^16.0.0",
"react": "16.14.0",
"react-dom": "16.14.0"
@ -79,5 +79,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/react-vite",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for React and Vite: Develop React components in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -53,13 +53,13 @@
"dependencies": {
"@joshwooding/vite-plugin-react-docgen-typescript": "^0.0.5",
"@rollup/pluginutils": "^4.2.0",
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/builder-vite": "7.0.0-alpha.39",
"@storybook/channel-postmessage": "7.0.0-alpha.39",
"@storybook/channel-websocket": "7.0.0-alpha.39",
"@storybook/client-api": "7.0.0-alpha.39",
"@storybook/preview-web": "7.0.0-alpha.39",
"@storybook/react": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/builder-vite": "7.0.0-alpha.40",
"@storybook/channel-postmessage": "7.0.0-alpha.40",
"@storybook/channel-websocket": "7.0.0-alpha.40",
"@storybook/client-api": "7.0.0-alpha.40",
"@storybook/preview-web": "7.0.0-alpha.40",
"@storybook/react": "7.0.0-alpha.40",
"@vitejs/plugin-react": "^2.0.0",
"ast-types": "^0.14.2",
"magic-string": "^0.26.1",
@ -88,5 +88,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/react-webpack5",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for React: Develop React Component in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -51,9 +51,9 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.39",
"@storybook/preset-react-webpack": "7.0.0-alpha.39",
"@storybook/react": "7.0.0-alpha.39",
"@storybook/builder-webpack5": "7.0.0-alpha.40",
"@storybook/preset-react-webpack": "7.0.0-alpha.40",
"@storybook/react": "7.0.0-alpha.40",
"@types/node": "^16.0.0"
},
"devDependencies": {
@ -86,5 +86,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/server-webpack5",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for Server: View HTML snippets from a server in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -50,10 +50,10 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/preset-server-webpack": "7.0.0-alpha.39",
"@storybook/server": "7.0.0-alpha.39",
"@storybook/builder-webpack5": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/preset-server-webpack": "7.0.0-alpha.40",
"@storybook/server": "7.0.0-alpha.40",
"@types/node": "^16.0.0",
"react": "16.14.0",
"react-dom": "16.14.0"
@ -74,5 +74,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/svelte-vite",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for Svelte and Vite: Develop Svelte components in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -52,14 +52,14 @@
},
"dependencies": {
"@storybook/addon-svelte-csf": "^2.0.0",
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/builder-vite": "7.0.0-alpha.39",
"@storybook/channel-postmessage": "7.0.0-alpha.39",
"@storybook/channel-websocket": "7.0.0-alpha.39",
"@storybook/client-api": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/preview-web": "7.0.0-alpha.39",
"@storybook/svelte": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/builder-vite": "7.0.0-alpha.40",
"@storybook/channel-postmessage": "7.0.0-alpha.40",
"@storybook/channel-websocket": "7.0.0-alpha.40",
"@storybook/client-api": "7.0.0-alpha.40",
"@storybook/node-logger": "7.0.0-alpha.40",
"@storybook/preview-web": "7.0.0-alpha.40",
"@storybook/svelte": "7.0.0-alpha.40",
"@sveltejs/vite-plugin-svelte": "^1.0.0",
"magic-string": "^0.26.1",
"svelte": "^3.0.0",
@ -92,5 +92,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/svelte-webpack5",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for Svelte: Develop Svelte Component in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -51,10 +51,10 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/preset-svelte-webpack": "7.0.0-alpha.39",
"@storybook/svelte": "7.0.0-alpha.39",
"@storybook/builder-webpack5": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/preset-svelte-webpack": "7.0.0-alpha.40",
"@storybook/svelte": "7.0.0-alpha.40",
"react": "16.14.0",
"react-dom": "16.14.0"
},
@ -81,5 +81,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/vue-vite",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for Vue2 and Vite: Develop Vue2 Components in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -50,15 +50,15 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/builder-vite": "7.0.0-alpha.39",
"@storybook/channel-postmessage": "7.0.0-alpha.39",
"@storybook/channel-websocket": "7.0.0-alpha.39",
"@storybook/client-api": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/core-server": "7.0.0-alpha.39",
"@storybook/preview-web": "7.0.0-alpha.39",
"@storybook/vue": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/builder-vite": "7.0.0-alpha.40",
"@storybook/channel-postmessage": "7.0.0-alpha.40",
"@storybook/channel-websocket": "7.0.0-alpha.40",
"@storybook/client-api": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/core-server": "7.0.0-alpha.40",
"@storybook/preview-web": "7.0.0-alpha.40",
"@storybook/vue": "7.0.0-alpha.40",
"magic-string": "^0.26.1",
"vite": "^3.1.3",
"vue-docgen-api": "^4.40.0"
@ -83,5 +83,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/vue-webpack5",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for Vue: Develop Vue Component in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -50,10 +50,10 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/preset-vue-webpack": "7.0.0-alpha.39",
"@storybook/vue": "7.0.0-alpha.39",
"@storybook/builder-webpack5": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/preset-vue-webpack": "7.0.0-alpha.40",
"@storybook/vue": "7.0.0-alpha.40",
"@types/node": "^16.0.0",
"react": "16.14.0",
"react-dom": "16.14.0"
@ -85,5 +85,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/vue3-vite",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for Vue3 and Vite: Develop Vue3 components in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -51,14 +51,14 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/builder-vite": "7.0.0-alpha.39",
"@storybook/channel-postmessage": "7.0.0-alpha.39",
"@storybook/channel-websocket": "7.0.0-alpha.39",
"@storybook/client-api": "7.0.0-alpha.39",
"@storybook/core-server": "7.0.0-alpha.39",
"@storybook/preview-web": "7.0.0-alpha.39",
"@storybook/vue3": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/builder-vite": "7.0.0-alpha.40",
"@storybook/channel-postmessage": "7.0.0-alpha.40",
"@storybook/channel-websocket": "7.0.0-alpha.40",
"@storybook/client-api": "7.0.0-alpha.40",
"@storybook/core-server": "7.0.0-alpha.40",
"@storybook/preview-web": "7.0.0-alpha.40",
"@storybook/vue3": "7.0.0-alpha.40",
"@vitejs/plugin-vue": "^3.0.0",
"magic-string": "^0.26.1",
"vite": "^3.1.3",
@ -82,5 +82,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/vue3-webpack5",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for Vue 3: Develop Vue 3 Components in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -50,10 +50,10 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/preset-vue3-webpack": "7.0.0-alpha.39",
"@storybook/vue3": "7.0.0-alpha.39",
"@storybook/builder-webpack5": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/preset-vue3-webpack": "7.0.0-alpha.40",
"@storybook/vue3": "7.0.0-alpha.40",
"@types/node": "^16.0.0",
"react": "16.14.0",
"react-dom": "16.14.0"
@ -82,5 +82,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/web-components-vite",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for web-components and Vite: Develop Web Components in isolation with Hot Reloading.",
"keywords": [
"storybook"
@ -51,15 +51,15 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/builder-vite": "7.0.0-alpha.39",
"@storybook/channel-postmessage": "7.0.0-alpha.39",
"@storybook/channel-websocket": "7.0.0-alpha.39",
"@storybook/client-api": "7.0.0-alpha.39",
"@storybook/core-server": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/preview-web": "7.0.0-alpha.39",
"@storybook/web-components": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/builder-vite": "7.0.0-alpha.40",
"@storybook/channel-postmessage": "7.0.0-alpha.40",
"@storybook/channel-websocket": "7.0.0-alpha.40",
"@storybook/client-api": "7.0.0-alpha.40",
"@storybook/core-server": "7.0.0-alpha.40",
"@storybook/node-logger": "7.0.0-alpha.40",
"@storybook/preview-web": "7.0.0-alpha.40",
"@storybook/web-components": "7.0.0-alpha.40",
"@vitejs/plugin-vue": "^3.0.3",
"magic-string": "^0.26.1",
"vite": "3"
@ -82,5 +82,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/web-components-webpack5",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook for web-components: View web components snippets in isolation with Hot Reloading.",
"keywords": [
"lit-html",
@ -53,10 +53,10 @@
},
"dependencies": {
"@babel/preset-env": "^7.12.11",
"@storybook/builder-webpack5": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/preset-web-components-webpack": "7.0.0-alpha.39",
"@storybook/web-components": "7.0.0-alpha.39",
"@storybook/builder-webpack5": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/preset-web-components-webpack": "7.0.0-alpha.40",
"@storybook/web-components": "7.0.0-alpha.40",
"@types/node": "^16.0.0",
"react": "16.14.0",
"react-dom": "16.14.0"
@ -81,5 +81,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -31,7 +31,10 @@ module.exports = {
'^.+\\.[jt]sx?$': '<rootDir>/../scripts/utils/jest-transform-js.js',
'^.+\\.mdx$': '@storybook/addon-docs/jest-transform-mdx',
},
transformIgnorePatterns: ['/node_modules/(?!lit-html).+\\.js'],
transformIgnorePatterns: [
'/node_modules/(?!(lit-html|@mdx-js)).+\\.js',
'/node_modules/(?!).+\\.js',
],
testMatch: ['**/__tests__/**/*.[jt]s?(x)', '**/?(*.)+(spec|test).[jt]s?(x)'],
testPathIgnorePatterns: [
'/storybook-static/',

View File

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

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/addons",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook addons store",
"keywords": [
"storybook"
@ -42,13 +42,13 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/api": "7.0.0-alpha.39",
"@storybook/channels": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/channels": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/router": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/router": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"global": "^4.4.0"
},
"peerDependencies": {
@ -63,5 +63,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/api",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Core Storybook API & Context",
"keywords": [
"storybook"
@ -45,12 +45,12 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/channels": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/channels": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/router": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/router": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"dequal": "^2.0.2",
"global": "^4.4.0",
"lodash": "^4.17.21",
@ -63,7 +63,7 @@
},
"devDependencies": {
"@jest/globals": "^26.6.2",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.40",
"@types/lodash": "^4.14.167",
"@types/qs": "^6",
"flush-promises": "^1.0.2",
@ -83,5 +83,5 @@
"./src/shortcut.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,10 +1,8 @@
import memoize from 'memoizerific';
import React from 'react';
import deprecate from 'util-deprecate';
import { dedent } from 'ts-dedent';
import mapValues from 'lodash/mapValues';
import countBy from 'lodash/countBy';
import global from 'global';
import { toId, sanitize } from '@storybook/csf';
import type {
StoryId,
@ -23,8 +21,6 @@ import merge from './merge';
import type { Provider } from '../modules/provider';
import type { ViewMode } from '../modules/addons';
const { FEATURES } = global;
export type { StoryId };
export interface BaseEntry {
@ -222,15 +218,6 @@ export interface StoryIndex {
entries: Record<StoryId, IndexEntry>;
}
const warnChangedDefaultHierarchySeparators = deprecate(
() => {},
dedent`
The default hierarchy separators changed in Storybook 6.0.
'|' and '.' will no longer create a hierarchy, but codemods are available.
Read more about it in the migration guide: https://github.com/storybookjs/storybook/blob/master/MIGRATION.md
`
);
export const denormalizeStoryParameters = ({
globalParameters,
kindParameters,
@ -366,12 +353,8 @@ export const transformStoryIndexToStoriesHash = (
const entryValues = Object.values(v4Index.entries);
const { sidebar = {} } = provider.getConfig();
const { showRoots, collapsedRoots = [], renderLabel } = sidebar;
const usesOldHierarchySeparator = entryValues.some(({ title }) => title.match(/\.|\|/)); // dot or pipe
const setShowRoots = typeof showRoots !== 'undefined';
if (usesOldHierarchySeparator && !setShowRoots && FEATURES?.warnOnLegacyHierarchySeparator) {
warnChangedDefaultHierarchySeparators();
}
const storiesHashOutOfOrder = Object.values(entryValues).reduce((acc, item) => {
if (docsOptions.docsMode && item.type !== 'docs') return acc;

View File

@ -4,8 +4,6 @@ import { dequal as deepEqual } from 'dequal';
import { create } from '@storybook/theming/create';
import { SET_CONFIG } from '@storybook/core-events';
import type { ThemeVars } from '@storybook/theming';
import { deprecate } from '@storybook/client-logger';
import { dedent } from 'ts-dedent';
import merge from '../lib/merge';
import type { State, ModuleFn } from '../index';
@ -225,15 +223,6 @@ export const init: ModuleFn = ({ store, provider, singleStory, fullAPI }) => {
getInitialOptions() {
const { theme, selectedPanel, ...options } = provider.getConfig();
if (options.layout?.isToolshown !== undefined) {
deprecate(dedent`
The "isToolshown" option is deprecated. Please use "showToolbar" instead.
See https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#renamed-istoolshown-to-showtoolbar
`);
options.layout.showToolbar = options.layout.isToolshown;
}
return {
...defaultState,
layout: {

View File

@ -13,7 +13,6 @@ import {
STORY_INDEX_INVALIDATED,
CONFIG_ERROR,
} from '@storybook/core-events';
import deprecate from 'util-deprecate';
import { logger } from '@storybook/client-logger';
import { getEventMetadata } from '../lib/events';
@ -92,28 +91,21 @@ export interface SubAPI {
updateStory: (storyId: StoryId, update: StoryUpdate, ref?: ComposedRef) => Promise<void>;
}
const deprecatedOptionsParameterWarnings: Record<string, () => void> = [
'enableShortcuts',
'theme',
'showRoots',
].reduce((acc, option: string) => {
acc[option] = deprecate(
() => {},
`parameters.options.${option} is deprecated and will be removed in Storybook 7.0.
To change this setting, use \`addons.setConfig\`. See https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#deprecated-immutable-options-parameters
`
);
return acc;
}, {} as Record<string, () => void>);
function checkDeprecatedOptionParameters(options?: Record<string, any>) {
if (!options) {
return;
const removedOptions = ['enableShortcuts', 'theme', 'showRoots'];
function removeRemovedOptions<T extends Record<string, any> = Record<string, any>>(options?: T): T {
if (!options || typeof options === 'string') {
return options;
}
Object.keys(options).forEach((option: string) => {
if (deprecatedOptionsParameterWarnings[option]) {
deprecatedOptionsParameterWarnings[option]();
const result: T = { ...options } as T;
removedOptions.forEach((option) => {
if (option in result) {
delete result[option];
}
});
return result;
}
export const init: ModuleFn<SubAPI, SubState, true> = ({
@ -424,8 +416,7 @@ export const init: ModuleFn<SubAPI, SubState, true> = ({
const options = fullAPI.getCurrentParameter('options');
if (options) {
checkDeprecatedOptionParameters(options);
fullAPI.setOptions(options);
fullAPI.setOptions(removeRemovedOptions(options));
}
}
});
@ -437,8 +428,7 @@ export const init: ModuleFn<SubAPI, SubState, true> = ({
if (!ref) {
if (!store.getState().hasCalledSetOptions) {
const { options } = update.parameters;
checkDeprecatedOptionParameters(options);
fullAPI.setOptions(options);
fullAPI.setOptions(removeRemovedOptions(options));
store.setState({ hasCalledSetOptions: true });
}
} else {
@ -474,8 +464,7 @@ export const init: ModuleFn<SubAPI, SubState, true> = ({
fullAPI.setStories(setStoriesData);
const options = fullAPI.getCurrentParameter('options');
checkDeprecatedOptionParameters(options);
fullAPI.setOptions(options);
fullAPI.setOptions(removeRemovedOptions(options));
} else {
fullAPI.setRef(ref.id, { ...ref, setStoriesData }, true);
}

View File

@ -1,4 +1,3 @@
import { deprecate } from '@storybook/client-logger';
import {
NAVIGATE_URL,
STORY_ARGS_UPDATED,
@ -8,10 +7,8 @@ import {
} from '@storybook/core-events';
import type { NavigateOptions } from '@storybook/router';
import { queryFromLocation, buildArgsParam } from '@storybook/router';
import { toId, sanitize } from '@storybook/csf';
import { dequal as deepEqual } from 'dequal';
import global from 'global';
import { dedent } from 'ts-dedent';
import { ModuleArgs, ModuleFn } from '../index';
import { Layout, UI } from './layout';
@ -49,11 +46,6 @@ const initialUrlSupport = ({
shortcuts,
addonPanel,
tabs,
addons, // deprecated
panelRight, // deprecated
stories, // deprecated
selectedKind, // deprecated
selectedStory, // deprecated
path: queryPath,
...otherParams // the rest gets passed to the iframe
} = queryFromLocation(location);
@ -70,47 +62,7 @@ const initialUrlSupport = ({
};
const selectedPanel = addonPanel || undefined;
// @deprecated Superceded by `panel=false`, to be removed in 7.0
if (addons === '0') {
deprecate(dedent`
The 'addons' query param is deprecated and will be removed in Storybook 7.0. Use 'panel=false' instead.
More info: https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#deprecated-layout-url-params
`);
layout.showPanel = false;
}
// @deprecated Superceded by `panel=right`, to be removed in 7.0
if (panelRight === '1') {
deprecate(dedent`
The 'panelRight' query param is deprecated and will be removed in Storybook 7.0. Use 'panel=right' instead.
More info: https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#deprecated-layout-url-params
`);
layout.panelPosition = 'right';
}
// @deprecated Superceded by `nav=false`, to be removed in 7.0
if (stories === '0') {
deprecate(dedent`
The 'stories' query param is deprecated and will be removed in Storybook 7.0. Use 'nav=false' instead.
More info: https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#deprecated-layout-url-params
`);
layout.showNav = false;
}
// @deprecated To be removed in 7.0
// If the user hasn't set the storyId on the URL, we support legacy URLs (selectedKind/selectedStory)
// NOTE: this "storyId" can just be a prefix of a storyId, really it is a storyIdSpecifier.
let storyId = storyIdFromUrl;
if (!storyId && selectedKind) {
deprecate(dedent`
The 'selectedKind' and 'selectedStory' query params are deprecated and will be removed in Storybook 7.0. Use 'path' instead.
More info: https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#deprecated-layout-url-params
`);
storyId = selectedStory ? toId(selectedKind, selectedStory) : sanitize(selectedKind);
}
const storyId = storyIdFromUrl;
// Avoid returning a new object each time if no params actually changed.
const customQueryParams = deepEqual(prevParams, otherParams) ? prevParams : otherParams;
prevParams = customQueryParams;

View File

@ -77,65 +77,6 @@ describe('initial state', () => {
expect(layout).toEqual({ showPanel: false });
});
});
describe('deprecated query parameters', () => {
const defaultDeprecatedParameters = {
selectedKind: 'kind',
selectedStory: 'story',
addons: '1',
stories: '1',
panelRight: '0',
};
it('sets sensible storyId for selectedKind/Story', () => {
const location = { search: qs.stringify(defaultDeprecatedParameters) };
const {
state: { layout, storyId },
} = initURL({ state: { location, viewMode } });
// Nothing unexpected in layout
expect(layout).toEqual({});
expect(storyId).toEqual('kind--story');
});
it('sets sensible storyId for selectedKind only', () => {
const location = { search: { selectedKind: 'kind' } };
const {
state: { storyId },
} = initURL({ state: { location, viewMode } });
expect(storyId).toEqual('kind');
});
it('handles addons and stories parameters', () => {
const location = {
search: qs.stringify({
...defaultDeprecatedParameters,
addons: '0',
stories: '0',
}),
};
const {
state: { layout },
} = initURL({ state: { location } });
expect(layout).toEqual({ showNav: false, showPanel: false });
});
it('handles panelRight parameter', () => {
const location = {
search: qs.stringify({
...defaultDeprecatedParameters,
panelRight: '1',
}),
};
const {
state: { layout },
} = initURL({ state: { location } });
expect(layout).toEqual({ panelPosition: 'right' });
});
});
});
describe('queryParams', () => {

View File

@ -1 +1 @@
export const version = '7.0.0-alpha.39';
export const version = '7.0.0-alpha.40';

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/blocks",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook Doc Blocks",
"keywords": [
"storybook"
@ -41,16 +41,17 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/api": "7.0.0-alpha.39",
"@storybook/channels": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/channels": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/docs-tools": "7.0.0-alpha.39",
"@storybook/preview-web": "7.0.0-alpha.39",
"@storybook/store": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/docs-tools": "7.0.0-alpha.40",
"@storybook/preview-web": "7.0.0-alpha.40",
"@storybook/store": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"@types/lodash": "^4.14.167",
"color-convert": "^2.0.1",
"dequal": "^2.0.2",
"global": "^4.4.0",
@ -63,8 +64,8 @@
"util-deprecate": "^1.0.2"
},
"devDependencies": {
"@storybook/addon-actions": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/addon-actions": "7.0.0-alpha.40",
"@storybook/addons": "7.0.0-alpha.40",
"@types/color-convert": "^2.0.0"
},
"peerDependencies": {
@ -78,5 +79,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,4 +1,3 @@
declare module '@mdx-js/react';
declare module 'global';
declare module 'markdown-to-jsx';
declare module '*.md';

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/builder-manager",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook manager builder",
"keywords": [
"storybook"
@ -42,9 +42,9 @@
},
"dependencies": {
"@fal-works/esbuild-plugin-global-externals": "^2.1.2",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/ui": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/node-logger": "7.0.0-alpha.40",
"@storybook/ui": "7.0.0-alpha.40",
"@types/ejs": "^3.1.1",
"@yarnpkg/esbuild-plugin-pnp": "^3.0.0-rc.10",
"browser-assert": "^1.2.1",
@ -68,5 +68,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/builder-vite",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "A plugin to run and build Storybooks with Vite",
"homepage": "https://github.com/storybookjs/storybook/tree/main/code/lib/builder-vite/#readme",
"repository": {
@ -19,13 +19,13 @@
},
"dependencies": {
"@joshwooding/vite-plugin-react-docgen-typescript": "0.0.5",
"@storybook/client-api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/mdx1-csf": "0.0.5-canary.13.9ce928a.0",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/preview-web": "7.0.0-alpha.39",
"@storybook/source-loader": "7.0.0-alpha.39",
"@storybook/client-api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/mdx2-csf": "0.1.0-next.0",
"@storybook/node-logger": "7.0.0-alpha.40",
"@storybook/preview-web": "7.0.0-alpha.40",
"@storybook/source-loader": "7.0.0-alpha.40",
"@vitejs/plugin-react": "^2.0.0",
"browser-assert": "^1.2.1",
"es-module-lexer": "^0.9.3",
@ -36,22 +36,13 @@
"vite": "^3.1.3"
},
"devDependencies": {
"@storybook/mdx2-csf": "^0.0.3",
"@types/express": "^4.17.13",
"@types/node": "^16.0.0",
"typescript": "~4.6.3",
"vite": "^3.1.3"
},
"peerDependencies": {
"@storybook/mdx2-csf": "^0.0.3"
},
"peerDependenciesMeta": {
"@storybook/mdx2-csf": {
"optional": true
}
},
"publishConfig": {
"access": "public"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -56,13 +56,11 @@ export function mdxPlugin(options: Options): Plugin {
if (!filter(id)) return undefined;
// @ts-expect-error typescript doesn't think compile exists, but it does.
const { compile } = features?.previewMdx2
? await import('@storybook/mdx2-csf')
: await import('@storybook/mdx1-csf');
const { compile } = await import('@storybook/mdx2-csf');
const mdxCode = String(await compile(src, { skipCsf: !isStorybookMdx(id) }));
const modifiedCode = injectRenderer(mdxCode, Boolean(features?.previewMdx2));
const modifiedCode = injectRenderer(mdxCode, true);
// Hooks in recent rollup versions can be functions or objects, and though react hasn't changed, the typescript defs have
const rTransform = reactRefresh?.transform;

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/builder-webpack5",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook framework-agnostic API",
"keywords": [
"storybook"
@ -53,22 +53,22 @@
},
"dependencies": {
"@babel/core": "^7.12.10",
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/api": "7.0.0-alpha.39",
"@storybook/channel-postmessage": "7.0.0-alpha.39",
"@storybook/channel-websocket": "7.0.0-alpha.39",
"@storybook/channels": "7.0.0-alpha.39",
"@storybook/client-api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/components": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/core-webpack": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/preview-web": "7.0.0-alpha.39",
"@storybook/router": "7.0.0-alpha.39",
"@storybook/store": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/api": "7.0.0-alpha.40",
"@storybook/channel-postmessage": "7.0.0-alpha.40",
"@storybook/channel-websocket": "7.0.0-alpha.40",
"@storybook/channels": "7.0.0-alpha.40",
"@storybook/client-api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/components": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/core-webpack": "7.0.0-alpha.40",
"@storybook/node-logger": "7.0.0-alpha.40",
"@storybook/preview-web": "7.0.0-alpha.40",
"@storybook/router": "7.0.0-alpha.40",
"@storybook/store": "7.0.0-alpha.40",
"@storybook/theming": "7.0.0-alpha.40",
"@types/node": "^16.0.0",
"@types/semver": "^7.3.4",
"babel-loader": "^8.2.5",
@ -120,5 +120,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/channel-postmessage",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "",
"keywords": [
"storybook"
@ -42,9 +42,9 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/channels": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/channels": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"global": "^4.4.0",
"qs": "^6.10.0",
"telejson": "^6.0.8"
@ -60,5 +60,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/channel-websocket",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "",
"keywords": [
"storybook"
@ -34,8 +34,8 @@
"prep": "node ../../../scripts/prepare.js"
},
"dependencies": {
"@storybook/channels": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/channels": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"global": "^4.4.0",
"telejson": "^6.0.8"
},
@ -45,5 +45,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/channels",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "",
"keywords": [
"storybook"
@ -52,5 +52,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "sb",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook CLI",
"keywords": [
"storybook"
@ -24,7 +24,7 @@
"prep": "node ../../../scripts/prepare.js"
},
"dependencies": {
"@storybook/cli": "7.0.0-alpha.39"
"@storybook/cli": "7.0.0-alpha.40"
},
"devDependencies": {
"typescript": "~4.6.3"
@ -32,5 +32,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "storybook",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook CLI",
"keywords": [
"storybook"
@ -27,7 +27,7 @@
"prep": "node ../../../scripts/prepare.js"
},
"dependencies": {
"@storybook/cli": "7.0.0-alpha.39"
"@storybook/cli": "7.0.0-alpha.40"
},
"devDependencies": {
"typescript": "~4.6.3"
@ -35,5 +35,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/cli",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook's CLI - easiest method of adding storybook to your projects",
"keywords": [
"cli",
@ -43,12 +43,12 @@
"dependencies": {
"@babel/core": "^7.12.10",
"@babel/preset-env": "^7.12.11",
"@storybook/codemod": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/core-server": "7.0.0-alpha.39",
"@storybook/csf-tools": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/telemetry": "7.0.0-alpha.39",
"@storybook/codemod": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/core-server": "7.0.0-alpha.40",
"@storybook/csf-tools": "7.0.0-alpha.40",
"@storybook/node-logger": "7.0.0-alpha.40",
"@storybook/telemetry": "7.0.0-alpha.40",
"@types/semver": "^7.3.4",
"boxen": "^5.1.2",
"chalk": "^4.1.0",
@ -76,7 +76,7 @@
"util-deprecate": "^1.0.2"
},
"devDependencies": {
"@storybook/client-api": "7.0.0-alpha.39",
"@storybook/client-api": "7.0.0-alpha.40",
"@types/cross-spawn": "^6.0.2",
"@types/degit": "^2.8.3",
"@types/prompts": "^2.0.9",
@ -98,5 +98,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -152,8 +152,7 @@ export async function baseGenerator(
addonPackages.push('@storybook/addon-interactions', '@storybook/testing-library');
}
const yarn2ExtraPackages =
packageManager.type === 'yarn2' ? ['@storybook/addon-docs', '@mdx-js/react@1.x.x'] : [];
const yarn2ExtraPackages = packageManager.type === 'yarn2' ? ['@storybook/addon-docs'] : [];
const files = await fse.readdir(process.cwd());

View File

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

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/client-api",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook Client API",
"keywords": [
"storybook"
@ -42,10 +42,10 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/store": "7.0.0-alpha.39",
"@storybook/store": "7.0.0-alpha.40",
"@types/qs": "^6.9.5",
"@types/webpack-env": "^1.16.4",
"global": "^4.4.0",
@ -55,7 +55,7 @@
"util-deprecate": "^1.0.2"
},
"devDependencies": {
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.40",
"typescript": "~4.6.3"
},
"peerDependencies": {
@ -70,5 +70,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/client-logger",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "",
"keywords": [
"storybook"
@ -55,5 +55,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -240,42 +240,6 @@ import { Meta, Story } from '@storybook/addon-docs';
</Story>
```
### mdx-to-csf
This converts all your MDX stories into Component Story Format.
```sh
./node_modules/.bin/jscodeshift -t ./node_modules/@storybook/codemod/dist/transforms/mdx-to-csf.js . --ignore-pattern "node_modules|dist" --extensions=mdx
```
For example:
```js
import React from 'react';
import Button from './Button';
import { Meta, Story } from '@storybook/addon-docs';
<Meta title='Button' />
<Story name='basic stories'><Button label='The Button' /></Story>
```
Becomes:
```js
import React from 'react';
import Button from './Button';
export default {
title: 'Button',
};
export const basicStory = () => <Button label="The Button" />;
basicStory.story = {
name: 'basic stories',
};
```
### upgrade-hierarchy-separators
Starting in 5.3, Storybook is moving to using a single path separator, `/`, to specify the story hierarchy. It previously defaulted to `|` for story "roots" (optional) and either `/` or `.` for denoting paths. This codemod updates the old default to the new default.

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/codemod",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "A collection of codemod scripts written with JSCodeshift",
"keywords": [
"storybook"
@ -38,10 +38,9 @@
},
"dependencies": {
"@babel/types": "^7.12.11",
"@mdx-js/mdx": "^1.6.22",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/csf-tools": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/csf-tools": "7.0.0-alpha.40",
"@storybook/node-logger": "7.0.0-alpha.40",
"cross-spawn": "^7.0.3",
"globby": "^11.0.2",
"jscodeshift": "^0.13.1",
@ -64,5 +63,5 @@
"./src/index.js"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -9,6 +9,9 @@ const inputRegExp = /\.input\.js$/;
const fixturesDir = path.resolve(__dirname, '../__testfixtures__');
fs.readdirSync(fixturesDir).forEach((transformName) => {
// FIXME: delete after https://github.com/storybookjs/storybook/issues/19497
if (transformName === 'mdx-to-csf') return;
const transformFixturesDir = path.join(fixturesDir, transformName);
describe(transformName, () =>
fs

View File

@ -1,184 +0,0 @@
// import recast from 'recast';
import mdx from '@mdx-js/mdx';
import prettier from 'prettier';
import { sanitizeName } from '../lib/utils';
/**
* Convert a component's MDX file into module story format
*/
export default function transformer(file, api) {
const j = api.jscodeshift;
const code = mdx.sync(file.source, {});
const root = j(code);
function parseJsxAttributes(attributes) {
const result = {};
attributes.forEach((attr) => {
const key = attr.name.name;
const val = attr.value.type === 'JSXExpressionContainer' ? attr.value.expression : attr.value;
result[key] = val;
});
return result;
}
function genObjectExpression(attrs) {
return j.objectExpression(
Object.entries(attrs).map(([key, val]) => j.property('init', j.identifier(key), val))
);
}
function convertToStories(path) {
const base = j(path);
const meta = {};
const includeStories = [];
const storyStatements = [];
// get rid of all mdxType junk
base
.find(j.JSXAttribute)
.filter((attr) => attr.node.name.name === 'mdxType')
.remove();
// parse <Meta title="..." />
base
.find(j.JSXElement)
.filter((elt) => elt.node.openingElement.name.name === 'Meta')
.forEach((elt) => {
const attrs = parseJsxAttributes(elt.node.openingElement.attributes);
Object.assign(meta, attrs);
});
// parse <Story name="..." />
base
.find(j.JSXElement)
.filter((elt) => elt.node.openingElement.name.name === 'Story')
.forEach((elt) => {
const attrs = parseJsxAttributes(elt.node.openingElement.attributes);
if (attrs.name) {
const storyKey = sanitizeName(attrs.name.value);
includeStories.push(storyKey);
if (storyKey === attrs.name.value) {
delete attrs.name;
}
let body =
elt.node.children.find((n) => n.type !== 'JSXText') ||
j.literal(elt.node.children[0].value);
if (body.type === 'JSXExpressionContainer') {
body = body.expression;
}
storyStatements.push(
j.exportDeclaration(
false,
j.variableDeclaration('const', [
j.variableDeclarator(
j.identifier(storyKey),
body.type === 'ArrowFunctionExpression'
? body
: j.arrowFunctionExpression([], body)
),
])
)
);
if (Object.keys(attrs).length > 0) {
storyStatements.push(
j.assignmentStatement(
'=',
j.memberExpression(j.identifier(storyKey), j.identifier('story')),
genObjectExpression(attrs)
)
);
}
storyStatements.push(j.emptyStatement());
}
});
if (root.find(j.ExportNamedDeclaration).size() > 0) {
meta.includeStories = j.arrayExpression(includeStories.map((key) => j.literal(key)));
}
const statements = [
j.exportDefaultDeclaration(genObjectExpression(meta)),
j.emptyStatement(),
...storyStatements,
];
const lastStatement = root.find(j.Statement).at(-1);
statements.reverse().forEach((stmt) => {
lastStatement.insertAfter(stmt);
});
base.remove();
}
root.find(j.ExportDefaultDeclaration).forEach(convertToStories);
// strip out Story/Meta import and MDX junk
// /* @jsx mdx */
root
.find(j.ImportDeclaration)
.at(0)
.replaceWith((exp) => j.importDeclaration(exp.node.specifiers, exp.node.source));
// import { Story, Meta } from '@storybook/addon-docs';
root
.find(j.ImportDeclaration)
.filter((exp) => exp.node.source.value === '@storybook/addon-docs')
.remove();
// const makeShortcode = ...
// const layoutProps = {};
// const MDXLayout = 'wrapper';
const MDX_DECLS = ['makeShortcode', 'layoutProps', 'MDXLayout'];
root
.find(j.VariableDeclaration)
.filter(
(decl) =>
decl.node.declarations.length === 1 && MDX_DECLS.includes(decl.node.declarations[0].id.name)
)
.remove();
// const Source = makeShortcode('Source');
root
.find(j.VariableDeclarator)
.filter(
(expr) =>
expr.node.init.type === 'CallExpression' &&
expr.node.init.callee.type === 'Identifier' &&
expr.node.init.callee.name === 'makeShortcode'
)
.remove();
// MDXContent.isMDXComponent = true;
root
.find(j.AssignmentExpression)
.filter(
(expr) =>
expr.node.left.type === 'MemberExpression' &&
expr.node.left.object.type === 'Identifier' &&
expr.node.left.object.name === 'MDXContent'
)
.remove();
// Add back `import React from 'react';` which is implicit in MDX
const react = root.find(j.ImportDeclaration).filter((decl) => decl.node.source.value === 'react');
if (react.size() === 0) {
root
.find(j.Statement)
.at(0)
.insertBefore(
j.importDeclaration([j.importDefaultSpecifier(j.identifier('React'))], j.literal('react'))
);
}
const source = root.toSource({ trailingComma: true, quote: 'single', tabWidth: 2 });
return prettier.format(source, {
parser: 'babel',
printWidth: 100,
tabWidth: 2,
bracketSpacing: true,
trailingComma: 'es5',
singleQuote: true,
});
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/components",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Core Storybook Components",
"keywords": [
"storybook"
@ -51,9 +51,9 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/theming": "7.0.0-alpha.39",
"@storybook/theming": "7.0.0-alpha.40",
"memoizerific": "^1.11.3",
"util-deprecate": "^1.0.2"
},
@ -86,5 +86,5 @@
],
"platform": "neutral"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/core-client",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook framework-agnostic API",
"keywords": [
"storybook"
@ -35,16 +35,16 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/channel-postmessage": "7.0.0-alpha.39",
"@storybook/channel-websocket": "7.0.0-alpha.39",
"@storybook/client-api": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/channel-postmessage": "7.0.0-alpha.40",
"@storybook/channel-websocket": "7.0.0-alpha.40",
"@storybook/client-api": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/preview-web": "7.0.0-alpha.39",
"@storybook/store": "7.0.0-alpha.39",
"@storybook/ui": "7.0.0-alpha.39",
"@storybook/preview-web": "7.0.0-alpha.40",
"@storybook/store": "7.0.0-alpha.40",
"@storybook/ui": "7.0.0-alpha.40",
"global": "^4.4.0",
"regenerator-runtime": "^0.13.7",
"util-deprecate": "^1.0.2"
@ -65,5 +65,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/core-common",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook framework-agnostic API",
"keywords": [
"storybook"
@ -48,7 +48,7 @@
"dependencies": {
"@babel/core": "^7.12.10",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.40",
"@types/babel__core": "^7.0.0",
"@types/express": "^4.7.0",
"@types/node": "^16.0.0",
@ -97,5 +97,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -362,11 +362,6 @@ export interface StorybookConfig {
* Will be removed in 7.0.
*/
warnOnLegacyHierarchySeparator?: boolean;
/**
* Preview MDX2 support, will become default in 7.0
*/
previewMdx2?: boolean;
};
/**

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/core-events",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Event names used in storybook core",
"keywords": [
"storybook"
@ -52,5 +52,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/core-server",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook framework-agnostic API",
"keywords": [
"storybook"
@ -35,16 +35,16 @@
"dependencies": {
"@aw-web-design/x-default-browser": "1.4.88",
"@discoveryjs/json-ext": "^0.5.3",
"@storybook/builder-manager": "7.0.0-alpha.39",
"@storybook/core-client": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/builder-manager": "7.0.0-alpha.40",
"@storybook/core-client": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/csf-tools": "7.0.0-alpha.39",
"@storybook/csf-tools": "7.0.0-alpha.40",
"@storybook/docs-mdx": "0.0.1-canary.12433cf.0",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/store": "7.0.0-alpha.39",
"@storybook/telemetry": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.40",
"@storybook/store": "7.0.0-alpha.40",
"@storybook/telemetry": "7.0.0-alpha.40",
"@types/node": "^16.0.0",
"@types/node-fetch": "^2.5.7",
"@types/pretty-hrtime": "^1.0.0",
@ -76,7 +76,7 @@
"ws": "^8.2.3"
},
"devDependencies": {
"@storybook/builder-webpack5": "7.0.0-alpha.39",
"@storybook/builder-webpack5": "7.0.0-alpha.40",
"@types/compression": "^1.7.0",
"@types/ip": "^1.1.0",
"@types/serve-favicon": "^2.5.2",
@ -102,5 +102,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -108,7 +108,6 @@ export const features = async (
interactionsDebugger: false,
babelModeV7: true,
argTypeTargetsV7: true,
previewMdx2: false,
});
export const storyIndexers = async (indexers?: StoryIndexer[]) => {

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/core-webpack",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook framework-agnostic API",
"keywords": [
"storybook"
@ -42,8 +42,8 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/node-logger": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/node-logger": "7.0.0-alpha.40",
"@types/node": "^16.0.0",
"ts-dedent": "^2.0.0"
},
@ -60,5 +60,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/csf-tools",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "",
"keywords": [
"storybook"
@ -63,5 +63,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/docs-tools",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Shared utility functions for frameworks to implement docs",
"keywords": [
"storybook"
@ -43,9 +43,9 @@
},
"dependencies": {
"@babel/core": "^7.12.10",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/store": "7.0.0-alpha.39",
"@storybook/store": "7.0.0-alpha.40",
"doctrine": "^3.0.0",
"lodash": "^4.17.21"
},
@ -62,5 +62,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/instrumenter",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "",
"keywords": [
"storybook"
@ -42,9 +42,9 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"core-js": "^3.8.2",
"global": "^4.4.0"
},
@ -59,5 +59,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/node-logger",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "",
"keywords": [
"storybook"
@ -59,5 +59,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/postinstall",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Storybook addons postinstall utilities",
"keywords": [
"api",
@ -56,5 +56,5 @@
"./src/index.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/preview-web",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "",
"keywords": [
"storybook"
@ -34,12 +34,12 @@
"prep": "node ../../../scripts/prepare.js"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/channels": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/channels": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"@storybook/store": "7.0.0-alpha.39",
"@storybook/store": "7.0.0-alpha.40",
"ansi-to-html": "^0.6.11",
"global": "^4.4.0",
"lodash": "^4.17.21",
@ -49,7 +49,7 @@
"util-deprecate": "^1.0.2"
},
"devDependencies": {
"@storybook/channel-postmessage": "7.0.0-alpha.39",
"@storybook/channel-postmessage": "7.0.0-alpha.40",
"react": "16.14.0",
"ts-jest": "^28.0.8",
"typescript": "~4.6.3"
@ -57,5 +57,5 @@
"publishConfig": {
"access": "public"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -2,7 +2,7 @@ import React from 'react';
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';
@ -55,7 +55,10 @@ beforeEach(() => {
projectAnnotations.renderToDOM.mockReset();
projectAnnotations.render.mockClear();
projectAnnotations.decorators[0].mockClear();
projectAnnotations.parameters.docs.renderer = () => new DocsRenderer() as any;
// We need to import DocsRenderer async because MDX2 is ESM-only so we inline
// this in each of the async tests below to get it working in Jest
// projectAnnotations.parameters.docs.renderer = () => new DocsRenderer() as any;
addons.setChannel(mockChannel as any);
addons.setServerChannel(createMockChannel());
@ -67,6 +70,9 @@ beforeEach(() => {
describe('PreviewWeb', () => {
describe('initial render', () => {
it('renders story mode through the stack', async () => {
const { DocsRenderer } = await import('@storybook/addon-docs');
projectAnnotations.parameters.docs.renderer = () => new DocsRenderer() as any;
projectAnnotations.renderToDOM.mockImplementationOnce(({ storyFn }: RenderContext<any>) =>
storyFn()
);
@ -80,6 +86,9 @@ describe('PreviewWeb', () => {
});
it('renders docs mode through docs page', async () => {
const { DocsRenderer } = await import('@storybook/addon-docs');
projectAnnotations.parameters.docs.renderer = () => new DocsRenderer() as any;
document.location.search = '?id=component-one--docs&viewMode=docs';
const preview = new PreviewWeb();
@ -116,6 +125,9 @@ describe('PreviewWeb', () => {
};
it('renders story mode through the updated stack', async () => {
const { DocsRenderer } = await import('@storybook/addon-docs');
projectAnnotations.parameters.docs.renderer = () => new DocsRenderer() as any;
document.location.search = '?id=component-one--a';
const preview = new PreviewWeb();
await preview.initialize({ importFn, getProjectAnnotations });

View File

@ -75,13 +75,6 @@ describe('UrlStore', () => {
viewMode: 'story',
});
});
it('should parse legacy queries', () => {
document.location.search = '?selectedKind=kind&selectedStory=story';
expect(getSelectionSpecifierFromPath()).toEqual({
storySpecifier: { title: 'kind', name: 'story' },
viewMode: 'story',
});
});
it('should parse args', () => {
document.location.search = '?id=story--id&args=obj.key:val';
expect(getSelectionSpecifierFromPath()).toEqual({

View File

@ -2,7 +2,6 @@ import type { SelectionSpecifier, Selection } from '@storybook/store';
import global from 'global';
import qs from 'qs';
import deprecate from 'util-deprecate';
import type { ViewMode } from '@storybook/addons';
import { parseArgsParam } from './parseArgsParam';
@ -66,13 +65,6 @@ const getFirstString = (v: ValueOf<qs.ParsedQs>): string | void => {
return undefined;
};
const deprecatedLegacyQuery = deprecate(
() => 0,
`URL formats with \`selectedKind\` and \`selectedName\` query parameters are deprecated.
Use \`id=$storyId\` instead.
See https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#new-url-structure`
);
export const getSelectionSpecifierFromPath: () => SelectionSpecifier | null = () => {
const query = qs.parse(document.location.search, { ignoreQueryPrefix: true });
const args = typeof query.args === 'string' ? parseArgsParam(query.args) : undefined;
@ -90,14 +82,6 @@ export const getSelectionSpecifierFromPath: () => SelectionSpecifier | null = ()
return { storySpecifier: storyId, args, globals, viewMode };
}
// Legacy URL format
const title = getFirstString(query.selectedKind);
const name = getFirstString(query.selectedStory);
if (title && name) {
deprecatedLegacyQuery();
return { storySpecifier: { title, name }, args, globals, viewMode };
}
return null;
};

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/router",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Core Storybook Router",
"keywords": [
"storybook"
@ -47,7 +47,7 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.40",
"memoizerific": "^1.11.3",
"qs": "^6.10.0"
},
@ -74,5 +74,5 @@
"./src/utils.ts"
]
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/source-loader",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Source loader",
"keywords": [
"lib",
@ -65,5 +65,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/store",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "",
"keywords": [
"storybook"
@ -42,9 +42,9 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/addons": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/core-events": "7.0.0-alpha.39",
"@storybook/addons": "7.0.0-alpha.40",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/core-events": "7.0.0-alpha.40",
"@storybook/csf": "0.0.2--canary.49.258942b.0",
"dequal": "^2.0.2",
"global": "^4.4.0",
@ -71,5 +71,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/telemetry",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Telemetry logging for crash reports and usage statistics",
"keywords": [
"storybook"
@ -42,8 +42,8 @@
"prep": "../../../scripts/prepare/bundle.ts"
},
"dependencies": {
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/core-common": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.40",
"@storybook/core-common": "7.0.0-alpha.40",
"chalk": "^4.1.0",
"detect-package-manager": "^2.0.1",
"fetch-retry": "^5.0.2",
@ -64,5 +64,5 @@
],
"platform": "node"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

View File

@ -1,6 +1,6 @@
{
"name": "@storybook/theming",
"version": "7.0.0-alpha.39",
"version": "7.0.0-alpha.40",
"description": "Core Storybook Components",
"keywords": [
"storybook"
@ -48,7 +48,7 @@
},
"dependencies": {
"@emotion/use-insertion-effect-with-fallbacks": "^1.0.0",
"@storybook/client-logger": "7.0.0-alpha.39",
"@storybook/client-logger": "7.0.0-alpha.40",
"memoizerific": "^1.11.3"
},
"devDependencies": {
@ -79,5 +79,5 @@
],
"post": "./scripts/fix-theme-type-export.ts"
},
"gitHead": "47386bd49d141ea70daac41ab3e4d52749fc5da9"
"gitHead": "8f6d8629f1ad7e776c39e2c7621f4a0d538aa93c"
}

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