@storybook/react 7.1.0-alpha.0 → 7.1.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +8 -8
- package/template/cli/js/Button.stories.js +2 -2
- package/template/cli/js/Header.stories.js +2 -2
- package/template/cli/js/Page.stories.js +2 -2
- package/template/cli/ts-3-8/Button.stories.ts +1 -1
- package/template/cli/ts-3-8/Header.stories.ts +1 -1
- package/template/cli/ts-4-9/Button.stories.ts +2 -2
- package/template/cli/ts-4-9/Header.stories.ts +2 -2
- package/template/cli/ts-4-9/Page.stories.ts +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storybook/react",
|
|
3
|
-
"version": "7.1.0-alpha.
|
|
3
|
+
"version": "7.1.0-alpha.2",
|
|
4
4
|
"description": "Storybook React renderer",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"storybook"
|
|
@@ -53,13 +53,13 @@
|
|
|
53
53
|
"prep": "../../../scripts/prepare/bundle.ts"
|
|
54
54
|
},
|
|
55
55
|
"dependencies": {
|
|
56
|
-
"@storybook/client-logger": "7.1.0-alpha.
|
|
57
|
-
"@storybook/core-client": "7.1.0-alpha.
|
|
58
|
-
"@storybook/docs-tools": "7.1.0-alpha.
|
|
56
|
+
"@storybook/client-logger": "7.1.0-alpha.2",
|
|
57
|
+
"@storybook/core-client": "7.1.0-alpha.2",
|
|
58
|
+
"@storybook/docs-tools": "7.1.0-alpha.2",
|
|
59
59
|
"@storybook/global": "^5.0.0",
|
|
60
|
-
"@storybook/preview-api": "7.1.0-alpha.
|
|
61
|
-
"@storybook/react-dom-shim": "7.1.0-alpha.
|
|
62
|
-
"@storybook/types": "7.1.0-alpha.
|
|
60
|
+
"@storybook/preview-api": "7.1.0-alpha.2",
|
|
61
|
+
"@storybook/react-dom-shim": "7.1.0-alpha.2",
|
|
62
|
+
"@storybook/types": "7.1.0-alpha.2",
|
|
63
63
|
"@types/escodegen": "^0.0.6",
|
|
64
64
|
"@types/estree": "^0.0.51",
|
|
65
65
|
"@types/node": "^16.0.0",
|
|
@@ -106,5 +106,5 @@
|
|
|
106
106
|
],
|
|
107
107
|
"platform": "browser"
|
|
108
108
|
},
|
|
109
|
-
"gitHead": "
|
|
109
|
+
"gitHead": "3f0c9a6636b9e69006ffb841234cf785598e0572"
|
|
110
110
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Button } from './Button';
|
|
2
2
|
|
|
3
|
-
// More on how to set up stories at: https://storybook.js.org/docs/
|
|
3
|
+
// More on how to set up stories at: https://storybook.js.org/docs/react/writing-stories/introduction
|
|
4
4
|
export default {
|
|
5
5
|
title: 'Example/Button',
|
|
6
6
|
component: Button,
|
|
@@ -10,7 +10,7 @@ export default {
|
|
|
10
10
|
},
|
|
11
11
|
};
|
|
12
12
|
|
|
13
|
-
// More on writing stories with args: https://storybook.js.org/docs/
|
|
13
|
+
// More on writing stories with args: https://storybook.js.org/docs/react/writing-stories/args
|
|
14
14
|
export const Primary = {
|
|
15
15
|
args: {
|
|
16
16
|
primary: true,
|
|
@@ -3,10 +3,10 @@ import { Header } from './Header';
|
|
|
3
3
|
export default {
|
|
4
4
|
title: 'Example/Header',
|
|
5
5
|
component: Header,
|
|
6
|
-
// This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/
|
|
6
|
+
// This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/react/writing-docs/autodocs
|
|
7
7
|
tags: ['autodocs'],
|
|
8
8
|
parameters: {
|
|
9
|
-
// More on how to position stories at: https://storybook.js.org/docs/
|
|
9
|
+
// More on how to position stories at: https://storybook.js.org/docs/react/configure/story-layout
|
|
10
10
|
layout: 'fullscreen',
|
|
11
11
|
},
|
|
12
12
|
};
|
|
@@ -6,14 +6,14 @@ export default {
|
|
|
6
6
|
title: 'Example/Page',
|
|
7
7
|
component: Page,
|
|
8
8
|
parameters: {
|
|
9
|
-
// More on how to position stories at: https://storybook.js.org/docs/
|
|
9
|
+
// More on how to position stories at: https://storybook.js.org/docs/react/configure/story-layout
|
|
10
10
|
layout: 'fullscreen',
|
|
11
11
|
},
|
|
12
12
|
};
|
|
13
13
|
|
|
14
14
|
export const LoggedOut = {};
|
|
15
15
|
|
|
16
|
-
// More on interaction testing: https://storybook.js.org/docs/
|
|
16
|
+
// More on interaction testing: https://storybook.js.org/docs/react/writing-tests/interaction-testing
|
|
17
17
|
export const LoggedIn = {
|
|
18
18
|
play: async ({ canvasElement }) => {
|
|
19
19
|
const canvas = within(canvasElement);
|
|
@@ -6,7 +6,7 @@ import { Button } from './Button';
|
|
|
6
6
|
const meta: Meta<typeof Button> = {
|
|
7
7
|
title: 'Example/Button',
|
|
8
8
|
component: Button,
|
|
9
|
-
// This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/
|
|
9
|
+
// This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/react/writing-docs/autodocs
|
|
10
10
|
tags: ['autodocs'],
|
|
11
11
|
// More on argTypes: https://storybook.js.org/docs/react/api/argtypes
|
|
12
12
|
argTypes: {
|
|
@@ -4,7 +4,7 @@ import { Header } from './Header';
|
|
|
4
4
|
const meta: Meta<typeof Header> = {
|
|
5
5
|
title: 'Example/Header',
|
|
6
6
|
component: Header,
|
|
7
|
-
// This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/
|
|
7
|
+
// This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/react/writing-docs/autodocs
|
|
8
8
|
tags: ['autodocs'],
|
|
9
9
|
parameters: {
|
|
10
10
|
// More on Story layout: https://storybook.js.org/docs/react/configure/story-layout
|
|
@@ -2,7 +2,7 @@ import type { Meta, StoryObj } from '@storybook/react';
|
|
|
2
2
|
|
|
3
3
|
import { Button } from './Button';
|
|
4
4
|
|
|
5
|
-
// More on how to set up stories at: https://storybook.js.org/docs/
|
|
5
|
+
// More on how to set up stories at: https://storybook.js.org/docs/react/writing-stories/introduction
|
|
6
6
|
const meta = {
|
|
7
7
|
title: 'Example/Button',
|
|
8
8
|
component: Button,
|
|
@@ -15,7 +15,7 @@ const meta = {
|
|
|
15
15
|
export default meta;
|
|
16
16
|
type Story = StoryObj<typeof meta>;
|
|
17
17
|
|
|
18
|
-
// More on writing stories with args: https://storybook.js.org/docs/
|
|
18
|
+
// More on writing stories with args: https://storybook.js.org/docs/react/writing-stories/args
|
|
19
19
|
export const Primary: Story = {
|
|
20
20
|
args: {
|
|
21
21
|
primary: true,
|
|
@@ -4,10 +4,10 @@ import { Header } from './Header';
|
|
|
4
4
|
const meta = {
|
|
5
5
|
title: 'Example/Header',
|
|
6
6
|
component: Header,
|
|
7
|
-
// This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/
|
|
7
|
+
// This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/react/writing-docs/autodocs
|
|
8
8
|
tags: ['autodocs'],
|
|
9
9
|
parameters: {
|
|
10
|
-
// More on how to position stories at: https://storybook.js.org/docs/
|
|
10
|
+
// More on how to position stories at: https://storybook.js.org/docs/react/configure/story-layout
|
|
11
11
|
layout: 'fullscreen',
|
|
12
12
|
},
|
|
13
13
|
} satisfies Meta<typeof Header>;
|
|
@@ -7,7 +7,7 @@ const meta = {
|
|
|
7
7
|
title: 'Example/Page',
|
|
8
8
|
component: Page,
|
|
9
9
|
parameters: {
|
|
10
|
-
// More on how to position stories at: https://storybook.js.org/docs/
|
|
10
|
+
// More on how to position stories at: https://storybook.js.org/docs/react/configure/story-layout
|
|
11
11
|
layout: 'fullscreen',
|
|
12
12
|
},
|
|
13
13
|
} satisfies Meta<typeof Page>;
|
|
@@ -17,7 +17,7 @@ type Story = StoryObj<typeof meta>;
|
|
|
17
17
|
|
|
18
18
|
export const LoggedOut: Story = {};
|
|
19
19
|
|
|
20
|
-
// More on interaction testing: https://storybook.js.org/docs/
|
|
20
|
+
// More on interaction testing: https://storybook.js.org/docs/react/writing-tests/interaction-testing
|
|
21
21
|
export const LoggedIn: Story = {
|
|
22
22
|
play: async ({ canvasElement }) => {
|
|
23
23
|
const canvas = within(canvasElement);
|