storybookjs / storybook

Storybook is the industry standard workshop for building, documenting, and testing UI components in isolation
https://storybook.js.org
MIT License
84.6k stars 9.31k forks source link

storyName property in CSF3 objects with storyStoreV7 enabled doesn't work #17548

Closed Guria closed 2 years ago

Guria commented 2 years ago

Describe the bug With storyStoreV7 feature enabled overriding story name with storyName property in CSF3 format doesn't works. image

To Reproduce

export const Secondary: ComponentStoryObj = { args: { label: 'Button', }, name: "Override using name" };


**System**

Environment Info:

System: OS: Linux 5.13 Ubuntu 21.10 21.10 (Impish Indri) CPU: (8) x64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz Binaries: Node: 14.18.1 - ~/.volta/tools/image/node/14.18.1/bin/node Yarn: 1.22.15 - ~/.volta/tools/image/yarn/1.22.15/bin/yarn npm: 8.5.0 - ~/.volta/tools/image/npm/8.5.0/bin/npm Browsers: Chrome: 98.0.4758.102 Firefox: 97.0



**Additional context**
Initially reported at https://github.com/eirslett/storybook-builder-vite/issues/253
Most suspicious code found during debug:
https://github.com/storybookjs/storybook/blob/main/lib/store/src/normalizeStory.ts#L47-L51
shilman commented 2 years ago

Yippee!! I just released https://github.com/storybookjs/storybook/releases/tag/v6.5.9-alpha.0 containing PR #18464 that references this issue. Upgrade today to the @prerelease NPM tag to try it out!

npx sb upgrade --prerelease

Closing this issue. Please re-open if you think there's still more to do.

shilman commented 2 years ago

Yowza!! I just released https://github.com/storybookjs/storybook/releases/tag/v6.5.9 containing PR #18464 that references this issue. Upgrade today to the @latest NPM tag to try it out!

npx sb upgrade
shilman commented 2 years ago

Zoinks!! I just released https://github.com/storybookjs/storybook/releases/tag/v7.0.0-alpha.2 containing PR #18464 that references this issue. Upgrade today to the @future NPM tag to try it out!

npx sb upgrade --prerelease