From f6352a1010117000ce4ca9f71315b67b1ec8e396 Mon Sep 17 00:00:00 2001 From: Taylor Jones Date: Thu, 28 Oct 2021 10:40:48 -0500 Subject: [PATCH 1/5] chore(release): v10.47.0 (#9981) --- packages/carbon-react/package.json | 12 +- packages/cli/package.json | 2 +- packages/colors/package.json | 6 +- packages/components/package.json | 12 +- packages/elements/package.json | 18 +-- packages/grid/package.json | 6 +- packages/icon-build-helpers/package.json | 4 +- packages/icon-helpers/package.json | 4 +- packages/icons-handlebars/package.json | 6 +- packages/icons-react/package.json | 8 +- packages/icons-vue/package.json | 6 +- packages/icons/package.json | 6 +- packages/layout/package.json | 6 +- packages/motion/package.json | 4 +- packages/pictograms-react/package.json | 8 +- packages/pictograms/package.json | 4 +- packages/react/package.json | 10 +- packages/sketch/package.json | 12 +- packages/styles/package.json | 16 +-- packages/test-utils/package.json | 2 +- packages/themes/package.json | 12 +- packages/type/package.json | 8 +- yarn.lock | 164 +++++++++++------------ 23 files changed, 168 insertions(+), 168 deletions(-) diff --git a/packages/carbon-react/package.json b/packages/carbon-react/package.json index 970d576ec904..b40614d6c588 100644 --- a/packages/carbon-react/package.json +++ b/packages/carbon-react/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/react", "description": "React components for the Carbon Design System", - "version": "0.8.0-rc.0", + "version": "0.8.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -43,11 +43,11 @@ }, "dependencies": { "@carbon/feature-flags": "^0.6.0", - "@carbon/icons-react": "^10.41.0", - "@carbon/styles": "^0.8.0-rc.0", + "@carbon/icons-react": "^10.42.0", + "@carbon/styles": "^0.8.0", "@carbon/telemetry": "0.0.0-alpha.6", - "carbon-components": "^10.47.0-rc.0", - "carbon-components-react": "^7.47.0-rc.0", + "carbon-components": "^10.47.0", + "carbon-components-react": "^7.47.0", "carbon-icons": "^7.0.7" }, "devDependencies": { @@ -58,7 +58,7 @@ "@babel/plugin-transform-react-constant-elements": "^7.14.5", "@babel/preset-env": "^7.14.7", "@babel/preset-react": "^7.14.5", - "@carbon/themes": "^10.46.0-rc.0", + "@carbon/themes": "^10.46.0", "@rollup/plugin-babel": "^5.3.0", "@rollup/plugin-commonjs": "^18.0.0", "@rollup/plugin-node-resolve": "^11.2.1", diff --git a/packages/cli/package.json b/packages/cli/package.json index df489105dbff..4ad29d89c3b3 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/cli", "description": "Task automation for working with the Carbon Design System", - "version": "10.30.0", + "version": "10.31.0", "license": "Apache-2.0", "bin": { "carbon-cli": "./bin/carbon-cli.js" diff --git a/packages/colors/package.json b/packages/colors/package.json index d6b74622bab2..2cef638980d8 100644 --- a/packages/colors/package.json +++ b/packages/colors/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/colors", "description": "Colors for digital and software products using the Carbon Design System", - "version": "10.33.0", + "version": "10.34.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -36,10 +36,10 @@ "clean": "rimraf css es lib umd scss index.scss" }, "devDependencies": { - "@carbon/cli": "^10.30.0", + "@carbon/cli": "^10.31.0", "@carbon/cli-reporter": "^10.5.0", "@carbon/scss-generator": "^10.13.0", - "@carbon/test-utils": "^10.19.0", + "@carbon/test-utils": "^10.20.0", "change-case": "^4.1.1", "fs-extra": "^8.1.0", "node-sass": "^6.0.1", diff --git a/packages/components/package.json b/packages/components/package.json index 6d9be19cc748..4b5948396f0a 100644 --- a/packages/components/package.json +++ b/packages/components/package.json @@ -1,7 +1,7 @@ { "name": "carbon-components", "description": "The Carbon Design System is IBM’s open-source design system for products and experiences.", - "version": "10.47.0-rc.0", + "version": "10.47.0", "license": "Apache-2.0", "main": "umd/index.js", "module": "es/index.js", @@ -80,11 +80,11 @@ "@babel/preset-env": "^7.14.7", "@babel/preset-react": "^7.14.5", "@babel/runtime": "^7.14.6", - "@carbon/cli": "^10.30.0", - "@carbon/elements": "^10.46.0-rc.0", - "@carbon/icons-handlebars": "^10.41.0", - "@carbon/icons-react": "^10.41.0", - "@carbon/test-utils": "^10.19.0", + "@carbon/cli": "^10.31.0", + "@carbon/elements": "^10.46.0", + "@carbon/icons-handlebars": "^10.42.0", + "@carbon/icons-react": "^10.42.0", + "@carbon/test-utils": "^10.20.0", "@frctl/fractal": "^1.1.0", "@rollup/plugin-babel": "^5.3.0", "@rollup/plugin-commonjs": "^18.0.0", diff --git a/packages/elements/package.json b/packages/elements/package.json index f19aa2f413d2..f999a300f23b 100644 --- a/packages/elements/package.json +++ b/packages/elements/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/elements", "description": "A collection of design elements in code for the IBM Design Language", - "version": "10.46.0-rc.0", + "version": "10.46.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -35,17 +35,17 @@ "clean": "rimraf es lib umd && node tasks/clean.js" }, "dependencies": { - "@carbon/colors": "^10.33.0", - "@carbon/grid": "^10.39.0-rc.0", - "@carbon/icons": "^10.41.0", + "@carbon/colors": "^10.34.0", + "@carbon/grid": "^10.39.0", + "@carbon/icons": "^10.42.0", "@carbon/import-once": "^10.6.0", - "@carbon/layout": "^10.34.0-rc.0", - "@carbon/motion": "^10.25.0", - "@carbon/themes": "^10.46.0-rc.0", - "@carbon/type": "^10.38.0-rc.0" + "@carbon/layout": "^10.34.0", + "@carbon/motion": "^10.26.0", + "@carbon/themes": "^10.46.0", + "@carbon/type": "^10.38.0" }, "devDependencies": { - "@carbon/cli": "^10.30.0", + "@carbon/cli": "^10.31.0", "fs-extra": "^8.1.0", "klaw-sync": "^6.0.0", "replace-in-file": "^3.4.2", diff --git a/packages/grid/package.json b/packages/grid/package.json index f7620788423a..5683bec368c5 100644 --- a/packages/grid/package.json +++ b/packages/grid/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/grid", "description": "Grid for digital and software products using the Carbon Design System", - "version": "10.39.0-rc.0", + "version": "10.39.0", "license": "Apache-2.0", "repository": { "type": "git", @@ -33,10 +33,10 @@ }, "dependencies": { "@carbon/import-once": "^10.6.0", - "@carbon/layout": "^10.34.0-rc.0" + "@carbon/layout": "^10.34.0" }, "devDependencies": { - "@carbon/cli": "^10.30.0", + "@carbon/cli": "^10.31.0", "rimraf": "^3.0.0" }, "eyeglass": { diff --git a/packages/icon-build-helpers/package.json b/packages/icon-build-helpers/package.json index 7480141818aa..02155cd8a0e3 100644 --- a/packages/icon-build-helpers/package.json +++ b/packages/icon-build-helpers/package.json @@ -2,7 +2,7 @@ "name": "@carbon/icon-build-helpers", "private": true, "description": "Build helpers for the Carbon Design System icon library", - "version": "0.29.0", + "version": "0.30.0", "license": "Apache-2.0", "main": "src/index.js", "repository": { @@ -29,7 +29,7 @@ "@babel/template": "^7.14.5", "@babel/types": "^7.14.5", "@carbon/cli-reporter": "^10.5.0", - "@carbon/icon-helpers": "^10.24.0", + "@carbon/icon-helpers": "^10.25.0", "@rollup/plugin-babel": "^5.3.0", "@rollup/plugin-replace": "^2.4.2", "browserslist-config-carbon": "^10.6.1", diff --git a/packages/icon-helpers/package.json b/packages/icon-helpers/package.json index a099dd8003cf..333093613652 100644 --- a/packages/icon-helpers/package.json +++ b/packages/icon-helpers/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/icon-helpers", "description": "Helpers used alongside icons for digital and software products using the Carbon Design System", - "version": "10.24.0", + "version": "10.25.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -33,7 +33,7 @@ "clean": "rimraf es lib umd" }, "devDependencies": { - "@carbon/cli": "^10.30.0", + "@carbon/cli": "^10.31.0", "rimraf": "^3.0.0" }, "sideEffects": false diff --git a/packages/icons-handlebars/package.json b/packages/icons-handlebars/package.json index 8367378b50c1..27c011389462 100644 --- a/packages/icons-handlebars/package.json +++ b/packages/icons-handlebars/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/icons-handlebars", "description": "Handlebars helpers for IBM Design Language icons in digital and software products using the Carbon Design System", - "version": "10.41.0", + "version": "10.42.0", "license": "Apache-2.0", "main": "index.js", "repository": { @@ -26,8 +26,8 @@ "handlebars": "^4.0.12" }, "dependencies": { - "@carbon/icon-helpers": "^10.24.0", - "@carbon/icons": "^10.41.0" + "@carbon/icon-helpers": "^10.25.0", + "@carbon/icons": "^10.42.0" }, "devDependencies": { "handlebars": "^4.0.12" diff --git a/packages/icons-react/package.json b/packages/icons-react/package.json index 905a566d11d1..bc2bd2143506 100644 --- a/packages/icons-react/package.json +++ b/packages/icons-react/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/icons-react", "description": "React components for icons in digital and software products using the Carbon Design System", - "version": "10.41.0", + "version": "10.42.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -38,13 +38,13 @@ "react": ">=16" }, "dependencies": { - "@carbon/icon-helpers": "^10.24.0", + "@carbon/icon-helpers": "^10.25.0", "@carbon/telemetry": "0.0.0-alpha.6", "prop-types": "^15.7.2" }, "devDependencies": { - "@carbon/icon-build-helpers": "^0.29.0", - "@carbon/icons": "^10.41.0", + "@carbon/icon-build-helpers": "^0.30.0", + "@carbon/icons": "^10.42.0", "rimraf": "^3.0.2" }, "sideEffects": false diff --git a/packages/icons-vue/package.json b/packages/icons-vue/package.json index e006fe9c40f0..2038a3e9967b 100644 --- a/packages/icons-vue/package.json +++ b/packages/icons-vue/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/icons-vue", "description": "Vue components for icons in digital and software products using the Carbon Design System", - "version": "10.41.0", + "version": "10.42.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -28,11 +28,11 @@ "clean": "rimraf es lib" }, "dependencies": { - "@carbon/icon-helpers": "^10.24.0" + "@carbon/icon-helpers": "^10.25.0" }, "devDependencies": { "@carbon/cli-reporter": "^10.5.0", - "@carbon/icons": "^10.41.0", + "@carbon/icons": "^10.42.0", "fs-extra": "^8.1.0", "prettier": "^2.2.1", "rimraf": "^3.0.0", diff --git a/packages/icons/package.json b/packages/icons/package.json index a898f4148496..73773bbcb868 100644 --- a/packages/icons/package.json +++ b/packages/icons/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/icons", "description": "Icons for digital and software products using the Carbon Design System", - "version": "10.41.0", + "version": "10.42.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -41,8 +41,8 @@ "svgson": "^5.2.1" }, "devDependencies": { - "@carbon/cli": "^10.30.0", - "@carbon/icon-build-helpers": "^0.29.0", + "@carbon/cli": "^10.31.0", + "@carbon/icon-build-helpers": "^0.30.0", "rimraf": "^3.0.2" } } diff --git a/packages/layout/package.json b/packages/layout/package.json index 6b4cebabf9b4..e21097e828ce 100644 --- a/packages/layout/package.json +++ b/packages/layout/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/layout", "description": "Layout helpers for digital and software products using the Carbon Design System", - "version": "10.34.0-rc.0", + "version": "10.34.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -29,10 +29,10 @@ "clean": "rimraf es lib umd scss/generated scss/modules/generated" }, "devDependencies": { - "@carbon/cli": "^10.30.0", + "@carbon/cli": "^10.31.0", "@carbon/cli-reporter": "^10.5.0", "@carbon/scss-generator": "^10.13.0", - "@carbon/test-utils": "^10.19.0", + "@carbon/test-utils": "^10.20.0", "core-js": "^3.16.0", "rimraf": "^3.0.0" }, diff --git a/packages/motion/package.json b/packages/motion/package.json index 535a47efa42f..72b9fae2acae 100644 --- a/packages/motion/package.json +++ b/packages/motion/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/motion", "description": "Motion helpers for digital and software products using the Carbon Design System", - "version": "10.25.0", + "version": "10.26.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -29,7 +29,7 @@ "clean": "rimraf es lib umd" }, "devDependencies": { - "@carbon/cli": "^10.30.0", + "@carbon/cli": "^10.31.0", "rimraf": "^3.0.0" }, "eyeglass": { diff --git a/packages/pictograms-react/package.json b/packages/pictograms-react/package.json index 25614640b315..32d274eb29c7 100644 --- a/packages/pictograms-react/package.json +++ b/packages/pictograms-react/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/pictograms-react", "description": "React components for pictograms in digital and software products using the Carbon Design System", - "version": "11.19.0", + "version": "11.20.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -37,13 +37,13 @@ "react": ">=16" }, "dependencies": { - "@carbon/icon-helpers": "^10.24.0", + "@carbon/icon-helpers": "^10.25.0", "@carbon/telemetry": "0.0.0-alpha.6", "prop-types": "^15.7.2" }, "devDependencies": { - "@carbon/icon-build-helpers": "^0.29.0", - "@carbon/pictograms": "^11.19.0" + "@carbon/icon-build-helpers": "^0.30.0", + "@carbon/pictograms": "^11.20.0" }, "sideEffects": false } diff --git a/packages/pictograms/package.json b/packages/pictograms/package.json index a5d85a129093..613aea6060c9 100644 --- a/packages/pictograms/package.json +++ b/packages/pictograms/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/pictograms", "description": "Pictograms for digital and software products using the Carbon Design System", - "version": "11.19.0", + "version": "11.20.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -31,7 +31,7 @@ "prepublishOnly": "yarn build" }, "devDependencies": { - "@carbon/icon-build-helpers": "^0.29.0", + "@carbon/icon-build-helpers": "^0.30.0", "rimraf": "^3.0.0" } } diff --git a/packages/react/package.json b/packages/react/package.json index cc2f603286c1..8291045ed7a0 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,7 +1,7 @@ { "name": "carbon-components-react", "description": "The Carbon Design System is IBM’s open-source design system for products and experiences.", - "version": "7.47.0-rc.0", + "version": "7.47.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -48,8 +48,8 @@ "dependencies": { "@babel/runtime": "^7.14.6", "@carbon/feature-flags": "^0.6.0", - "@carbon/icons-react": "^10.41.0", - "@carbon/layout": "^10.34.0-rc.0", + "@carbon/icons-react": "^10.42.0", + "@carbon/layout": "^10.34.0", "@carbon/telemetry": "0.0.0-alpha.6", "classnames": "2.3.1", "copy-to-clipboard": "^3.3.1", @@ -78,7 +78,7 @@ "@babel/plugin-transform-object-assign": "^7.14.5", "@babel/preset-env": "^7.14.7", "@babel/preset-react": "^7.14.5", - "@carbon/test-utils": "^10.19.0", + "@carbon/test-utils": "^10.20.0", "@cypress/react": "^5.4.0", "@cypress/webpack-dev-server": "^1.1.5", "@percy/cypress": "^3.1.1", @@ -103,7 +103,7 @@ "babel-plugin-react-docgen": "^4.2.1", "babel-plugin-transform-inline-environment-variables": "^0.4.3", "browserslist-config-carbon": "^10.6.1", - "carbon-components": "^10.47.0-rc.0", + "carbon-components": "^10.47.0", "carbon-icons": "^7.0.5", "chalk": "^4.1.1", "cli-table": "^0.3.0", diff --git a/packages/sketch/package.json b/packages/sketch/package.json index 67288cf88067..de84f3c4b458 100644 --- a/packages/sketch/package.json +++ b/packages/sketch/package.json @@ -2,7 +2,7 @@ "name": "@carbon/sketch", "private": true, "description": "Tooling for generating a sketch plugin to bring code to design", - "version": "10.45.0-rc.0", + "version": "10.45.0", "license": "Apache-2.0", "repository": { "type": "git", @@ -28,11 +28,11 @@ "skpm:link": "skpm-link" }, "dependencies": { - "@carbon/colors": "^10.33.0", - "@carbon/icon-helpers": "^10.24.0", - "@carbon/icons": "^10.41.0", - "@carbon/themes": "^10.46.0-rc.0", - "@carbon/type": "^10.38.0-rc.0", + "@carbon/colors": "^10.34.0", + "@carbon/icon-helpers": "^10.25.0", + "@carbon/icons": "^10.42.0", + "@carbon/themes": "^10.46.0", + "@carbon/type": "^10.38.0", "@skpm/builder": "^0.7.0", "color-string": "^1.5.3", "core-js": "^3.16.0", diff --git a/packages/styles/package.json b/packages/styles/package.json index 8c2fc256fd84..8cf18bf7ed17 100644 --- a/packages/styles/package.json +++ b/packages/styles/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/styles", "description": "Styles for the Carbon Design System", - "version": "0.8.0-rc.0", + "version": "0.8.0", "license": "Apache-2.0", "repository": { "type": "git", @@ -20,17 +20,17 @@ "access": "public" }, "dependencies": { - "@carbon/colors": "^10.33.0", + "@carbon/colors": "^10.34.0", "@carbon/feature-flags": "^0.6.0", - "@carbon/grid": "^10.39.0-rc.0", - "@carbon/layout": "^10.34.0-rc.0", - "@carbon/motion": "^10.25.0", - "@carbon/themes": "^10.46.0-rc.0", - "@carbon/type": "^10.38.0-rc.0", + "@carbon/grid": "^10.39.0", + "@carbon/layout": "^10.34.0", + "@carbon/motion": "^10.26.0", + "@carbon/themes": "^10.46.0", + "@carbon/type": "^10.38.0", "@ibm/plex": "6.0.0-next.6" }, "devDependencies": { - "@carbon/test-utils": "^10.19.0", + "@carbon/test-utils": "^10.20.0", "css": "^3.0.0" } } diff --git a/packages/test-utils/package.json b/packages/test-utils/package.json index 872b2c762fee..74616598ec14 100644 --- a/packages/test-utils/package.json +++ b/packages/test-utils/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/test-utils", "private": true, - "version": "10.19.0", + "version": "10.20.0", "license": "Apache-2.0", "repository": { "type": "git", diff --git a/packages/themes/package.json b/packages/themes/package.json index e30739521f8a..d5ea57f6bf1b 100644 --- a/packages/themes/package.json +++ b/packages/themes/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/themes", "description": "Themes for applying color in the Carbon Design System", - "version": "10.46.0-rc.0", + "version": "10.46.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -29,18 +29,18 @@ "build": "yarn clean && carbon-cli bundle src/index.js --name CarbonThemes && babel-node --presets '@babel/preset-env' tasks/build.js && carbon-cli check \"scss/*.scss\"" }, "dependencies": { - "@carbon/colors": "^10.33.0", - "@carbon/layout": "^10.34.0-rc.0", - "@carbon/type": "^10.38.0-rc.0", + "@carbon/colors": "^10.34.0", + "@carbon/layout": "^10.34.0", + "@carbon/type": "^10.38.0", "color": "^3.1.2" }, "devDependencies": { "@babel/node": "^7.14.2", "@babel/preset-env": "^7.14.2", - "@carbon/cli": "^10.30.0", + "@carbon/cli": "^10.31.0", "@carbon/cli-reporter": "^10.5.0", "@carbon/scss-generator": "^10.13.0", - "@carbon/test-utils": "^10.19.0", + "@carbon/test-utils": "^10.20.0", "change-case": "^4.1.1", "core-js": "^3.16.0", "fs-extra": "^8.1.0", diff --git a/packages/type/package.json b/packages/type/package.json index 47c17a3c5e57..690c7c995afd 100644 --- a/packages/type/package.json +++ b/packages/type/package.json @@ -1,7 +1,7 @@ { "name": "@carbon/type", "description": "Typography for digital and software products using the Carbon Design System", - "version": "10.38.0-rc.0", + "version": "10.38.0", "license": "Apache-2.0", "main": "lib/index.js", "module": "es/index.js", @@ -38,11 +38,11 @@ }, "dependencies": { "@carbon/import-once": "^10.6.0", - "@carbon/layout": "^10.34.0-rc.0" + "@carbon/layout": "^10.34.0" }, "devDependencies": { - "@carbon/cli": "^10.30.0", - "@carbon/test-utils": "^10.19.0", + "@carbon/cli": "^10.31.0", + "@carbon/test-utils": "^10.20.0", "change-case": "^4.1.1", "rimraf": "^3.0.0" }, diff --git a/yarn.lock b/yarn.lock index 8b3cbfaf09b8..d8378eab9bf9 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1707,7 +1707,7 @@ __metadata: languageName: unknown linkType: soft -"@carbon/cli@^10.30.0, @carbon/cli@workspace:packages/cli": +"@carbon/cli@^10.31.0, @carbon/cli@workspace:packages/cli": version: 0.0.0-use.local resolution: "@carbon/cli@workspace:packages/cli" dependencies: @@ -1753,14 +1753,14 @@ __metadata: languageName: unknown linkType: soft -"@carbon/colors@^10.33.0, @carbon/colors@workspace:packages/colors": +"@carbon/colors@^10.34.0, @carbon/colors@workspace:packages/colors": version: 0.0.0-use.local resolution: "@carbon/colors@workspace:packages/colors" dependencies: - "@carbon/cli": ^10.30.0 + "@carbon/cli": ^10.31.0 "@carbon/cli-reporter": ^10.5.0 "@carbon/scss-generator": ^10.13.0 - "@carbon/test-utils": ^10.19.0 + "@carbon/test-utils": ^10.20.0 change-case: ^4.1.1 fs-extra: ^8.1.0 node-sass: ^6.0.1 @@ -1768,19 +1768,19 @@ __metadata: languageName: unknown linkType: soft -"@carbon/elements@^10.46.0-rc.0, @carbon/elements@workspace:packages/elements": +"@carbon/elements@^10.46.0, @carbon/elements@workspace:packages/elements": version: 0.0.0-use.local resolution: "@carbon/elements@workspace:packages/elements" dependencies: - "@carbon/cli": ^10.30.0 - "@carbon/colors": ^10.33.0 - "@carbon/grid": ^10.39.0-rc.0 - "@carbon/icons": ^10.41.0 + "@carbon/cli": ^10.31.0 + "@carbon/colors": ^10.34.0 + "@carbon/grid": ^10.39.0 + "@carbon/icons": ^10.42.0 "@carbon/import-once": ^10.6.0 - "@carbon/layout": ^10.34.0-rc.0 - "@carbon/motion": ^10.25.0 - "@carbon/themes": ^10.46.0-rc.0 - "@carbon/type": ^10.38.0-rc.0 + "@carbon/layout": ^10.34.0 + "@carbon/motion": ^10.26.0 + "@carbon/themes": ^10.46.0 + "@carbon/type": ^10.38.0 fs-extra: ^8.1.0 klaw-sync: ^6.0.0 replace-in-file: ^3.4.2 @@ -1809,18 +1809,18 @@ __metadata: languageName: unknown linkType: soft -"@carbon/grid@^10.39.0-rc.0, @carbon/grid@workspace:packages/grid": +"@carbon/grid@^10.39.0, @carbon/grid@workspace:packages/grid": version: 0.0.0-use.local resolution: "@carbon/grid@workspace:packages/grid" dependencies: - "@carbon/cli": ^10.30.0 + "@carbon/cli": ^10.31.0 "@carbon/import-once": ^10.6.0 - "@carbon/layout": ^10.34.0-rc.0 + "@carbon/layout": ^10.34.0 rimraf: ^3.0.0 languageName: unknown linkType: soft -"@carbon/icon-build-helpers@^0.29.0, @carbon/icon-build-helpers@workspace:packages/icon-build-helpers": +"@carbon/icon-build-helpers@^0.30.0, @carbon/icon-build-helpers@workspace:packages/icon-build-helpers": version: 0.0.0-use.local resolution: "@carbon/icon-build-helpers@workspace:packages/icon-build-helpers" dependencies: @@ -1831,7 +1831,7 @@ __metadata: "@babel/template": ^7.14.5 "@babel/types": ^7.14.5 "@carbon/cli-reporter": ^10.5.0 - "@carbon/icon-helpers": ^10.24.0 + "@carbon/icon-helpers": ^10.25.0 "@rollup/plugin-babel": ^5.3.0 "@rollup/plugin-replace": ^2.4.2 browserslist-config-carbon: ^10.6.1 @@ -1854,11 +1854,11 @@ __metadata: languageName: unknown linkType: soft -"@carbon/icon-helpers@^10.24.0, @carbon/icon-helpers@workspace:packages/icon-helpers": +"@carbon/icon-helpers@^10.25.0, @carbon/icon-helpers@workspace:packages/icon-helpers": version: 0.0.0-use.local resolution: "@carbon/icon-helpers@workspace:packages/icon-helpers" dependencies: - "@carbon/cli": ^10.30.0 + "@carbon/cli": ^10.31.0 rimraf: ^3.0.0 languageName: unknown linkType: soft @@ -1870,25 +1870,25 @@ __metadata: languageName: node linkType: hard -"@carbon/icons-handlebars@^10.41.0, @carbon/icons-handlebars@workspace:packages/icons-handlebars": +"@carbon/icons-handlebars@^10.42.0, @carbon/icons-handlebars@workspace:packages/icons-handlebars": version: 0.0.0-use.local resolution: "@carbon/icons-handlebars@workspace:packages/icons-handlebars" dependencies: - "@carbon/icon-helpers": ^10.24.0 - "@carbon/icons": ^10.41.0 + "@carbon/icon-helpers": ^10.25.0 + "@carbon/icons": ^10.42.0 handlebars: ^4.0.12 peerDependencies: handlebars: ^4.0.12 languageName: unknown linkType: soft -"@carbon/icons-react@^10.41.0, @carbon/icons-react@workspace:packages/icons-react": +"@carbon/icons-react@^10.42.0, @carbon/icons-react@workspace:packages/icons-react": version: 0.0.0-use.local resolution: "@carbon/icons-react@workspace:packages/icons-react" dependencies: - "@carbon/icon-build-helpers": ^0.29.0 - "@carbon/icon-helpers": ^10.24.0 - "@carbon/icons": ^10.41.0 + "@carbon/icon-build-helpers": ^0.30.0 + "@carbon/icon-helpers": ^10.25.0 + "@carbon/icons": ^10.42.0 "@carbon/telemetry": 0.0.0-alpha.6 prop-types: ^15.7.2 rimraf: ^3.0.2 @@ -1912,8 +1912,8 @@ __metadata: resolution: "@carbon/icons-vue@workspace:packages/icons-vue" dependencies: "@carbon/cli-reporter": ^10.5.0 - "@carbon/icon-helpers": ^10.24.0 - "@carbon/icons": ^10.41.0 + "@carbon/icon-helpers": ^10.25.0 + "@carbon/icons": ^10.42.0 fs-extra: ^8.1.0 prettier: ^2.2.1 rimraf: ^3.0.0 @@ -1922,12 +1922,12 @@ __metadata: languageName: unknown linkType: soft -"@carbon/icons@^10.41.0, @carbon/icons@workspace:packages/icons": +"@carbon/icons@^10.42.0, @carbon/icons@workspace:packages/icons": version: 0.0.0-use.local resolution: "@carbon/icons@workspace:packages/icons" dependencies: - "@carbon/cli": ^10.30.0 - "@carbon/icon-build-helpers": ^0.29.0 + "@carbon/cli": ^10.31.0 + "@carbon/icon-build-helpers": ^0.30.0 rimraf: ^3.0.2 svgson: ^5.2.1 languageName: unknown @@ -1939,24 +1939,24 @@ __metadata: languageName: unknown linkType: soft -"@carbon/layout@^10.34.0-rc.0, @carbon/layout@workspace:packages/layout": +"@carbon/layout@^10.34.0, @carbon/layout@workspace:packages/layout": version: 0.0.0-use.local resolution: "@carbon/layout@workspace:packages/layout" dependencies: - "@carbon/cli": ^10.30.0 + "@carbon/cli": ^10.31.0 "@carbon/cli-reporter": ^10.5.0 "@carbon/scss-generator": ^10.13.0 - "@carbon/test-utils": ^10.19.0 + "@carbon/test-utils": ^10.20.0 core-js: ^3.16.0 rimraf: ^3.0.0 languageName: unknown linkType: soft -"@carbon/motion@^10.25.0, @carbon/motion@workspace:packages/motion": +"@carbon/motion@^10.26.0, @carbon/motion@workspace:packages/motion": version: 0.0.0-use.local resolution: "@carbon/motion@workspace:packages/motion" dependencies: - "@carbon/cli": ^10.30.0 + "@carbon/cli": ^10.31.0 rimraf: ^3.0.0 languageName: unknown linkType: soft @@ -1965,9 +1965,9 @@ __metadata: version: 0.0.0-use.local resolution: "@carbon/pictograms-react@workspace:packages/pictograms-react" dependencies: - "@carbon/icon-build-helpers": ^0.29.0 - "@carbon/icon-helpers": ^10.24.0 - "@carbon/pictograms": ^11.19.0 + "@carbon/icon-build-helpers": ^0.30.0 + "@carbon/icon-helpers": ^10.25.0 + "@carbon/pictograms": ^11.20.0 "@carbon/telemetry": 0.0.0-alpha.6 prop-types: ^15.7.2 peerDependencies: @@ -1975,11 +1975,11 @@ __metadata: languageName: unknown linkType: soft -"@carbon/pictograms@^11.19.0, @carbon/pictograms@workspace:packages/pictograms": +"@carbon/pictograms@^11.20.0, @carbon/pictograms@workspace:packages/pictograms": version: 0.0.0-use.local resolution: "@carbon/pictograms@workspace:packages/pictograms" dependencies: - "@carbon/icon-build-helpers": ^0.29.0 + "@carbon/icon-build-helpers": ^0.30.0 rimraf: ^3.0.0 languageName: unknown linkType: soft @@ -1996,10 +1996,10 @@ __metadata: "@babel/preset-env": ^7.14.7 "@babel/preset-react": ^7.14.5 "@carbon/feature-flags": ^0.6.0 - "@carbon/icons-react": ^10.41.0 - "@carbon/styles": ^0.8.0-rc.0 + "@carbon/icons-react": ^10.42.0 + "@carbon/styles": ^0.8.0 "@carbon/telemetry": 0.0.0-alpha.6 - "@carbon/themes": ^10.46.0-rc.0 + "@carbon/themes": ^10.46.0 "@rollup/plugin-babel": ^5.3.0 "@rollup/plugin-commonjs": ^18.0.0 "@rollup/plugin-node-resolve": ^11.2.1 @@ -2013,8 +2013,8 @@ __metadata: babel-plugin-dev-expression: ^0.2.2 babel-preset-carbon: ^0.1.0 browserslist-config-carbon: ^10.6.1 - carbon-components: ^10.47.0-rc.0 - carbon-components-react: ^7.47.0-rc.0 + carbon-components: ^10.47.0 + carbon-components-react: ^7.47.0 carbon-icons: ^7.0.7 css-loader: ^5.2.4 fs-extra: ^10.0.0 @@ -2052,11 +2052,11 @@ __metadata: version: 0.0.0-use.local resolution: "@carbon/sketch@workspace:packages/sketch" dependencies: - "@carbon/colors": ^10.33.0 - "@carbon/icon-helpers": ^10.24.0 - "@carbon/icons": ^10.41.0 - "@carbon/themes": ^10.46.0-rc.0 - "@carbon/type": ^10.38.0-rc.0 + "@carbon/colors": ^10.34.0 + "@carbon/icon-helpers": ^10.25.0 + "@carbon/icons": ^10.42.0 + "@carbon/themes": ^10.46.0 + "@carbon/type": ^10.38.0 "@skpm/builder": ^0.7.0 color-string: ^1.5.3 core-js: ^3.16.0 @@ -2067,18 +2067,18 @@ __metadata: languageName: unknown linkType: soft -"@carbon/styles@^0.8.0-rc.0, @carbon/styles@workspace:packages/styles": +"@carbon/styles@^0.8.0, @carbon/styles@workspace:packages/styles": version: 0.0.0-use.local resolution: "@carbon/styles@workspace:packages/styles" dependencies: - "@carbon/colors": ^10.33.0 + "@carbon/colors": ^10.34.0 "@carbon/feature-flags": ^0.6.0 - "@carbon/grid": ^10.39.0-rc.0 - "@carbon/layout": ^10.34.0-rc.0 - "@carbon/motion": ^10.25.0 - "@carbon/test-utils": ^10.19.0 - "@carbon/themes": ^10.46.0-rc.0 - "@carbon/type": ^10.38.0-rc.0 + "@carbon/grid": ^10.39.0 + "@carbon/layout": ^10.34.0 + "@carbon/motion": ^10.26.0 + "@carbon/test-utils": ^10.20.0 + "@carbon/themes": ^10.46.0 + "@carbon/type": ^10.38.0 "@ibm/plex": 6.0.0-next.6 css: ^3.0.0 languageName: unknown @@ -2104,7 +2104,7 @@ __metadata: languageName: node linkType: hard -"@carbon/test-utils@^10.19.0, @carbon/test-utils@workspace:packages/test-utils": +"@carbon/test-utils@^10.20.0, @carbon/test-utils@workspace:packages/test-utils": version: 0.0.0-use.local resolution: "@carbon/test-utils@workspace:packages/test-utils" dependencies: @@ -2121,19 +2121,19 @@ __metadata: languageName: unknown linkType: soft -"@carbon/themes@^10.46.0-rc.0, @carbon/themes@workspace:packages/themes": +"@carbon/themes@^10.46.0, @carbon/themes@workspace:packages/themes": version: 0.0.0-use.local resolution: "@carbon/themes@workspace:packages/themes" dependencies: "@babel/node": ^7.14.2 "@babel/preset-env": ^7.14.2 - "@carbon/cli": ^10.30.0 + "@carbon/cli": ^10.31.0 "@carbon/cli-reporter": ^10.5.0 - "@carbon/colors": ^10.33.0 - "@carbon/layout": ^10.34.0-rc.0 + "@carbon/colors": ^10.34.0 + "@carbon/layout": ^10.34.0 "@carbon/scss-generator": ^10.13.0 - "@carbon/test-utils": ^10.19.0 - "@carbon/type": ^10.38.0-rc.0 + "@carbon/test-utils": ^10.20.0 + "@carbon/type": ^10.38.0 change-case: ^4.1.1 color: ^3.1.2 core-js: ^3.16.0 @@ -2144,14 +2144,14 @@ __metadata: languageName: unknown linkType: soft -"@carbon/type@^10.38.0-rc.0, @carbon/type@workspace:packages/type": +"@carbon/type@^10.38.0, @carbon/type@workspace:packages/type": version: 0.0.0-use.local resolution: "@carbon/type@workspace:packages/type" dependencies: - "@carbon/cli": ^10.30.0 + "@carbon/cli": ^10.31.0 "@carbon/import-once": ^10.6.0 - "@carbon/layout": ^10.34.0-rc.0 - "@carbon/test-utils": ^10.19.0 + "@carbon/layout": ^10.34.0 + "@carbon/test-utils": ^10.20.0 change-case: ^4.1.1 rimraf: ^3.0.0 languageName: unknown @@ -10293,7 +10293,7 @@ __metadata: languageName: node linkType: hard -"carbon-components-react@^7.47.0-rc.0, carbon-components-react@workspace:packages/react": +"carbon-components-react@^7.47.0, carbon-components-react@workspace:packages/react": version: 0.0.0-use.local resolution: "carbon-components-react@workspace:packages/react" dependencies: @@ -10310,10 +10310,10 @@ __metadata: "@babel/preset-react": ^7.14.5 "@babel/runtime": ^7.14.6 "@carbon/feature-flags": ^0.6.0 - "@carbon/icons-react": ^10.41.0 - "@carbon/layout": ^10.34.0-rc.0 + "@carbon/icons-react": ^10.42.0 + "@carbon/layout": ^10.34.0 "@carbon/telemetry": 0.0.0-alpha.6 - "@carbon/test-utils": ^10.19.0 + "@carbon/test-utils": ^10.20.0 "@cypress/react": ^5.4.0 "@cypress/webpack-dev-server": ^1.1.5 "@percy/cypress": ^3.1.1 @@ -10338,7 +10338,7 @@ __metadata: babel-plugin-react-docgen: ^4.2.1 babel-plugin-transform-inline-environment-variables: ^0.4.3 browserslist-config-carbon: ^10.6.1 - carbon-components: ^10.47.0-rc.0 + carbon-components: ^10.47.0 carbon-icons: ^7.0.5 chalk: ^4.1.1 classnames: 2.3.1 @@ -10423,7 +10423,7 @@ __metadata: languageName: node linkType: hard -"carbon-components@^10.47.0-rc.0, carbon-components@workspace:packages/components": +"carbon-components@^10.47.0, carbon-components@workspace:packages/components": version: 0.0.0-use.local resolution: "carbon-components@workspace:packages/components" dependencies: @@ -10435,12 +10435,12 @@ __metadata: "@babel/preset-env": ^7.14.7 "@babel/preset-react": ^7.14.5 "@babel/runtime": ^7.14.6 - "@carbon/cli": ^10.30.0 - "@carbon/elements": ^10.46.0-rc.0 - "@carbon/icons-handlebars": ^10.41.0 - "@carbon/icons-react": ^10.41.0 + "@carbon/cli": ^10.31.0 + "@carbon/elements": ^10.46.0 + "@carbon/icons-handlebars": ^10.42.0 + "@carbon/icons-react": ^10.42.0 "@carbon/telemetry": 0.0.0-alpha.6 - "@carbon/test-utils": ^10.19.0 + "@carbon/test-utils": ^10.20.0 "@frctl/fractal": ^1.1.0 "@rollup/plugin-babel": ^5.3.0 "@rollup/plugin-commonjs": ^18.0.0 From 90ffba0bdd2ab389eca1803492e0ea84e8faa610 Mon Sep 17 00:00:00 2001 From: Tanner Summers Date: Thu, 28 Oct 2021 14:00:15 -0500 Subject: [PATCH 2/5] feat(fileuploaderdropcontainer): added pattern for accepted file ext (#9929) * feat(fileuploaderdropcontainer): added pattern for accepted file ext * chore: update snaps Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com> Co-authored-by: Taylor Jones Co-authored-by: Taylor Jones --- .../__snapshots__/PublicAPI-test.js.snap | 4 + .../FileUploader/FileUploader-story.js | 4 + .../FileUploader/FileUploaderDropContainer.js | 9 +- .../FileUploaderDropContainer-test.js | 88 +++++++++++++++++++ 4 files changed, 104 insertions(+), 1 deletion(-) diff --git a/packages/react/__tests__/__snapshots__/PublicAPI-test.js.snap b/packages/react/__tests__/__snapshots__/PublicAPI-test.js.snap index d5682bce1b43..84503e1fe30c 100644 --- a/packages/react/__tests__/__snapshots__/PublicAPI-test.js.snap +++ b/packages/react/__tests__/__snapshots__/PublicAPI-test.js.snap @@ -2946,6 +2946,7 @@ Map { "labelText": "Add file", "multiple": false, "onAddFiles": [Function], + "pattern": ".[0-9a-z]+$", "tabIndex": 0, }, "propTypes": Object { @@ -2979,6 +2980,9 @@ Map { "onAddFiles": Object { "type": "func", }, + "pattern": Object { + "type": "string", + }, "role": Object { "type": "string", }, diff --git a/packages/react/src/components/FileUploader/FileUploader-story.js b/packages/react/src/components/FileUploader/FileUploader-story.js index 230378f48aaa..a897693167c5 100644 --- a/packages/react/src/components/FileUploader/FileUploader-story.js +++ b/packages/react/src/components/FileUploader/FileUploader-story.js @@ -140,6 +140,10 @@ const props = { disabled: boolean('Disabled (disabled)', false), role: text('ARIA role of the button (role)', ''), tabIndex: number('Tab index (tabIndex)', 0), + pattern: text( + 'Accepted MIME types or file extensions regex pattern (pattern)', + undefined + ), onAddFiles: action('onAddFiles'), }), }; diff --git a/packages/react/src/components/FileUploader/FileUploaderDropContainer.js b/packages/react/src/components/FileUploader/FileUploaderDropContainer.js index e3dd02a08a95..72f858202b57 100644 --- a/packages/react/src/components/FileUploader/FileUploaderDropContainer.js +++ b/packages/react/src/components/FileUploader/FileUploaderDropContainer.js @@ -21,6 +21,7 @@ function FileUploaderDropContainer({ multiple, name, onAddFiles, + pattern, role, tabIndex, ...rest @@ -52,7 +53,7 @@ function FileUploaderDropContainer({ const acceptedTypes = new Set(accept); return transferredFiles.reduce((acc, curr) => { const { name, type: mimeType = '' } = curr; - const fileExtensionRegExp = new RegExp(/\.[0-9a-z]+$/, 'i'); + const fileExtensionRegExp = new RegExp(pattern, 'i'); const hasFileExtension = fileExtensionRegExp.test(name); if (!hasFileExtension) { return acc; @@ -178,6 +179,11 @@ FileUploaderDropContainer.propTypes = { */ onAddFiles: PropTypes.func, + /** + * Provide a custom regex pattern for the acceptedTypes + */ + pattern: PropTypes.string, + /** * Provide an accessibility role for the */ @@ -202,6 +208,7 @@ FileUploaderDropContainer.defaultProps = { multiple: false, onAddFiles: () => {}, accept: [], + pattern: '.[0-9a-z]+$', }; export default FileUploaderDropContainer; diff --git a/packages/react/src/components/FileUploader/__tests__/FileUploaderDropContainer-test.js b/packages/react/src/components/FileUploader/__tests__/FileUploaderDropContainer-test.js index 3b6f12a3fb65..2639845c1900 100644 --- a/packages/react/src/components/FileUploader/__tests__/FileUploaderDropContainer-test.js +++ b/packages/react/src/components/FileUploader/__tests__/FileUploaderDropContainer-test.js @@ -87,4 +87,92 @@ describe('FileUploaderDropContainer', () => { { addedFiles: files } ); }); + + it('should mark invalid files using default pattern', () => { + const onAddFiles = jest.fn(); + const { container } = render( + + ); + const input = container.querySelector('input'); + + const files = [ + new File(['foo'], 'foo.txt', { type: 'text/plain' }), + new File(['bar'], 'bar.a_a', { type: 'text/plain' }), + new File(['bar_foo'], 'bar_foo.b-b', { type: 'text/plain' }), + new File(['bar-foo'], 'bar-foo.a-b_c', { type: 'text/plain' }), + ]; + + uploadFiles(input, files); + + expect(onAddFiles).toHaveBeenCalledWith( + expect.objectContaining({ + target: { + files, + }, + }), + { addedFiles: files } + ); + + expect(onAddFiles).toHaveBeenCalledWith( + expect.objectContaining({ + target: { + files, + }, + }), + { + addedFiles: expect.arrayContaining([ + expect.not.objectContaining({ invalidFileType: true }), + expect.objectContaining({ invalidFileType: true }), + expect.objectContaining({ invalidFileType: true }), + expect.objectContaining({ invalidFileType: true }), + ]), + } + ); + }); + + it('should not mark any invalid files using custom pattern', () => { + const onAddFiles = jest.fn(); + const { container } = render( + + ); + const input = container.querySelector('input'); + + const files = [ + new File(['foo'], 'foo.txt', { type: 'text/plain' }), + new File(['bar'], 'bar.a_a', { type: 'text/plain' }), + new File(['bar_foo'], 'bar_foo.b-b', { type: 'text/plain' }), + new File(['bar-foo'], 'bar-foo.a-b_c', { type: 'text/plain' }), + ]; + + uploadFiles(input, files); + + expect(onAddFiles).toHaveBeenCalledWith( + expect.objectContaining({ + target: { + files, + }, + }), + { addedFiles: files } + ); + + expect(onAddFiles).toHaveBeenCalledWith( + expect.objectContaining({ + target: { + files, + }, + }), + { + addedFiles: expect.arrayContaining([ + expect.not.objectContaining({ invalidFileType: true }), + expect.not.objectContaining({ invalidFileType: true }), + expect.not.objectContaining({ invalidFileType: true }), + expect.not.objectContaining({ invalidFileType: true }), + ]), + } + ); + }); }); From a1c3b6fe885fddb45624489875eb7f6fa811dbb2 Mon Sep 17 00:00:00 2001 From: Tanner Summers Date: Fri, 29 Oct 2021 10:12:16 -0500 Subject: [PATCH 3/5] docs(readme): updated readme to add TannerS as contributor (#9992) --- .all-contributorsrc | 9 +++++++++ README.md | 1 + 2 files changed, 10 insertions(+) diff --git a/.all-contributorsrc b/.all-contributorsrc index 92e7b8f4fbf8..eccc97c94e5f 100644 --- a/.all-contributorsrc +++ b/.all-contributorsrc @@ -820,6 +820,15 @@ "contributions": [ "code" ] + }, + { + "login": "TannerS", + "name": "Tanner Summers", + "avatar_url": "https://avatars.githubusercontent.com/u/8866319?v=4", + "profile": "https://github.com/TannerS", + "contributions": [ + "code" + ] } ], "commitConvention": "none" diff --git a/README.md b/README.md index a3911db05b94..265e3da08835 100644 --- a/README.md +++ b/README.md @@ -189,6 +189,7 @@ check out our [Contributing Guide](/.github/CONTRIBUTING.md) and our
Eshin Griffith

💻
@RianTavaresOn

💻 🎨
ColbyJohnIBM

💻 +
Tanner Summers

💻 From 9f3da13f3588ee74dc82087aafcd461fb55758e0 Mon Sep 17 00:00:00 2001 From: DAK <40970507+dakahn@users.noreply.github.com> Date: Fri, 29 Oct 2021 11:30:27 -0500 Subject: [PATCH 4/5] fix(UIShell): expand check so side nav items close properly (#9976) Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com> --- packages/react/src/components/UIShell/SideNav.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/react/src/components/UIShell/SideNav.js b/packages/react/src/components/UIShell/SideNav.js index 7f2f4bacb0b0..8c8ade147b3b 100644 --- a/packages/react/src/components/UIShell/SideNav.js +++ b/packages/react/src/components/UIShell/SideNav.js @@ -90,7 +90,9 @@ const SideNav = React.forwardRef(function SideNav(props, ref) { : expanded; // avoid spreading `isSideNavExpanded` to non-Carbon UI Shell children return React.cloneElement(child, { - ...(CARBON_SIDENAV_ITEMS.includes(child.type?.displayName) + ...(CARBON_SIDENAV_ITEMS.includes( + child.type?.displayName ?? child.type?.name + ) ? { isSideNavExpanded: currentExpansionState, } From 6ce1b54ee0f0407d1949b3c6375eff6f91cce8c0 Mon Sep 17 00:00:00 2001 From: Josefina Mancilla <32556167+jnm2377@users.noreply.github.com> Date: Fri, 29 Oct 2021 14:00:37 -0500 Subject: [PATCH 5/5] fix(DataTable): fixes overflowing sort button and select column spacing (#9956) * fix: add width to checkbox column * feat: add select/sort story * feat: add fix to styles package Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com> --- .../data-table/_data-table-core.scss | 1 + .../stories/DataTable-selection-story.js | 42 +++++++++++++++++++ .../components/data-table/_data-table.scss | 1 + 3 files changed, 44 insertions(+) diff --git a/packages/components/src/components/data-table/_data-table-core.scss b/packages/components/src/components/data-table/_data-table-core.scss index cb754fa0a593..ee5621a39ed3 100644 --- a/packages/components/src/components/data-table/_data-table-core.scss +++ b/packages/components/src/components/data-table/_data-table-core.scss @@ -345,6 +345,7 @@ .#{$prefix}--data-table thead th.#{$prefix}--table-column-checkbox, .#{$prefix}--data-table tbody td.#{$prefix}--table-column-checkbox { + width: 2.5rem; // spacing between checkbox / chevron and next cell should be 8px / 0.5rem padding-right: rem(4px); padding-left: 1rem; diff --git a/packages/react/src/components/DataTable/stories/DataTable-selection-story.js b/packages/react/src/components/DataTable/stories/DataTable-selection-story.js index 849ea1687658..e24bee3404d2 100644 --- a/packages/react/src/components/DataTable/stories/DataTable-selection-story.js +++ b/packages/react/src/components/DataTable/stories/DataTable-selection-story.js @@ -124,3 +124,45 @@ export const WithRadioSelection = () => ( )} ); + +export const WithSelectionAndSorting = () => ( + + {({ + rows, + headers, + getHeaderProps, + getRowProps, + getSelectionProps, + getTableProps, + getTableContainerProps, + }) => ( + + + + + + {headers.map((header, i) => ( + + {header.header} + + ))} + + + + {rows.map((row, i) => ( + + + {row.cells.map((cell) => ( + {cell.value} + ))} + + ))} + +
+
+ )} +
+); diff --git a/packages/styles/scss/components/data-table/_data-table.scss b/packages/styles/scss/components/data-table/_data-table.scss index 802a3a033888..be47444d01e6 100644 --- a/packages/styles/scss/components/data-table/_data-table.scss +++ b/packages/styles/scss/components/data-table/_data-table.scss @@ -341,6 +341,7 @@ .#{$prefix}--data-table thead th.#{$prefix}--table-column-checkbox, .#{$prefix}--data-table tbody td.#{$prefix}--table-column-checkbox { + width: 2.5rem; // spacing between checkbox / chevron and next cell should be 8px / 0.5rem padding-right: rem(4px); padding-left: 1rem;