Storybook: Fix after update to PNPM 7 broke build (#34724)

* Add package.json to storybook

* use @woocommerce/storybook name
This commit is contained in:
Paul Sealock 2022-09-20 12:39:31 +12:00 committed by GitHub
parent 651c67eec8
commit 0b62bf85bd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 833 additions and 1362 deletions

View File

@ -16,12 +16,9 @@
"scripts": {
"build": "pnpm exec turbo run turbo:build",
"test": "pnpm exec turbo run turbo:test",
"build-storybook": "build-storybook -c ./tools/storybook/.storybook",
"preinstall": "npx only-allow pnpm",
"postinstall": "pnpm git:update-hooks",
"git:update-hooks": "rm -r .git/hooks && mkdir -p .git/hooks && husky install",
"storybook": "./tools/storybook/import-wp-css-storybook.sh && BABEL_ENV=storybook STORYBOOK=true start-storybook -c ./tools/storybook/.storybook -p 6007 --ci",
"storybook-rtl": "USE_RTL_STYLE=true pnpm run storybook",
"create-extension": "node ./tools/create-extension/index.js",
"cherry-pick": "node ./tools/cherry-pick/bin/run",
"sync-dependencies": "pnpm exec syncpack -- fix-mismatches"
@ -29,23 +26,6 @@
"devDependencies": {
"@babel/preset-env": "^7.16.11",
"@babel/runtime": "^7.17.2",
"@storybook/addon-a11y": "^6.4.19",
"@storybook/addon-actions": "^6.4.19",
"@storybook/addon-console": "^1.2.3",
"@storybook/addon-controls": "^6.4.19",
"@storybook/addon-docs": "^6.4.19",
"@storybook/addon-knobs": "^6.4.0",
"@storybook/addon-links": "^6.4.19",
"@storybook/addon-storysource": "^6.4.19",
"@storybook/addon-viewport": "^6.4.19",
"@storybook/addons": "^6.4.19",
"@storybook/api": "^6.4.19",
"@storybook/builder-webpack5": "^6.4.19",
"@storybook/components": "^6.4.19",
"@storybook/core-events": "^6.4.19",
"@storybook/manager-webpack5": "^6.4.19",
"@storybook/react": "^6.4.19",
"@storybook/theming": "^6.4.19",
"@types/node": "14.14.33",
"@woocommerce/eslint-plugin": "workspace:*",
"@wordpress/data": "^6.15.0",

File diff suppressed because it is too large Load Diff

View File

@ -10,3 +10,4 @@ packages:
- 'tools/release-posts'
- 'tools/cli-core'
- 'tools/version-bump'
- 'tools/storybook'

1
tools/storybook/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
storybook-static

View File

@ -0,0 +1,49 @@
{
"name": "@woocommerce/storybook",
"title": "WooCommerce Storybook",
"description": "Storybook implementation for WooCommerce",
"homepage": "https://woocommerce.github.io/woocommerce-admin/#/components/",
"private": true,
"repository": {
"type": "git",
"url": "https://github.com/woocommerce/woocommerce.git"
},
"author": "Automattic",
"license": "GPL-3.0-or-later",
"bugs": {
"url": "https://github.com/woocommerce/woocommerce/issues"
},
"scripts": {
"build-storybook": "build-storybook -c ./.storybook",
"preinstall": "npx only-allow pnpm",
"storybook": "./import-wp-css-storybook.sh && BABEL_ENV=storybook STORYBOOK=true start-storybook -c ./.storybook -p 6007 --ci",
"storybook-rtl": "USE_RTL_STYLE=true pnpm run storybook"
},
"devDependencies": {
"@babel/preset-env": "^7.16.11",
"@babel/runtime": "^7.17.2",
"@storybook/addon-a11y": "^6.4.19",
"@storybook/addon-actions": "^6.4.19",
"@storybook/addon-console": "^1.2.3",
"@storybook/addon-controls": "^6.4.19",
"@storybook/addon-docs": "^6.4.19",
"@storybook/addon-knobs": "^6.4.0",
"@storybook/addon-links": "^6.4.19",
"@storybook/addon-storysource": "^6.4.19",
"@storybook/addon-viewport": "^6.4.19",
"@storybook/addons": "^6.4.19",
"@storybook/api": "^6.4.19",
"@storybook/builder-webpack5": "^6.4.19",
"@storybook/components": "^6.4.19",
"@storybook/core-events": "^6.4.19",
"@storybook/manager-webpack5": "^6.4.19",
"@storybook/react": "^6.4.19",
"@storybook/theming": "^6.4.19",
"@woocommerce/eslint-plugin": "workspace:*",
"typescript": "4.2.4",
"webpack": "^5.70.0"
},
"dependencies": {
"@babel/preset-typescript": "^7.16.7"
}
}