From 615db423a000e7c59f186bb2c72a347c9ed51dcd Mon Sep 17 00:00:00 2001 From: Kasper Peulen Date: Thu, 3 Aug 2023 10:43:40 +0200 Subject: [PATCH 01/29] Don't assign values to all slots (rollback to v7.0.27) --- code/renderers/vue3/src/render.ts | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) diff --git a/code/renderers/vue3/src/render.ts b/code/renderers/vue3/src/render.ts index 552438220600..a8873bb67772 100644 --- a/code/renderers/vue3/src/render.ts +++ b/code/renderers/vue3/src/render.ts @@ -3,7 +3,6 @@ import type { App } from 'vue'; import { createApp, h, reactive, isVNode, isReactive } from 'vue'; import type { ArgsStoryFn, RenderContext } from '@storybook/types'; import type { Args, StoryContext } from '@storybook/csf'; - import type { StoryFnVueReturnType, StoryID, VueRenderer } from './types'; export const render: ArgsStoryFn = (props, context) => { @@ -14,7 +13,7 @@ export const render: ArgsStoryFn = (props, context) => { ); } - return () => h(Component, props, generateSlots(context)); + return () => h(Component, props, getSlots(props, context)); }; // set of setup functions that will be called when story is created @@ -36,7 +35,6 @@ const map = new Map< { vueApp: ReturnType; reactiveArgs: Args; - reactiveSlots?: Args; } >(); @@ -93,20 +91,16 @@ export function renderToCanvas( /** * generate slots for default story without render function template - * @param context */ - -function generateSlots(context: StoryContext) { +function getSlots(props: Args, context: StoryContext) { const { argTypes } = context; - const slots = Object.entries(argTypes) - .filter(([key, value]) => argTypes[key]?.table?.category === 'slots') - .map(([key, value]) => { - const slotValue = context.args[key]; - return [key, typeof slotValue === 'function' ? slotValue : () => slotValue]; - }); - - return reactive(Object.fromEntries(slots)); + const slots = Object.entries(props) + .filter(([key]) => argTypes[key]?.table?.category === 'slots') + .map(([key, value]) => [key, typeof value === 'function' ? value : () => value]); + + return Object.fromEntries(slots); } + /** * get the args from the root element props if it is a vnode otherwise from the context * @param element is the root element of the story From 04a0270f6ba9dddc7a4dbbe8ca47682736681f54 Mon Sep 17 00:00:00 2001 From: Charles de Dreuille Date: Wed, 9 Aug 2023 12:33:48 +0200 Subject: [PATCH 02/29] Improve Link component --- .../components/src/new/Link/Link.stories.tsx | 54 ++++++--------- code/ui/components/src/new/Link/Link.tsx | 68 +++++++++---------- 2 files changed, 53 insertions(+), 69 deletions(-) diff --git a/code/ui/components/src/new/Link/Link.stories.tsx b/code/ui/components/src/new/Link/Link.stories.tsx index 356329f8e53c..c8ca067b2671 100644 --- a/code/ui/components/src/new/Link/Link.stories.tsx +++ b/code/ui/components/src/new/Link/Link.stories.tsx @@ -1,7 +1,5 @@ import type { Meta, StoryObj } from '@storybook/react'; import React from 'react'; - -import { Icon } from '@storybook/components/experimental'; import { Link } from './Link'; const meta: Meta = { @@ -26,8 +24,24 @@ export const Variants: Story = { Secondary - - Tertiary + + ), +}; + +export const Underline: Story = { + render: () => ( +
+ + Primary + + + Secondary + + + Secondary + + + Secondary
), @@ -36,15 +50,12 @@ export const Variants: Story = { export const WithIcon: Story = { render: () => (
- }> + Primary - }> + Secondary - }> - Tertiary -
), }; @@ -59,35 +70,14 @@ export const WithArrow: Story = { Secondary - - Tertiary -
- } - withArrow - > + Primary - } - withArrow - > + Secondary - } - withArrow - > - Tertiary -
), diff --git a/code/ui/components/src/new/Link/Link.tsx b/code/ui/components/src/new/Link/Link.tsx index a1da0f81733d..11eb79e782fa 100644 --- a/code/ui/components/src/new/Link/Link.tsx +++ b/code/ui/components/src/new/Link/Link.tsx @@ -1,15 +1,17 @@ -import type { MouseEvent, ReactNode } from 'react'; +import type { MouseEvent } from 'react'; import React, { forwardRef } from 'react'; import { styled } from '@storybook/theming'; -import { darken } from 'polished'; +import type { Icons } from '@storybook/icons'; import { Icon } from '../Icon/Icon'; import type { PropsOf } from '../utils/types'; export interface LinkProps { as?: T; children: string; - variant?: 'primary' | 'secondary' | 'tertiary'; - icon?: ReactNode; + variant?: 'primary' | 'secondary'; + weight?: 'regular' | 'medium' | 'bold'; + underline?: 'hover' | 'always'; + icon?: Icons; onClick?: (e: MouseEvent) => void; withArrow?: boolean; } @@ -20,11 +22,12 @@ export const Link: { ): JSX.Element; displayName?: string; } = forwardRef( - ({ as, children, icon, withArrow, ...props }: LinkProps, ref: React.Ref) => { + ({ children, icon, withArrow, ...props }: LinkProps, ref: React.Ref) => { + const LocalIcon = Icon[icon]; return ( - + - {icon} + {icon && } {children} {withArrow && } @@ -35,39 +38,30 @@ export const Link: { Link.displayName = 'Link'; -const StyledLink = styled.a>(({ theme, variant = 'primary' }) => ({ - display: 'inline-flex', - gap: 4, - alignItems: 'center', - transition: 'all 150ms ease-out', - textDecoration: 'none', - lineHeight: 1, - color: `${(() => { - if (variant === 'primary') return theme.color.secondary; - if (variant === 'secondary') return theme.textMutedColor; - if (variant === 'tertiary') return theme.color.dark; - return theme.color.secondary; - })()}`, - - '&:hover, &:focus': { - cursor: 'pointer', +const StyledLink = styled.a>( + ({ theme, variant = 'primary', underline = 'hover' }) => ({ + display: 'inline-flex', + gap: 4, + alignItems: 'center', + transition: 'all 150ms ease-out', + textDecoration: 'none', + lineHeight: 1, color: `${(() => { - if (variant === 'primary') return darken(0.07, theme.color.secondary); - if (variant === 'secondary') return theme.color.dark; - if (variant === 'tertiary') return theme.color.darkest; - return darken(0.07, theme.color.secondary); + if (variant === 'primary') return theme.color.secondary; + if (variant === 'secondary') return theme.textMutedColor; + return theme.color.secondary; })()}`, - }, + textDecorationLine: `${underline === 'always' ? 'underline' : 'none'}`, + textDecorationStyle: 'solid', + textDecorationThickness: '1px', + textUnderlineOffset: '2px', - '&:active': { - color: `${(() => { - if (variant === 'primary') return darken(0.1, theme.color.secondary); - if (variant === 'secondary') return theme.color.darker; - if (variant === 'tertiary') return theme.textMutedColor; - return darken(0.1, theme.color.secondary); - })()}`, - }, -})); + '&:hover, &:focus': { + cursor: 'pointer', + textDecorationLine: 'underline', + }, + }) +); const StyledLeft = styled.span(({ theme }) => ({ display: 'inline-flex', From af247074865cd56c39f2fa76a8b6cc0f3eb104e5 Mon Sep 17 00:00:00 2001 From: Charles de Dreuille Date: Wed, 9 Aug 2023 12:34:05 +0200 Subject: [PATCH 03/29] Fix exports --- code/ui/components/src/experimental.ts | 1 + code/ui/manager/src/globals/exports.ts | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/code/ui/components/src/experimental.ts b/code/ui/components/src/experimental.ts index 47764d881891..7280862f230f 100644 --- a/code/ui/components/src/experimental.ts +++ b/code/ui/components/src/experimental.ts @@ -12,3 +12,4 @@ export { Input } from './new/Input/Input'; export { Select } from './new/Select/Select'; export { Link } from './new/Link/Link'; export { Icon } from './new/Icon/Icon'; +export { IconButton } from './new/IconButton/IconButton'; diff --git a/code/ui/manager/src/globals/exports.ts b/code/ui/manager/src/globals/exports.ts index ffd247fdd30d..6ad6218c0fff 100644 --- a/code/ui/manager/src/globals/exports.ts +++ b/code/ui/manager/src/globals/exports.ts @@ -114,7 +114,7 @@ export default { 'resetComponents', 'withReset', ], - '@storybook/components/experimental': ['Button', 'Icon', 'Input', 'Link', 'Select'], + '@storybook/components/experimental': ['Button', 'Icon', 'IconButton', 'Input', 'Link', 'Select'], '@storybook/channels': [ 'Channel', 'PostMessageTransport', From 06ab5039dfbbff7627fdc6f4e864eca758ba4a28 Mon Sep 17 00:00:00 2001 From: Charles de Dreuille Date: Wed, 9 Aug 2023 12:34:16 +0200 Subject: [PATCH 04/29] Update Empty.tsx --- .../blocks/src/components/ArgsTable/Empty.tsx | 23 ++----------------- 1 file changed, 2 insertions(+), 21 deletions(-) diff --git a/code/ui/blocks/src/components/ArgsTable/Empty.tsx b/code/ui/blocks/src/components/ArgsTable/Empty.tsx index 7962d475acf8..ea8e3c2f17fc 100644 --- a/code/ui/blocks/src/components/ArgsTable/Empty.tsx +++ b/code/ui/blocks/src/components/ArgsTable/Empty.tsx @@ -1,7 +1,7 @@ import type { FC } from 'react'; import React, { useEffect, useState } from 'react'; import { styled } from '@storybook/theming'; -import { Icon, Link } from '@storybook/components/experimental'; +import { Link } from '@storybook/components/experimental'; interface EmptyProps { inAddonPanel?: boolean; @@ -53,16 +53,6 @@ const Divider = styled.div(({ theme }) => ({ backgroundColor: theme.appBorderColor, })); -const VideoIcon = styled.div(({ theme }) => ({ - width: 22, - height: 16, - borderRadius: theme.appBorderRadius, - border: `1px solid ${theme.color.secondary}`, - display: 'flex', - alignItems: 'center', - justifyContent: 'center', -})); - export const Empty: FC = ({ inAddonPanel }) => { const [isLoading, setIsLoading] = useState(true); @@ -95,16 +85,7 @@ export const Empty: FC = ({ inAddonPanel }) => { {inAddonPanel && ( <> - - - - } - withArrow - > + Watch 5m video From 764b20f7dc1e7ca531f1a55ed0648faf18a98a3e Mon Sep 17 00:00:00 2001 From: Charles de Dreuille Date: Wed, 9 Aug 2023 12:50:21 +0200 Subject: [PATCH 05/29] Fix weight on Link --- .../components/src/new/Link/Link.stories.tsx | 19 +++++++++++++++++++ code/ui/components/src/new/Link/Link.tsx | 11 ++++++++--- 2 files changed, 27 insertions(+), 3 deletions(-) diff --git a/code/ui/components/src/new/Link/Link.stories.tsx b/code/ui/components/src/new/Link/Link.stories.tsx index c8ca067b2671..0fee3e095b8a 100644 --- a/code/ui/components/src/new/Link/Link.stories.tsx +++ b/code/ui/components/src/new/Link/Link.stories.tsx @@ -47,6 +47,25 @@ export const Underline: Story = { ), }; +export const Weight: Story = { + render: () => ( +
+ + Primary + + + Secondary + + + Secondary + + + Secondary + +
+ ), +}; + export const WithIcon: Story = { render: () => (
diff --git a/code/ui/components/src/new/Link/Link.tsx b/code/ui/components/src/new/Link/Link.tsx index 11eb79e782fa..3422ac6a7f31 100644 --- a/code/ui/components/src/new/Link/Link.tsx +++ b/code/ui/components/src/new/Link/Link.tsx @@ -9,7 +9,7 @@ export interface LinkProps { as?: T; children: string; variant?: 'primary' | 'secondary'; - weight?: 'regular' | 'medium' | 'bold'; + weight?: 'regular' | 'bold'; underline?: 'hover' | 'always'; icon?: Icons; onClick?: (e: MouseEvent) => void; @@ -39,7 +39,7 @@ export const Link: { Link.displayName = 'Link'; const StyledLink = styled.a>( - ({ theme, variant = 'primary', underline = 'hover' }) => ({ + ({ theme, variant = 'primary', underline = 'hover', weight = 'regular' }) => ({ display: 'inline-flex', gap: 4, alignItems: 'center', @@ -48,9 +48,14 @@ const StyledLink = styled.a>( lineHeight: 1, color: `${(() => { if (variant === 'primary') return theme.color.secondary; - if (variant === 'secondary') return theme.textMutedColor; + if (variant === 'secondary') return theme.color.defaultText; return theme.color.secondary; })()}`, + fontWeight: `${(() => { + if (weight === 'regular') return theme.typography.weight.regular; + if (weight === 'bold') return theme.typography.weight.bold; + return theme.typography.weight.bold; + })()}`, textDecorationLine: `${underline === 'always' ? 'underline' : 'none'}`, textDecorationStyle: 'solid', textDecorationThickness: '1px', From 03625362ccf9378b9e7fd8fa08f879e87227f2cc Mon Sep 17 00:00:00 2001 From: Charles de Dreuille Date: Wed, 9 Aug 2023 13:09:37 +0200 Subject: [PATCH 06/29] Update IconButton.tsx --- .../src/new/IconButton/IconButton.tsx | 34 +++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/code/ui/components/src/new/IconButton/IconButton.tsx b/code/ui/components/src/new/IconButton/IconButton.tsx index 9a0e1ad98ea9..ae20fa9e38ad 100644 --- a/code/ui/components/src/new/IconButton/IconButton.tsx +++ b/code/ui/components/src/new/IconButton/IconButton.tsx @@ -35,7 +35,7 @@ export const IconButton: { IconButton.displayName = 'IconButton'; const StyledButton = styled.button>( - ({ theme, variant = 'primary', size = 'medium', disabled = false, active = false }) => ({ + ({ theme, variant = 'solid', size = 'medium', disabled = false, active = false }) => ({ border: 0, cursor: disabled ? 'not-allowed' : 'pointer', display: 'inline-flex', @@ -64,41 +64,41 @@ const StyledButton = styled.button>( fontWeight: theme.typography.weight.bold, lineHeight: '1', background: `${(() => { - if (variant === 'primary') return theme.color.secondary; - if (variant === 'secondary') return theme.button.background; - if (variant === 'tertiary' && active) return theme.background.hoverable; + if (variant === 'solid') return theme.color.secondary; + if (variant === 'outline') return theme.button.background; + if (variant === 'ghost' && active) return theme.background.hoverable; return 'transparent'; })()}`, color: `${(() => { - if (variant === 'primary') return theme.color.lightest; - if (variant === 'secondary') return theme.input.color; - if (variant === 'tertiary' && active) return theme.color.secondary; - if (variant === 'tertiary') return theme.color.mediumdark; + if (variant === 'solid') return theme.color.lightest; + if (variant === 'outline') return theme.input.color; + if (variant === 'ghost' && active) return theme.color.secondary; + if (variant === 'ghost') return theme.color.mediumdark; return theme.input.color; })()}`, - boxShadow: variant === 'secondary' ? `${theme.button.border} 0 0 0 1px inset` : 'none', + boxShadow: variant === 'outline' ? `${theme.button.border} 0 0 0 1px inset` : 'none', borderRadius: theme.input.borderRadius, '&:hover': { - color: variant === 'tertiary' ? theme.color.secondary : null, + color: variant === 'ghost' ? theme.color.secondary : null, background: `${(() => { let bgColor = theme.color.secondary; - if (variant === 'primary') bgColor = theme.color.secondary; - if (variant === 'secondary') bgColor = theme.button.background; + if (variant === 'solid') bgColor = theme.color.secondary; + if (variant === 'outline') bgColor = theme.button.background; - if (variant === 'tertiary') return transparentize(0.86, theme.color.secondary); + if (variant === 'ghost') return transparentize(0.86, theme.color.secondary); return theme.base === 'light' ? darken(0.02, bgColor) : lighten(0.03, bgColor); })()}`, }, '&:active': { - color: variant === 'tertiary' ? theme.color.secondary : null, + color: variant === 'ghost' ? theme.color.secondary : null, background: `${(() => { let bgColor = theme.color.secondary; - if (variant === 'primary') bgColor = theme.color.secondary; - if (variant === 'secondary') bgColor = theme.button.background; + if (variant === 'solid') bgColor = theme.color.secondary; + if (variant === 'outline') bgColor = theme.button.background; - if (variant === 'tertiary') return theme.background.hoverable; + if (variant === 'ghost') return theme.background.hoverable; return theme.base === 'light' ? darken(0.02, bgColor) : lighten(0.03, bgColor); })()}`, }, From facb2a2c6b9e3032248bde5d9358a61a82f6a610 Mon Sep 17 00:00:00 2001 From: Kasper Peulen Date: Wed, 9 Aug 2023 15:36:25 +0200 Subject: [PATCH 07/29] Remove patch label checking --- scripts/dangerfile.ts | 8 -------- 1 file changed, 8 deletions(-) diff --git a/scripts/dangerfile.ts b/scripts/dangerfile.ts index 7b87377c0cd3..754686981c80 100644 --- a/scripts/dangerfile.ts +++ b/scripts/dangerfile.ts @@ -50,14 +50,6 @@ const checkRequiredLabels = (labels: string[]) => { fail(`Please choose only one of these labels: ${JSON.stringify(foundRequiredLabels)}`); } - const labelsForPatchStatus = ['patch:no', 'patch:yes']; - const foundPatchLabels = intersection(labelsForPatchStatus, labels); - if (isEmpty(foundPatchLabels)) { - fail(`PR is not labeled with one of: ${JSON.stringify(labelsForPatchStatus)}`); - } else if (foundPatchLabels.length > 1) { - fail(`Please choose only one of these labels: ${JSON.stringify(foundPatchLabels)}`); - } - const foundCILabels = intersection(ciLabels, labels); if (isEmpty(foundCILabels)) { fail(`PR is not labeled with one of: ${JSON.stringify(ciLabels)}`); From 4a9e3ecc96085157d331b4667e37bd32395d8a6f Mon Sep 17 00:00:00 2001 From: storybook-bot <32066757+storybook-bot@users.noreply.github.com> Date: Wed, 9 Aug 2023 13:46:42 +0000 Subject: [PATCH 08/29] Write changelog for 7.2.2-alpha.1 --- CHANGELOG.prerelease.md | 9 +++++++++ code/package.json | 3 ++- docs/versions/next.json | 7 +------ 3 files changed, 12 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.prerelease.md b/CHANGELOG.prerelease.md index 53ddf862c349..18b151809ed3 100644 --- a/CHANGELOG.prerelease.md +++ b/CHANGELOG.prerelease.md @@ -1,3 +1,12 @@ +## 7.2.2-alpha.1 + +- CSF-Tools: Remove prettier from printConfig - [#23766](https://github.com/storybookjs/storybook/pull/23766), thanks [@kasperpeulen](https://github.com/kasperpeulen)! +- UI: Improve Link component - [#23767](https://github.com/storybookjs/storybook/pull/23767), thanks [@cdedreuille](https://github.com/cdedreuille)! +- UI: Improve new `Button` component - [#23765](https://github.com/storybookjs/storybook/pull/23765), thanks [@cdedreuille](https://github.com/cdedreuille)! +- UI: Update Button types to allow for no children on iconOnly buttons - [#23735](https://github.com/storybookjs/storybook/pull/23735), thanks [@cdedreuille](https://github.com/cdedreuille)! +- UI: Upgrade Icon component - [#23680](https://github.com/storybookjs/storybook/pull/23680), thanks [@cdedreuille](https://github.com/cdedreuille)! +- WebpackBuilder: Remove need for `react` as peerDependency - [#23496](https://github.com/storybookjs/storybook/pull/23496), thanks [@ndelangen](https://github.com/ndelangen)! + ## 7.2.2-alpha.0 - Indexer: Introduce new experimental `indexer` API - #23691, thanks [@JReinhold](https://github.com/jreinhold)! diff --git a/code/package.json b/code/package.json index 7fd9c897bb52..2013de5f4248 100644 --- a/code/package.json +++ b/code/package.json @@ -326,5 +326,6 @@ "Dependency Upgrades" ] ] - } + }, + "deferredNextVersion": "7.2.2-alpha.1" } diff --git a/docs/versions/next.json b/docs/versions/next.json index 63e92dde8084..c23698d4d4ef 100644 --- a/docs/versions/next.json +++ b/docs/versions/next.json @@ -1,6 +1 @@ -{ - "version": "7.2.2-alpha.0", - "info": { - "plain": "- Indexer: Introduce new experimental `indexer` API - #23691, thanks [@JReinhold](https://github.com/jreinhold)!\n- Addon-docs, Core, Server: Use new `indexer` API - #23660, thanks [@JReinhold](https://github.com/jreinhold)!\n- Server: Add support for tags - #23660, thanks [@JReinhold](https://github.com/jreinhold)! \n- Core-server: Improve internal types - #23632, thanks [@JReinhold](https://github.com/jreinhold)!" - } -} +{"version":"7.2.2-alpha.1","info":{"plain":"- CSF-Tools: Remove prettier from printConfig - [#23766](https://github.com/storybookjs/storybook/pull/23766), thanks [@kasperpeulen](https://github.com/kasperpeulen)!\n- UI: Improve Link component - [#23767](https://github.com/storybookjs/storybook/pull/23767), thanks [@cdedreuille](https://github.com/cdedreuille)!\n- UI: Improve new `Button` component - [#23765](https://github.com/storybookjs/storybook/pull/23765), thanks [@cdedreuille](https://github.com/cdedreuille)!\n- UI: Update Button types to allow for no children on iconOnly buttons - [#23735](https://github.com/storybookjs/storybook/pull/23735), thanks [@cdedreuille](https://github.com/cdedreuille)!\n- UI: Upgrade Icon component - [#23680](https://github.com/storybookjs/storybook/pull/23680), thanks [@cdedreuille](https://github.com/cdedreuille)!\n- WebpackBuilder: Remove need for `react` as peerDependency - [#23496](https://github.com/storybookjs/storybook/pull/23496), thanks [@ndelangen](https://github.com/ndelangen)!"}} From a1406c739b17607c2fd763376a9a383145bb18a7 Mon Sep 17 00:00:00 2001 From: storybook-bot <32066757+storybook-bot@users.noreply.github.com> Date: Wed, 9 Aug 2023 14:12:44 +0000 Subject: [PATCH 09/29] Update CHANGELOG.md for v7.2.2 [skip ci] --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 029cacbefcc0..c3d2cc1933c5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +## 7.2.2 + +- CSF-Tools: Remove prettier from printConfig - [#23766](https://github.com/storybookjs/storybook/pull/23766), thanks [@kasperpeulen](https://github.com/kasperpeulen)! + ## 7.2.1 - Addon docs: Add safe check in Webpack preset - [#23687](https://github.com/storybookjs/storybook/pull/23687), thanks [@yannbf](https://github.com/yannbf)! From 4d1de6b0d507312c92010ac09ce9ccd56b847eb3 Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Thu, 10 Aug 2023 11:07:50 +0800 Subject: [PATCH 10/29] Build: Benchmark Vite-React-TS with docs disabled --- .circleci/config.yml | 12 +++---- code/lib/cli/src/sandbox-templates.ts | 12 +++++++ scripts/bench/browse.ts | 8 ++--- scripts/task.ts | 10 +++++- scripts/tasks/bench.ts | 5 +-- scripts/tasks/sandbox-parts.ts | 49 ++++++++++++++++++++++----- 6 files changed, 74 insertions(+), 22 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index b011deeaefab..f25da2b8ea12 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -489,11 +489,11 @@ workflows: requires: - unit-tests - create-sandboxes: - parallelism: 11 + parallelism: 12 requires: - build - build-sandboxes: - parallelism: 11 + parallelism: 12 requires: - create-sandboxes - chromatic-sandboxes: @@ -513,7 +513,7 @@ workflows: requires: - build-sandboxes - bench: - parallelism: 2 + parallelism: 3 requires: - build-sandboxes # TODO: reenable once we find out the source of flakyness @@ -545,11 +545,11 @@ workflows: requires: - unit-tests - create-sandboxes: - parallelism: 20 + parallelism: 21 requires: - build - build-sandboxes: - parallelism: 20 + parallelism: 21 requires: - create-sandboxes - chromatic-sandboxes: @@ -569,7 +569,7 @@ workflows: requires: - build-sandboxes - bench: - parallelism: 2 + parallelism: 3 requires: - build-sandboxes # TODO: reenable once we find out the source of flakyness diff --git a/code/lib/cli/src/sandbox-templates.ts b/code/lib/cli/src/sandbox-templates.ts index 5b19a3d8d4ad..95aa9bf029a3 100644 --- a/code/lib/cli/src/sandbox-templates.ts +++ b/code/lib/cli/src/sandbox-templates.ts @@ -62,6 +62,7 @@ export type Template = { modifications?: { skipTemplateStories?: boolean; mainConfig?: Partial; + disableDocs?: boolean; }; /** * Flag to indicate that this template is a secondary template, which is used mainly to test rather specific features. @@ -526,6 +527,16 @@ const benchTemplates = { }, skipTasks: ['e2e-tests-dev', 'test-runner', 'test-runner-dev', 'e2e-tests', 'chromatic'], }, + 'bench/react-vite-default-ts-nodocs': { + ...baseTemplates['react-vite/default-ts'], + name: 'Bench (react-vite/default-ts, no docs)', + isInternal: true, + modifications: { + skipTemplateStories: true, + disableDocs: true, + }, + skipTasks: ['e2e-tests-dev', 'test-runner', 'test-runner-dev', 'e2e-tests', 'chromatic'], + }, } satisfies Record<`bench/${string}`, Template & { isInternal: true }>; export const allTemplates: Record = { @@ -546,6 +557,7 @@ export const normal: TemplateKey[] = [ 'nextjs/default-ts', 'bench/react-vite-default-ts', 'bench/react-webpack-18-ts', + 'bench/react-vite-default-ts-nodocs', ]; export const merged: TemplateKey[] = [ ...normal, diff --git a/scripts/bench/browse.ts b/scripts/bench/browse.ts index d101f27e8c47..c063fed1ff8d 100644 --- a/scripts/bench/browse.ts +++ b/scripts/bench/browse.ts @@ -10,7 +10,7 @@ interface Result { mdxVisible?: number; } -export const browse = async (url: string) => { +export const browse = async (url: string, { disableDocs }: { disableDocs?: boolean }) => { const result: Result = {}; /* Heat up time for playwright and the builder @@ -21,13 +21,13 @@ export const browse = async (url: string) => { * We instantiate a new browser for each run to avoid any caching happening in the browser itself */ const x = await benchStory(url); - await benchAutodocs(url); + if (!disableDocs) await benchAutodocs(url); result.storyVisibleUncached = x.storyVisible; - Object.assign(result, await benchMDX(url)); + if (!disableDocs) Object.assign(result, await benchMDX(url)); Object.assign(result, await benchStory(url)); - Object.assign(result, await benchAutodocs(url)); + if (!disableDocs) Object.assign(result, await benchAutodocs(url)); return result; }; diff --git a/scripts/task.ts b/scripts/task.ts index 66314121768a..67a70ae30a86 100644 --- a/scripts/task.ts +++ b/scripts/task.ts @@ -176,6 +176,11 @@ export const options = createOptions({ description: 'Do not include template stories and their addons', promptType: false, }, + disableDocs: { + type: 'boolean', + description: 'Disable addon-docs from essentials', + promptType: false, + }, }); type PassedOptionValues = Omit, 'task' | 'startFrom' | 'junit'>; @@ -304,7 +309,10 @@ async function runTask(task: Task, details: TemplateDetails, optionValues: Passe try { let updatedOptions = optionValues; if (details.template?.modifications?.skipTemplateStories) { - updatedOptions = { ...optionValues, skipTemplateStories: true }; + updatedOptions = { ...updatedOptions, skipTemplateStories: true }; + } + if (details.template?.modifications?.disableDocs) { + updatedOptions = { ...updatedOptions, disableDocs: true }; } const controller = await task.run(details, updatedOptions); diff --git a/scripts/tasks/bench.ts b/scripts/tasks/bench.ts index e1b1fec753ea..25325e1090e0 100644 --- a/scripts/tasks/bench.ts +++ b/scripts/tasks/bench.ts @@ -16,6 +16,7 @@ export const bench: Task = { async run(details, options) { const controllers: AbortController[] = []; try { + const { disableDocs } = options; const { browse } = await import('../bench/browse'); const { saveBench, loadBench } = await import('../bench/utils'); const { default: prettyBytes } = await dynamicImport('pretty-bytes'); @@ -26,7 +27,7 @@ export const bench: Task = { throw new Error('dev: controller is null'); } controllers.push(devController); - const devBrowseResult = await browse(`http://localhost:${devPort}`); + const devBrowseResult = await browse(`http://localhost:${devPort}`, { disableDocs }); devController.abort(); const serveController = await serve.run(details, { ...options, debug: false }); @@ -34,7 +35,7 @@ export const bench: Task = { throw new Error('serve: controller is null'); } controllers.push(serveController); - const buildBrowseResult = await browse(`http://localhost:${servePort}`); + const buildBrowseResult = await browse(`http://localhost:${servePort}`, { disableDocs }); serveController.abort(); await saveBench( diff --git a/scripts/tasks/sandbox-parts.ts b/scripts/tasks/sandbox-parts.ts index d08360a22ebe..fadbdf41c901 100644 --- a/scripts/tasks/sandbox-parts.ts +++ b/scripts/tasks/sandbox-parts.ts @@ -283,13 +283,13 @@ function updateStoriesField(mainConfig: ConfigFile, isJs: boolean) { } // Add a stories field entry for the passed symlink -function addStoriesEntry(mainConfig: ConfigFile, path: string) { +function addStoriesEntry(mainConfig: ConfigFile, path: string, disableDocs: boolean) { const stories = mainConfig.getFieldValue(['stories']) as string[]; const entry = { directory: slash(join('../template-stories', path)), titlePrefix: slash(path), - files: '**/*.@(mdx|stories.@(js|jsx|ts|tsx))', + files: disableDocs ? '**/*.stories.@(js|jsx|ts|tsx)' : '**/*.@(mdx|stories.@(js|jsx|ts|tsx))', }; mainConfig.setFieldValue(['stories'], [...stories, entry]); @@ -302,7 +302,12 @@ function getStoriesFolderWithVariant(variant?: string, folder = 'stories') { // packageDir is eg 'renderers/react', 'addons/actions' async function linkPackageStories( packageDir: string, - { mainConfig, cwd, linkInDir }: { mainConfig: ConfigFile; cwd: string; linkInDir?: string }, + { + mainConfig, + cwd, + linkInDir, + disableDocs, + }: { mainConfig: ConfigFile; cwd: string; linkInDir?: string; disableDocs: boolean }, variant?: string ) { const storiesFolderName = variant ? getStoriesFolderWithVariant(variant) : 'stories'; @@ -320,7 +325,7 @@ async function linkPackageStories( await ensureSymlink(source, target); if (!linkInDir) { - addStoriesEntry(mainConfig, packageDir); + addStoriesEntry(mainConfig, packageDir, disableDocs); } // Add `previewAnnotation` entries of the form @@ -373,7 +378,7 @@ async function addExtraDependencies({ export const addStories: Task['run'] = async ( { sandboxDir, template, key }, - { addon: extraAddons, dryRun, debug } + { addon: extraAddons, dryRun, debug, disableDocs } ) => { logger.log('💃 adding stories'); const cwd = sandboxDir; @@ -385,7 +390,8 @@ export const addStories: Task['run'] = async ( // Ensure that we match the right stories in the stories directory updateStoriesField( mainConfig, - (await detectLanguage(packageManager)) === SupportedLanguage.JAVASCRIPT + (await detectLanguage(packageManager)) === SupportedLanguage.JAVASCRIPT, + disableDocs ); const isCoreRenderer = @@ -409,6 +415,7 @@ export const addStories: Task['run'] = async ( mainConfig, cwd, linkInDir: resolve(cwd, storiesPath), + disableDocs, }); if ( @@ -422,6 +429,7 @@ export const addStories: Task['run'] = async ( mainConfig, cwd, linkInDir: resolve(cwd, storiesPath), + disableDocs, }, sandboxSpecificStoriesFolder ); @@ -439,6 +447,7 @@ export const addStories: Task['run'] = async ( mainConfig, cwd, linkInDir: resolve(cwd, storiesPath), + disableDocs, }); } @@ -453,6 +462,7 @@ export const addStories: Task['run'] = async ( mainConfig, cwd, linkInDir: resolve(cwd, storiesPath), + disableDocs, }, sandboxSpecificStoriesFolder ); @@ -465,6 +475,7 @@ export const addStories: Task['run'] = async ( await linkPackageStories(await workspacePath('core package', '@storybook/preview-api'), { mainConfig, cwd, + disableDocs, }); } @@ -475,7 +486,10 @@ export const addStories: Task['run'] = async ( if (!match) return acc; const suffix = match[1]; if (suffix === 'essentials') { - return [...acc, ...essentialsAddons]; + const essentials = disableDocs + ? essentialsAddons.filter((a) => a !== 'docs') + : essentialsAddons; + return [...acc, ...essentials]; } return [...acc, suffix]; }, @@ -494,7 +508,7 @@ export const addStories: Task['run'] = async ( if (isCoreRenderer) { const existingStories = await filterExistsInCodeDir(addonDirs, join('template', 'stories')); for (const packageDir of existingStories) { - await linkPackageStories(packageDir, { mainConfig, cwd }); + await linkPackageStories(packageDir, { mainConfig, cwd, disableDocs }); } // Add some extra settings (see above for what these do) @@ -509,7 +523,7 @@ export const addStories: Task['run'] = async ( await writeConfig(mainConfig); }; -export const extendMain: Task['run'] = async ({ template, sandboxDir }) => { +export const extendMain: Task['run'] = async ({ template, sandboxDir }, { disableDocs }) => { logger.log('📝 Extending main.js'); const mainConfig = await readMainConfig({ cwd: sandboxDir }); const templateConfig = template.modifications?.mainConfig || {}; @@ -527,6 +541,23 @@ export const extendMain: Task['run'] = async ({ template, sandboxDir }) => { Object.entries(configToAdd).forEach(([field, value]) => mainConfig.setFieldValue([field], value)); + // Simulate Storybook Lite + if (disableDocs) { + const addons = mainConfig.getFieldValue(['addons']); + const addonsNoDocs = addons.map((addon: any) => + addon !== '@storybook/addon-essentials' ? addon : { name: addon, options: { docs: false } } + ); + mainConfig.setFieldValue(['addons'], addonsNoDocs); + + // remove the docs options so that docs tags are ignored + mainConfig.setFieldValue(['docs'], {}); + mainConfig.setFieldValue(['typescript'], { reactDocgen: false }); + + let updatedStories = mainConfig.getFieldValue(['stories']) as string[]; + updatedStories = updatedStories.filter((specifier) => !specifier.endsWith('.mdx')); + mainConfig.setFieldValue(['stories'], updatedStories); + } + if (template.expected.builder === '@storybook/builder-vite') setSandboxViteFinal(mainConfig); await writeConfig(mainConfig); }; From 2842b799d7f014c3415c71a08c8f01bb3fc7c0d2 Mon Sep 17 00:00:00 2001 From: Yann Braga Date: Thu, 10 Aug 2023 09:47:42 +0200 Subject: [PATCH 11/29] make the test-runner tests fail on console.error --- scripts/tasks/test-runner-build.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/tasks/test-runner-build.ts b/scripts/tasks/test-runner-build.ts index 546bb6c5aa38..b57d4c803233 100644 --- a/scripts/tasks/test-runner-build.ts +++ b/scripts/tasks/test-runner-build.ts @@ -12,7 +12,12 @@ export const testRunnerBuild: Task & { port: number } = { }, async run({ sandboxDir, junitFilename, template }, { dryRun, debug }) { const execOptions = { cwd: sandboxDir }; - const flags = [`--url http://localhost:${this.port}`, '--junit', '--maxWorkers=2']; + const flags = [ + `--url http://localhost:${this.port}`, + '--junit', + '--maxWorkers=2', + '--failOnConsole', + ]; // index-json mode is only supported in ssv7 if (template.modifications?.mainConfig?.features?.storyStoreV7 !== false) { From 6ffb2c3e89593f7dcead318dcf3c43399c352d77 Mon Sep 17 00:00:00 2001 From: storybook-bot <32066757+storybook-bot@users.noreply.github.com> Date: Thu, 10 Aug 2023 10:43:29 +0000 Subject: [PATCH 12/29] Bump version from "7.2.2-alpha.0" to "7.2.2-alpha.1" [skip ci] --- code/addons/a11y/package.json | 2 +- code/addons/actions/package.json | 2 +- code/addons/backgrounds/package.json | 2 +- code/addons/controls/package.json | 2 +- code/addons/docs/package.json | 2 +- code/addons/essentials/package.json | 2 +- code/addons/gfm/package.json | 2 +- code/addons/highlight/package.json | 2 +- code/addons/interactions/package.json | 2 +- code/addons/jest/package.json | 2 +- code/addons/links/package.json | 2 +- code/addons/measure/package.json | 2 +- code/addons/outline/package.json | 2 +- code/addons/storyshots-core/package.json | 2 +- code/addons/storyshots-puppeteer/package.json | 2 +- code/addons/storysource/package.json | 2 +- code/addons/themes/package.json | 2 +- code/addons/toolbars/package.json | 2 +- code/addons/viewport/package.json | 2 +- code/builders/builder-manager/package.json | 2 +- code/builders/builder-vite/package.json | 2 +- code/builders/builder-webpack5/package.json | 2 +- code/deprecated/addons/package.json | 2 +- .../channel-postmessage/package.json | 2 +- .../deprecated/channel-websocket/package.json | 2 +- code/deprecated/client-api/package.json | 2 +- code/deprecated/core-client/package.json | 2 +- code/deprecated/manager-api-shim/package.json | 2 +- code/deprecated/preview-web/package.json | 2 +- code/deprecated/store/package.json | 2 +- code/frameworks/angular/package.json | 2 +- code/frameworks/ember/package.json | 2 +- code/frameworks/html-vite/package.json | 2 +- code/frameworks/html-webpack5/package.json | 2 +- code/frameworks/nextjs/package.json | 2 +- code/frameworks/preact-vite/package.json | 2 +- code/frameworks/preact-webpack5/package.json | 2 +- code/frameworks/react-vite/package.json | 2 +- code/frameworks/react-webpack5/package.json | 2 +- code/frameworks/server-webpack5/package.json | 2 +- code/frameworks/svelte-vite/package.json | 2 +- code/frameworks/svelte-webpack5/package.json | 2 +- code/frameworks/sveltekit/package.json | 2 +- code/frameworks/vue-vite/package.json | 2 +- code/frameworks/vue-webpack5/package.json | 2 +- code/frameworks/vue3-vite/package.json | 2 +- code/frameworks/vue3-webpack5/package.json | 2 +- .../web-components-vite/package.json | 2 +- .../web-components-webpack5/package.json | 2 +- code/lib/channels/package.json | 2 +- code/lib/cli-sb/package.json | 2 +- code/lib/cli-storybook/package.json | 2 +- code/lib/cli/package.json | 2 +- code/lib/cli/src/versions.ts | 188 +++++++++--------- code/lib/client-logger/package.json | 2 +- code/lib/codemod/package.json | 2 +- code/lib/core-common/package.json | 2 +- code/lib/core-events/package.json | 2 +- code/lib/core-server/package.json | 2 +- code/lib/core-webpack/package.json | 2 +- code/lib/csf-plugin/package.json | 2 +- code/lib/csf-tools/package.json | 2 +- code/lib/docs-tools/package.json | 2 +- code/lib/instrumenter/package.json | 2 +- code/lib/manager-api/package.json | 2 +- code/lib/manager-api/src/version.ts | 2 +- code/lib/node-logger/package.json | 2 +- code/lib/postinstall/package.json | 2 +- code/lib/preview-api/package.json | 2 +- code/lib/preview/package.json | 2 +- code/lib/react-dom-shim/package.json | 2 +- code/lib/router/package.json | 2 +- code/lib/source-loader/package.json | 2 +- code/lib/telemetry/package.json | 2 +- code/lib/theming/package.json | 2 +- code/lib/types/package.json | 2 +- code/package.json | 5 +- code/presets/create-react-app/package.json | 2 +- code/presets/html-webpack/package.json | 2 +- code/presets/preact-webpack/package.json | 2 +- code/presets/react-webpack/package.json | 2 +- code/presets/server-webpack/package.json | 2 +- code/presets/svelte-webpack/package.json | 2 +- code/presets/vue-webpack/package.json | 2 +- code/presets/vue3-webpack/package.json | 2 +- .../web-components-webpack/package.json | 2 +- code/renderers/html/package.json | 2 +- code/renderers/preact/package.json | 2 +- code/renderers/react/package.json | 2 +- code/renderers/server/package.json | 2 +- code/renderers/svelte/package.json | 2 +- code/renderers/vue/package.json | 2 +- code/renderers/vue3/package.json | 2 +- code/renderers/web-components/package.json | 2 +- code/ui/blocks/package.json | 2 +- code/ui/components/package.json | 2 +- code/ui/manager/package.json | 2 +- 97 files changed, 191 insertions(+), 192 deletions(-) diff --git a/code/addons/a11y/package.json b/code/addons/a11y/package.json index f0fc38af7eb4..405241bfb0b0 100644 --- a/code/addons/a11y/package.json +++ b/code/addons/a11y/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-a11y", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Test component compliance with web accessibility standards", "keywords": [ "a11y", diff --git a/code/addons/actions/package.json b/code/addons/actions/package.json index 0b0e2f3a5b2c..ee3b33e7a4a4 100644 --- a/code/addons/actions/package.json +++ b/code/addons/actions/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-actions", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Get UI feedback when an action is performed on an interactive element", "keywords": [ "storybook", diff --git a/code/addons/backgrounds/package.json b/code/addons/backgrounds/package.json index 6e653fe4f18a..1e062ca1ae9c 100644 --- a/code/addons/backgrounds/package.json +++ b/code/addons/backgrounds/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-backgrounds", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Switch backgrounds to view components in different settings", "keywords": [ "addon", diff --git a/code/addons/controls/package.json b/code/addons/controls/package.json index ac577fa48761..7fb30e0e78b5 100644 --- a/code/addons/controls/package.json +++ b/code/addons/controls/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-controls", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Interact with component inputs dynamically in the Storybook UI", "keywords": [ "addon", diff --git a/code/addons/docs/package.json b/code/addons/docs/package.json index 398e0a6e5183..db1f750050c2 100644 --- a/code/addons/docs/package.json +++ b/code/addons/docs/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-docs", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Document component usage and properties in Markdown", "keywords": [ "addon", diff --git a/code/addons/essentials/package.json b/code/addons/essentials/package.json index 868757892e7c..d602e9b915a1 100644 --- a/code/addons/essentials/package.json +++ b/code/addons/essentials/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-essentials", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Curated addons to bring out the best of Storybook", "keywords": [ "addon", diff --git a/code/addons/gfm/package.json b/code/addons/gfm/package.json index bafed10477dc..df2469e220cb 100644 --- a/code/addons/gfm/package.json +++ b/code/addons/gfm/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-mdx-gfm", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "GitHub Flavored Markdown in Storybook", "keywords": [ "addon", diff --git a/code/addons/highlight/package.json b/code/addons/highlight/package.json index c9a0b6a9a0ab..09a29705a5db 100644 --- a/code/addons/highlight/package.json +++ b/code/addons/highlight/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-highlight", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Highlight DOM nodes within your stories", "keywords": [ "storybook-addons", diff --git a/code/addons/interactions/package.json b/code/addons/interactions/package.json index e5686ec715ac..6bb39cc41bab 100644 --- a/code/addons/interactions/package.json +++ b/code/addons/interactions/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-interactions", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Automate, test and debug user interactions", "keywords": [ "storybook-addons", diff --git a/code/addons/jest/package.json b/code/addons/jest/package.json index 45db226093dd..404c1c1d4619 100644 --- a/code/addons/jest/package.json +++ b/code/addons/jest/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-jest", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "React storybook addon that show component jest report", "keywords": [ "addon", diff --git a/code/addons/links/package.json b/code/addons/links/package.json index c9915a4d7a92..ac68feb39d34 100644 --- a/code/addons/links/package.json +++ b/code/addons/links/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-links", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Link stories together to build demos and prototypes with your UI components", "keywords": [ "addon", diff --git a/code/addons/measure/package.json b/code/addons/measure/package.json index bcad0ce14769..3dd32f977916 100644 --- a/code/addons/measure/package.json +++ b/code/addons/measure/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-measure", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Inspect layouts by visualizing the box model", "keywords": [ "storybook-addons", diff --git a/code/addons/outline/package.json b/code/addons/outline/package.json index 67a572183153..1d34b12004e4 100644 --- a/code/addons/outline/package.json +++ b/code/addons/outline/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-outline", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Outline all elements with CSS to help with layout placement and alignment", "keywords": [ "storybook-addons", diff --git a/code/addons/storyshots-core/package.json b/code/addons/storyshots-core/package.json index c4e3acbe4929..23a2cf1b13ad 100644 --- a/code/addons/storyshots-core/package.json +++ b/code/addons/storyshots-core/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-storyshots", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Take a code snapshot of every story automatically with Jest", "keywords": [ "addon", diff --git a/code/addons/storyshots-puppeteer/package.json b/code/addons/storyshots-puppeteer/package.json index 8598b02d0b62..6662febccb9f 100644 --- a/code/addons/storyshots-puppeteer/package.json +++ b/code/addons/storyshots-puppeteer/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-storyshots-puppeteer", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Image snapshots addition to StoryShots based on puppeteer", "keywords": [ "addon", diff --git a/code/addons/storysource/package.json b/code/addons/storysource/package.json index 820c5b2af605..b354ef17c028 100644 --- a/code/addons/storysource/package.json +++ b/code/addons/storysource/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-storysource", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "View a story’s source code to see how it works and paste into your app", "keywords": [ "addon", diff --git a/code/addons/themes/package.json b/code/addons/themes/package.json index 16be2bb0fc4e..ca376134d031 100644 --- a/code/addons/themes/package.json +++ b/code/addons/themes/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-themes", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Switch between multiple themes for you components in Storybook", "keywords": [ "css", diff --git a/code/addons/toolbars/package.json b/code/addons/toolbars/package.json index e20663d5fe93..e239c1ef8fca 100644 --- a/code/addons/toolbars/package.json +++ b/code/addons/toolbars/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-toolbars", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Create your own toolbar items that control story rendering", "keywords": [ "addon", diff --git a/code/addons/viewport/package.json b/code/addons/viewport/package.json index bcc1036bf580..5c578517ee1c 100644 --- a/code/addons/viewport/package.json +++ b/code/addons/viewport/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-viewport", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Build responsive components by adjusting Storybook’s viewport size and orientation", "keywords": [ "addon", diff --git a/code/builders/builder-manager/package.json b/code/builders/builder-manager/package.json index 7c54121e1fae..f3c3f6bead9d 100644 --- a/code/builders/builder-manager/package.json +++ b/code/builders/builder-manager/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/builder-manager", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook manager builder", "keywords": [ "storybook" diff --git a/code/builders/builder-vite/package.json b/code/builders/builder-vite/package.json index 756e28fc54dd..6028a6b9fd99 100644 --- a/code/builders/builder-vite/package.json +++ b/code/builders/builder-vite/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/builder-vite", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "A plugin to run and build Storybooks with Vite", "homepage": "https://github.com/storybookjs/storybook/tree/next/code/builders/builder-vite/#readme", "bugs": { diff --git a/code/builders/builder-webpack5/package.json b/code/builders/builder-webpack5/package.json index 1af2435ef428..f94a9ef43917 100644 --- a/code/builders/builder-webpack5/package.json +++ b/code/builders/builder-webpack5/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/builder-webpack5", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook framework-agnostic API", "keywords": [ "storybook" diff --git a/code/deprecated/addons/package.json b/code/deprecated/addons/package.json index d4cc1c599695..980de983f727 100644 --- a/code/deprecated/addons/package.json +++ b/code/deprecated/addons/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addons", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook addons store", "keywords": [ "storybook" diff --git a/code/deprecated/channel-postmessage/package.json b/code/deprecated/channel-postmessage/package.json index f9b5167635ca..a4dcc0cefc18 100644 --- a/code/deprecated/channel-postmessage/package.json +++ b/code/deprecated/channel-postmessage/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/channel-postmessage", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "", "keywords": [ "storybook" diff --git a/code/deprecated/channel-websocket/package.json b/code/deprecated/channel-websocket/package.json index 5c42b2217eaf..532504e574e0 100644 --- a/code/deprecated/channel-websocket/package.json +++ b/code/deprecated/channel-websocket/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/channel-websocket", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "", "keywords": [ "storybook" diff --git a/code/deprecated/client-api/package.json b/code/deprecated/client-api/package.json index f2a6623edc9a..9e1c6a6433f1 100644 --- a/code/deprecated/client-api/package.json +++ b/code/deprecated/client-api/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/client-api", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook Client API", "keywords": [ "storybook" diff --git a/code/deprecated/core-client/package.json b/code/deprecated/core-client/package.json index 8f7a30dffdea..6276e96ccc1e 100644 --- a/code/deprecated/core-client/package.json +++ b/code/deprecated/core-client/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/core-client", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook framework-agnostic API", "keywords": [ "storybook" diff --git a/code/deprecated/manager-api-shim/package.json b/code/deprecated/manager-api-shim/package.json index 916608494af1..95a8504b599c 100644 --- a/code/deprecated/manager-api-shim/package.json +++ b/code/deprecated/manager-api-shim/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/api", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook Manager API (facade)", "keywords": [ "storybook" diff --git a/code/deprecated/preview-web/package.json b/code/deprecated/preview-web/package.json index 0ccd29281d7a..ac8ff273d28a 100644 --- a/code/deprecated/preview-web/package.json +++ b/code/deprecated/preview-web/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preview-web", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "", "keywords": [ "storybook" diff --git a/code/deprecated/store/package.json b/code/deprecated/store/package.json index 4b1a7baae822..915defd1d61a 100644 --- a/code/deprecated/store/package.json +++ b/code/deprecated/store/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/store", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "", "keywords": [ "storybook" diff --git a/code/frameworks/angular/package.json b/code/frameworks/angular/package.json index da0b539ef608..7d2724cf94ce 100644 --- a/code/frameworks/angular/package.json +++ b/code/frameworks/angular/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/angular", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Angular: Develop Angular components in isolation with hot reloading.", "keywords": [ "storybook", diff --git a/code/frameworks/ember/package.json b/code/frameworks/ember/package.json index 78b99d05d9a6..4d3bfdd975a2 100644 --- a/code/frameworks/ember/package.json +++ b/code/frameworks/ember/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/ember", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Ember: Develop Ember Component in isolation with Hot Reloading.", "homepage": "https://github.com/storybookjs/storybook/tree/next/code/frameworks/ember", "bugs": { diff --git a/code/frameworks/html-vite/package.json b/code/frameworks/html-vite/package.json index 95ee2c885b10..de8eddb06581 100644 --- a/code/frameworks/html-vite/package.json +++ b/code/frameworks/html-vite/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/html-vite", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for HTML and Vite: Develop HTML in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/html-webpack5/package.json b/code/frameworks/html-webpack5/package.json index 062b42020485..c557b6b8e275 100644 --- a/code/frameworks/html-webpack5/package.json +++ b/code/frameworks/html-webpack5/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/html-webpack5", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for HTML: View HTML snippets in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/nextjs/package.json b/code/frameworks/nextjs/package.json index 531c04b78799..e8509e4e723a 100644 --- a/code/frameworks/nextjs/package.json +++ b/code/frameworks/nextjs/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/nextjs", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Next.js", "keywords": [ "storybook", diff --git a/code/frameworks/preact-vite/package.json b/code/frameworks/preact-vite/package.json index 97605674ac10..7a636d9ff637 100644 --- a/code/frameworks/preact-vite/package.json +++ b/code/frameworks/preact-vite/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preact-vite", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Preact and Vite: Develop Preact components in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/preact-webpack5/package.json b/code/frameworks/preact-webpack5/package.json index df8979925d9d..7b40dfacaa98 100644 --- a/code/frameworks/preact-webpack5/package.json +++ b/code/frameworks/preact-webpack5/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preact-webpack5", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Preact: Develop Preact Component in isolation.", "keywords": [ "storybook" diff --git a/code/frameworks/react-vite/package.json b/code/frameworks/react-vite/package.json index 79ff83dbc921..79cf62a786b1 100644 --- a/code/frameworks/react-vite/package.json +++ b/code/frameworks/react-vite/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/react-vite", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for React and Vite: Develop React components in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/react-webpack5/package.json b/code/frameworks/react-webpack5/package.json index fe22ef8cdd3a..84b9fbbbdac8 100644 --- a/code/frameworks/react-webpack5/package.json +++ b/code/frameworks/react-webpack5/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/react-webpack5", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for React: Develop React Component in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/server-webpack5/package.json b/code/frameworks/server-webpack5/package.json index ac8e72a4ba5d..389f15e73037 100644 --- a/code/frameworks/server-webpack5/package.json +++ b/code/frameworks/server-webpack5/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/server-webpack5", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Server: View HTML snippets from a server in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/svelte-vite/package.json b/code/frameworks/svelte-vite/package.json index e1a3bbe3dd91..37b535a15ff6 100644 --- a/code/frameworks/svelte-vite/package.json +++ b/code/frameworks/svelte-vite/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/svelte-vite", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Svelte and Vite: Develop Svelte components in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/svelte-webpack5/package.json b/code/frameworks/svelte-webpack5/package.json index b54212d3d6b2..d8a52eb1e699 100644 --- a/code/frameworks/svelte-webpack5/package.json +++ b/code/frameworks/svelte-webpack5/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/svelte-webpack5", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Svelte: Develop Svelte Component in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/sveltekit/package.json b/code/frameworks/sveltekit/package.json index b45cbf7311ce..90d40815197e 100644 --- a/code/frameworks/sveltekit/package.json +++ b/code/frameworks/sveltekit/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/sveltekit", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for SvelteKit", "keywords": [ "storybook", diff --git a/code/frameworks/vue-vite/package.json b/code/frameworks/vue-vite/package.json index 916ee61075fc..d764e4d69982 100644 --- a/code/frameworks/vue-vite/package.json +++ b/code/frameworks/vue-vite/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/vue-vite", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Vue2 and Vite: Develop Vue2 Components in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/vue-webpack5/package.json b/code/frameworks/vue-webpack5/package.json index 45dc487b5789..8a9595210afe 100644 --- a/code/frameworks/vue-webpack5/package.json +++ b/code/frameworks/vue-webpack5/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/vue-webpack5", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Vue: Develop Vue Component in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/vue3-vite/package.json b/code/frameworks/vue3-vite/package.json index 035c15599301..0baa2e498039 100644 --- a/code/frameworks/vue3-vite/package.json +++ b/code/frameworks/vue3-vite/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/vue3-vite", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Vue3 and Vite: Develop Vue3 components in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/vue3-webpack5/package.json b/code/frameworks/vue3-webpack5/package.json index 8236167c189d..55710f577353 100644 --- a/code/frameworks/vue3-webpack5/package.json +++ b/code/frameworks/vue3-webpack5/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/vue3-webpack5", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Vue 3: Develop Vue 3 Components in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/web-components-vite/package.json b/code/frameworks/web-components-vite/package.json index a08d76ae3909..9cdcc72b743f 100644 --- a/code/frameworks/web-components-vite/package.json +++ b/code/frameworks/web-components-vite/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/web-components-vite", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for web-components and Vite: Develop Web Components in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/frameworks/web-components-webpack5/package.json b/code/frameworks/web-components-webpack5/package.json index 637d93fb4cae..4a7a59dbd490 100644 --- a/code/frameworks/web-components-webpack5/package.json +++ b/code/frameworks/web-components-webpack5/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/web-components-webpack5", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for web-components: View web components snippets in isolation with Hot Reloading.", "keywords": [ "lit", diff --git a/code/lib/channels/package.json b/code/lib/channels/package.json index abbfede9a5a8..1b7be6591afa 100644 --- a/code/lib/channels/package.json +++ b/code/lib/channels/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/channels", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "", "keywords": [ "storybook" diff --git a/code/lib/cli-sb/package.json b/code/lib/cli-sb/package.json index 8ebff80df3cd..90ddd4c4624d 100644 --- a/code/lib/cli-sb/package.json +++ b/code/lib/cli-sb/package.json @@ -1,6 +1,6 @@ { "name": "sb", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook CLI", "keywords": [ "storybook" diff --git a/code/lib/cli-storybook/package.json b/code/lib/cli-storybook/package.json index 508c84eff23e..8f0909422939 100644 --- a/code/lib/cli-storybook/package.json +++ b/code/lib/cli-storybook/package.json @@ -1,6 +1,6 @@ { "name": "storybook", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook CLI", "keywords": [ "storybook" diff --git a/code/lib/cli/package.json b/code/lib/cli/package.json index c910696354ce..b0adeda320e2 100644 --- a/code/lib/cli/package.json +++ b/code/lib/cli/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/cli", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook's CLI - easiest method of adding storybook to your projects", "keywords": [ "cli", diff --git a/code/lib/cli/src/versions.ts b/code/lib/cli/src/versions.ts index c889bd159956..d2c2e010c5e4 100644 --- a/code/lib/cli/src/versions.ts +++ b/code/lib/cli/src/versions.ts @@ -1,97 +1,97 @@ // auto generated file, do not edit export default { - '@storybook/addon-a11y': '7.2.2-alpha.0', - '@storybook/addon-actions': '7.2.2-alpha.0', - '@storybook/addon-backgrounds': '7.2.2-alpha.0', - '@storybook/addon-controls': '7.2.2-alpha.0', - '@storybook/addon-docs': '7.2.2-alpha.0', - '@storybook/addon-essentials': '7.2.2-alpha.0', - '@storybook/addon-highlight': '7.2.2-alpha.0', - '@storybook/addon-interactions': '7.2.2-alpha.0', - '@storybook/addon-jest': '7.2.2-alpha.0', - '@storybook/addon-links': '7.2.2-alpha.0', - '@storybook/addon-mdx-gfm': '7.2.2-alpha.0', - '@storybook/addon-measure': '7.2.2-alpha.0', - '@storybook/addon-outline': '7.2.2-alpha.0', - '@storybook/addon-themes': '7.2.2-alpha.0', - '@storybook/addon-storyshots': '7.2.2-alpha.0', - '@storybook/addon-storyshots-puppeteer': '7.2.2-alpha.0', - '@storybook/addon-storysource': '7.2.2-alpha.0', - '@storybook/addon-toolbars': '7.2.2-alpha.0', - '@storybook/addon-viewport': '7.2.2-alpha.0', - '@storybook/addons': '7.2.2-alpha.0', - '@storybook/angular': '7.2.2-alpha.0', - '@storybook/api': '7.2.2-alpha.0', - '@storybook/blocks': '7.2.2-alpha.0', - '@storybook/builder-manager': '7.2.2-alpha.0', - '@storybook/builder-vite': '7.2.2-alpha.0', - '@storybook/builder-webpack5': '7.2.2-alpha.0', - '@storybook/channel-postmessage': '7.2.2-alpha.0', - '@storybook/channel-websocket': '7.2.2-alpha.0', - '@storybook/channels': '7.2.2-alpha.0', - '@storybook/cli': '7.2.2-alpha.0', - '@storybook/client-api': '7.2.2-alpha.0', - '@storybook/client-logger': '7.2.2-alpha.0', - '@storybook/codemod': '7.2.2-alpha.0', - '@storybook/components': '7.2.2-alpha.0', - '@storybook/core-client': '7.2.2-alpha.0', - '@storybook/core-common': '7.2.2-alpha.0', - '@storybook/core-events': '7.2.2-alpha.0', - '@storybook/core-server': '7.2.2-alpha.0', - '@storybook/core-webpack': '7.2.2-alpha.0', - '@storybook/csf-plugin': '7.2.2-alpha.0', - '@storybook/csf-tools': '7.2.2-alpha.0', - '@storybook/docs-tools': '7.2.2-alpha.0', - '@storybook/ember': '7.2.2-alpha.0', - '@storybook/html': '7.2.2-alpha.0', - '@storybook/html-vite': '7.2.2-alpha.0', - '@storybook/html-webpack5': '7.2.2-alpha.0', - '@storybook/instrumenter': '7.2.2-alpha.0', - '@storybook/manager': '7.2.2-alpha.0', - '@storybook/manager-api': '7.2.2-alpha.0', - '@storybook/nextjs': '7.2.2-alpha.0', - '@storybook/node-logger': '7.2.2-alpha.0', - '@storybook/postinstall': '7.2.2-alpha.0', - '@storybook/preact': '7.2.2-alpha.0', - '@storybook/preact-vite': '7.2.2-alpha.0', - '@storybook/preact-webpack5': '7.2.2-alpha.0', - '@storybook/preset-create-react-app': '7.2.2-alpha.0', - '@storybook/preset-html-webpack': '7.2.2-alpha.0', - '@storybook/preset-preact-webpack': '7.2.2-alpha.0', - '@storybook/preset-react-webpack': '7.2.2-alpha.0', - '@storybook/preset-server-webpack': '7.2.2-alpha.0', - '@storybook/preset-svelte-webpack': '7.2.2-alpha.0', - '@storybook/preset-vue-webpack': '7.2.2-alpha.0', - '@storybook/preset-vue3-webpack': '7.2.2-alpha.0', - '@storybook/preset-web-components-webpack': '7.2.2-alpha.0', - '@storybook/preview': '7.2.2-alpha.0', - '@storybook/preview-api': '7.2.2-alpha.0', - '@storybook/preview-web': '7.2.2-alpha.0', - '@storybook/react': '7.2.2-alpha.0', - '@storybook/react-dom-shim': '7.2.2-alpha.0', - '@storybook/react-vite': '7.2.2-alpha.0', - '@storybook/react-webpack5': '7.2.2-alpha.0', - '@storybook/router': '7.2.2-alpha.0', - '@storybook/server': '7.2.2-alpha.0', - '@storybook/server-webpack5': '7.2.2-alpha.0', - '@storybook/source-loader': '7.2.2-alpha.0', - '@storybook/store': '7.2.2-alpha.0', - '@storybook/svelte': '7.2.2-alpha.0', - '@storybook/svelte-vite': '7.2.2-alpha.0', - '@storybook/svelte-webpack5': '7.2.2-alpha.0', - '@storybook/sveltekit': '7.2.2-alpha.0', - '@storybook/telemetry': '7.2.2-alpha.0', - '@storybook/theming': '7.2.2-alpha.0', - '@storybook/types': '7.2.2-alpha.0', - '@storybook/vue': '7.2.2-alpha.0', - '@storybook/vue-vite': '7.2.2-alpha.0', - '@storybook/vue-webpack5': '7.2.2-alpha.0', - '@storybook/vue3': '7.2.2-alpha.0', - '@storybook/vue3-vite': '7.2.2-alpha.0', - '@storybook/vue3-webpack5': '7.2.2-alpha.0', - '@storybook/web-components': '7.2.2-alpha.0', - '@storybook/web-components-vite': '7.2.2-alpha.0', - '@storybook/web-components-webpack5': '7.2.2-alpha.0', - sb: '7.2.2-alpha.0', - storybook: '7.2.2-alpha.0', + '@storybook/addon-a11y': '7.2.2-alpha.1', + '@storybook/addon-actions': '7.2.2-alpha.1', + '@storybook/addon-backgrounds': '7.2.2-alpha.1', + '@storybook/addon-controls': '7.2.2-alpha.1', + '@storybook/addon-docs': '7.2.2-alpha.1', + '@storybook/addon-essentials': '7.2.2-alpha.1', + '@storybook/addon-highlight': '7.2.2-alpha.1', + '@storybook/addon-interactions': '7.2.2-alpha.1', + '@storybook/addon-jest': '7.2.2-alpha.1', + '@storybook/addon-links': '7.2.2-alpha.1', + '@storybook/addon-mdx-gfm': '7.2.2-alpha.1', + '@storybook/addon-measure': '7.2.2-alpha.1', + '@storybook/addon-outline': '7.2.2-alpha.1', + '@storybook/addon-themes': '7.2.2-alpha.1', + '@storybook/addon-storyshots': '7.2.2-alpha.1', + '@storybook/addon-storyshots-puppeteer': '7.2.2-alpha.1', + '@storybook/addon-storysource': '7.2.2-alpha.1', + '@storybook/addon-toolbars': '7.2.2-alpha.1', + '@storybook/addon-viewport': '7.2.2-alpha.1', + '@storybook/addons': '7.2.2-alpha.1', + '@storybook/angular': '7.2.2-alpha.1', + '@storybook/api': '7.2.2-alpha.1', + '@storybook/blocks': '7.2.2-alpha.1', + '@storybook/builder-manager': '7.2.2-alpha.1', + '@storybook/builder-vite': '7.2.2-alpha.1', + '@storybook/builder-webpack5': '7.2.2-alpha.1', + '@storybook/channel-postmessage': '7.2.2-alpha.1', + '@storybook/channel-websocket': '7.2.2-alpha.1', + '@storybook/channels': '7.2.2-alpha.1', + '@storybook/cli': '7.2.2-alpha.1', + '@storybook/client-api': '7.2.2-alpha.1', + '@storybook/client-logger': '7.2.2-alpha.1', + '@storybook/codemod': '7.2.2-alpha.1', + '@storybook/components': '7.2.2-alpha.1', + '@storybook/core-client': '7.2.2-alpha.1', + '@storybook/core-common': '7.2.2-alpha.1', + '@storybook/core-events': '7.2.2-alpha.1', + '@storybook/core-server': '7.2.2-alpha.1', + '@storybook/core-webpack': '7.2.2-alpha.1', + '@storybook/csf-plugin': '7.2.2-alpha.1', + '@storybook/csf-tools': '7.2.2-alpha.1', + '@storybook/docs-tools': '7.2.2-alpha.1', + '@storybook/ember': '7.2.2-alpha.1', + '@storybook/html': '7.2.2-alpha.1', + '@storybook/html-vite': '7.2.2-alpha.1', + '@storybook/html-webpack5': '7.2.2-alpha.1', + '@storybook/instrumenter': '7.2.2-alpha.1', + '@storybook/manager': '7.2.2-alpha.1', + '@storybook/manager-api': '7.2.2-alpha.1', + '@storybook/nextjs': '7.2.2-alpha.1', + '@storybook/node-logger': '7.2.2-alpha.1', + '@storybook/postinstall': '7.2.2-alpha.1', + '@storybook/preact': '7.2.2-alpha.1', + '@storybook/preact-vite': '7.2.2-alpha.1', + '@storybook/preact-webpack5': '7.2.2-alpha.1', + '@storybook/preset-create-react-app': '7.2.2-alpha.1', + '@storybook/preset-html-webpack': '7.2.2-alpha.1', + '@storybook/preset-preact-webpack': '7.2.2-alpha.1', + '@storybook/preset-react-webpack': '7.2.2-alpha.1', + '@storybook/preset-server-webpack': '7.2.2-alpha.1', + '@storybook/preset-svelte-webpack': '7.2.2-alpha.1', + '@storybook/preset-vue-webpack': '7.2.2-alpha.1', + '@storybook/preset-vue3-webpack': '7.2.2-alpha.1', + '@storybook/preset-web-components-webpack': '7.2.2-alpha.1', + '@storybook/preview': '7.2.2-alpha.1', + '@storybook/preview-api': '7.2.2-alpha.1', + '@storybook/preview-web': '7.2.2-alpha.1', + '@storybook/react': '7.2.2-alpha.1', + '@storybook/react-dom-shim': '7.2.2-alpha.1', + '@storybook/react-vite': '7.2.2-alpha.1', + '@storybook/react-webpack5': '7.2.2-alpha.1', + '@storybook/router': '7.2.2-alpha.1', + '@storybook/server': '7.2.2-alpha.1', + '@storybook/server-webpack5': '7.2.2-alpha.1', + '@storybook/source-loader': '7.2.2-alpha.1', + '@storybook/store': '7.2.2-alpha.1', + '@storybook/svelte': '7.2.2-alpha.1', + '@storybook/svelte-vite': '7.2.2-alpha.1', + '@storybook/svelte-webpack5': '7.2.2-alpha.1', + '@storybook/sveltekit': '7.2.2-alpha.1', + '@storybook/telemetry': '7.2.2-alpha.1', + '@storybook/theming': '7.2.2-alpha.1', + '@storybook/types': '7.2.2-alpha.1', + '@storybook/vue': '7.2.2-alpha.1', + '@storybook/vue-vite': '7.2.2-alpha.1', + '@storybook/vue-webpack5': '7.2.2-alpha.1', + '@storybook/vue3': '7.2.2-alpha.1', + '@storybook/vue3-vite': '7.2.2-alpha.1', + '@storybook/vue3-webpack5': '7.2.2-alpha.1', + '@storybook/web-components': '7.2.2-alpha.1', + '@storybook/web-components-vite': '7.2.2-alpha.1', + '@storybook/web-components-webpack5': '7.2.2-alpha.1', + sb: '7.2.2-alpha.1', + storybook: '7.2.2-alpha.1', }; diff --git a/code/lib/client-logger/package.json b/code/lib/client-logger/package.json index 2d22166aa99b..dc83b8cf7ccd 100644 --- a/code/lib/client-logger/package.json +++ b/code/lib/client-logger/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/client-logger", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "", "keywords": [ "storybook" diff --git a/code/lib/codemod/package.json b/code/lib/codemod/package.json index eee088fa1937..0783c5f37d51 100644 --- a/code/lib/codemod/package.json +++ b/code/lib/codemod/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/codemod", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "A collection of codemod scripts written with JSCodeshift", "keywords": [ "storybook" diff --git a/code/lib/core-common/package.json b/code/lib/core-common/package.json index 23bf3839be45..e512cbc30cd0 100644 --- a/code/lib/core-common/package.json +++ b/code/lib/core-common/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/core-common", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook framework-agnostic API", "keywords": [ "storybook" diff --git a/code/lib/core-events/package.json b/code/lib/core-events/package.json index afd331dfdecf..1c2372e3207a 100644 --- a/code/lib/core-events/package.json +++ b/code/lib/core-events/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/core-events", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Event names used in storybook core", "keywords": [ "storybook" diff --git a/code/lib/core-server/package.json b/code/lib/core-server/package.json index 6f41a3ed87d1..4206ab50164f 100644 --- a/code/lib/core-server/package.json +++ b/code/lib/core-server/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/core-server", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook framework-agnostic API", "keywords": [ "storybook" diff --git a/code/lib/core-webpack/package.json b/code/lib/core-webpack/package.json index e47fa3e89bef..64b7c9414f53 100644 --- a/code/lib/core-webpack/package.json +++ b/code/lib/core-webpack/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/core-webpack", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook framework-agnostic API", "keywords": [ "storybook" diff --git a/code/lib/csf-plugin/package.json b/code/lib/csf-plugin/package.json index 3a34106c7a98..de1b30119e09 100644 --- a/code/lib/csf-plugin/package.json +++ b/code/lib/csf-plugin/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/csf-plugin", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Enrich CSF files via static analysis", "keywords": [ "storybook" diff --git a/code/lib/csf-tools/package.json b/code/lib/csf-tools/package.json index 7ab953b8d7d8..69434d110324 100644 --- a/code/lib/csf-tools/package.json +++ b/code/lib/csf-tools/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/csf-tools", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Parse and manipulate CSF and Storybook config files", "keywords": [ "storybook" diff --git a/code/lib/docs-tools/package.json b/code/lib/docs-tools/package.json index 4d9f59d99ce6..8c3088f6b949 100644 --- a/code/lib/docs-tools/package.json +++ b/code/lib/docs-tools/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/docs-tools", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Shared utility functions for frameworks to implement docs", "keywords": [ "storybook" diff --git a/code/lib/instrumenter/package.json b/code/lib/instrumenter/package.json index 13d9e187c5e7..963edeb98304 100644 --- a/code/lib/instrumenter/package.json +++ b/code/lib/instrumenter/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/instrumenter", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "", "keywords": [ "storybook" diff --git a/code/lib/manager-api/package.json b/code/lib/manager-api/package.json index 5228f3d1b442..65c2e212b356 100644 --- a/code/lib/manager-api/package.json +++ b/code/lib/manager-api/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/manager-api", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Core Storybook Manager API & Context", "keywords": [ "storybook" diff --git a/code/lib/manager-api/src/version.ts b/code/lib/manager-api/src/version.ts index 55d3cd58e73d..1e509af31c36 100644 --- a/code/lib/manager-api/src/version.ts +++ b/code/lib/manager-api/src/version.ts @@ -1 +1 @@ -export const version = '7.2.2-alpha.0'; +export const version = '7.2.2-alpha.1'; diff --git a/code/lib/node-logger/package.json b/code/lib/node-logger/package.json index 91cac3c031e8..17090344ca26 100644 --- a/code/lib/node-logger/package.json +++ b/code/lib/node-logger/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/node-logger", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "", "keywords": [ "storybook" diff --git a/code/lib/postinstall/package.json b/code/lib/postinstall/package.json index e5767369da45..813bfa3dee5b 100644 --- a/code/lib/postinstall/package.json +++ b/code/lib/postinstall/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/postinstall", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook addons postinstall utilities", "keywords": [ "api", diff --git a/code/lib/preview-api/package.json b/code/lib/preview-api/package.json index 63360435ff81..602cfd09e87e 100644 --- a/code/lib/preview-api/package.json +++ b/code/lib/preview-api/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preview-api", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "", "keywords": [ "storybook" diff --git a/code/lib/preview/package.json b/code/lib/preview/package.json index 17640147d4d6..b0b831845e85 100644 --- a/code/lib/preview/package.json +++ b/code/lib/preview/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preview", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "", "keywords": [ "storybook" diff --git a/code/lib/react-dom-shim/package.json b/code/lib/react-dom-shim/package.json index 61891b19bb92..ef2e879a9495 100644 --- a/code/lib/react-dom-shim/package.json +++ b/code/lib/react-dom-shim/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/react-dom-shim", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "", "keywords": [ "storybook" diff --git a/code/lib/router/package.json b/code/lib/router/package.json index a0d90d3c9722..f781481b5179 100644 --- a/code/lib/router/package.json +++ b/code/lib/router/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/router", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Core Storybook Router", "keywords": [ "storybook" diff --git a/code/lib/source-loader/package.json b/code/lib/source-loader/package.json index 5ced6d58ea11..396e07c186b9 100644 --- a/code/lib/source-loader/package.json +++ b/code/lib/source-loader/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/source-loader", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Source loader", "keywords": [ "lib", diff --git a/code/lib/telemetry/package.json b/code/lib/telemetry/package.json index 94baf024d9e6..88bcb92ea40e 100644 --- a/code/lib/telemetry/package.json +++ b/code/lib/telemetry/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/telemetry", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Telemetry logging for crash reports and usage statistics", "keywords": [ "storybook" diff --git a/code/lib/theming/package.json b/code/lib/theming/package.json index 9f2f5d3f2f59..ae8b8190755f 100644 --- a/code/lib/theming/package.json +++ b/code/lib/theming/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/theming", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Core Storybook Components", "keywords": [ "storybook" diff --git a/code/lib/types/package.json b/code/lib/types/package.json index 37aa5e722f69..6f711e61b46b 100644 --- a/code/lib/types/package.json +++ b/code/lib/types/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/types", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Core Storybook TS Types", "keywords": [ "storybook" diff --git a/code/package.json b/code/package.json index 2013de5f4248..0f9ba134d090 100644 --- a/code/package.json +++ b/code/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/root", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "private": true, "description": "Storybook root", "homepage": "https://storybook.js.org/", @@ -326,6 +326,5 @@ "Dependency Upgrades" ] ] - }, - "deferredNextVersion": "7.2.2-alpha.1" + } } diff --git a/code/presets/create-react-app/package.json b/code/presets/create-react-app/package.json index d03d838dbac3..b73a34c2d615 100644 --- a/code/presets/create-react-app/package.json +++ b/code/presets/create-react-app/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preset-create-react-app", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Create React App preset", "keywords": [ "storybook" diff --git a/code/presets/html-webpack/package.json b/code/presets/html-webpack/package.json index 40f2a73df8c8..98c1cc4ed201 100644 --- a/code/presets/html-webpack/package.json +++ b/code/presets/html-webpack/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preset-html-webpack", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for HTML: View HTML snippets in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/presets/preact-webpack/package.json b/code/presets/preact-webpack/package.json index e5fa57078583..86c329925bd5 100644 --- a/code/presets/preact-webpack/package.json +++ b/code/presets/preact-webpack/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preset-preact-webpack", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Preact: Develop Preact Component in isolation.", "keywords": [ "storybook" diff --git a/code/presets/react-webpack/package.json b/code/presets/react-webpack/package.json index 1d5fadfa76b2..5bdab67f066e 100644 --- a/code/presets/react-webpack/package.json +++ b/code/presets/react-webpack/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preset-react-webpack", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for React: Develop React Component in isolation with Hot Reloading", "keywords": [ "storybook" diff --git a/code/presets/server-webpack/package.json b/code/presets/server-webpack/package.json index 43ce64d92ce9..8c43af3c7557 100644 --- a/code/presets/server-webpack/package.json +++ b/code/presets/server-webpack/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preset-server-webpack", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Server: View HTML snippets from a server in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/presets/svelte-webpack/package.json b/code/presets/svelte-webpack/package.json index e35c561c9027..01252e033569 100644 --- a/code/presets/svelte-webpack/package.json +++ b/code/presets/svelte-webpack/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preset-svelte-webpack", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Svelte: Develop Svelte Component in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/presets/vue-webpack/package.json b/code/presets/vue-webpack/package.json index bba0446fb4ad..530fec7a4dac 100644 --- a/code/presets/vue-webpack/package.json +++ b/code/presets/vue-webpack/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preset-vue-webpack", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Vue: Develop Vue Component in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/presets/vue3-webpack/package.json b/code/presets/vue3-webpack/package.json index 0b681973d19e..9c8ce38391c3 100644 --- a/code/presets/vue3-webpack/package.json +++ b/code/presets/vue3-webpack/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preset-vue3-webpack", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for Vue 3: Develop Vue 3 Components in isolation with Hot Reloading.", "keywords": [ "storybook" diff --git a/code/presets/web-components-webpack/package.json b/code/presets/web-components-webpack/package.json index d072a21948b1..e02b964b5c4d 100644 --- a/code/presets/web-components-webpack/package.json +++ b/code/presets/web-components-webpack/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preset-web-components-webpack", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook for web-components: View web components snippets in isolation with Hot Reloading.", "keywords": [ "lit", diff --git a/code/renderers/html/package.json b/code/renderers/html/package.json index 2e439e37dcd2..0634c9d4c309 100644 --- a/code/renderers/html/package.json +++ b/code/renderers/html/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/html", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook HTML renderer", "keywords": [ "storybook" diff --git a/code/renderers/preact/package.json b/code/renderers/preact/package.json index 2ffc96db935f..f9443024552b 100644 --- a/code/renderers/preact/package.json +++ b/code/renderers/preact/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preact", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook Preact renderer", "keywords": [ "storybook" diff --git a/code/renderers/react/package.json b/code/renderers/react/package.json index baac72ad3f46..dd710739925e 100644 --- a/code/renderers/react/package.json +++ b/code/renderers/react/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/react", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook React renderer", "keywords": [ "storybook" diff --git a/code/renderers/server/package.json b/code/renderers/server/package.json index 4d0945f95927..3228aa30867a 100644 --- a/code/renderers/server/package.json +++ b/code/renderers/server/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/server", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook Server renderer", "keywords": [ "storybook" diff --git a/code/renderers/svelte/package.json b/code/renderers/svelte/package.json index 9d514c1c9237..4afaf9b38687 100644 --- a/code/renderers/svelte/package.json +++ b/code/renderers/svelte/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/svelte", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook Svelte renderer", "keywords": [ "storybook" diff --git a/code/renderers/vue/package.json b/code/renderers/vue/package.json index 6818e855ca4d..a24e51876845 100644 --- a/code/renderers/vue/package.json +++ b/code/renderers/vue/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/vue", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook Vue renderer", "keywords": [ "storybook" diff --git a/code/renderers/vue3/package.json b/code/renderers/vue3/package.json index 3dba3f7495dd..27121f55deff 100644 --- a/code/renderers/vue3/package.json +++ b/code/renderers/vue3/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/vue3", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook Vue 3 renderer", "keywords": [ "storybook" diff --git a/code/renderers/web-components/package.json b/code/renderers/web-components/package.json index d0aecddb51eb..6efbc9f197c1 100644 --- a/code/renderers/web-components/package.json +++ b/code/renderers/web-components/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/web-components", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook web-components renderer", "keywords": [ "lit", diff --git a/code/ui/blocks/package.json b/code/ui/blocks/package.json index 49c29abb70ec..eb27ae5cabeb 100644 --- a/code/ui/blocks/package.json +++ b/code/ui/blocks/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/blocks", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Storybook Doc Blocks", "keywords": [ "storybook" diff --git a/code/ui/components/package.json b/code/ui/components/package.json index 86e7eae05e97..b46cd262b0a7 100644 --- a/code/ui/components/package.json +++ b/code/ui/components/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/components", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Core Storybook Components", "keywords": [ "storybook" diff --git a/code/ui/manager/package.json b/code/ui/manager/package.json index 8ff9e1fdc10c..c746c3bb5e09 100644 --- a/code/ui/manager/package.json +++ b/code/ui/manager/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/manager", - "version": "7.2.2-alpha.0", + "version": "7.2.2-alpha.1", "description": "Core Storybook UI", "keywords": [ "storybook" From d89dee3b8367bdafd8c71fcce3759ec1bd8913f0 Mon Sep 17 00:00:00 2001 From: Shaun Lloyd Date: Thu, 10 Aug 2023 09:57:38 -0400 Subject: [PATCH 13/29] Update postinstall to look for addon script --- code/lib/cli/src/add.ts | 61 ++++++++++++----------------------------- 1 file changed, 18 insertions(+), 43 deletions(-) diff --git a/code/lib/cli/src/add.ts b/code/lib/cli/src/add.ts index 7b9aca413e16..7f2f55ce812d 100644 --- a/code/lib/cli/src/add.ts +++ b/code/lib/cli/src/add.ts @@ -1,11 +1,6 @@ -import path from 'path'; -import fs from 'fs'; -import { sync as spawnSync } from 'cross-spawn'; - import { getStorybookInfo } from '@storybook/core-common'; import { readConfig, writeConfig } from '@storybook/csf-tools'; -import { commandLog } from './helpers'; import { JsPackageManagerFactory, useNpmWarning, @@ -15,43 +10,23 @@ import { getStorybookVersion } from './utils'; const logger = console; -const LEGACY_CONFIGS = ['addons', 'config', 'presets']; - -const postinstallAddon = async (addonName: string, isOfficialAddon: boolean) => { - let skipMsg = null; - if (!isOfficialAddon) { - skipMsg = 'unofficial addon'; - } else if (!fs.existsSync('.storybook')) { - skipMsg = 'no .storybook config'; - } else { - skipMsg = 'no codmods found'; - LEGACY_CONFIGS.forEach((config) => { - try { - const codemod = require.resolve( - // @ts-expect-error (it is broken) - `${getPackageName(addonName, isOfficialAddon)}/postinstall/${config}.js` - ); - commandLog(`Running postinstall script for ${addonName}`)(); - let configFile = path.join('.storybook', `${config}.ts`); - if (!fs.existsSync(configFile)) { - configFile = path.join('.storybook', `${config}.js`); - if (!fs.existsSync(configFile)) { - fs.writeFileSync(configFile, '', 'utf8'); - } - } - spawnSync('npx', ['jscodeshift', '-t', codemod, configFile], { - stdio: 'inherit', - shell: true, - }); - skipMsg = null; - } catch (err) { - // resolve failed, skip - } - }); - } +const postinstallAddon = async (addonName: string) => { + try { + const modulePath = require.resolve(`${addonName}/postinstall`, { paths: [process.cwd()] }); + // eslint-disable-next-line import/no-dynamic-require, global-require + const postinstall = require(modulePath); - if (skipMsg) { - commandLog(`Skipping postinstall for ${addonName}, ${skipMsg}`)(); + try { + logger.log(`Running postinstall script for ${addonName}`); + await postinstall(); + } catch (e) { + logger.error(`Error running postinstall script for ${addonName}`); + logger.error(e); + } + } catch (e) { + // no postinstall script + logger.log(`No postinstall script for ${addonName}`); + logger.log(e); } }; @@ -109,7 +84,7 @@ export async function add( main.appendValueToArray(['addons'], addonName); await writeConfig(main); - if (!options.skipPostinstall) { - await postinstallAddon(addon, isStorybookAddon); + if (!options.skipPostinstall && isStorybookAddon) { + await postinstallAddon(addonName); } } From d4ca02a5db54be37a028858f8a3cf43a884dfd96 Mon Sep 17 00:00:00 2001 From: Kasper Peulen Date: Thu, 10 Aug 2023 16:02:31 +0200 Subject: [PATCH 14/29] Deprecate key in addon render function as it is not available anymore --- code/lib/types/src/modules/addons.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/code/lib/types/src/modules/addons.ts b/code/lib/types/src/modules/addons.ts index 463c2c0e3b99..f55efcd29983 100644 --- a/code/lib/types/src/modules/addons.ts +++ b/code/lib/types/src/modules/addons.ts @@ -307,7 +307,11 @@ export type BaseStory = export interface Addon_RenderOptions { active: boolean; - key: string; + /** + * @deprecated You should not use key anymore as of Storybook 7.2 this render method is invoked as a React component. + * This property will be removed in 8.0. + * */ + key?: unknown; } /** From 9550c42ea34ef99b8e4a44fac4b878a18039c11d Mon Sep 17 00:00:00 2001 From: Kasper Peulen Date: Thu, 10 Aug 2023 16:18:47 +0200 Subject: [PATCH 15/29] Fix TS checks --- .../src/legacy/tabs/tabs.stories.tsx | 32 ++++--------------- .../src/components/layout/app.mockdata.tsx | 14 ++------ .../src/components/panel/panel.stories.tsx | 29 +++-------------- 3 files changed, 14 insertions(+), 61 deletions(-) diff --git a/code/ui/components/src/legacy/tabs/tabs.stories.tsx b/code/ui/components/src/legacy/tabs/tabs.stories.tsx index 77d357acf0b9..cac0a76b4deb 100644 --- a/code/ui/components/src/legacy/tabs/tabs.stories.tsx +++ b/code/ui/components/src/legacy/tabs/tabs.stories.tsx @@ -47,18 +47,12 @@ type Panels = Record>; const panels: Panels = { test1: { title: 'Tab title #1', - render: ({ active, key }) => - active ? ( -
- CONTENT 1 -
- ) : null, + render: ({ active }) => (active ?
CONTENT 1
: null), }, test2: { title: 'Tab title #2', - render: ({ active, key }) => ( + render: ({ active }) => (
+ render: ({ active }) => active ? ( -
+
{colours.map((colour, i) => (
- active ? ( -
- CONTENT 4 -
- ) : null, + render: ({ active }) => (active ?
CONTENT 4
: null), }, test5: { title: 'Tab title #5', - render: ({ active, key }) => - active ? ( -
- CONTENT 5 -
- ) : null, + render: ({ active }) => (active ?
CONTENT 5
: null), }, test6: { title: 'Tab title #6', - render: ({ active, key }) => ( -
CONTENT 6
} /> - ), + render: ({ active }) =>
CONTENT 6
} />, }, }; diff --git a/code/ui/manager/src/components/layout/app.mockdata.tsx b/code/ui/manager/src/components/layout/app.mockdata.tsx index 32b22148adfb..1cb665508b7b 100644 --- a/code/ui/manager/src/components/layout/app.mockdata.tsx +++ b/code/ui/manager/src/components/layout/app.mockdata.tsx @@ -42,22 +42,12 @@ export const panels: Addon_Collection = { test1: { title: 'Test 1', type: Addon_TypesEnum.PANEL, - render: ({ active, key }) => - active ? ( -
- TEST 1 -
- ) : null, + render: ({ active }) => (active ?
TEST 1
: null), }, test2: { title: 'Test 2', type: Addon_TypesEnum.PANEL, - render: ({ active, key }) => - active ? ( -
- TEST 2 -
- ) : null, + render: ({ active }) => (active ?
TEST 2
: null), }, }; diff --git a/code/ui/manager/src/components/panel/panel.stories.tsx b/code/ui/manager/src/components/panel/panel.stories.tsx index 9d29a9c07b9e..6fe0f00f833e 100644 --- a/code/ui/manager/src/components/panel/panel.stories.tsx +++ b/code/ui/manager/src/components/panel/panel.stories.tsx @@ -37,12 +37,7 @@ export const JSXTitles = () => { 'function-string': { type: Addon_TypesEnum.PANEL, title: () => 'Test 1', - render: ({ active, key }) => - active ? ( -
- TEST as string -
- ) : null, + render: ({ active }) => (active ?
TEST as string
: null), }, 'function-jsx': { type: Addon_TypesEnum.PANEL, @@ -54,12 +49,7 @@ export const JSXTitles = () => {
), - render: ({ active, key }) => - active ? ( -
- TEST with label -
- ) : null, + render: ({ active }) => (active ?
TEST with label
: null), }, 'function-jsx-icon': { type: Addon_TypesEnum.PANEL, @@ -71,12 +61,7 @@ export const JSXTitles = () => {
), - render: ({ active, key }) => - active ? ( -
- TEST with label -
- ) : null, + render: ({ active }) => (active ?
TEST with label
: null), }, 'function-jsx-state': { type: Addon_TypesEnum.PANEL, @@ -125,12 +110,8 @@ export const JSXTitles = () => {
); }, - render: ({ active, key }) => { - return active ? ( -
- TEST with timer -
- ) : null; + render: ({ active }) => { + return active ?
TEST with timer
: null; }, }, }} From 910b671ce6fbd7c974be3eca933239f309235a97 Mon Sep 17 00:00:00 2001 From: Charles de Dreuille Date: Thu, 10 Aug 2023 17:26:50 +0200 Subject: [PATCH 16/29] Improve Icon component --- .../src/new/IconButton/IconButton.stories.tsx | 14 ++++++ .../src/new/IconButton/IconButton.tsx | 46 +++++++++++++++---- 2 files changed, 52 insertions(+), 8 deletions(-) diff --git a/code/ui/components/src/new/IconButton/IconButton.stories.tsx b/code/ui/components/src/new/IconButton/IconButton.stories.tsx index 4d4b82cf7e22..4e239b9fb1b3 100644 --- a/code/ui/components/src/new/IconButton/IconButton.stories.tsx +++ b/code/ui/components/src/new/IconButton/IconButton.stories.tsx @@ -52,6 +52,20 @@ export const Disabled: Story = { }, }; +export const Animated: Story = { + args: { + ...Base.args, + icon: 'FaceHappy', + }, + render: () => ( +
+ + + +
+ ), +}; + export const WithHref: Story = { render: () => (
diff --git a/code/ui/components/src/new/IconButton/IconButton.tsx b/code/ui/components/src/new/IconButton/IconButton.tsx index ae20fa9e38ad..18385bf3609d 100644 --- a/code/ui/components/src/new/IconButton/IconButton.tsx +++ b/code/ui/components/src/new/IconButton/IconButton.tsx @@ -1,32 +1,53 @@ -import React, { forwardRef } from 'react'; +import type { SyntheticEvent } from 'react'; +import React, { forwardRef, useEffect, useState } from 'react'; import { styled } from '@storybook/theming'; import { darken, lighten, rgba, transparentize } from 'polished'; import type { Icons } from '@storybook/icons'; import type { PropsOf } from '../utils/types'; import { Icon } from '../Icon/Icon'; -interface ButtonProps { +interface IconButtonProps { icon: Icons; as?: T; size?: 'small' | 'medium'; variant?: 'solid' | 'outline' | 'ghost'; - onClick?: () => void; + onClick?: (event: SyntheticEvent) => void; disabled?: boolean; active?: boolean; + onClickAnimation?: 'none' | 'rotate360' | 'glow' | 'jiggle'; } export const IconButton: { ( - props: ButtonProps & Omit, keyof ButtonProps> + props: IconButtonProps & Omit, keyof IconButtonProps> ): JSX.Element; displayName?: string; } = forwardRef( - ({ as, icon = 'FaceHappy', ...props }: ButtonProps, ref: React.Ref) => { + ( + { as, icon = 'FaceHappy', onClickAnimation = 'none', onClick, ...props }: IconButtonProps, + ref: React.Ref + ) => { const LocalIcon = Icon[icon]; + const [isAnimating, setIsAnimating] = useState(false); + + const handleClick = (event: SyntheticEvent) => { + if (onClick) onClick(event); + if (onClickAnimation === 'none') return; + setIsAnimating(true); + }; + + useEffect(() => { + const timer = setTimeout(() => { + if (isAnimating) setIsAnimating(false); + }, 1000); + return () => clearTimeout(timer); + }, [isAnimating]); return ( - - {icon && } + + + + ); } @@ -34,7 +55,7 @@ export const IconButton: { IconButton.displayName = 'IconButton'; -const StyledButton = styled.button>( +const StyledButton = styled.button>( ({ theme, variant = 'solid', size = 'medium', disabled = false, active = false }) => ({ border: 0, cursor: disabled ? 'not-allowed' : 'pointer', @@ -109,3 +130,12 @@ const StyledButton = styled.button>( }, }) ); + +const IconWrapper = styled.div<{ + isAnimating: boolean; + animation: IconButtonProps['onClickAnimation']; +}>(({ theme, isAnimating, animation }) => ({ + width: 14, + height: 14, + animation: isAnimating && animation !== 'none' && `${theme.animation[animation]} 1000ms ease-out`, +})); From d964d59de7c4830a4f876746092c33ec0aa7412d Mon Sep 17 00:00:00 2001 From: Charles de Dreuille Date: Thu, 10 Aug 2023 17:27:18 +0200 Subject: [PATCH 17/29] Added the new Toolbar component --- code/ui/components/package.json | 1 + code/ui/components/src/experimental.ts | 1 + .../src/new/Toolbar/Toolbar.stories.tsx | 117 +++++++++++++++++ .../ui/components/src/new/Toolbar/Toolbar.tsx | 83 ++++++++++++ code/ui/manager/src/globals/exports.ts | 10 +- code/yarn.lock | 123 ++++++++++++++++++ 6 files changed, 334 insertions(+), 1 deletion(-) create mode 100644 code/ui/components/src/new/Toolbar/Toolbar.stories.tsx create mode 100644 code/ui/components/src/new/Toolbar/Toolbar.tsx diff --git a/code/ui/components/package.json b/code/ui/components/package.json index b46cd262b0a7..b5e51b7b6de7 100644 --- a/code/ui/components/package.json +++ b/code/ui/components/package.json @@ -68,6 +68,7 @@ }, "dependencies": { "@radix-ui/react-select": "^1.2.2", + "@radix-ui/react-toolbar": "^1.0.4", "@storybook/client-logger": "workspace:*", "@storybook/csf": "^0.1.0", "@storybook/global": "^5.0.0", diff --git a/code/ui/components/src/experimental.ts b/code/ui/components/src/experimental.ts index 7280862f230f..a210f26c37a6 100644 --- a/code/ui/components/src/experimental.ts +++ b/code/ui/components/src/experimental.ts @@ -13,3 +13,4 @@ export { Select } from './new/Select/Select'; export { Link } from './new/Link/Link'; export { Icon } from './new/Icon/Icon'; export { IconButton } from './new/IconButton/IconButton'; +export { Toolbar } from './new/Toolbar/Toolbar'; diff --git a/code/ui/components/src/new/Toolbar/Toolbar.stories.tsx b/code/ui/components/src/new/Toolbar/Toolbar.stories.tsx new file mode 100644 index 000000000000..d50a8f2bab23 --- /dev/null +++ b/code/ui/components/src/new/Toolbar/Toolbar.stories.tsx @@ -0,0 +1,117 @@ +import type { Meta, StoryObj } from '@storybook/react'; +import React from 'react'; + +import { Toolbar } from './Toolbar'; +import { IconButton } from '../IconButton/IconButton'; +import { Button } from '../Button/Button'; + +const meta: Meta = { + title: 'Toolbar', + component: Toolbar.Root, + tags: ['autodocs'], +}; + +export default meta; +type Story = StoryObj; + +export const Base: Story = { + args: { + hasPadding: true, + borderTop: false, + borderBottom: true, + }, + render: (_, { args }) => ( + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ), +}; + +export const NoMargin: Story = { + args: { + ...Base.args, + hasPadding: false, + }, + render: Base.render, +}; + +export const BorderTop: Story = { + args: { + ...Base.args, + borderTop: true, + borderBottom: false, + }, + render: Base.render, +}; + +export const BorderBottom: Story = { + args: { + ...Base.args, + borderTop: false, + borderBottom: true, + }, + render: Base.render, +}; + +export const BorderTopBottom: Story = { + args: { + ...Base.args, + borderTop: true, + borderBottom: true, + }, + render: Base.render, +}; diff --git a/code/ui/components/src/new/Toolbar/Toolbar.tsx b/code/ui/components/src/new/Toolbar/Toolbar.tsx new file mode 100644 index 000000000000..827011ba06fa --- /dev/null +++ b/code/ui/components/src/new/Toolbar/Toolbar.tsx @@ -0,0 +1,83 @@ +import type { ComponentPropsWithoutRef, ElementRef } from 'react'; +import React, { forwardRef } from 'react'; +import * as ToolbarPrimitive from '@radix-ui/react-toolbar'; +import { styled } from '@storybook/theming'; + +interface RootProps extends ComponentPropsWithoutRef { + hasPadding?: boolean; + borderBottom?: boolean; + borderTop?: boolean; +} + +const ToolbarRoot = forwardRef, RootProps>( + ({ className, children, ...props }, ref) => ( + + {children} + + ) +); +ToolbarRoot.displayName = ToolbarPrimitive.Root.displayName; + +const ToolbarSeparator = React.forwardRef< + ElementRef, + ComponentPropsWithoutRef +>(({ className, ...props }, ref) => ); +ToolbarSeparator.displayName = ToolbarPrimitive.Separator.displayName; + +const ToolbarToggleGroup = React.forwardRef< + ElementRef, + ToolbarPrimitive.ToolbarToggleGroupSingleProps | ToolbarPrimitive.ToolbarToggleGroupMultipleProps +>(({ className, ...props }, ref) => ); +ToolbarToggleGroup.displayName = ToolbarPrimitive.ToggleGroup.displayName; + +const ToolbarToggleItem = React.forwardRef< + ElementRef, + ComponentPropsWithoutRef +>(({ className, ...props }, ref) => ); +ToolbarToggleItem.displayName = ToolbarPrimitive.ToggleItem.displayName; + +const StyledRoot = styled(ToolbarPrimitive.Root)( + ({ theme, hasPadding = true, borderBottom = true, borderTop = false }) => ({ + display: 'flex', + padding: hasPadding ? '0 10px' : 0, + justifyContent: 'space-between', + height: 40, + borderBottom: borderBottom ? `1px solid ${theme.appBorderColor}` : 'none', + borderTop: borderTop ? `1px solid ${theme.appBorderColor}` : 'none', + boxSizing: 'border-box', + backgroundColor: theme.barBg, + }) +); + +const StyledSeparator = styled(ToolbarPrimitive.Separator)(({ theme }) => ({ + width: 1, + height: 20, + backgroundColor: theme.appBorderColor, +})); + +const StyledToggleGroup = styled(ToolbarPrimitive.ToggleGroup)({ + display: 'flex', + gap: 5, + alignItems: 'center', +}); + +const Left = styled.div({ + display: 'flex', + gap: 5, + alignItems: 'center', +}); + +const Right = styled.div({ + display: 'flex', + gap: 5, + alignItems: 'center', +}); + +export const Toolbar = { + Root: ToolbarRoot, + Left, + Right, + ToogleGroup: ToolbarToggleGroup, + ToggleItem: ToolbarToggleItem, + Separator: ToolbarSeparator, +}; diff --git a/code/ui/manager/src/globals/exports.ts b/code/ui/manager/src/globals/exports.ts index 6ad6218c0fff..793165aaf103 100644 --- a/code/ui/manager/src/globals/exports.ts +++ b/code/ui/manager/src/globals/exports.ts @@ -114,7 +114,15 @@ export default { 'resetComponents', 'withReset', ], - '@storybook/components/experimental': ['Button', 'Icon', 'IconButton', 'Input', 'Link', 'Select'], + '@storybook/components/experimental': [ + 'Button', + 'Icon', + 'IconButton', + 'Input', + 'Link', + 'Select', + 'Toolbar', + ], '@storybook/channels': [ 'Channel', 'PostMessageTransport', diff --git a/code/yarn.lock b/code/yarn.lock index 2aff024414fb..3d8fd9362ec7 100644 --- a/code/yarn.lock +++ b/code/yarn.lock @@ -5204,6 +5204,34 @@ __metadata: languageName: node linkType: hard +"@radix-ui/react-roving-focus@npm:1.0.4": + version: 1.0.4 + resolution: "@radix-ui/react-roving-focus@npm:1.0.4" + dependencies: + "@babel/runtime": ^7.13.10 + "@radix-ui/primitive": 1.0.1 + "@radix-ui/react-collection": 1.0.3 + "@radix-ui/react-compose-refs": 1.0.1 + "@radix-ui/react-context": 1.0.1 + "@radix-ui/react-direction": 1.0.1 + "@radix-ui/react-id": 1.0.1 + "@radix-ui/react-primitive": 1.0.3 + "@radix-ui/react-use-callback-ref": 1.0.1 + "@radix-ui/react-use-controllable-state": 1.0.1 + peerDependencies: + "@types/react": "*" + "@types/react-dom": "*" + react: ^16.8 || ^17.0 || ^18.0 + react-dom: ^16.8 || ^17.0 || ^18.0 + peerDependenciesMeta: + "@types/react": + optional: true + "@types/react-dom": + optional: true + checksum: 61e3ddfd1647e64fba855434ff41e8e7ba707244fe8841f78c450fbdce525383b64259279475615d030dbf1625cbffd8eeebee72d91bf6978794f5dbcf887fc0 + languageName: node + linkType: hard + "@radix-ui/react-select@npm:^1.2.2": version: 1.2.2 resolution: "@radix-ui/react-select@npm:1.2.2" @@ -5244,6 +5272,26 @@ __metadata: languageName: node linkType: hard +"@radix-ui/react-separator@npm:1.0.3": + version: 1.0.3 + resolution: "@radix-ui/react-separator@npm:1.0.3" + dependencies: + "@babel/runtime": ^7.13.10 + "@radix-ui/react-primitive": 1.0.3 + peerDependencies: + "@types/react": "*" + "@types/react-dom": "*" + react: ^16.8 || ^17.0 || ^18.0 + react-dom: ^16.8 || ^17.0 || ^18.0 + peerDependenciesMeta: + "@types/react": + optional: true + "@types/react-dom": + optional: true + checksum: 87bcde47343f2bc4439a0dc34381f557905d9b3c1e8c5a0d32ceea62a8ef84f3abf671c5cb29309fc87759ad41d39af619ba546cf54109d64c8746e3ca683de3 + languageName: node + linkType: hard + "@radix-ui/react-slot@npm:1.0.2": version: 1.0.2 resolution: "@radix-ui/react-slot@npm:1.0.2" @@ -5260,6 +5308,80 @@ __metadata: languageName: node linkType: hard +"@radix-ui/react-toggle-group@npm:1.0.4": + version: 1.0.4 + resolution: "@radix-ui/react-toggle-group@npm:1.0.4" + dependencies: + "@babel/runtime": ^7.13.10 + "@radix-ui/primitive": 1.0.1 + "@radix-ui/react-context": 1.0.1 + "@radix-ui/react-direction": 1.0.1 + "@radix-ui/react-primitive": 1.0.3 + "@radix-ui/react-roving-focus": 1.0.4 + "@radix-ui/react-toggle": 1.0.3 + "@radix-ui/react-use-controllable-state": 1.0.1 + peerDependencies: + "@types/react": "*" + "@types/react-dom": "*" + react: ^16.8 || ^17.0 || ^18.0 + react-dom: ^16.8 || ^17.0 || ^18.0 + peerDependenciesMeta: + "@types/react": + optional: true + "@types/react-dom": + optional: true + checksum: 4f4761965022759ac0950ac026029b64049e1f18ef07a01ddde788b7606efcb262c9ae3a418de0c0756bf7285182ed0d268502c6f17ba86d2ff27eee5507bbf7 + languageName: node + linkType: hard + +"@radix-ui/react-toggle@npm:1.0.3": + version: 1.0.3 + resolution: "@radix-ui/react-toggle@npm:1.0.3" + dependencies: + "@babel/runtime": ^7.13.10 + "@radix-ui/primitive": 1.0.1 + "@radix-ui/react-primitive": 1.0.3 + "@radix-ui/react-use-controllable-state": 1.0.1 + peerDependencies: + "@types/react": "*" + "@types/react-dom": "*" + react: ^16.8 || ^17.0 || ^18.0 + react-dom: ^16.8 || ^17.0 || ^18.0 + peerDependenciesMeta: + "@types/react": + optional: true + "@types/react-dom": + optional: true + checksum: 9b487dad213ea7e70b0aa205e7c6f790a6f2bf394c39912e22dbe003403fd0d24a41c2efd31695fc31ab7bac286f28253dbb2fc5202cacd572ebf909f1fdc86c + languageName: node + linkType: hard + +"@radix-ui/react-toolbar@npm:^1.0.4": + version: 1.0.4 + resolution: "@radix-ui/react-toolbar@npm:1.0.4" + dependencies: + "@babel/runtime": ^7.13.10 + "@radix-ui/primitive": 1.0.1 + "@radix-ui/react-context": 1.0.1 + "@radix-ui/react-direction": 1.0.1 + "@radix-ui/react-primitive": 1.0.3 + "@radix-ui/react-roving-focus": 1.0.4 + "@radix-ui/react-separator": 1.0.3 + "@radix-ui/react-toggle-group": 1.0.4 + peerDependencies: + "@types/react": "*" + "@types/react-dom": "*" + react: ^16.8 || ^17.0 || ^18.0 + react-dom: ^16.8 || ^17.0 || ^18.0 + peerDependenciesMeta: + "@types/react": + optional: true + "@types/react-dom": + optional: true + checksum: 3ed7ebe22ef2e8369e08bb59776671a7b8c413628249c338b8db86b4b9ac40127b4201d5bd4a9c23ea1fd21464769b4fa427d3ebcda3a7fcdbd45b256b5a753a + languageName: node + linkType: hard + "@radix-ui/react-use-callback-ref@npm:1.0.1": version: 1.0.1 resolution: "@radix-ui/react-use-callback-ref@npm:1.0.1" @@ -6545,6 +6667,7 @@ __metadata: dependencies: "@popperjs/core": ^2.6.0 "@radix-ui/react-select": ^1.2.2 + "@radix-ui/react-toolbar": ^1.0.4 "@storybook/client-logger": "workspace:*" "@storybook/csf": ^0.1.0 "@storybook/global": ^5.0.0 From 7ffce28c7eb6961bb3b8fa5fb2c39aa8d820424c Mon Sep 17 00:00:00 2001 From: Ben McCann <322311+benmccann@users.noreply.github.com> Date: Thu, 10 Aug 2023 09:57:26 -0700 Subject: [PATCH 18/29] docs: remove references to missed deadline --- code/frameworks/sveltekit/README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/frameworks/sveltekit/README.md b/code/frameworks/sveltekit/README.md index 0777e8fe9ed5..467643ee1ae5 100644 --- a/code/frameworks/sveltekit/README.md +++ b/code/frameworks/sveltekit/README.md @@ -26,10 +26,10 @@ However SvelteKit has some [Kit-specific modules](https://kit.svelte.dev/docs/mo | **Module** | **Status** | **Note** | | ---------------------------------------------------------------------------------- | ---------------------- | ----------------------------------------------------------------------------------------------------------------------------------- | | [`$app/environment`](https://kit.svelte.dev/docs/modules#$app-environment) | ✅ Supported | `version` is always empty in Storybook. | -| [`$app/forms`](https://kit.svelte.dev/docs/modules#$app-forms) | ⏳ Planned for 7.1 | Will use mocks. Tracked in [#20999](https://github.com/storybookjs/storybook/issues/20999) | -| [`$app/navigation`](https://kit.svelte.dev/docs/modules#$app-navigation) | ⏳ Planned for 7.1 | Will use mocks. Tracked in [#20999](https://github.com/storybookjs/storybook/issues/20999) | +| [`$app/forms`](https://kit.svelte.dev/docs/modules#$app-forms) | ⏳ Future | Will use mocks. Tracked in [#20999](https://github.com/storybookjs/storybook/issues/20999) | +| [`$app/navigation`](https://kit.svelte.dev/docs/modules#$app-navigation) | ⏳ Future | Will use mocks. Tracked in [#20999](https://github.com/storybookjs/storybook/issues/20999) | | [`$app/paths`](https://kit.svelte.dev/docs/modules#$app-paths) | ✅ Supported | Requires SvelteKit 1.4.0 or newer | -| [`$app/stores`](https://kit.svelte.dev/docs/modules#$app-stores) | ✅ Supported | Mocks planned for 7.1, so you can set different store values per story. | +| [`$app/stores`](https://kit.svelte.dev/docs/modules#$app-stores) | ✅ Supported | Mocks planned, so you can set different store values per story. | | [`$env/dynamic/private`](https://kit.svelte.dev/docs/modules#$env-dynamic-private) | ⛔ Not supported | They are meant to only be available server-side, and Storybook renders all components on the client. | | [`$env/dynamic/public`](https://kit.svelte.dev/docs/modules#$env-dynamic-public) | 🚧 Partially supported | Only supported in development mode. Storybook is built as a static app with no server-side API so cannot dynamically serve content. | | [`$env/static/private`](https://kit.svelte.dev/docs/modules#$env-static-private) | ⛔ Not supported | They are meant to only be available server-side, and Storybook renders all components on the client. | From b1573768d6f35e75a7a1a1b4c646d7cbb72920e6 Mon Sep 17 00:00:00 2001 From: Shaun Lloyd Date: Thu, 10 Aug 2023 13:37:03 -0400 Subject: [PATCH 19/29] Don't log when there is no postinstall script --- code/lib/cli/src/add.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/code/lib/cli/src/add.ts b/code/lib/cli/src/add.ts index 7f2f55ce812d..2b8565085dab 100644 --- a/code/lib/cli/src/add.ts +++ b/code/lib/cli/src/add.ts @@ -25,8 +25,6 @@ const postinstallAddon = async (addonName: string) => { } } catch (e) { // no postinstall script - logger.log(`No postinstall script for ${addonName}`); - logger.log(e); } }; From c75a8fc64bbcff4c71e7806dda4cc82e20c98d97 Mon Sep 17 00:00:00 2001 From: jonniebigodes Date: Thu, 10 Aug 2023 20:40:43 +0100 Subject: [PATCH 20/29] Adds more video coverage to the documentation --- docs/api/doc-block-argtypes.md | 2 ++ docs/api/doc-block-canvas.md | 2 ++ docs/api/doc-block-controls.md | 2 ++ docs/api/doc-block-description.md | 2 ++ docs/api/doc-block-primary.md | 2 ++ docs/api/doc-block-source.md | 2 ++ docs/api/doc-block-stories.md | 2 ++ docs/api/doc-block-story.md | 4 ++++ docs/api/doc-block-subtitle.md | 2 ++ docs/api/doc-block-title.md | 2 ++ docs/sharing/embed.md | 2 ++ docs/sharing/publish-storybook.md | 2 ++ docs/writing-docs/autodocs.md | 14 ++++++++------ docs/writing-docs/doc-blocks.md | 2 ++ 14 files changed, 36 insertions(+), 6 deletions(-) diff --git a/docs/api/doc-block-argtypes.md b/docs/api/doc-block-argtypes.md index a7aaf4775844..7ee304217ce5 100644 --- a/docs/api/doc-block-argtypes.md +++ b/docs/api/doc-block-argtypes.md @@ -2,6 +2,8 @@ title: 'ArgTypes' --- + + The `ArgTypes` block can be used to show a static table of [arg types](./argtypes.md) for a given component, as a way to document its interface.
diff --git a/docs/api/doc-block-canvas.md b/docs/api/doc-block-canvas.md index a77fb401d1f0..8c27490bacb8 100644 --- a/docs/api/doc-block-canvas.md +++ b/docs/api/doc-block-canvas.md @@ -2,6 +2,8 @@ title: 'Canvas' --- + + The `Canvas` block is a wrapper around a [`Story`](./doc-block-story.md), featuring a toolbar that allows you to interact with its content while automatically providing the required [`Source`](./doc-block-source.md) snippets. ![Screenshot of Canvas block](./doc-block-canvas.png) diff --git a/docs/api/doc-block-controls.md b/docs/api/doc-block-controls.md index 133ceed32c1c..835384203a5c 100644 --- a/docs/api/doc-block-controls.md +++ b/docs/api/doc-block-controls.md @@ -2,6 +2,8 @@ title: 'Controls' --- + + The `Controls` block can be used to show a dynamic table of args for a given story, as a way to document its interface, and to allow you to change the args for a (separately) rendered story (via the [`Story`](./doc-block-story.md) or [`Canvas`](./doc-block-canvas.md) blocks).
diff --git a/docs/api/doc-block-description.md b/docs/api/doc-block-description.md index e9efa50e2e9e..1c188a239349 100644 --- a/docs/api/doc-block-description.md +++ b/docs/api/doc-block-description.md @@ -2,6 +2,8 @@ title: 'Description' --- + + The `Description` block displays the description for a component, story, or meta, obtained from their respective JSDoc comments. ![Screenshot of Description block](./doc-block-title-subtitle-description.png) diff --git a/docs/api/doc-block-primary.md b/docs/api/doc-block-primary.md index be806ab0c50b..5d124df65b9f 100644 --- a/docs/api/doc-block-primary.md +++ b/docs/api/doc-block-primary.md @@ -2,6 +2,8 @@ title: 'Primary' --- + + The `Primary` block displays the primary (first defined in the stories file) story, in a [`Story`](./doc-block-story.md) block. It is typically rendered immediately under the title in a docs entry. ![Screenshot of Primary block](./doc-block-primary.png) diff --git a/docs/api/doc-block-source.md b/docs/api/doc-block-source.md index 7e80d698f0e8..0595c387a238 100644 --- a/docs/api/doc-block-source.md +++ b/docs/api/doc-block-source.md @@ -2,6 +2,8 @@ title: 'Source' --- + + The `Source` block is used to render a snippet of source code directly. ![Screenshot of Source block](./doc-block-source.png) diff --git a/docs/api/doc-block-stories.md b/docs/api/doc-block-stories.md index 657e27beab32..75728b54df71 100644 --- a/docs/api/doc-block-stories.md +++ b/docs/api/doc-block-stories.md @@ -2,6 +2,8 @@ title: 'Stories' --- + + The `Stories` block renders the full collection of stories in a stories file. ![Screenshot of Stories block](./doc-block-stories.png) diff --git a/docs/api/doc-block-story.md b/docs/api/doc-block-story.md index 1532740946fd..89499df3328c 100644 --- a/docs/api/doc-block-story.md +++ b/docs/api/doc-block-story.md @@ -2,6 +2,8 @@ title: 'Story' --- + + Stories (component tests) are Storybook's fundamental building blocks. In Storybook Docs, you can render any of your stories from your CSF files in the context of an MDX file with all annotations (parameters, args, loaders, decorators, play function) applied using the `Story` block. @@ -124,6 +126,8 @@ Type: Story export Specifies which story is rendered by the `Story` block. If no `of` is defined and the MDX file is [attached](./doc-block-meta.md#attached-vs-unattached), the primary (first) story will be rendered. + + ### `args` (⛔️ **Deprecated**) diff --git a/docs/api/doc-block-subtitle.md b/docs/api/doc-block-subtitle.md index f0d1d5ed5a6c..1104184c9992 100644 --- a/docs/api/doc-block-subtitle.md +++ b/docs/api/doc-block-subtitle.md @@ -2,6 +2,8 @@ title: 'Subtitle' --- + + The `Subtitle` block can serve as a secondary heading for your docs entry. ![Screenshot of Subtitle block](./doc-block-title-subtitle-description.png) diff --git a/docs/api/doc-block-title.md b/docs/api/doc-block-title.md index acdc1cee0f90..886d19075386 100644 --- a/docs/api/doc-block-title.md +++ b/docs/api/doc-block-title.md @@ -2,6 +2,8 @@ title: 'Title' --- + + The `Title` block serves as the primary heading for your docs entry. It is typically used to provide the component or page name. ![Screenshot of Title block](./doc-block-title-subtitle-description.png) diff --git a/docs/sharing/embed.md b/docs/sharing/embed.md index 01b697f3f62a..fac0efba259c 100644 --- a/docs/sharing/embed.md +++ b/docs/sharing/embed.md @@ -2,6 +2,8 @@ title: 'Embed stories' --- + + Embed stories to showcase your work to teammates and the developer community at large. In order to use embeds, your Storybook must be published and publicly accessible. Storybook supports `