woocommerce/plugins/woocommerce-blocks/package.json

434 lines
17 KiB
JSON

{
"name": "@woocommerce/block-library",
"private": true,
"title": "WooCommerce Blocks",
"author": "Automattic",
"version": "11.8.0-dev",
"description": "WooCommerce blocks for the Gutenberg editor.",
"homepage": "https://github.com/woocommerce/woocommerce/plugins/woocommerce-blocks/",
"keywords": [
"woocommerce",
"wordpress",
"blocks"
],
"sideEffects": [
"*.css",
"*.scss",
"./assets/js/atomic/blocks/**",
"./assets/js/filters/**",
"./assets/js/middleware/**",
"./assets/js/types/**",
"./assets/js/blocks/checkout/inner-blocks/**/index.tsx",
"./assets/js/blocks/checkout/inner-blocks/register-components.ts",
"./assets/js/blocks/cart/inner-blocks/**/index.tsx",
"./assets/js/blocks/cart/inner-blocks/register-components.ts",
"./assets/js/base/components/**/*.{tsx,ts}",
"./assets/js/blocks/mini-cart/mini-cart-contents/inner-blocks/**/index.tsx",
"./assets/js/blocks/mini-cart/mini-cart-contents/inner-blocks/register-components.ts",
"./assets/js/blocks/cart-checkout-shared/sidebar-notices/index.tsx",
"./assets/js/blocks/cart-checkout-shared/view-switcher/index.tsx",
"./assets/js/blocks/filter-wrapper/register-components.ts",
"./assets/js/blocks/product-query/variations/**.tsx",
"./assets/js/blocks/product-query/index.tsx",
"./assets/js/blocks/product-query/inspector-controls.tsx",
"./assets/js/blocks/product-gallery/**.tsx",
"./assets/js/blocks/product-gallery/inner-blocks/**/index.tsx",
"./assets/js/templates/revert-button/index.tsx",
"./assets/js/settings/blocks/index.ts",
"./assets/js/atomic/utils/blocks-registration-manager/index.ts",
"./packages/**/*.{tsx,ts,js}"
],
"repository": {
"type": "git",
"url": "https://github.com:woocommerce/woocommerce.git"
},
"license": "GPL-3.0+",
"scripts": {
"analyze-bundles": "cross-env WP_BUNDLE_ANALYZER=1 pnpm run build",
"changelog": "composer install && composer exec -- changelogger",
"build": "pnpm --if-present --workspace-concurrency=Infinity --stream --filter=\"$npm_package_name...\" '/^build:project:.*$/'",
"build:project": "pnpm --if-present '/^build:project:.*$/'",
"build:project:bundle": "wireit",
"build:check-assets": "rimraf build/* && cross-env ASSET_CHECK=true BABEL_ENV=default NODE_ENV=production webpack",
"build:deploy": "rimraf vendor/* && cross-env WOOCOMMERCE_BLOCKS_PHASE=2 composer install --no-dev && cross-env WOOCOMMERCE_BLOCKS_PHASE=2 pnpm run build --loglevel error",
"prebuild:docs": "rimraf docs/extensibility/actions.md & rimraf docs/extensibility/filters.md",
"build:docs": "./vendor/bin/wp-hooks-generator --input=src --output=bin/hook-docs/data && node ./bin/hook-docs && pnpm build:docs:block-references",
"build:docs:block-references": "node ./bin/gen-block-list-doc.js",
"postbuild:docs": "./bin/add-doc-footer.sh",
"changelog:zenhub": "node ./bin/changelog --changelogSrcType='ZENHUB_RELEASE'",
"change-versions": "source ./bin/change-versions.sh",
"deploy": "pnpm run build:deploy && sh ./bin/github-deploy.sh",
"dev": "rimraf build/* && cross-env BABEL_ENV=default webpack",
"labels:dry": "github-label-sync --labels ./.github/label-sync-config.json --allow-added-labels --dry-run woocommerce/woocommerce-gutenberg-products-block",
"labels:sync": "github-label-sync --labels ./.github/label-sync-config.json --allow-added-labels woocommerce/woocommerce-gutenberg-products-block",
"lint": "pnpm --if-present '/^lint:lang:.*$/'",
"lint:fix": "pnpm --if-present '/^lint:fix:lang:.*$/'",
"lint:fix:lang:css": "pnpm lint:css-fix",
"lint:fix:lang:js": "pnpm lint:js-fix",
"lint:lang:css": "pnpm lint:css",
"lint:lang:js": "pnpm lint:js",
"lint:ci": "pnpm run lint:js && pnpm run lint:css",
"lint:css": "stylelint '**/*.scss'",
"lint:css-fix": "stylelint '**/*.scss' --fix",
"lint:js": "wp-scripts lint-js --ext=js,ts,tsx",
"lint:js:report": "pnpm run lint:js -- --output-file eslint_report.json --ext=js,ts,tsx --format json",
"lint:js-fix": "eslint assets/js --ext=js,jsx,ts,tsx --fix",
"lint:md:docs": "wp-scripts lint-md-docs",
"fix-package-lock": "./bin/fix-package-lock.sh",
"pre-commit": "lint-staged",
"reformat-files": "prettier --ignore-path .eslintignore --write \"**/*.{js,jsx,json,ts,tsx}\"",
"release": "sh ./bin/wordpress-deploy.sh",
"rimraf": "./node_modules/rimraf/bin.js",
"start": "rimraf build/* && cross-env BABEL_ENV=default CHECK_CIRCULAR_DEPS=true webpack --watch",
"storybook": "storybook dev -c ./storybook -p 6006 --ci",
"storybook:build": "BABEL_ENV=development storybook build -c ./storybook -o ./storybook/dist",
"storybook:deploy": "rimraf ./storybook/dist/* && pnpm run storybook:build && gh-pages -d ./storybook/dist",
"test:js": "wp-scripts test-unit-js --config tests/js/jest.config.json",
"test:debug": "ndb .",
"test:e2e": "sh ./bin/check-env.sh && pnpm playwright test --config=tests/e2e/playwright.config.ts",
"test:e2e:report": "sh ./bin/check-env.sh && npx playwright test --config=tests/e2e/playwright.config.ts --reporter=html",
"test:e2e:side-effects": "pnpm run test:e2e --config=tests/e2e/playwright.side-effects.config.ts",
"test:e2e:side-effects:report": "pnpm run test:e2e:report --config=tests/e2e/playwright.side-effects.config.ts --reporter=html",
"test:e2e:classic-theme": "pnpm run test:e2e --config=tests/e2e/playwright.classic-theme.config.ts",
"test:e2e:classic-theme:report": "pnpm run test:e2e:report --config=tests/e2e/playwright.classic-theme.config.ts",
"test:e2e:block-theme-with-templates": "pnpm run test:e2e --config=tests/e2e/playwright.block-theme-with-templates.config.ts",
"test:e2e:block-theme-with-templates:report": "pnpm run test:e2e:report --config=tests/e2e/playwright.block-theme-with-templates.config.ts",
"test:e2e:jest": "pnpm run wp-env:config && cross-env JEST_PUPPETEER_CONFIG=tests/e2e-jest/config/jest-puppeteer.config.js NODE_CONFIG_DIR=tests/e2e-jest/config wp-scripts test-e2e --config tests/e2e-jest/config/jest.config.js",
"test:e2e:jest:dev": "pnpm run wp-env:config && cross-env JEST_PUPPETEER_CONFIG=tests/e2e-jest/config/jest-puppeteer.config-dev.js NODE_CONFIG_DIR=tests/e2e-jest/config wp-scripts test-e2e --config tests/e2e-jest/config/jest.config.js",
"test:e2e:jest:dev-watch": "pnpm run wp-env:config && cross-env JEST_PUPPETEER_CONFIG=tests/e2e-jest/config/jest-puppeteer.config-dev.js NODE_CONFIG_DIR=tests/e2e-jest/config wp-scripts test-e2e --config tests/e2e-jest/config/jest.config.js --watch",
"test:e2e:jest:update": "pnpm run wp-env:config && cross-env JEST_PUPPETEER_CONFIG=tests/e2e-jest/config/jest-puppeteer.config.js NODE_CONFIG_DIR=tests/e2e-jest/config wp-scripts test-e2e --config tests/e2e-jest/config/jest.config.js --updateSnapshot",
"env:start": "pnpm --filter='@woocommerce/block-library' wp-env start && ./tests/e2e/bin/test-env-setup.sh",
"env:restart": "pnpm run wp-env clean all && pnpm run wp-env start && ./tests/e2e/bin/test-env-setup.sh",
"env:stop": "pnpm run wp-env stop",
"test:help": "wp-scripts test-unit-js --help",
"test:performance": "sh ./bin/check-env.sh && pnpm playwright test --config=tests/e2e/playwright.performance.config.ts",
"test:update": "wp-scripts test-unit-js --updateSnapshot --config tests/js/jest.config.json",
"test:watch": "pnpm run test -- --watch",
"ts:check": "tsc --build",
"ts:log-errors": "npm --silent run ts:check | npx -y @bartekbp/typescript-checkstyle > checkstyle.xml",
"wp-env": "wp-env",
"wp-env:config": "./bin/wp-env-pre-config.sh",
"watch:build": "pnpm --if-present --workspace-concurrency=Infinity --filter=\"$npm_package_name...\" --parallel '/^watch:build:project:.*$/'",
"watch:build:project": "pnpm --if-present run '/^watch:build:project:.*$/'",
"watch:build:project:bundle": "wireit"
},
"devDependencies": {
"@actions/core": "1.10.0",
"@actions/github": "5.1.1",
"@automattic/color-studio": "2.5.0",
"@babel/cli": "7.23.0",
"@babel/core": "7.23.2",
"@babel/plugin-proposal-class-properties": "7.18.6",
"@babel/plugin-proposal-optional-chaining": "7.21.0",
"@babel/plugin-syntax-jsx": "7.22.5",
"@babel/polyfill": "7.12.1",
"@babel/preset-react": "7.23.3",
"@babel/preset-typescript": "7.23.2",
"@bartekbp/typescript-checkstyle": "5.0.0",
"@octokit/action": "5.0.2",
"@octokit/graphql": "5.0.5",
"@playwright/test": "^1.40.1",
"@storybook/addon-a11y": "7.5.2",
"@storybook/addon-actions": "^7.6.4",
"@storybook/addon-docs": "^7.6.4",
"@storybook/addon-essentials": "7.5.2",
"@storybook/addon-links": "7.5.2",
"@storybook/addon-storysource": "7.5.2",
"@storybook/addon-styling-webpack": "^0.0.5",
"@storybook/addons": "7.5.2",
"@storybook/client-api": "7.5.2",
"@storybook/preview-api": "^7.6.4",
"@storybook/react": "7.5.2",
"@storybook/react-webpack5": "^7.6.4",
"@testing-library/dom": "9.3.3",
"@testing-library/jest-dom": "5.16.5",
"@testing-library/react": "12.1.5",
"@testing-library/react-hooks": "7.0.2",
"@testing-library/user-event": "13.5.0",
"@types/classnames": "2.3.0",
"@types/dinero.js": "1.9.0",
"@types/dompurify": "2.3.4",
"@types/gtag.js": "0.0.10",
"@types/jest": "27.5.2",
"@types/jest-environment-puppeteer": "5.0.2",
"@types/jquery": "3.5.14",
"@types/lodash": "4.14.182",
"@types/prop-types": "^15.7.11",
"@types/puppeteer": "5.4.6",
"@types/react": "^17.0.71",
"@types/react-dom": "18.0.10",
"@types/react-transition-group": "^4.4.10",
"@types/wordpress__block-editor": "6.0.6",
"@types/wordpress__blocks": "11.0.9",
"@types/wordpress__components": "^23.0.10",
"@types/wordpress__core-data": "^2.4.5",
"@types/wordpress__data": "^6.0.2",
"@types/wordpress__data-controls": "2.2.0",
"@types/wordpress__editor": "^13.6.7",
"@types/wordpress__notices": "^3.27.6",
"@types/wordpress__wordcount": "^2.4.5",
"@typescript-eslint/eslint-plugin": "5.56.0",
"@typescript-eslint/parser": "5.56.0",
"@woocommerce/api": "0.2.0",
"@woocommerce/data": "workspace:*",
"@woocommerce/e2e-utils": "workspace:*",
"@woocommerce/eslint-plugin": "workspace:*",
"@woocommerce/woocommerce-rest-api": "1.0.1",
"@wordpress/api-fetch": "6.21.0",
"@wordpress/babel-preset-default": "7.28.0",
"@wordpress/base-styles": "4.35.0",
"@wordpress/block-editor": "8.2.0",
"@wordpress/blocks": "11.1.5",
"@wordpress/browserslist-config": "5.21.0",
"@wordpress/components": "19.17.0",
"@wordpress/core-data": "5.5.0",
"@wordpress/data": "6.15.0",
"@wordpress/data-controls": "2.2.7",
"@wordpress/date": "4.44.0",
"@wordpress/dependency-extraction-webpack-plugin": "4.28.0",
"@wordpress/dom": "3.27.0",
"@wordpress/dom-ready": "3.27.0",
"@wordpress/e2e-test-utils": "10.12.0",
"@wordpress/e2e-test-utils-playwright": "wp-6.5",
"@wordpress/e2e-tests": "^4.9.2",
"@wordpress/element": "5.22.0",
"@wordpress/env": "8.2.0",
"@wordpress/html-entities": "3.24.0",
"@wordpress/i18n": "4.45.0",
"@wordpress/is-shallow-equal": "4.24.0",
"@wordpress/postcss-plugins-preset": "1.6.0",
"@wordpress/postcss-themes": "1.0.5",
"@wordpress/prettier-config": "1.4.0",
"@wordpress/scripts": "24.6.0",
"@wordpress/stylelint-config": "^21.36.0",
"autoprefixer": "10.4.14",
"axios": "0.27.2",
"babel-jest": "^29.7.0",
"babel-plugin-explicit-exports-references": "^1.0.2",
"babel-plugin-react-docgen": "4.2.1",
"babel-plugin-transform-react-remove-prop-types": "0.4.24",
"chalk": "4.1.2",
"circular-dependency-plugin": "5.2.2",
"commander": "11.0.0",
"copy-webpack-plugin": "11.0.0",
"core-js": "3.25.0",
"create-file-webpack": "1.0.2",
"cross-env": "7.0.3",
"css-loader": "^6.8.1",
"cssnano": "5.1.12",
"deep-freeze": "0.0.1",
"dotenv": "^16.3.1",
"eslint-import-resolver-typescript": "3.6.1",
"eslint-import-resolver-webpack": "0.13.2",
"eslint-plugin-import": "2.28.1",
"eslint-plugin-playwright": "1.6.0",
"eslint-plugin-rulesdir": "^0.2.2",
"eslint-plugin-storybook": "^0.6.15",
"eslint-plugin-woocommerce": "file:bin/eslint-plugin-woocommerce",
"eslint-plugin-you-dont-need-lodash-underscore": "6.12.0",
"expect-puppeteer": "6.1.1",
"fast-xml-parser": "4.2.5",
"fs-extra": "11.1.1",
"gh-pages": "4.0.0",
"github-label-sync": "^2.3.1",
"glob": "7.2.3",
"glob-promise": "4.2.2",
"handlebars": "^4.7.8",
"ignore-loader": "0.1.2",
"jest": "^29.7.0",
"jest-circus": "27.5.1",
"jest-environment-puppeteer": "6.1.1",
"jest-fetch-mock": "3.0.3",
"jest-html-reporters": "3.0.10",
"json2md": "1.12.0",
"lint-staged": "13.2.0",
"lodash": "4.17.21",
"markdown-it": "13.0.1",
"merge-config": "2.0.0",
"mini-css-extract-plugin": "2.7.6",
"patch-package": "6.4.7",
"postcss": "8.4.32",
"postcss-color-function": "4.1.0",
"postcss-loader": "4.3.0",
"prettier": "npm:wp-prettier@^2.8.5",
"progress-bar-webpack-plugin": "2.1.0",
"promptly": "3.2.0",
"puppeteer": "17.1.3",
"react-docgen": "5.4.3",
"react-docgen-typescript-plugin": "^1.0.5",
"react-test-renderer": "17.0.2",
"redux": "4.2.1",
"request-promise": "4.2.6",
"rimraf": "5.0.5",
"rtlcss": "^4.1.1",
"sass-loader": "^10.5.0",
"storybook": "^7.6.4",
"storybook-addon-react-docgen": "1.2.44",
"stylelint": "^14.16.1",
"terser-webpack-plugin": "5.3.6",
"typescript": "5.3.2",
"utility-types": "3.10.0",
"webpack": "5.91.0",
"webpack-bundle-analyzer": "4.7.0",
"webpack-cli": "5.1.4",
"wireit": "0.14.3",
"wp-types": "3.63.0",
"zenhub-api": "0.2.0"
},
"engines": {
"node": "^20.11.1",
"pnpm": "^8.12.1"
},
"dependencies": {
"@ariakit/react": "^0.4.4",
"@dnd-kit/core": "^6.1.0",
"@dnd-kit/modifiers": "^6.0.1",
"@dnd-kit/sortable": "^7.0.2",
"@dnd-kit/utilities": "^3.2.2",
"@emotion/styled": "^11.11.0",
"@preact/signals": "^1.2.2",
"@woocommerce/tracks": "workspace:^",
"@wordpress/autop": "3.16.0",
"@wordpress/compose": "5.5.0",
"@wordpress/deprecated": "3.41.0",
"@wordpress/icons": "9.36.0",
"@wordpress/notices": "3.12.0",
"@wordpress/plugins": "4.10.0",
"@wordpress/primitives": "3.0.4",
"@wordpress/server-side-render": "3.10.0",
"@wordpress/style-engine": "^1.30.0",
"@wordpress/url": "3.13.0",
"@wordpress/wordcount": "3.47.0",
"change-case": "^4.1.2",
"classnames": "^2.3.2",
"compare-versions": "4.1.3",
"config": "3.3.7",
"dataloader": "2.2.2",
"deepsignal": "1.3.6",
"dinero.js": "1.9.1",
"dompurify": "^2.4.7",
"downshift": "6.1.7",
"fast-deep-equal": "^3.1.3",
"fast-sort": "^3.4.0",
"html-react-parser": "3.0.4",
"postcode-validator": "3.8.15",
"preact": "^10.19.3",
"prop-types": "^15.8.1",
"react-number-format": "4.9.3",
"react-transition-group": "^4.4.5",
"request": "2.88.2",
"trim-html": "0.1.9",
"use-debounce": "9.0.4",
"usehooks-ts": "^2.9.1",
"wordpress-components": "npm:@wordpress/components@14.2.0"
},
"peerDependencies": {
"react": "^17.0.0",
"react-dom": "^17.0.0"
},
"optionalDependencies": {
"ndb": "1.1.5"
},
"lint-staged": {
"*.scss": [
"pnpm run lint:css"
],
"*.{js,ts,tsx}": [
"prettier --write",
"pnpm run lint:js"
],
"*.php": [
"php -d display_errors=1 -l",
"composer run-script phpcs"
],
"*.md": [
"pnpm run lint:md:docs"
]
},
"files": [
"build",
"blocks.ini"
],
"config": {
"ci": {
"lint": {
"command": "lint",
"changes": [
"assets/**/*.{js,ts,tsx,scss}",
"packages/**/*.{js,ts,tsx,scss}",
"tests/**/*.{js,ts,tsx,scss}"
]
},
"tests": [
{
"name": "JavaScript",
"command": "test:js",
"changes": [
"jest.config.js",
"webpack.config.js",
"babel.config.js",
"tsconfig.json",
"assets/**/*.{js,ts,tsx,scss}",
"packages/**/*.{js,ts,tsx,scss}"
],
"cascade": "test:js"
}
]
}
},
"wireit": {
"build:project:bundle": {
"command": "webpack",
"clean": "if-file-deleted",
"env": {
"NODE_ENV": {
"external": true,
"default": "production"
},
"BABEL_ENV": {
"external": true,
"default": "default"
},
"WOOCOMMERCE_BLOCKS_PHASE": {
"external": true
}
},
"files": [
"webpack.config.js",
"bin/webpack-*.js",
"tsconfig.json",
"tsconfig.base.json",
"babel.config.js",
"assets",
"packages"
],
"output": [
"build",
"blocks.ini"
],
"dependencies": [
"dependencyOutputs"
]
},
"watch:build:project:bundle": {
"command": "webpack --watch",
"service": true
},
"dependencyOutputs": {
"allowUsuallyExcludedPaths": true,
"files": [
"node_modules/@woocommerce/eslint-plugin/configs",
"node_modules/@woocommerce/eslint-plugin/rules",
"node_modules/@woocommerce/eslint-plugin/index.js",
"node_modules/@woocommerce/data/build",
"node_modules/@woocommerce/data/build-module",
"node_modules/@woocommerce/data/build-types",
"node_modules/@woocommerce/tracks/build",
"node_modules/@woocommerce/tracks/build-module",
"node_modules/@woocommerce/tracks/build-types",
"package.json"
]
}
}
}