diff --git a/.circleci/config.yml b/.circleci/config.yml index 74998eba11ed6e..c10fe610fb550f 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -338,7 +338,7 @@ jobs: <<: *defaults resource_class: 'medium+' docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -368,7 +368,7 @@ jobs: test_e2e: <<: *defaults docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -385,9 +385,10 @@ jobs: name: Test umd release command: pnpm test:umd test_e2e_website: + # NOTE: This workflow runs after successful docs deploy. See /test/e2e-website/README.md#ci <<: *defaults docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -402,7 +403,7 @@ jobs: test_profile: <<: *defaults docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -429,7 +430,7 @@ jobs: test_regressions: <<: *defaults docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -483,7 +484,7 @@ jobs: <<: *defaults working_directory: /tmp/material-ui/test/bundling/fixtures/next-webpack4/ docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -507,7 +508,7 @@ jobs: <<: *defaults working_directory: /tmp/material-ui/test/bundling/fixtures/next-webpack5/ docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -531,7 +532,7 @@ jobs: <<: *defaults working_directory: /tmp/material-ui/test/bundling/fixtures/create-react-app/ docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -555,7 +556,7 @@ jobs: <<: *defaults working_directory: /tmp/material-ui/test/bundling/fixtures/snowpack/ docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -579,7 +580,7 @@ jobs: <<: *defaults working_directory: /tmp/material-ui/test/bundling/fixtures/vite/ docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -603,7 +604,7 @@ jobs: <<: *defaults working_directory: /tmp/material-ui/test/bundling/fixtures/esbuild/ docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -631,7 +632,7 @@ jobs: <<: *defaults working_directory: /tmp/material-ui/test/bundling/fixtures/gatsby/ docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: @@ -732,7 +733,7 @@ jobs: test_benchmark: <<: *defaults docker: - - image: mcr.microsoft.com/playwright:v1.41.2-focal + - image: mcr.microsoft.com/playwright:v1.42.1-focal environment: NODE_ENV: development # Needed if playwright is in `devDependencies` steps: diff --git a/.codesandbox/ci.json b/.codesandbox/ci.json index 7d03e0dee7362d..6b395d8ebe8487 100644 --- a/.codesandbox/ci.json +++ b/.codesandbox/ci.json @@ -9,6 +9,7 @@ "packages/mui-base", "packages/mui-codemod", "packages/mui-core-downloads-tracker", + "packages/mui-docs", "packages/mui-icons-material", "packages/mui-joy", "packages/mui-lab", @@ -22,16 +23,13 @@ "packages/mui-system", "packages/mui-types", "packages/mui-utils", - "packages-internal/scripts", - "packages/pigment-react", - "packages/pigment-unplugin", - "packages/pigment-vite-plugin", - "packages/pigment-nextjs-plugin" + "packages-internal/scripts" ], "publishDirectory": { "@mui/base": "packages/mui-base/build", "@mui/codemod": "packages/mui-codemod/build", "@mui/core-downloads-tracker": "packages/mui-core-downloads-tracker/build", + "@mui/docs": "packages/mui-docs/build", "@mui/icons-material": "packages/mui-icons-material/build", "@mui/internal-babel-macros": "packages/mui-babel-macros", "@mui/internal-markdown": "packages/markdown", @@ -48,11 +46,7 @@ "@mui/system": "packages/mui-system/build", "@mui/types": "packages/mui-types/build", "@mui/utils": "packages/mui-utils/build", - "@mui-internal/docs-utils": "packages/docs-utils", - "@pigmentcss/react": "packages/pigment-react", - "@pigmentcss/unplugin": "packages/pigment-unplugin", - "@pigmentcss/vite-plugin": "packages/pigment-vite-plugin", - "@pigmentcss/nextjs-plugin": "packages/pigment-nextjs-plugin" + "@mui-internal/docs-utils": "packages/docs-utils" }, "sandboxes": [ "/examples/material-ui-cra-ts", diff --git a/.eslintignore b/.eslintignore index 40b0fcc4a9fce1..5043b4bb97f494 100644 --- a/.eslintignore +++ b/.eslintignore @@ -23,7 +23,7 @@ /packages/pigment-react/processors/ /packages/pigment-react/exports/ /packages/pigment-react/theme/ -/packages/pigment-react/tests/fixtures/ +/packages/pigment-react/tests/**/fixtures /packages/pigment-nextjs-plugin/loader.js # Ignore fixtures /packages-internal/scripts/typescript-to-proptypes/test/*/* diff --git a/.github/ISSUE_TEMPLATE/1.bug.yml b/.github/ISSUE_TEMPLATE/1.bug.yml index e765d2527d1d06..44f994ac9fd282 100644 --- a/.github/ISSUE_TEMPLATE/1.bug.yml +++ b/.github/ISSUE_TEMPLATE/1.bug.yml @@ -9,7 +9,7 @@ body: attributes: label: Search keywords description: | - Your issue may have already been reported! First search for duplicates among the [existing issues](https://github.com/mui/material-ui/issues). + Your issue may have already been reported! First search for duplicates among the [existing issues](https://github.com/mui/material-ui/issues?q=is%3Aopen+is%3Aclosed). If your issue isn't a duplicate, great! Please list the keywords you used so people in the future can find this one more easily: validations: required: true diff --git a/.github/ISSUE_TEMPLATE/2.feature.yml b/.github/ISSUE_TEMPLATE/2.feature.yml index b225d797ae8cd8..080e31177c3b1c 100644 --- a/.github/ISSUE_TEMPLATE/2.feature.yml +++ b/.github/ISSUE_TEMPLATE/2.feature.yml @@ -9,7 +9,7 @@ body: attributes: label: Search keywords description: | - Your issue may have already been reported! First search for duplicates among the [existing issues](https://github.com/mui/material-ui/issues). + Your issue may have already been reported! First search for duplicates among the [existing issues](https://github.com/mui/material-ui/issues?q=is%3Aopen+is%3Aclosed). If your issue isn't a duplicate, great! Please list the keywords you used so people in the future can find this one more easily: validations: required: true diff --git a/.github/ISSUE_TEMPLATE/4.docs-feedback.yml b/.github/ISSUE_TEMPLATE/4.docs-feedback.yml index 8c41c69d7c074a..70d90a31e8a690 100644 --- a/.github/ISSUE_TEMPLATE/4.docs-feedback.yml +++ b/.github/ISSUE_TEMPLATE/4.docs-feedback.yml @@ -10,7 +10,7 @@ body: attributes: label: Search keywords description: | - Your issue may have already been reported! First search for duplicates among the [existing issues](https://github.com/mui/material-ui/issues). + Your issue may have already been reported! First search for duplicates among the [existing issues](https://github.com/mui/material-ui/issues?q=is%3Aopen+is%3Aclosed). If your issue isn't a duplicate, great! Please list the keywords you used so people in the future can find this one more easily: validations: required: true diff --git a/.github/ISSUE_TEMPLATE/5.priority-support.yml b/.github/ISSUE_TEMPLATE/5.priority-support.yml index fb19f4eb3b26d2..530a16772a5c62 100644 --- a/.github/ISSUE_TEMPLATE/5.priority-support.yml +++ b/.github/ISSUE_TEMPLATE/5.priority-support.yml @@ -11,7 +11,7 @@ body: attributes: label: Search keywords description: | - Your issue may have already been reported! First search for duplicates among the [existing issues](https://github.com/mui/material-ui/issues). + Your issue may have already been reported! First search for duplicates among the [existing issues](https://github.com/mui/material-ui/issues?q=is%3Aopen+is%3Aclosed). If your issue isn't a duplicate, great! Please list the keywords you used so people in the future can find this one more easily: required: true - type: checkboxes diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml index 992abaa29bdbec..6e8cfcc755e3d1 100644 --- a/.github/workflows/codeql.yml +++ b/.github/workflows/codeql.yml @@ -19,7 +19,7 @@ jobs: uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL - uses: github/codeql-action/init@47b3d888fe66b639e431abf22ebca059152f1eea # v3.24.5 + uses: github/codeql-action/init@8a470fddafa5cbb6266ee11b37ef4d8aae19c571 # v3.24.6 with: languages: typescript config-file: ./.github/codeql/codeql-config.yml @@ -30,4 +30,4 @@ jobs: # Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs # queries: security-extended,security-and-quality - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@47b3d888fe66b639e431abf22ebca059152f1eea # v3.24.5 + uses: github/codeql-action/analyze@8a470fddafa5cbb6266ee11b37ef4d8aae19c571 # v3.24.6 diff --git a/.github/workflows/scorecards.yml b/.github/workflows/scorecards.yml index 2a8485237033a0..e00b33d3986606 100644 --- a/.github/workflows/scorecards.yml +++ b/.github/workflows/scorecards.yml @@ -43,6 +43,6 @@ jobs: # Upload the results to GitHub's code scanning dashboard. - name: Upload to code-scanning - uses: github/codeql-action/upload-sarif@47b3d888fe66b639e431abf22ebca059152f1eea # v3.24.5 + uses: github/codeql-action/upload-sarif@8a470fddafa5cbb6266ee11b37ef4d8aae19c571 # v3.24.6 with: sarif_file: results.sarif diff --git a/CHANGELOG.md b/CHANGELOG.md index 7ff80ee5d1fb27..c392f200b594fe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,87 @@ # [Versions](https://mui.com/versions/) +## v5.15.12 + + + +_Mar 5, 2024_ + +A big thanks to the 21 contributors who made this release possible. +This release was mostly about ๐Ÿ› bug fixes and ๐Ÿ“š documentation improvements. + +### `@pigment-css/react@0.0.1`, `@pigment-css/nextjs-plugin@0.0.1`, `@pigment-css/vite-plugin@0.0.1`, & `@pigment-css/unplugin@0.0.1` + +- This is the first public release of our new zero-runtime CSS-in-JS library, Pigment CSS. + +### `@mui/material@5.15.12` + +- ​Support props callback type in theme variants (#40946) @ZeeshanTamboli +- ​[Alert] Convert to support zero runtime (#41230) @siriwatknp +- ​[Alert] Deprecate composed classes (#40688) @DiegoAndai +- ​[Button] Deprecate classes for v6 (#40675) @sai6855 +- ​[Checkbox] `large` size added in type (#34909) @smox +- ​[Chip] Deprecate composed classes (#41235) @sai6855 +- ​[Chip] Correct `deleteIconColorPrimary` and `deleteIconColorSecondary` class descriptions (#41231) @sai6855 +- ​Remove unused dev dependency on @mui/lab (#41198) @brijeshb42 +- ​[Slider] Deprecate components and componentProps props for v6 (#40777) @lhilgert9 + +### `@mui/system@5.15.12` + +- ​[pigment-css][material-ui] Render badge demos (#41353) @siriwatknp +- ​[pigment-css] Update to latest wyw version (#41363) @brijeshb42 +- ​[pigment-css] Rename scope to @pigment-css (#41354) @brijeshb42 +- ​[pigment-css] Rename zero-runtime to pigmentcss (#41317) @brijeshb42 +- ​Fix createSpacing return type (#41318) @matystroia +- ​[zero] Add support for styled tagged-template literals (#41268) @brijeshb42 +- ​[zero] Set up Material UI migration demos (#41267) @siriwatknp +- ​[zero] Move extendTheme to already existing @mui/zero-runtime/utils (#41254) @brijeshb42 +- ​[zero] Remove `object` intersection from CSS Fallback (#41271) @siriwatknp +- ​[zero] Minor wording changes in README (#41253) @brijeshb42 +- ​[zero] Prepare zero-runtime packages for public release (#41226) @brijeshb42 + +### `@mui/joy@5.0.0-beta.30` + +- ​[joy-ui][Autocomplete] Fix text overflow in Chip (#40229) @PunitSoniME + +### Docs + +- ​[base-ui] Update the docs post repo separation (#41328) @danilo-leal +- ​Fix missing partner link @oliviertassinari +- ​Update links to GitHub projects (#41297) @danilo-leal +- ​Standardize WAI-ARIA referencest @oliviertassinari +- ​Fix image layout shift when loading @oliviertassinari +- ​[joy-ui] Add stray adjustments throughout the docs (#41211) @danilo-leal +- ​[material-ui] Remove duplicated text at FAQ page (#41326) @zanivan +- ​[material-ui] Fix color mode toggle of the landing page template (#41293) @zanivan +- ​[system] Tweak the Usage demos (#41242) @danilo-leal +- ​[zero] Add a Why section on the README (#41284) @danilo-leal + +### Core + +- ​Revert "[utils] Port `useLocalStorageState` hook from Toolpad (#41096)" @oliviertassinari +- ​[blog] Add post about how MUI uses Toolpad (#40172) @prakhargupta1 +- ​[blog] No bundled demos in blog posts @oliviertassinari +- ​[code-infra] Embed translations in the @mui/docs package (#41246) @Janpot +- ​[code-infra] Prepare the markdown package for publishing (#41240) @michaldudak +- ​[code-infra] Unpin the version of docs-utils in scripts (#41232) @michaldudak +- ​[core] Use runtime agnostic setTimeout type @oliviertassinari +- ​[core] Remove window. reference for common globals @oliviertassinari +- ​[core] Add a script to build all packages (#40631) @michaldudak +- ​[docs-infra] Fix missing non breaking spaces @oliviertassinari +- ​[docs-infra] Add design customizations to the disclosure element (#41285) @danilo-leal +- ​[docs-infra] Adjust headings dark mode color (#41292) @danilo-leal +- ​[docs-infra] Fix Stack Overflow breaking space @oliviertassinari +- ​[docs-infra] Fix product selector popup not closing on route change (#41166) @divyammadhok +- ​[docs-infra] Improve fix blank links ad @oliviertassinari +- ​[docs-infra] Support interfaces for X docs (#41069) @alexfauquette +- ​[infra] Adjust the links to search for issues (#41008) @michelengelen +- ​[website] Move the `React Engineer - xCharts` to `Next roles` section (#41368) @DanailH +- ​[website] Add James to About Us (#41362) @atomiks +- ​[website] Polish Button outline primary medium (#41298) @oliviertassinari +- ​[website] Remove Heatmap chart from community plan on pricing table (#41081) @alexfauquette + +All contributors of this release in alphabetical order: @alexfauquette, @atomiks, @brijeshb42, @DanailH, @danilo-leal, @DiegoAndai, @divyammadhok, @Janpot, @lhilgert9, @matystroia, @michaldudak, @michelengelen, @mj12albert, @oliviertassinari, @prakhargupta1, @PunitSoniME, @sai6855, @siriwatknp, @smox, @zanivan, @ZeeshanTamboli + ## v5.15.11 @@ -1193,7 +1275,7 @@ A big thanks to the 17 contributors who made this release possible. - ​Update peer dep of @mui/material (#39398) @brijeshb42 -### `@pigmentcss/react@0.0.1-alpha.0` +### `@pigment-css/react@0.0.1-alpha.0` - ​Implement typings for public runtime API (#39215) @brijeshb42 @@ -1794,7 +1876,7 @@ A big thanks to the 11 contributors who made this release possible. This release - [useButton][base-ui] Accept arbitrary props in getRootProps and forward them (#38475) @DiegoAndai -### `@pigmentcss/react@0.0.1-alpha.1` +### `@pigment-css/react@0.0.1-alpha.1` - [system][zero][tag] Add support for sx prop (#38535) @brijeshb42 @@ -1857,7 +1939,7 @@ A big thanks to the 21 contributors who made this release possible. Here are som - [ButtonBase] Add ButtonBase component (#38319) @DiegoAndai - [Input] Add InputBase component (#38392) @mj12albert -### `@pigmentcss/react@0.0.1-alpha.0` +### `@pigment-css/react@0.0.1-alpha.0` - Implementation of styled tag processor for linaria (#38378) @brijeshb42 @@ -2834,7 +2916,7 @@ _May 10, 2023_ A big thanks to the 18 contributors who made this release possible. Here are some highlights โœจ: - ๐Ÿš€ Baseย UI is now in beta - all planned breaking changes are now complete! -- ๐Ÿ—บ We have a new [project roadmap](https://github.com/orgs/mui/projects/18/views/1) on GitHub where you can learn about what's coming next. +- ๐Ÿ—บ We have new [project boards](https://github.com/mui/material-ui/projects?query=is%3Aopen) on GitHub where you can learn about what's coming next. - ๐Ÿ› Various bug fixes, ๐Ÿ“š documentation and ๐Ÿงช testing improvements ### `@mui/material@5.13.0` diff --git a/apps/local-ui-lib/index.js b/apps/local-ui-lib/index.js index 6422c23c197a3c..21893b8348b4ac 100644 --- a/apps/local-ui-lib/index.js +++ b/apps/local-ui-lib/index.js @@ -1,4 +1,4 @@ -import { keyframes, styled } from '@pigmentcss/react'; +import { keyframes, styled } from '@pigment-css/react'; export const bounceAnim = keyframes({ 'from, 20%, 53%, 80%, to': { diff --git a/apps/local-ui-lib/package.json b/apps/local-ui-lib/package.json index 8f9dbab3e96078..8e7e2264364d9c 100644 --- a/apps/local-ui-lib/package.json +++ b/apps/local-ui-lib/package.json @@ -3,6 +3,6 @@ "version": "0.0.1", "private": true, "dependencies": { - "@pigmentcss/react": "file:../../packages/pigment-react" + "@pigment-css/react": "file:../../packages/pigment-react" } } diff --git a/apps/pigment-next-app/README.md b/apps/pigment-next-app/README.md index c880e18615edf9..11f66aa10d4f20 100644 --- a/apps/pigment-next-app/README.md +++ b/apps/pigment-next-app/README.md @@ -20,7 +20,7 @@ Open [http://localhost:3000](http://localhost:3000) with your browser to see the You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file. -If you see and error like package `@pigmentcss/react` not found, add it as a peer-dependency in `@mui/material`'s `package.json` file and run `pnpm build` and `pnpm install` again. Make sure to not push this change to git. +If you see and error like package `@pigment-css/react` not found, add it as a peer-dependency in `@mui/material`'s `package.json` file and run `pnpm build` and `pnpm install` again. Make sure to not push this change to git. ### Note diff --git a/apps/pigment-next-app/next.config.js b/apps/pigment-next-app/next.config.js index 32ef7ccb1bb26b..076069c4db48e5 100644 --- a/apps/pigment-next-app/next.config.js +++ b/apps/pigment-next-app/next.config.js @@ -1,10 +1,10 @@ /* eslint-env node */ // eslint-ignore-next-line import/no-unresolved -const { withPigment } = require('@pigmentcss/nextjs-plugin'); +const { withPigment } = require('@pigment-css/nextjs-plugin'); const { experimental_extendTheme: extendTheme } = require('@mui/material/styles'); /** - * @typedef {import('@pigmentcss/nextjs-plugin').PigmentOptions} PigmentOptions + * @typedef {import('@pigment-css/nextjs-plugin').PigmentOptions} PigmentOptions */ const theme = extendTheme({ diff --git a/apps/pigment-next-app/package.json b/apps/pigment-next-app/package.json index ceae7353a5daea..99c9a8de5bb66c 100644 --- a/apps/pigment-next-app/package.json +++ b/apps/pigment-next-app/package.json @@ -9,7 +9,7 @@ "clean": "rimraf .next" }, "dependencies": { - "@pigmentcss/react": "file:../../packages/pigment-react", + "@pigment-css/react": "file:../../packages/pigment-react", "@mui/utils": "file:../../packages/mui-utils/build", "@mui/base": "file:../../packages/mui-base/build", "@mui/material": "file:../../packages/mui-material/build", @@ -23,8 +23,8 @@ "next": "latest" }, "devDependencies": { - "@pigmentcss/unplugin": "file:../../packages/pigment-unplugin", - "@pigmentcss/nextjs-plugin": "file:../../packages/pigment-nextjs-plugin", + "@pigment-css/unplugin": "file:../../packages/pigment-unplugin", + "@pigment-css/nextjs-plugin": "file:../../packages/pigment-nextjs-plugin", "@types/node": "^20.5.7", "@types/react": "^18.2.55", "@types/react-dom": "^18.2.19", diff --git a/apps/pigment-next-app/src/app/box/page.tsx b/apps/pigment-next-app/src/app/box/page.tsx index fb56ce056198d5..877b36e5a39275 100644 --- a/apps/pigment-next-app/src/app/box/page.tsx +++ b/apps/pigment-next-app/src/app/box/page.tsx @@ -1,6 +1,6 @@ /* eslint-disable material-ui/no-empty-box */ -import { styled } from '@pigmentcss/react'; +import { styled } from '@pigment-css/react'; import * as React from 'react'; import { Box as MuiBox } from '../../components/Box'; diff --git a/apps/pigment-next-app/src/app/globals.css b/apps/pigment-next-app/src/app/globals.css index f986282c43ac47..7f5569579ba220 100644 --- a/apps/pigment-next-app/src/app/globals.css +++ b/apps/pigment-next-app/src/app/globals.css @@ -1,22 +1,26 @@ -* { - box-sizing: border-box; - padding: 0; - margin: 0; -} +@layer reset, mui; -html, -body { - max-width: 100vw; - overflow-x: hidden; -} +@layer reset { + * { + box-sizing: border-box; + padding: 0; + margin: 0; + } -a { - color: inherit; - text-decoration: none; -} + html, + body { + max-width: 100vw; + overflow-x: hidden; + } + + a { + color: inherit; + text-decoration: none; + } -@media (prefers-color-scheme: dark) { - html { - color-scheme: dark; + @media (prefers-color-scheme: dark) { + html { + color-scheme: dark; + } } } diff --git a/apps/pigment-next-app/src/app/layout.tsx b/apps/pigment-next-app/src/app/layout.tsx index 01f8c34afd4e9e..3907673a0fdf0a 100644 --- a/apps/pigment-next-app/src/app/layout.tsx +++ b/apps/pigment-next-app/src/app/layout.tsx @@ -3,7 +3,7 @@ import { Inter } from 'next/font/google'; import { AppRouterCacheProvider } from '@mui/material-nextjs/v14-appRouter'; import { ThemeProvider } from '@mui/material/styles'; import CssBaseline from '@mui/material/CssBaseline'; -import '@pigmentcss/react/styles.css'; +import '@pigment-css/react/styles.css'; import theme from './theme'; import './globals.css'; diff --git a/apps/pigment-next-app/src/app/material-ui/layout.tsx b/apps/pigment-next-app/src/app/material-ui/layout.tsx index 92f476c84477c5..06afb2f9251928 100644 --- a/apps/pigment-next-app/src/app/material-ui/layout.tsx +++ b/apps/pigment-next-app/src/app/material-ui/layout.tsx @@ -1,5 +1,5 @@ import * as React from 'react'; -import { styled } from '@pigmentcss/react'; +import { styled } from '@pigment-css/react'; const Main = styled('div')(({ theme }) => ({ display: 'flex', diff --git a/apps/pigment-next-app/src/app/material-ui/page.tsx b/apps/pigment-next-app/src/app/material-ui/page.tsx new file mode 100644 index 00000000000000..3a7c71710986c5 --- /dev/null +++ b/apps/pigment-next-app/src/app/material-ui/page.tsx @@ -0,0 +1,44 @@ +// eslint-disable-next-line @typescript-eslint/no-unused-vars +import * as React from 'react'; +import Link from 'next/link'; +import fs from 'fs/promises'; +import path from 'path'; +import { css } from '@pigment-css/react'; + +export default async function MaterialUIPage() { + const rootPaths = await fs.readdir(path.join(process.cwd(), `src/app/material-ui`)); + return ( +
+

Material UI Components

+ +
+ ); +} diff --git a/apps/pigment-next-app/src/app/material-ui/react-alert/page.tsx b/apps/pigment-next-app/src/app/material-ui/react-alert/page.tsx new file mode 100644 index 00000000000000..35a5714870939b --- /dev/null +++ b/apps/pigment-next-app/src/app/material-ui/react-alert/page.tsx @@ -0,0 +1,72 @@ +'use client'; +import * as React from 'react'; +import ActionAlerts from '../../../../../../docs/data/material/components/alert/ActionAlerts'; +import BasicAlerts from '../../../../../../docs/data/material/components/alert/BasicAlerts'; +import ColorAlerts from '../../../../../../docs/data/material/components/alert/ColorAlerts'; +import DescriptionAlerts from '../../../../../../docs/data/material/components/alert/DescriptionAlerts'; +import FilledAlerts from '../../../../../../docs/data/material/components/alert/FilledAlerts'; +import IconAlerts from '../../../../../../docs/data/material/components/alert/IconAlerts'; +import OutlinedAlerts from '../../../../../../docs/data/material/components/alert/OutlinedAlerts'; +import SimpleAlert from '../../../../../../docs/data/material/components/alert/SimpleAlert'; +import TransitionAlerts from '../../../../../../docs/data/material/components/alert/TransitionAlerts'; + +export default function Alert() { + return ( + +
+

Action Alerts

+
+ +
+
+
+

Basic Alerts

+
+ +
+
+
+

Color Alerts

+
+ +
+
+
+

Description Alerts

+
+ +
+
+
+

Filled Alerts

+
+ +
+
+
+

Icon Alerts

+
+ +
+
+
+

Outlined Alerts

+
+ +
+
+
+

Simple Alert

+
+ +
+
+
+

Transition Alerts

+
+ +
+
+
+ ); +} diff --git a/apps/pigment-next-app/src/app/material-ui/react-badge/page.tsx b/apps/pigment-next-app/src/app/material-ui/react-badge/page.tsx new file mode 100644 index 00000000000000..7612e906882b39 --- /dev/null +++ b/apps/pigment-next-app/src/app/material-ui/react-badge/page.tsx @@ -0,0 +1,72 @@ +'use client'; +import * as React from 'react'; +import AccessibleBadges from '../../../../../../docs/data/material/components/badges/AccessibleBadges'; +import BadgeMax from '../../../../../../docs/data/material/components/badges/BadgeMax'; +import BadgeOverlap from '../../../../../../docs/data/material/components/badges/BadgeOverlap'; +import BadgeVisibility from '../../../../../../docs/data/material/components/badges/BadgeVisibility'; +import ColorBadge from '../../../../../../docs/data/material/components/badges/ColorBadge'; +import CustomizedBadges from '../../../../../../docs/data/material/components/badges/CustomizedBadges'; +import DotBadge from '../../../../../../docs/data/material/components/badges/DotBadge'; +import ShowZeroBadge from '../../../../../../docs/data/material/components/badges/ShowZeroBadge'; +import SimpleBadge from '../../../../../../docs/data/material/components/badges/SimpleBadge'; + +export default function Badges() { + return ( + +
+

Accessible Badges

+
+ +
+
+
+

Badge Max

+
+ +
+
+
+

Badge Overlap

+
+ +
+
+
+

Badge Visibility

+
+ +
+
+
+

Color Badge

+
+ +
+
+
+

Customized Badges

+
+ +
+
+
+

Dot Badge

+
+ +
+
+
+

Show Zero Badge

+
+ +
+
+
+

Simple Badge

+
+ +
+
+
+ ); +} diff --git a/apps/pigment-next-app/src/app/material-ui/react-switch/page.tsx b/apps/pigment-next-app/src/app/material-ui/react-switch/page.tsx new file mode 100644 index 00000000000000..03a99083243bcf --- /dev/null +++ b/apps/pigment-next-app/src/app/material-ui/react-switch/page.tsx @@ -0,0 +1,65 @@ +'use client'; +import * as React from 'react'; +import BasicSwitches from '../../../../../../docs/data/material/components/switches/BasicSwitches'; +import ColorSwitches from '../../../../../../docs/data/material/components/switches/ColorSwitches'; +import ControlledSwitches from '../../../../../../docs/data/material/components/switches/ControlledSwitches'; +import CustomizedSwitches from '../../../../../../docs/data/material/components/switches/CustomizedSwitches'; +import FormControlLabelPosition from '../../../../../../docs/data/material/components/switches/FormControlLabelPosition'; +import SwitchLabels from '../../../../../../docs/data/material/components/switches/SwitchLabels'; +import SwitchesGroup from '../../../../../../docs/data/material/components/switches/SwitchesGroup'; +import SwitchesSize from '../../../../../../docs/data/material/components/switches/SwitchesSize'; + +export default function Switches() { + return ( + +
+

Basic Switches

+
+ +
+
+
+

Color Switches

+
+ +
+
+
+

Controlled Switches

+
+ +
+
+
+

Customized Switches

+
+ +
+
+
+

Form Control Label Position

+
+ +
+
+
+

Switch Labels

+
+ +
+
+
+

Switches Group

+
+ +
+
+
+

Switches Size

+
+ +
+
+
+ ); +} diff --git a/apps/pigment-next-app/src/app/page.tsx b/apps/pigment-next-app/src/app/page.tsx index 76668cda213da1..0a9b3811f9974d 100644 --- a/apps/pigment-next-app/src/app/page.tsx +++ b/apps/pigment-next-app/src/app/page.tsx @@ -1,5 +1,5 @@ import Image from 'next/image'; -import { styled, css } from '@pigmentcss/react'; +import { styled, css } from '@pigment-css/react'; import styles from './page.module.css'; const visuallyHidden = css({ diff --git a/apps/pigment-next-app/src/app/slider/page.tsx b/apps/pigment-next-app/src/app/slider/page.tsx index c4db9973689ec8..07e5fca1c0f2f2 100644 --- a/apps/pigment-next-app/src/app/slider/page.tsx +++ b/apps/pigment-next-app/src/app/slider/page.tsx @@ -1,6 +1,6 @@ 'use client'; import * as React from 'react'; -import { styled } from '@pigmentcss/react'; +import { styled } from '@pigment-css/react'; import { Button } from 'local-ui-lib'; import Slider from '@/components/Slider/ZeroSlider'; diff --git a/apps/pigment-next-app/src/augment.d.ts b/apps/pigment-next-app/src/augment.d.ts index 2fbc8851cf8eba..6e98d66132560d 100644 --- a/apps/pigment-next-app/src/augment.d.ts +++ b/apps/pigment-next-app/src/augment.d.ts @@ -1,6 +1,6 @@ -import type { ExtendTheme } from '@pigmentcss/react'; +import type { ExtendTheme } from '@pigment-css/react'; -declare module '@pigmentcss/react/theme' { +declare module '@pigment-css/react/theme' { interface ThemeTokens { 'max-width': string; 'border-radius': string; diff --git a/apps/pigment-next-app/src/components/Box.jsx b/apps/pigment-next-app/src/components/Box.jsx index 938492ee6f5903..930ee1bdf985ed 100644 --- a/apps/pigment-next-app/src/components/Box.jsx +++ b/apps/pigment-next-app/src/components/Box.jsx @@ -1,4 +1,4 @@ -import { generateAtomics } from '@pigmentcss/react'; +import { generateAtomics } from '@pigment-css/react'; const atomics = generateAtomics(({ theme }) => ({ conditions: Object.keys(theme.breakpoints.values).reduce((acc, breakpoint) => { diff --git a/apps/pigment-next-app/src/components/Slider/ZeroSlider.tsx b/apps/pigment-next-app/src/components/Slider/ZeroSlider.tsx index ac3757a241d1de..cef2f605d9c5cf 100644 --- a/apps/pigment-next-app/src/components/Slider/ZeroSlider.tsx +++ b/apps/pigment-next-app/src/components/Slider/ZeroSlider.tsx @@ -8,7 +8,7 @@ import { getSliderUtilityClass, } from '@mui/material/Slider'; import { isHostComponent, useSlotProps } from '@mui/base/utils'; -import { styled } from '@pigmentcss/react'; +import { styled } from '@pigment-css/react'; import { capitalize } from '@mui/material/utils'; import SliderValueLabel from '@mui/material/Slider/SliderValueLabel'; import { useSlider, valueToPercent } from '@mui/base/useSlider'; diff --git a/apps/pigment-vite-app/README.md b/apps/pigment-vite-app/README.md index 891a06e2509823..40f1dcc6ced468 100644 --- a/apps/pigment-vite-app/README.md +++ b/apps/pigment-vite-app/README.md @@ -7,8 +7,8 @@ This project is not part of the workspace yet. You can either run `pnpm build` command to build all the packages, or you need to build, the the minimum - -1. `@pigmentcss/react` -2. `@pigmentcss/vite-plugin` +1. `@pigment-css/react` +2. `@pigment-css/vite-plugin` Make sure you have also run `pnpm release:build` at least once because we also use `@mui/material` and `@mui/system` packages. On subsequent runs, you can only build the above packages using - @@ -24,4 +24,4 @@ After building, you can run the project by changing into the directory and then Optionally, before running the dev server, you can run `pnpm vite optimize --force` if it logged some error during `pnpm vite`. -If you see and error like package `@pigmentcss/react` not found, add it as a peer-dependency in `@mui/material`'s `package.json` file and run `pnpm build` and `pnpm install` again. Make sure to not push this change to git. +If you see and error like package `@pigment-css/react` not found, add it as a peer-dependency in `@mui/material`'s `package.json` file and run `pnpm build` and `pnpm install` again. Make sure to not push this change to git. diff --git a/apps/pigment-vite-app/package.json b/apps/pigment-vite-app/package.json index 7499c0a565f8a0..4c4c70d581786e 100644 --- a/apps/pigment-vite-app/package.json +++ b/apps/pigment-vite-app/package.json @@ -9,12 +9,11 @@ "build": "vite build" }, "dependencies": { - "@pigmentcss/react": "file:../../packages/pigment-react", + "@pigment-css/react": "file:../../packages/pigment-react", "@mui/utils": "file:../../packages/mui-utils/build", "@mui/base": "file:../../packages/mui-base/build", "@mui/material": "file:../../packages/mui-material/build", "@mui/system": "file:../../packages/mui-system/build", - "@mui/material-nextjs": "file:../../packages/mui-material-nextjs/build", "@mui/icons-material": "file:../../packages/mui-icons-material/build", "clsx": "^2.1.0", "local-ui-lib": "workspace:^", @@ -27,7 +26,7 @@ "@babel/preset-env": "^7.23.9", "@babel/preset-react": "^7.23.3", "@babel/preset-typescript": "^7.23.3", - "@pigmentcss/vite-plugin": "file:../../packages/pigment-vite-plugin", + "@pigment-css/vite-plugin": "file:../../packages/pigment-vite-plugin", "@types/react": "^18.2.55", "@types/react-dom": "^18.2.19", "@vitejs/plugin-react": "^4.2.1", diff --git a/apps/pigment-vite-app/src/App.tsx b/apps/pigment-vite-app/src/App.tsx index 6bfbb8e4930c56..526e5a872499cf 100644 --- a/apps/pigment-vite-app/src/App.tsx +++ b/apps/pigment-vite-app/src/App.tsx @@ -1,5 +1,5 @@ import * as React from 'react'; -import { styled, generateAtomics } from '@pigmentcss/react'; +import { styled, generateAtomics } from '@pigment-css/react'; import type { Breakpoint } from '@mui/system'; import { Button, bounceAnim } from 'local-ui-lib'; import Slider from './Slider/ZeroSlider'; diff --git a/apps/pigment-vite-app/src/Box.jsx b/apps/pigment-vite-app/src/Box.jsx index 938492ee6f5903..930ee1bdf985ed 100644 --- a/apps/pigment-vite-app/src/Box.jsx +++ b/apps/pigment-vite-app/src/Box.jsx @@ -1,4 +1,4 @@ -import { generateAtomics } from '@pigmentcss/react'; +import { generateAtomics } from '@pigment-css/react'; const atomics = generateAtomics(({ theme }) => ({ conditions: Object.keys(theme.breakpoints.values).reduce((acc, breakpoint) => { diff --git a/apps/pigment-vite-app/src/Layout.tsx b/apps/pigment-vite-app/src/Layout.tsx index 92f476c84477c5..06afb2f9251928 100644 --- a/apps/pigment-vite-app/src/Layout.tsx +++ b/apps/pigment-vite-app/src/Layout.tsx @@ -1,5 +1,5 @@ import * as React from 'react'; -import { styled } from '@pigmentcss/react'; +import { styled } from '@pigment-css/react'; const Main = styled('div')(({ theme }) => ({ display: 'flex', diff --git a/apps/pigment-vite-app/src/Slider/ZeroSlider.tsx b/apps/pigment-vite-app/src/Slider/ZeroSlider.tsx index 312b53791a82bb..81de28da9f9b23 100644 --- a/apps/pigment-vite-app/src/Slider/ZeroSlider.tsx +++ b/apps/pigment-vite-app/src/Slider/ZeroSlider.tsx @@ -8,7 +8,7 @@ import { getSliderUtilityClass, } from '@mui/material/Slider'; import { isHostComponent, useSlotProps } from '@mui/base/utils'; -import { styled } from '@pigmentcss/react'; +import { styled } from '@pigment-css/react'; import { capitalize } from '@mui/material/utils'; import SliderValueLabel from '@mui/material/Slider/SliderValueLabel'; import { useSlider, valueToPercent } from '@mui/base/useSlider'; diff --git a/apps/pigment-vite-app/src/augment.ts b/apps/pigment-vite-app/src/augment.ts index cdad20e18f18f4..1ce2a8f663e557 100644 --- a/apps/pigment-vite-app/src/augment.ts +++ b/apps/pigment-vite-app/src/augment.ts @@ -1,7 +1,7 @@ import type { experimental_extendTheme } from '@mui/material/styles'; -import '@pigmentcss/react/theme'; +import '@pigment-css/react/theme'; -declare module '@pigmentcss/react/theme' { +declare module '@pigment-css/react/theme' { export interface ThemeArgs { theme: ReturnType & { applyDarkStyles(obj: T): Record; diff --git a/apps/pigment-vite-app/src/component.tsx b/apps/pigment-vite-app/src/component.tsx index 1574ffb134df88..a6c1861c3c115f 100644 --- a/apps/pigment-vite-app/src/component.tsx +++ b/apps/pigment-vite-app/src/component.tsx @@ -1,4 +1,4 @@ -import { styled } from '@pigmentcss/react'; +import { styled } from '@pigment-css/react'; export function Component() { return null; diff --git a/apps/pigment-vite-app/src/extend-zero.ts b/apps/pigment-vite-app/src/extend-zero.ts index 578bffe1d1dfe5..0d111cdfda4d6b 100644 --- a/apps/pigment-vite-app/src/extend-zero.ts +++ b/apps/pigment-vite-app/src/extend-zero.ts @@ -1,6 +1,6 @@ import type { experimental_extendTheme } from '@mui/material/styles'; -declare module '@pigmentcss/react/theme' { +declare module '@pigment-css/react/theme' { interface ThemeArgs { theme: ReturnType & { applyDarkStyles(obj: T): Record; diff --git a/apps/pigment-vite-app/src/main.tsx b/apps/pigment-vite-app/src/main.tsx index 96bdf75f62712a..e0f34c2030ede3 100644 --- a/apps/pigment-vite-app/src/main.tsx +++ b/apps/pigment-vite-app/src/main.tsx @@ -4,7 +4,7 @@ import { BrowserRouter as Router, useRoutes } from 'react-router-dom'; import { ThemeProvider, createTheme } from '@mui/material/styles'; import CssBaseline from '@mui/material/CssBaseline'; import routes from '~react-pages'; -import '@pigmentcss/react/styles.css'; +import '@pigment-css/react/styles.css'; function App() { return Loading...

}>{useRoutes(routes)}
; diff --git a/apps/pigment-vite-app/src/pages/material-ui/react-alert.tsx b/apps/pigment-vite-app/src/pages/material-ui/react-alert.tsx new file mode 100644 index 00000000000000..830003ff827170 --- /dev/null +++ b/apps/pigment-vite-app/src/pages/material-ui/react-alert.tsx @@ -0,0 +1,73 @@ +import * as React from 'react'; +import MaterialUILayout from '../../Layout'; +import ActionAlerts from '../../../../../docs/data/material/components/alert/ActionAlerts.tsx'; +import BasicAlerts from '../../../../../docs/data/material/components/alert/BasicAlerts.tsx'; +import ColorAlerts from '../../../../../docs/data/material/components/alert/ColorAlerts.tsx'; +import DescriptionAlerts from '../../../../../docs/data/material/components/alert/DescriptionAlerts.tsx'; +import FilledAlerts from '../../../../../docs/data/material/components/alert/FilledAlerts.tsx'; +import IconAlerts from '../../../../../docs/data/material/components/alert/IconAlerts.tsx'; +import OutlinedAlerts from '../../../../../docs/data/material/components/alert/OutlinedAlerts.tsx'; +import SimpleAlert from '../../../../../docs/data/material/components/alert/SimpleAlert.tsx'; +import TransitionAlerts from '../../../../../docs/data/material/components/alert/TransitionAlerts.tsx'; + +export default function Alert() { + return ( + +

Alert

+
+

Action Alerts

+
+ +
+
+
+

Basic Alerts

+
+ +
+
+
+

Color Alerts

+
+ +
+
+
+

Description Alerts

+
+ +
+
+
+

Filled Alerts

+
+ +
+
+
+

Icon Alerts

+
+ +
+
+
+

Outlined Alerts

+
+ +
+
+
+

Simple Alert

+
+ +
+
+
+

Transition Alerts

+
+ +
+
+
+ ); +} diff --git a/apps/pigment-vite-app/src/pages/material-ui/react-badge.tsx b/apps/pigment-vite-app/src/pages/material-ui/react-badge.tsx new file mode 100644 index 00000000000000..8bd470dca20dfb --- /dev/null +++ b/apps/pigment-vite-app/src/pages/material-ui/react-badge.tsx @@ -0,0 +1,73 @@ +import * as React from 'react'; +import MaterialUILayout from '../../Layout'; +import AccessibleBadges from '../../../../../docs/data/material/components/badges/AccessibleBadges.tsx'; +import BadgeMax from '../../../../../docs/data/material/components/badges/BadgeMax.tsx'; +import BadgeOverlap from '../../../../../docs/data/material/components/badges/BadgeOverlap.tsx'; +import BadgeVisibility from '../../../../../docs/data/material/components/badges/BadgeVisibility.tsx'; +import ColorBadge from '../../../../../docs/data/material/components/badges/ColorBadge.tsx'; +import CustomizedBadges from '../../../../../docs/data/material/components/badges/CustomizedBadges.tsx'; +import DotBadge from '../../../../../docs/data/material/components/badges/DotBadge.tsx'; +import ShowZeroBadge from '../../../../../docs/data/material/components/badges/ShowZeroBadge.tsx'; +import SimpleBadge from '../../../../../docs/data/material/components/badges/SimpleBadge.tsx'; + +export default function Badges() { + return ( + +

Badges

+
+

Accessible Badges

+
+ +
+
+
+

Badge Max

+
+ +
+
+
+

Badge Overlap

+
+ +
+
+
+

Badge Visibility

+
+ +
+
+
+

Color Badge

+
+ +
+
+
+

Customized Badges

+
+ +
+
+
+

Dot Badge

+
+ +
+
+
+

Show Zero Badge

+
+ +
+
+
+

Simple Badge

+
+ +
+
+
+ ); +} diff --git a/apps/pigment-vite-app/src/pages/material-ui/react-switch.tsx b/apps/pigment-vite-app/src/pages/material-ui/react-switch.tsx new file mode 100644 index 00000000000000..b16762ace16826 --- /dev/null +++ b/apps/pigment-vite-app/src/pages/material-ui/react-switch.tsx @@ -0,0 +1,66 @@ +import * as React from 'react'; +import MaterialUILayout from '../../Layout'; +import BasicSwitches from '../../../../../docs/data/material/components/switches/BasicSwitches.tsx'; +import ColorSwitches from '../../../../../docs/data/material/components/switches/ColorSwitches.tsx'; +import ControlledSwitches from '../../../../../docs/data/material/components/switches/ControlledSwitches.tsx'; +import CustomizedSwitches from '../../../../../docs/data/material/components/switches/CustomizedSwitches.tsx'; +import FormControlLabelPosition from '../../../../../docs/data/material/components/switches/FormControlLabelPosition.tsx'; +import SwitchLabels from '../../../../../docs/data/material/components/switches/SwitchLabels.tsx'; +import SwitchesGroup from '../../../../../docs/data/material/components/switches/SwitchesGroup.tsx'; +import SwitchesSize from '../../../../../docs/data/material/components/switches/SwitchesSize.tsx'; + +export default function Switches() { + return ( + +

Switches

+
+

Basic Switches

+
+ +
+
+
+

Color Switches

+
+ +
+
+
+

Controlled Switches

+
+ +
+
+
+

Customized Switches

+
+ +
+
+
+

Form Control Label Position

+
+ +
+
+
+

Switch Labels

+
+ +
+
+
+

Switches Group

+
+ +
+
+
+

Switches Size

+
+ +
+
+
+ ); +} diff --git a/apps/pigment-vite-app/vite.config.ts b/apps/pigment-vite-app/vite.config.ts index b60ca64ba31f9b..814f407f2231db 100644 --- a/apps/pigment-vite-app/vite.config.ts +++ b/apps/pigment-vite-app/vite.config.ts @@ -1,7 +1,7 @@ import { defineConfig, splitVendorChunkPlugin } from 'vite'; import reactPlugin from '@vitejs/plugin-react'; import Pages from 'vite-plugin-pages'; -import { pigment } from '@pigmentcss/vite-plugin'; +import { pigment } from '@pigment-css/vite-plugin'; import { experimental_extendTheme as extendTheme } from '@mui/material/styles'; const theme = extendTheme(); diff --git a/apps/pnpm-lock.yaml b/apps/pnpm-lock.yaml index eda05ad8846c0f..e0c6444c44b2ad 100644 --- a/apps/pnpm-lock.yaml +++ b/apps/pnpm-lock.yaml @@ -46,7 +46,7 @@ importers: specifier: ^7.20.5 version: 7.20.5 '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/doctrine': specifier: ^0.0.9 @@ -110,7 +110,7 @@ importers: specifier: ^3.1.3 version: 3.1.3 '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/mocha': specifier: ^10.0.6 @@ -162,7 +162,7 @@ importers: specifier: ^14.5.2 version: 14.5.2(@testing-library/dom@9.3.4) '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/prop-types': specifier: ^15.7.11 @@ -214,17 +214,17 @@ importers: specifier: ^1.0.10 version: 1.0.10(jscodeshift@0.13.1) postcss: - specifier: ^8.4.33 + specifier: ^8.4.35 version: 8.4.35 postcss-cli: - specifier: ^8.0.0 + specifier: ^8.3.1 version: 8.3.1(postcss@8.4.35) yargs: specifier: ^17.7.2 version: 17.7.2 devDependencies: '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/jscodeshift': specifier: 0.11.5 @@ -272,7 +272,7 @@ importers: version: 18.2.55 next: specifier: ^13.5.1 - version: 13.5.1(@babel/core@7.23.9)(react-dom@18.2.0)(react@18.2.0) + version: 13.5.1(react-dom@18.2.0)(react@18.2.0) react: specifier: ^18.2.0 version: 18.2.0 @@ -285,7 +285,7 @@ importers: version: 7.11.1 devDependencies: '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 chai: specifier: ^4.4.1 @@ -310,7 +310,7 @@ importers: specifier: workspace:^ version: link:../mui-material/build '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/react': specifier: ^18.2.55 @@ -393,7 +393,7 @@ importers: specifier: workspace:^ version: link:../mui-material/build '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/prop-types': specifier: ^15.7.11 @@ -418,7 +418,7 @@ importers: version: 4.17.21 next: specifier: ^13.4.19 - version: 13.5.1(@babel/core@7.23.9)(react-dom@18.2.0)(react@18.2.0) + version: 13.5.1(react-dom@18.2.0)(react@18.2.0) react: specifier: ^18.2.0 version: 18.2.0 @@ -467,7 +467,7 @@ importers: specifier: workspace:^ version: link:../test-utils '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/prop-types': specifier: ^15.7.11 @@ -559,7 +559,7 @@ importers: specifier: ^14.5.2 version: 14.5.2(@testing-library/dom@9.3.4) '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/prop-types': specifier: ^15.7.11 @@ -580,8 +580,8 @@ importers: specifier: ^0.1.2 version: 0.1.2 express: - specifier: ^4.18.2 - version: 4.18.2 + specifier: ^4.18.3 + version: 4.18.3 fast-glob: specifier: ^3.3.2 version: 3.3.2 @@ -592,8 +592,8 @@ importers: specifier: ^4.17.21 version: 4.17.21 playwright: - specifier: ^1.41.2 - version: 1.41.2 + specifier: ^1.42.1 + version: 1.42.1 react: specifier: ^18.2.0 version: 18.2.0 @@ -633,7 +633,7 @@ importers: version: 7.23.9 '@emotion/styled': specifier: ^11.3.0 - version: 11.11.0(@emotion/react@11.11.3)(@types/react@18.2.55)(react@18.2.0) + version: 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.55)(react@18.2.0) '@mui/base': specifier: workspace:* version: link:../mui-base/build @@ -666,8 +666,8 @@ importers: version: 4.4.5(react-dom@18.2.0)(react@18.2.0) devDependencies: '@emotion/react': - specifier: ^11.11.3 - version: 11.11.3(@types/react@18.2.55)(react@18.2.0) + specifier: ^11.11.4 + version: 11.11.4(@types/react@18.2.55)(react@18.2.0) '@mui-internal/test-utils': specifier: workspace:^ version: link:../test-utils @@ -678,7 +678,7 @@ importers: specifier: ^14.5.2 version: 14.5.2(@testing-library/dom@9.3.4) '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/prop-types': specifier: ^15.7.11 @@ -728,8 +728,8 @@ importers: specifier: ^11.11.0 version: 11.11.0 '@emotion/react': - specifier: ^11.11.3 - version: 11.11.3(@types/react@18.2.55)(react@18.2.0) + specifier: ^11.11.4 + version: 11.11.4(@types/react@18.2.55)(react@18.2.0) '@emotion/server': specifier: ^11.11.0 version: 11.11.0 @@ -738,7 +738,7 @@ importers: version: 18.2.55 next: specifier: 13.5.1 - version: 13.5.1(@babel/core@7.23.9)(react-dom@18.2.0)(react@18.2.0) + version: 13.5.1(react-dom@18.2.0)(react@18.2.0) react: specifier: ^18.2.0 version: 18.2.0 @@ -763,7 +763,7 @@ importers: specifier: workspace:^ version: link:../mui-types/build '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/react': specifier: ^18.2.55 @@ -792,11 +792,11 @@ importers: version: 15.8.1 devDependencies: '@emotion/react': - specifier: ^11.11.3 - version: 11.11.3(@types/react@18.2.55)(react@18.2.0) + specifier: ^11.11.4 + version: 11.11.4(@types/react@18.2.55)(react@18.2.0) '@emotion/styled': specifier: ^11.11.0 - version: 11.11.0(@emotion/react@11.11.3)(@types/react@18.2.55)(react@18.2.0) + version: 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.55)(react@18.2.0) '@mui-internal/test-utils': specifier: workspace:^ version: link:../test-utils @@ -804,7 +804,7 @@ importers: specifier: workspace:* version: link:build '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/react': specifier: ^18.2.55 @@ -839,7 +839,7 @@ importers: specifier: workspace:* version: link:build '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/hoist-non-react-statics': specifier: ^3.3.5 @@ -919,7 +919,7 @@ importers: specifier: workspace:^ version: link:../mui-material/build '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/react': specifier: ^18.2.55 @@ -972,11 +972,11 @@ importers: version: 15.8.1 devDependencies: '@emotion/react': - specifier: ^11.11.3 - version: 11.11.3(@types/react@18.2.55)(react@18.2.0) + specifier: ^11.11.4 + version: 11.11.4(@types/react@18.2.55)(react@18.2.0) '@emotion/styled': specifier: ^11.11.0 - version: 11.11.0(@emotion/react@11.11.3)(@types/react@18.2.55)(react@18.2.0) + version: 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.55)(react@18.2.0) '@mui-internal/test-utils': specifier: workspace:^ version: link:../test-utils @@ -987,7 +987,7 @@ importers: specifier: workspace:* version: link:build '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/prop-types': specifier: ^15.7.11 @@ -1053,7 +1053,7 @@ importers: specifier: workspace:^ version: link:../mui-types/build '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/mocha': specifier: ^10.0.6 @@ -1089,13 +1089,13 @@ importers: ../packages/pigment-nextjs-plugin: dependencies: - '@pigmentcss/unplugin': + '@pigment-css/unplugin': specifier: workspace:^ version: link:../pigment-unplugin devDependencies: next: specifier: ^13.5.1 - version: 13.5.1(@babel/core@7.23.9)(react-dom@18.2.0)(react@18.2.0) + version: 13.5.1(react-dom@18.2.0)(react@18.2.0) ../packages/pigment-react: dependencies: @@ -1118,26 +1118,26 @@ importers: specifier: ^11.11.2 version: 11.11.2 '@emotion/react': - specifier: ^11.11.3 - version: 11.11.3(@types/react@18.2.55)(react@18.2.0) + specifier: ^11.11.4 + version: 11.11.4(@types/react@18.2.55)(react@18.2.0) '@emotion/serialize': specifier: ^1.1.3 version: 1.1.3 '@emotion/styled': specifier: ^11.11.0 - version: 11.11.0(@emotion/react@11.11.3)(@types/react@18.2.55)(react@18.2.0) + version: 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.55)(react@18.2.0) '@mui/system': specifier: workspace:^ version: link:../mui-system/build '@wyw-in-js/processor-utils': - specifier: ^0.4.1 - version: 0.4.1 + specifier: ^0.5.0 + version: 0.5.0 '@wyw-in-js/shared': - specifier: ^0.4.1 - version: 0.4.1 + specifier: ^0.5.0 + version: 0.5.0 '@wyw-in-js/transform': - specifier: ^0.4.1 - version: 0.4.1(typescript@5.3.3) + specifier: ^0.5.0 + version: 0.5.0(typescript@5.3.3) clsx: specifier: ^2.1.0 version: 2.1.0 @@ -1190,15 +1190,15 @@ importers: '@babel/core': specifier: ^7.23.9 version: 7.23.9 - '@pigmentcss/react': + '@pigment-css/react': specifier: workspace:^ version: link:../pigment-react '@wyw-in-js/shared': - specifier: ^0.4.1 - version: 0.4.1 + specifier: ^0.5.0 + version: 0.5.0 '@wyw-in-js/transform': - specifier: ^0.4.1 - version: 0.4.1(typescript@5.3.3) + specifier: ^0.5.0 + version: 0.5.0(typescript@5.3.3) babel-plugin-transform-react-remove-prop-types: specifier: ^0.4.24 version: 0.4.24 @@ -1218,15 +1218,15 @@ importers: '@babel/preset-typescript': specifier: ^7.23.3 version: 7.23.3(@babel/core@7.23.9) - '@pigmentcss/react': + '@pigment-css/react': specifier: workspace:^ version: link:../pigment-react '@wyw-in-js/shared': - specifier: ^0.4.1 - version: 0.4.1 + specifier: ^0.5.0 + version: 0.5.0 '@wyw-in-js/transform': - specifier: ^0.4.1 - version: 0.4.1(typescript@5.3.3) + specifier: ^0.5.0 + version: 0.5.0(typescript@5.3.3) babel-plugin-transform-react-remove-prop-types: specifier: ^0.4.24 version: 0.4.24 @@ -1256,8 +1256,8 @@ importers: specifier: ^11.11.0 version: 11.11.0 '@emotion/react': - specifier: ^11.11.3 - version: 11.11.3(@types/react@18.2.55)(react@18.2.0) + specifier: ^11.11.4 + version: 11.11.4(@types/react@18.2.55)(react@18.2.0) '@mnajdova/enzyme-adapter-react-18': specifier: ^0.2.0 version: 0.2.0(enzyme@3.11.0)(react-dom@18.2.0)(react@18.2.0) @@ -1292,11 +1292,11 @@ importers: specifier: ^4.17.21 version: 4.17.21 mocha: - specifier: ^10.2.0 + specifier: ^10.3.0 version: 10.3.0 playwright: - specifier: ^1.41.2 - version: 1.41.2 + specifier: ^1.42.1 + version: 1.42.1 prop-types: specifier: ^15.8.1 version: 15.8.1 @@ -1314,7 +1314,7 @@ importers: version: 15.2.0 devDependencies: '@types/chai': - specifier: ^4.3.11 + specifier: ^4.3.12 version: 4.3.12 '@types/chai-dom': specifier: ^1.11.3 @@ -1348,7 +1348,7 @@ importers: local-ui-lib: dependencies: - '@pigmentcss/react': + '@pigment-css/react': specifier: file:../../packages/pigment-react version: file:../packages/pigment-react(@types/react@18.2.55)(react@18.2.0)(typescript@5.3.3) @@ -1362,20 +1362,20 @@ importers: version: file:../packages/mui-base/build(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0) '@mui/icons-material': specifier: file:../../packages/mui-icons-material/build - version: file:../packages/mui-icons-material/build(@mui/material@5.15.11)(@types/react@18.2.55)(react@18.2.0) + version: file:../packages/mui-icons-material/build(@mui/material@5.15.12)(@types/react@18.2.55)(react@18.2.0) '@mui/material': specifier: file:../../packages/mui-material/build - version: file:../packages/mui-material/build(@emotion/react@11.11.3)(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0) + version: file:../packages/mui-material/build(@emotion/react@11.11.4)(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0) '@mui/material-nextjs': specifier: file:../../packages/mui-material-nextjs/build - version: file:../packages/mui-material-nextjs/build(@emotion/cache@11.11.0)(@mui/material@5.15.11)(@types/react@18.2.55)(next@14.1.0)(react@18.2.0) + version: file:../packages/mui-material-nextjs/build(@emotion/cache@11.11.0)(@mui/material@5.15.12)(@types/react@18.2.55)(next@14.1.0)(react@18.2.0) '@mui/system': specifier: file:../../packages/mui-system/build - version: file:../packages/mui-system/build(@emotion/react@11.11.3)(@types/react@18.2.55)(react@18.2.0) + version: file:../packages/mui-system/build(@emotion/react@11.11.4)(@types/react@18.2.55)(react@18.2.0) '@mui/utils': specifier: file:../../packages/mui-utils/build version: file:../packages/mui-utils/build(@types/react@18.2.55)(react@18.2.0) - '@pigmentcss/react': + '@pigment-css/react': specifier: file:../../packages/pigment-react version: file:../packages/pigment-react(@types/react@18.2.55)(react@18.2.0)(typescript@5.3.3) local-ui-lib: @@ -1391,10 +1391,10 @@ importers: specifier: ^18.2.0 version: 18.2.0(react@18.2.0) devDependencies: - '@pigmentcss/nextjs-plugin': + '@pigment-css/nextjs-plugin': specifier: file:../../packages/pigment-nextjs-plugin version: file:../packages/pigment-nextjs-plugin(next@14.1.0) - '@pigmentcss/unplugin': + '@pigment-css/unplugin': specifier: file:../../packages/pigment-unplugin version: file:../packages/pigment-unplugin(typescript@5.3.3) '@types/node': @@ -1420,20 +1420,17 @@ importers: version: file:../packages/mui-base/build(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0) '@mui/icons-material': specifier: file:../../packages/mui-icons-material/build - version: file:../packages/mui-icons-material/build(@mui/material@5.15.11)(@types/react@18.2.55)(react@18.2.0) + version: file:../packages/mui-icons-material/build(@mui/material@5.15.12)(@types/react@18.2.55)(react@18.2.0) '@mui/material': specifier: file:../../packages/mui-material/build - version: file:../packages/mui-material/build(@emotion/react@11.11.3)(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0) - '@mui/material-nextjs': - specifier: file:../../packages/mui-material-nextjs/build - version: file:../packages/mui-material-nextjs/build(@mui/material@5.15.11)(@types/react@18.2.55)(next@13.5.1)(react@18.2.0) + version: file:../packages/mui-material/build(@emotion/react@11.11.4)(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0) '@mui/system': specifier: file:../../packages/mui-system/build - version: file:../packages/mui-system/build(@emotion/react@11.11.3)(@types/react@18.2.55)(react@18.2.0) + version: file:../packages/mui-system/build(@emotion/react@11.11.4)(@types/react@18.2.55)(react@18.2.0) '@mui/utils': specifier: file:../../packages/mui-utils/build version: file:../packages/mui-utils/build(@types/react@18.2.55)(react@18.2.0) - '@pigmentcss/react': + '@pigment-css/react': specifier: file:../../packages/pigment-react version: file:../packages/pigment-react(@types/react@18.2.55)(react@18.2.0)(typescript@5.3.3) clsx: @@ -1464,7 +1461,7 @@ importers: '@babel/preset-typescript': specifier: ^7.23.3 version: 7.23.3(@babel/core@7.23.9) - '@pigmentcss/vite-plugin': + '@pigment-css/vite-plugin': specifier: file:../../packages/pigment-vite-plugin version: file:../packages/pigment-vite-plugin(vite@5.0.12) '@types/react': @@ -2831,6 +2828,27 @@ packages: '@types/react': 18.2.55 hoist-non-react-statics: 3.3.2 react: 18.2.0 + dev: false + + /@emotion/react@11.11.4(@types/react@18.2.55)(react@18.2.0): + resolution: {integrity: sha512-t8AjMlF0gHpvvxk5mAtCqR4vmxiGHCeJBaQO6gncUSdklELOgtwjerNY2yuJNfwnc6vi16U/+uMF+afIawJ9iw==} + peerDependencies: + '@types/react': '*' + react: '>=16.8.0' + peerDependenciesMeta: + '@types/react': + optional: true + dependencies: + '@babel/runtime': 7.23.9 + '@emotion/babel-plugin': 11.11.0 + '@emotion/cache': 11.11.0 + '@emotion/serialize': 1.1.3 + '@emotion/use-insertion-effect-with-fallbacks': 1.0.1(react@18.2.0) + '@emotion/utils': 1.2.1 + '@emotion/weak-memoize': 0.3.1 + '@types/react': 18.2.55 + hoist-non-react-statics: 3.3.2 + react: 18.2.0 /@emotion/serialize@1.1.3: resolution: {integrity: sha512-iD4D6QVZFDhcbH0RAG1uVu1CwVLMWUkCvAqqlewO/rxf8+87yIBAlt4+AxMiiKPLs5hFc0owNk/sLLAOROw3cA==} @@ -2877,6 +2895,27 @@ packages: '@emotion/utils': 1.2.1 '@types/react': 18.2.55 react: 18.2.0 + dev: false + + /@emotion/styled@11.11.0(@emotion/react@11.11.4)(@types/react@18.2.55)(react@18.2.0): + resolution: {integrity: sha512-hM5Nnvu9P3midq5aaXj4I+lnSfNi7Pmd4EWk1fOZ3pxookaQTNew6bp4JaCBYM4HVFZF9g7UjJmsUmC2JlxOng==} + peerDependencies: + '@emotion/react': ^11.0.0-rc.0 + '@types/react': '*' + react: '>=16.8.0' + peerDependenciesMeta: + '@types/react': + optional: true + dependencies: + '@babel/runtime': 7.23.9 + '@emotion/babel-plugin': 11.11.0 + '@emotion/is-prop-valid': 1.2.1 + '@emotion/react': 11.11.4(@types/react@18.2.55)(react@18.2.0) + '@emotion/serialize': 1.1.3 + '@emotion/use-insertion-effect-with-fallbacks': 1.0.1(react@18.2.0) + '@emotion/utils': 1.2.1 + '@types/react': 18.2.55 + react: 18.2.0 /@emotion/unitless@0.8.0: resolution: {integrity: sha512-VINS5vEYAscRl2ZUDiT3uMPlrFQupiKgHz5AA4bCH1miKBg4qtwkim1qPmJj/4WG6TreYMY111rEFsjupcOKHw==} @@ -3257,6 +3296,7 @@ packages: /@next/env@13.5.1: resolution: {integrity: sha512-CIMWiOTyflFn/GFx33iYXkgLSQsMQZV4jB91qaj/TfxGaGOXxn8C1j72TaUSPIyN7ziS/AYG46kGmnvuk1oOpg==} + dev: true /@next/env@14.1.0: resolution: {integrity: sha512-Py8zIo+02ht82brwwhTg36iogzFqGLPXlRGKQw5s+qP/kMNc4MAyDeEwBKDijk6zTIbegEgu8Qy7C1LboslQAw==} @@ -3267,6 +3307,7 @@ packages: cpu: [arm64] os: [darwin] requiresBuild: true + dev: true optional: true /@next/swc-darwin-arm64@14.1.0: @@ -3283,6 +3324,7 @@ packages: cpu: [x64] os: [darwin] requiresBuild: true + dev: true optional: true /@next/swc-darwin-x64@14.1.0: @@ -3299,6 +3341,7 @@ packages: cpu: [arm64] os: [linux] requiresBuild: true + dev: true optional: true /@next/swc-linux-arm64-gnu@14.1.0: @@ -3315,6 +3358,7 @@ packages: cpu: [arm64] os: [linux] requiresBuild: true + dev: true optional: true /@next/swc-linux-arm64-musl@14.1.0: @@ -3331,6 +3375,7 @@ packages: cpu: [x64] os: [linux] requiresBuild: true + dev: true optional: true /@next/swc-linux-x64-gnu@14.1.0: @@ -3347,6 +3392,7 @@ packages: cpu: [x64] os: [linux] requiresBuild: true + dev: true optional: true /@next/swc-linux-x64-musl@14.1.0: @@ -3363,6 +3409,7 @@ packages: cpu: [arm64] os: [win32] requiresBuild: true + dev: true optional: true /@next/swc-win32-arm64-msvc@14.1.0: @@ -3379,6 +3426,7 @@ packages: cpu: [ia32] os: [win32] requiresBuild: true + dev: true optional: true /@next/swc-win32-ia32-msvc@14.1.0: @@ -3395,6 +3443,7 @@ packages: cpu: [x64] os: [win32] requiresBuild: true + dev: true optional: true /@next/swc-win32-x64-msvc@14.1.0: @@ -3877,17 +3926,17 @@ packages: - supports-color dev: true - /@wyw-in-js/processor-utils@0.4.1: - resolution: {integrity: sha512-0MVgPC3Svplm2WB4G4eSLLfx8n1EaIpClMXqNcTmfyrFcpLjYYcSXDP7aVgQVvy5wQCqqq+EmPbnU6yXq8X19w==} + /@wyw-in-js/processor-utils@0.5.0: + resolution: {integrity: sha512-3sRwuDTMy2GmD+44bhCTcBasCrjBexzYRzhxkmMrX49cpVDmQOH+4O7kX5OMRbmzMXe6Z5MsnxIlDlm3bJlcww==} engines: {node: '>=16.0.0'} dependencies: '@babel/generator': 7.23.6 - '@wyw-in-js/shared': 0.4.1 + '@wyw-in-js/shared': 0.5.0 transitivePeerDependencies: - supports-color - /@wyw-in-js/shared@0.4.1: - resolution: {integrity: sha512-luKAAP6augn+j7EE9bcVP1chs5RdtmJx1PbRIqT8j12oP2YV32fvhHFX/99XxPujYLxFIexZrhJkNKHnL5uyKA==} + /@wyw-in-js/shared@0.5.0: + resolution: {integrity: sha512-W6Uic3cqRs75XZfXGOYH/0fADbl3Wz/kqnNaowgyNTdTN7/9vdlqk/D/gMT5WGolj4t418+rYe2FHHs0LdlmvA==} engines: {node: '>=16.0.0'} dependencies: debug: 4.3.4(supports-color@8.1.1) @@ -3896,8 +3945,8 @@ packages: transitivePeerDependencies: - supports-color - /@wyw-in-js/transform@0.4.1(typescript@5.3.3): - resolution: {integrity: sha512-MhU/A58QJ7SkAjVNgvmoa5kbg7h28u4RkwGxm0/qt49sPMSlY8AsIW4wXX2k0rX5GTKHASVcNKrSywE2acjzxQ==} + /@wyw-in-js/transform@0.5.0(typescript@5.3.3): + resolution: {integrity: sha512-tpa2/FsB30fdXB1E+9MmfxQYbRgLv/+VMKzpBKNraDH39zwnA2eGGAEho5gpqK40cEV7NH6zhVbaBcEnV0HQyw==} engines: {node: '>=16.0.0'} dependencies: '@babel/core': 7.23.9 @@ -3907,8 +3956,8 @@ packages: '@babel/template': 7.23.9 '@babel/traverse': 7.23.9 '@babel/types': 7.23.9 - '@wyw-in-js/processor-utils': 0.4.1 - '@wyw-in-js/shared': 0.4.1 + '@wyw-in-js/processor-utils': 0.5.0 + '@wyw-in-js/shared': 0.5.0 babel-merge: 3.0.0(@babel/core@7.23.9) cosmiconfig: 8.3.6(typescript@5.3.3) happy-dom: 12.10.3 @@ -4242,8 +4291,8 @@ packages: resolution: {integrity: sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==} engines: {node: '>=8'} - /body-parser@1.20.1: - resolution: {integrity: sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==} + /body-parser@1.20.2: + resolution: {integrity: sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==} engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} dependencies: bytes: 3.1.2 @@ -4255,7 +4304,7 @@ packages: iconv-lite: 0.4.24 on-finished: 2.4.1 qs: 6.11.0 - raw-body: 2.5.1 + raw-body: 2.5.2 type-is: 1.6.18 unpipe: 1.0.0 transitivePeerDependencies: @@ -5317,13 +5366,13 @@ packages: - supports-color dev: false - /express@4.18.2: - resolution: {integrity: sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==} + /express@4.18.3: + resolution: {integrity: sha512-6VyCijWQ+9O7WuVMTRBTl+cjNNIzD5cY5mQ1WM8r/LEkI2u8EYpOotESNwzNlyCn3g+dmjKYI6BmNneSr/FSRw==} engines: {node: '>= 0.10.0'} dependencies: accepts: 1.3.8 array-flatten: 1.1.1 - body-parser: 1.20.1 + body-parser: 1.20.2 content-disposition: 0.5.4 content-type: 1.0.5 cookie: 0.5.0 @@ -5660,6 +5709,7 @@ packages: /glob-to-regexp@0.4.1: resolution: {integrity: sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==} + dev: true /glob@10.3.10: resolution: {integrity: sha512-fa46+tv1Ak0UPK1TOy/pZrIybNNt4HCv7SDzwyfiOZkvZLEbjsZkJBPtDHVshZjbecAoAGSC20MjLDG/qr679g==} @@ -6805,7 +6855,7 @@ packages: resolution: {integrity: sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==} dev: false - /next@13.5.1(@babel/core@7.23.9)(react-dom@18.2.0)(react@18.2.0): + /next@13.5.1(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-GIudNR7ggGUZoIL79mSZcxbXK9f5pwAIPZxEM8+j2yLqv5RODg4TkmUlaKSYVqE1bPQueamXSqdC3j7axiTSEg==} engines: {node: '>=16.14.0'} hasBin: true @@ -6843,6 +6893,7 @@ packages: transitivePeerDependencies: - '@babel/core' - babel-plugin-macros + dev: true /next@14.1.0(@babel/core@7.23.9)(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-wlzrsbfeSU48YQBjZhDzOwhWhGsy+uQycR8bHAOt1LY1bn3zZEcDyHQOEoN3aWzQ8LHCAJ1nqrWCc9XF2+O45Q==} @@ -7198,17 +7249,17 @@ packages: pathe: 1.1.2 dev: true - /playwright-core@1.41.2: - resolution: {integrity: sha512-VaTvwCA4Y8kxEe+kfm2+uUUw5Lubf38RxF7FpBxLPmGe5sdNkSg5e3ChEigaGrX7qdqT3pt2m/98LiyvU2x6CA==} + /playwright-core@1.42.1: + resolution: {integrity: sha512-mxz6zclokgrke9p1vtdy/COWBH+eOZgYUVVU34C73M+4j4HLlQJHtfcqiqqxpP0o8HhMkflvfbquLX5dg6wlfA==} engines: {node: '>=16'} hasBin: true - /playwright@1.41.2: - resolution: {integrity: sha512-v0bOa6H2GJChDL8pAeLa/LZC4feoAMbSQm1/jF/ySsWWoaNItvrMP7GEkvEEFyCTUYKMxjQKaTSg5up7nR6/8A==} + /playwright@1.42.1: + resolution: {integrity: sha512-PgwB03s2DZBcNRoW+1w9E+VkLBxweib6KTXM0M3tkiT4jVxKSi6PmVJ591J+0u10LUrgxB7dLRbiJqO5s2QPMg==} engines: {node: '>=16'} hasBin: true dependencies: - playwright-core: 1.41.2 + playwright-core: 1.42.1 optionalDependencies: fsevents: 2.3.2 @@ -7298,6 +7349,7 @@ packages: nanoid: 3.3.7 picocolors: 1.0.0 source-map-js: 1.0.2 + dev: true /postcss@8.4.31: resolution: {integrity: sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ==} @@ -7427,8 +7479,8 @@ packages: engines: {node: '>= 0.6'} dev: true - /raw-body@2.5.1: - resolution: {integrity: sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==} + /raw-body@2.5.2: + resolution: {integrity: sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==} engines: {node: '>= 0.8'} dependencies: bytes: 3.1.2 @@ -8680,6 +8732,7 @@ packages: dependencies: glob-to-regexp: 0.4.1 graceful-fs: 4.2.11 + dev: true /webidl-conversions@3.0.1: resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==} @@ -8899,6 +8952,7 @@ packages: /zod@3.21.4: resolution: {integrity: sha512-m46AKbrzKVzOzs/DZgVnG5H55N1sv1M8qZU3A8RIKbs3mrACDNeIOeilDymVb2HdmP8uwshOCF4uJ8uM9rCqJw==} + dev: true file:../packages/mui-base/build(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0): resolution: {directory: ../packages/mui-base/build, type: directory} @@ -8925,7 +8979,7 @@ packages: react-dom: 18.2.0(react@18.2.0) dev: false - file:../packages/mui-icons-material/build(@mui/material@5.15.11)(@types/react@18.2.55)(react@18.2.0): + file:../packages/mui-icons-material/build(@mui/material@5.15.12)(@types/react@18.2.55)(react@18.2.0): resolution: {directory: ../packages/mui-icons-material/build, type: directory} id: file:../packages/mui-icons-material/build name: '@mui/icons-material' @@ -8939,12 +8993,12 @@ packages: optional: true dependencies: '@babel/runtime': 7.23.9 - '@mui/material': file:../packages/mui-material/build(@emotion/react@11.11.3)(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0) + '@mui/material': file:../packages/mui-material/build(@emotion/react@11.11.4)(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0) '@types/react': 18.2.55 react: 18.2.0 dev: false - file:../packages/mui-material-nextjs/build(@emotion/cache@11.11.0)(@mui/material@5.15.11)(@types/react@18.2.55)(next@14.1.0)(react@18.2.0): + file:../packages/mui-material-nextjs/build(@emotion/cache@11.11.0)(@mui/material@5.15.12)(@types/react@18.2.55)(next@14.1.0)(react@18.2.0): resolution: {directory: ../packages/mui-material-nextjs/build, type: directory} id: file:../packages/mui-material-nextjs/build name: '@mui/material-nextjs' @@ -8966,40 +9020,13 @@ packages: dependencies: '@babel/runtime': 7.23.9 '@emotion/cache': 11.11.0 - '@mui/material': file:../packages/mui-material/build(@emotion/react@11.11.3)(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0) + '@mui/material': file:../packages/mui-material/build(@emotion/react@11.11.4)(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0) '@types/react': 18.2.55 next: 14.1.0(@babel/core@7.23.9)(react-dom@18.2.0)(react@18.2.0) react: 18.2.0 dev: false - file:../packages/mui-material-nextjs/build(@mui/material@5.15.11)(@types/react@18.2.55)(next@13.5.1)(react@18.2.0): - resolution: {directory: ../packages/mui-material-nextjs/build, type: directory} - id: file:../packages/mui-material-nextjs/build - name: '@mui/material-nextjs' - engines: {node: '>=12.0.0'} - peerDependencies: - '@emotion/cache': ^11.11.0 - '@emotion/server': ^11.11.0 - '@mui/material': ^5.0.0 - '@types/react': ^17.0.0 || ^18.0.0 - next: ^13.0.0 || ^14.0.0 - react: ^17.0.0 || ^18.0.0 - peerDependenciesMeta: - '@emotion/cache': - optional: true - '@emotion/server': - optional: true - '@types/react': - optional: true - dependencies: - '@babel/runtime': 7.23.9 - '@mui/material': file:../packages/mui-material/build(@emotion/react@11.11.3)(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0) - '@types/react': 18.2.55 - next: 13.5.1(@babel/core@7.23.9)(react-dom@18.2.0)(react@18.2.0) - react: 18.2.0 - dev: false - - file:../packages/mui-material/build(@emotion/react@11.11.3)(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0): + file:../packages/mui-material/build(@emotion/react@11.11.4)(@types/react@18.2.55)(react-dom@18.2.0)(react@18.2.0): resolution: {directory: ../packages/mui-material/build, type: directory} id: file:../packages/mui-material/build name: '@mui/material' @@ -9019,7 +9046,7 @@ packages: optional: true dependencies: '@babel/runtime': 7.23.9 - '@emotion/react': 11.11.3(@types/react@18.2.55)(react@18.2.0) + '@emotion/react': 11.11.4(@types/react@18.2.55)(react@18.2.0) '@mui/base': link:../packages/mui-base/build '@mui/core-downloads-tracker': link:../packages/mui-core-downloads-tracker/build '@mui/system': link:../packages/mui-system/build @@ -9036,7 +9063,7 @@ packages: react-transition-group: 4.4.5(react-dom@18.2.0)(react@18.2.0) dev: false - file:../packages/mui-system/build(@emotion/react@11.11.3)(@types/react@18.2.55)(react@18.2.0): + file:../packages/mui-system/build(@emotion/react@11.11.4)(@types/react@18.2.55)(react@18.2.0): resolution: {directory: ../packages/mui-system/build, type: directory} id: file:../packages/mui-system/build name: '@mui/system' @@ -9055,7 +9082,7 @@ packages: optional: true dependencies: '@babel/runtime': 7.23.9 - '@emotion/react': 11.11.3(@types/react@18.2.55)(react@18.2.0) + '@emotion/react': 11.11.4(@types/react@18.2.55)(react@18.2.0) '@mui/private-theming': link:../packages/mui-private-theming/build '@mui/styled-engine': link:../packages/mui-styled-engine/build '@mui/types': link:../packages/mui-types/build @@ -9090,18 +9117,18 @@ packages: file:../packages/pigment-nextjs-plugin(next@14.1.0): resolution: {directory: ../packages/pigment-nextjs-plugin, type: directory} id: file:../packages/pigment-nextjs-plugin - name: '@pigmentcss/nextjs-plugin' + name: '@pigment-css/nextjs-plugin' peerDependencies: next: ^12.0.0 || ^13.0.0 || ^14.0.0 dependencies: - '@pigmentcss/unplugin': link:../packages/pigment-unplugin + '@pigment-css/unplugin': link:../packages/pigment-unplugin next: 14.1.0(@babel/core@7.23.9)(react-dom@18.2.0)(react@18.2.0) dev: true file:../packages/pigment-react(@types/react@18.2.55)(react@18.2.0)(typescript@5.3.3): resolution: {directory: ../packages/pigment-react, type: directory} id: file:../packages/pigment-react - name: '@pigmentcss/react' + name: '@pigment-css/react' peerDependencies: react: ^17.0.0 || ^18.0.0 dependencies: @@ -9111,13 +9138,13 @@ packages: '@babel/parser': 7.23.9 '@babel/types': 7.23.9 '@emotion/css': 11.11.2 - '@emotion/react': 11.11.3(@types/react@18.2.55)(react@18.2.0) + '@emotion/react': 11.11.4(@types/react@18.2.55)(react@18.2.0) '@emotion/serialize': 1.1.3 - '@emotion/styled': 11.11.0(@emotion/react@11.11.3)(@types/react@18.2.55)(react@18.2.0) + '@emotion/styled': 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.55)(react@18.2.0) '@mui/system': link:../packages/mui-system/build - '@wyw-in-js/processor-utils': 0.4.1 - '@wyw-in-js/shared': 0.4.1 - '@wyw-in-js/transform': 0.4.1(typescript@5.3.3) + '@wyw-in-js/processor-utils': 0.5.0 + '@wyw-in-js/shared': 0.5.0 + '@wyw-in-js/transform': 0.5.0(typescript@5.3.3) clsx: 2.1.0 cssesc: 3.0.0 csstype: 3.1.3 @@ -9133,12 +9160,12 @@ packages: file:../packages/pigment-unplugin(typescript@5.3.3): resolution: {directory: ../packages/pigment-unplugin, type: directory} id: file:../packages/pigment-unplugin - name: '@pigmentcss/unplugin' + name: '@pigment-css/unplugin' dependencies: '@babel/core': 7.23.9 - '@pigmentcss/react': link:../packages/pigment-react - '@wyw-in-js/shared': 0.4.1 - '@wyw-in-js/transform': 0.4.1(typescript@5.3.3) + '@pigment-css/react': link:../packages/pigment-react + '@wyw-in-js/shared': 0.5.0 + '@wyw-in-js/transform': 0.5.0(typescript@5.3.3) babel-plugin-transform-react-remove-prop-types: 0.4.24 unplugin: 1.7.1 transitivePeerDependencies: @@ -9149,15 +9176,15 @@ packages: file:../packages/pigment-vite-plugin(vite@5.0.12): resolution: {directory: ../packages/pigment-vite-plugin, type: directory} id: file:../packages/pigment-vite-plugin - name: '@pigmentcss/vite-plugin' + name: '@pigment-css/vite-plugin' peerDependencies: vite: ^4.0.0 || ^5.0.0 dependencies: '@babel/core': 7.23.9 '@babel/preset-typescript': 7.23.3(@babel/core@7.23.9) - '@pigmentcss/react': link:../packages/pigment-react - '@wyw-in-js/shared': 0.4.1 - '@wyw-in-js/transform': 0.4.1(typescript@5.3.3) + '@pigment-css/react': link:../packages/pigment-react + '@wyw-in-js/shared': 0.5.0 + '@wyw-in-js/transform': 0.5.0(typescript@5.3.3) babel-plugin-transform-react-remove-prop-types: 0.4.24 vite: 5.0.12 transitivePeerDependencies: diff --git a/babel.config.js b/babel.config.js index e62c73ff88c671..7e6e17d626dd81 100644 --- a/babel.config.js +++ b/babel.config.js @@ -32,7 +32,7 @@ module.exports = function getBabelConfig(api) { '@mui/utils': resolveAliasPath('./packages/mui-utils/src'), '@mui/material-next': resolveAliasPath('./packages/mui-material-next/src'), '@mui/joy': resolveAliasPath('./packages/mui-joy/src'), - '@pigmentcss/react': resolveAliasPath('./packages/pigment-react/src'), + '@pigment-css/react': resolveAliasPath('./packages/pigment-react/src'), '@mui-internal/docs-utils': resolveAliasPath('./packages/docs-utils/src'), docs: resolveAliasPath('./docs'), test: resolveAliasPath('./test'), diff --git a/benchmark/package.json b/benchmark/package.json index 5ed95e188f31e0..48ca1c919ad051 100644 --- a/benchmark/package.json +++ b/benchmark/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@chakra-ui/system": "^2.6.2", - "@emotion/react": "^11.11.3", + "@emotion/react": "^11.11.4", "@emotion/server": "^11.11.0", "@emotion/styled": "^11.11.0", "@mui/material": "workspace:^", @@ -21,10 +21,10 @@ "@styled-system/css": "^5.1.5", "benchmark": "^2.1.4", "docs": "workspace:^", - "express": "^4.18.2", + "express": "^4.18.3", "fs-extra": "^11.2.0", "jss": "^10.10.0", - "playwright": "^1.41.2", + "playwright": "^1.42.1", "prop-types": "^15.8.1", "react": "^18.2.0", "react-dom": "^18.2.0", @@ -35,7 +35,7 @@ "serve-handler": "^6.1.5", "styled-components": "^6.1.8", "styled-system": "^5.1.5", - "theme-ui": "^0.16.1", + "theme-ui": "^0.16.2", "webpack": "^5.90.3" } } diff --git a/docs/data/about/teamMembers.json b/docs/data/about/teamMembers.json index e22f764b48b7f0..7750344851ac1c 100644 --- a/docs/data/about/teamMembers.json +++ b/docs/data/about/teamMembers.json @@ -265,5 +265,13 @@ "about": "Product experience geek \uD83D\uDECB, Mediterranean vibes \uD83C\uDF4A", "twitter": "vadym_raksha", "github": "hasdfa" + }, + { + "name": "James Nelson", + "title": "Software Engineer - Base UI", + "location": "Gold Coast, Australia", + "locationCountry": "au", + "about": "Enjoy creating open source libraries and reading about AI ๐Ÿค–", + "github": "atomiks" } ] diff --git a/docs/data/base/components/snackbar/TransitionComponentSnackbar.tsx b/docs/data/base/components/snackbar/TransitionComponentSnackbar.tsx index c04116d1174cfc..ccd8821e10f1d1 100644 --- a/docs/data/base/components/snackbar/TransitionComponentSnackbar.tsx +++ b/docs/data/base/components/snackbar/TransitionComponentSnackbar.tsx @@ -10,7 +10,7 @@ export default function TransitionComponentSnackbar() { const [exited, setExited] = React.useState(true); const nodeRef = React.useRef(null); - const handleClose = (_: any, reason: SnackbarCloseReason) => { + const handleClose = (_: any, reason?: SnackbarCloseReason) => { if (reason === 'clickaway') { return; } diff --git a/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/css/index.tsx b/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/css/index.tsx index 36e003cd345db8..93f36426d306cc 100644 --- a/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/css/index.tsx +++ b/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/css/index.tsx @@ -11,7 +11,7 @@ export default function UnstyledSnackbarIntroduction() { const [exited, setExited] = React.useState(true); const nodeRef = React.useRef(null); - const handleClose = (_: any, reason: SnackbarCloseReason) => { + const handleClose = (_: any, reason?: SnackbarCloseReason) => { if (reason === 'clickaway') { return; } diff --git a/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/system/index.tsx b/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/system/index.tsx index d73eb6c45eea53..b4fed03c2a230f 100644 --- a/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/system/index.tsx +++ b/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/system/index.tsx @@ -11,7 +11,7 @@ export default function UnstyledSnackbarIntroduction() { const [exited, setExited] = React.useState(true); const nodeRef = React.useRef(null); - const handleClose = (_: any, reason: SnackbarCloseReason) => { + const handleClose = (_: any, reason?: SnackbarCloseReason) => { if (reason === 'clickaway') { return; } diff --git a/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/tailwind/index.tsx b/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/tailwind/index.tsx index e34bf3d5c5c45f..f36868dd2de782 100644 --- a/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/tailwind/index.tsx +++ b/docs/data/base/components/snackbar/UnstyledSnackbarIntroduction/tailwind/index.tsx @@ -18,7 +18,7 @@ export default function UnstyledSnackbarIntroduction() { const [exited, setExited] = React.useState(true); const nodeRef = React.useRef(null); - const handleClose = (_: any, reason: SnackbarCloseReason) => { + const handleClose = (_: any, reason?: SnackbarCloseReason) => { if (reason === 'clickaway') { return; } diff --git a/docs/data/base/getting-started/overview/overview.md b/docs/data/base/getting-started/overview/overview.md index 883c486e29cc85..5d1327c7f1276d 100644 --- a/docs/data/base/getting-started/overview/overview.md +++ b/docs/data/base/getting-started/overview/overview.md @@ -16,12 +16,9 @@ Baseย UI includes prebuilt components with production-ready functionality, along With Baseย UI, you can rapidly build on top of our foundational components using any styling solution you chooseโ€”no need to override any default style engine or theme. -:::info -Baseย UI is currently in beta. - -We're adding new components and features regularly, and you're welcome to contribute! - -Look for the [`package: base-ui`](https://github.com/mui/material-ui/labels/package%3A%20base-ui) label on open issues and pull requests in the `mui/material-ui` repository on GitHub to see what other community members are working on, and feel free to submit your own. +:::warning +Base UI's API is currently being revised; there will be no new features or components added to the current implementation. +Learn more about plans for Base UI in [this blog post](/blog/base-ui-2024-plans/). ::: ## Advantages of Baseย UI diff --git a/docs/data/base/getting-started/roadmap/roadmap.md b/docs/data/base/getting-started/roadmap/roadmap.md new file mode 100644 index 00000000000000..26e20e250cf474 --- /dev/null +++ b/docs/data/base/getting-started/roadmap/roadmap.md @@ -0,0 +1,22 @@ +# Roadmap + +

Keep up with ongoing projects and help shape the future of Base UI.

+ +## How we prioritize + +Base UI is a community-driven project, meaning we usually pick the issues and suggestions that resonate the most with the community. +Therefore, make sure to leave an upvote ๐Ÿ‘ on [the GitHub issues](https://github.com/mui/base-ui/issues) you are most interested in. + +Additionally, we conduct annual [developer surveys](/blog/?tags=Developer+survey/) which also serve as key inputs for Base UI's roadmap. +Your participation is invaluableโ€”keep an eye on MUI's social media to catch the next survey and help shape the future of the library! + +## Keeping track of the roadmap + +### GitHub project + +The Base UI GitHub project is where you can see the ongoing priorities for the library. +We typically add umbrella issues to the project board after discussing them internally. + +**[Visit the Base UI project board ๐Ÿ‘‰](https://github.com/orgs/mui/projects/1/views/13)** + +A screenshot of the public Base UI GitHub project. diff --git a/docs/data/base/getting-started/support/support.md b/docs/data/base/getting-started/support/support.md index 93c069adfc4c65..515a72b1d914e4 100644 --- a/docs/data/base/getting-started/support/support.md +++ b/docs/data/base/getting-started/support/support.md @@ -8,9 +8,9 @@ We use GitHub issues as a bug and feature request tracker. If you think you've found a bug, or you have a new feature idea: -1. Please start by [making sure it hasn't already been reported or fixed](https://github.com/mui/material-ui/issues?utf8=%E2%9C%93&q=is%3Aopen+is%3Aclosed). +1. Please start by [making sure it hasn't already been reported or fixed](https://github.com/mui/base-ui/issues?q=is%3Aopen+is%3Aclosed). You can search through existing issues and pull requests to see if someone has reported one similar to yours. -2. Then, if no duplicates exist, [open an issue](https://github.com/mui/material-ui/issues/new/choose) in the Baseย UI repository. +2. Then, if no duplicates exist, [open an issue](https://github.com/mui/base-ui/issues/new/choose) in the Baseย UI repository. ### New issue guidelines @@ -78,7 +78,7 @@ This includes issues introduced by external sources, like browser upgrades or ch ### Social media -The Baseย UI community is active on both [X/Twitter](https://twitter.com/MaterialUI) and [LinkedIn](https://www.linkedin.com/company/mui/). +The Baseย UI community is active on both [X/Twitter](https://twitter.com/MUI_hq) and [LinkedIn](https://www.linkedin.com/company/mui/). These are great platforms to share what you're working on and connect with other developers. ### Discord diff --git a/docs/data/base/pages.ts b/docs/data/base/pages.ts index cc7e0c556b4529..ee24d0826d97df 100644 --- a/docs/data/base/pages.ts +++ b/docs/data/base/pages.ts @@ -11,6 +11,7 @@ const pages: readonly MuiPage[] = [ { pathname: '/base-ui/getting-started/usage', title: 'Usage' }, { pathname: '/base-ui/getting-started/customization', title: 'Customization' }, { pathname: '/base-ui/getting-started/accessibility', title: 'Accessibility' }, + { pathname: '/base-ui/getting-started/roadmap', title: 'Roadmap' }, { pathname: '/base-ui/getting-started/support' }, ], }, diff --git a/docs/data/joy/components/autocomplete/CustomTags.js b/docs/data/joy/components/autocomplete/CustomTags.js index 1b83a19a03b900..edcdc0edef35ce 100644 --- a/docs/data/joy/components/autocomplete/CustomTags.js +++ b/docs/data/joy/components/autocomplete/CustomTags.js @@ -18,6 +18,7 @@ export default function CustomTags() { variant="solid" color="primary" endDecorator={} + sx={{ minWidth: 0 }} {...getTagProps({ index })} > {item.title} diff --git a/docs/data/joy/components/autocomplete/CustomTags.tsx b/docs/data/joy/components/autocomplete/CustomTags.tsx index 1b83a19a03b900..edcdc0edef35ce 100644 --- a/docs/data/joy/components/autocomplete/CustomTags.tsx +++ b/docs/data/joy/components/autocomplete/CustomTags.tsx @@ -18,6 +18,7 @@ export default function CustomTags() { variant="solid" color="primary" endDecorator={} + sx={{ minWidth: 0 }} {...getTagProps({ index })} > {item.title} diff --git a/docs/data/joy/components/autocomplete/FixedTags.js b/docs/data/joy/components/autocomplete/FixedTags.js index 17e80d30b5ddf8..91744804a2f22e 100644 --- a/docs/data/joy/components/autocomplete/FixedTags.js +++ b/docs/data/joy/components/autocomplete/FixedTags.js @@ -28,6 +28,7 @@ export default function FixedTags() { diff --git a/docs/data/joy/components/autocomplete/FixedTags.tsx b/docs/data/joy/components/autocomplete/FixedTags.tsx index 17e80d30b5ddf8..91744804a2f22e 100644 --- a/docs/data/joy/components/autocomplete/FixedTags.tsx +++ b/docs/data/joy/components/autocomplete/FixedTags.tsx @@ -28,6 +28,7 @@ export default function FixedTags() { diff --git a/docs/data/joy/getting-started/support/support.md b/docs/data/joy/getting-started/support/support.md index 09c5049750f2bc..ca2d02212f96cc 100644 --- a/docs/data/joy/getting-started/support/support.md +++ b/docs/data/joy/getting-started/support/support.md @@ -8,7 +8,7 @@ We use GitHub issues as a bug and feature request tracker. If you think you've found a bug, or you have a new feature idea: -1. Please start by [making sure it hasn't already been reported or fixed](https://github.com/mui/material-ui/issues?utf8=%E2%9C%93&q=is%3Aopen+is%3Aclosed). +1. Please start by [making sure it hasn't already been reported or fixed](https://github.com/mui/material-ui/issues?q=is%3Aopen+is%3Aclosed). You can search through existing issues and pull requests to see if someone has reported one similar to yours. 2. Then, if no duplicates exist, [open an issue](https://github.com/mui/material-ui/issues/new/choose) in the Joyย UI repository. diff --git a/docs/data/joy/integrations/icon-libraries/IconFontSizes.js b/docs/data/joy/integrations/icon-libraries/IconFontSizes.js index b8bcc044becadb..72a86184653993 100644 --- a/docs/data/joy/integrations/icon-libraries/IconFontSizes.js +++ b/docs/data/joy/integrations/icon-libraries/IconFontSizes.js @@ -1,19 +1,22 @@ import * as React from 'react'; -import { useTheme } from '@mui/joy/styles'; import Stack from '@mui/joy/Stack'; import Person from '@mui/icons-material/Person'; export default function IconFontSizes() { - const theme = useTheme(); return ( - {Object.keys(theme.fontSize).map((size) => ( - - ))} + + + + + + + + ); } diff --git a/docs/data/joy/integrations/icon-libraries/IconFontSizes.tsx b/docs/data/joy/integrations/icon-libraries/IconFontSizes.tsx index b8bcc044becadb..72a86184653993 100644 --- a/docs/data/joy/integrations/icon-libraries/IconFontSizes.tsx +++ b/docs/data/joy/integrations/icon-libraries/IconFontSizes.tsx @@ -1,19 +1,22 @@ import * as React from 'react'; -import { useTheme } from '@mui/joy/styles'; import Stack from '@mui/joy/Stack'; import Person from '@mui/icons-material/Person'; export default function IconFontSizes() { - const theme = useTheme(); return ( - {Object.keys(theme.fontSize).map((size) => ( - - ))} + + + + + + + + ); } diff --git a/docs/data/joy/integrations/icon-libraries/IconFontSizes.tsx.preview b/docs/data/joy/integrations/icon-libraries/IconFontSizes.tsx.preview index a94d346b70bd0c..bccdfe423278bf 100644 --- a/docs/data/joy/integrations/icon-libraries/IconFontSizes.tsx.preview +++ b/docs/data/joy/integrations/icon-libraries/IconFontSizes.tsx.preview @@ -1,3 +1,8 @@ -{Object.keys(theme.fontSize).map((size) => ( - -))} \ No newline at end of file + + + + + + + + \ No newline at end of file diff --git a/docs/data/material/discover-more/roadmap/roadmap.md b/docs/data/material/discover-more/roadmap/roadmap.md index 61aeadd60a29a2..2cba0d105d72c6 100644 --- a/docs/data/material/discover-more/roadmap/roadmap.md +++ b/docs/data/material/discover-more/roadmap/roadmap.md @@ -12,14 +12,14 @@ Your participation is invaluableโ€”keep an eye on MUI's social media to catch th ## Keeping track of the roadmap -### Public GitHub project +### GitHub project -The Materialย UI public GitHub project is where you can see the ongoing priorities for the library. +The Materialย UI GitHub project is where you can see the ongoing priorities for the library. We typically add umbrella issues to the project board after discussing them internally. -**[Visit the public Materialย UI project board ๐Ÿ‘‰](https://github.com/mui/material-ui/projects/26)** +**[Visit the Materialย UI project board ๐Ÿ‘‰](https://github.com/orgs/mui/projects/23/views/12)** -A screenshot of the public Materialย UI GitHub project. +A screenshot of the public Materialย UI GitHub project. ### Milestones @@ -28,4 +28,4 @@ Check it out to keep up with ongoing progress and see which issues have been pic **[Visit the Materialย UI milestones page ๐Ÿ‘‰](https://github.com/mui/material-ui/milestone/42)** -A screenshot from GitHub of the Materialย UI v6 milestone. +A screenshot from GitHub of the Materialย UI v6 milestone. diff --git a/docs/data/material/getting-started/example-projects/example-projects.md b/docs/data/material/getting-started/example-projects/example-projects.md index 2fb1e57bb55088..ee15e9aefa966a 100644 --- a/docs/data/material/getting-started/example-projects/example-projects.md +++ b/docs/data/material/getting-started/example-projects/example-projects.md @@ -48,7 +48,7 @@ They're great resources for learning more about real-world usage of Materialย UI ### Paid -- [ScaffoldHub](https://v2.scaffoldhub.io/scaffolds/react-material-ui): +- [ScaffoldHub](https://v2.scaffoldhub.io/scaffolds/react-material-ui?partner=1): - Tool for building web applications. - Choose your framework and library (React with Materialย UI). diff --git a/docs/data/material/getting-started/faq/faq.md b/docs/data/material/getting-started/faq/faq.md index b756cafbf70a9b..78beedd8ca101b 100644 --- a/docs/data/material/getting-started/faq/faq.md +++ b/docs/data/material/getting-started/faq/faq.md @@ -16,7 +16,7 @@ There are many ways to support us: - **Make changes happen**. - Edit the documentation. At the bottom of every page, you can find an "Edit this page" button. - Report bugs or missing features by [creating an issue](https://github.com/mui/material-ui/issues/new). - - Review and comment on existing [pull requests](https://github.com/mui/material-ui/pulls) and [issues](https://github.com/mui/material-ui/issues). + - Review and comment on existing [pull requests](https://github.com/mui/material-ui/pulls?q=is%3Apr) and [issues](https://github.com/mui/material-ui/issues?q=is%3Aopen+is%3Aclosed). - [Improve our documentation](https://github.com/mui/material-ui/tree/HEAD/docs), fix bugs, or add features by [submitting a pull request](https://github.com/mui/material-ui/pulls). - **Support us financially on [Openย Collective](https://opencollective.com/mui-org)**. If you use Materialย UI in a commercial project and would like to support its continued development by becoming a Sponsor, or in a side or hobby project and would like to become a Backer, you can do so through Openย Collective. @@ -138,7 +138,7 @@ const element = ref.current; ``` If you're not sure if the Materialย UI component in question forwards its ref you can check the API documentation under "Props." -You should find the message below, like in the [Button API](/material-ui/api/button/#props), [Button API](/material-ui/api/button/#props) +You should find the message below, like in the [Button API](/material-ui/api/button/#props). > The ref is forwarded to the root element. diff --git a/docs/data/material/getting-started/support/support.md b/docs/data/material/getting-started/support/support.md index b4a3591f87d034..a1ac63363746be 100644 --- a/docs/data/material/getting-started/support/support.md +++ b/docs/data/material/getting-started/support/support.md @@ -8,7 +8,7 @@ We use GitHub issues as a bug and feature request tracker. If you think you've found a bug, or you have a new feature idea: -1. Please start by [making sure it hasn't already been reported or fixed](https://github.com/mui/material-ui/issues?utf8=%E2%9C%93&q=is%3Aopen+is%3Aclosed). +1. Please start by [making sure it hasn't already been reported or fixed](https://github.com/mui/material-ui/issues?q=is%3Aopen+is%3Aclosed). You can search through existing issues and pull requests to see if someone has reported one similar to yours. 2. Then, if no duplicates exist, [open an issue](https://github.com/mui/material-ui/issues/new/choose) in the Materialย UI repository. diff --git a/docs/data/material/getting-started/supported-components/supported-components.md b/docs/data/material/getting-started/supported-components/supported-components.md index 14ebd7bb7ce3a8..defae379f9fb5a 100644 --- a/docs/data/material/getting-started/supported-components/supported-components.md +++ b/docs/data/material/getting-started/supported-components/supported-components.md @@ -9,7 +9,7 @@ feature of every component, but rather to provide the building blocks to allow developers to create compelling user interfaces and experiences. If you wish to add support for a component or feature not highlighted -here, please search for the relevant [GitHub Issue](https://github.com/mui/material-ui/issues), or create a new one +here, please search for the relevant [GitHub Issue](https://github.com/mui/material-ui/issues?q=is%3Aopen+is%3Aclosed), or create a new one to discuss the approach before submitting a pull request. {{"demo": "MaterialUIComponents.js", "hideToolbar": true, "bg": true}} diff --git a/docs/data/system/getting-started/support/support.md b/docs/data/system/getting-started/support/support.md index 64ecfd87848a11..2c39e0f61039d3 100644 --- a/docs/data/system/getting-started/support/support.md +++ b/docs/data/system/getting-started/support/support.md @@ -8,7 +8,7 @@ We use GitHub issues as a bug and feature request tracker. If you think you've found a bug, or you have a new feature idea: -1. Please start by [making sure it hasn't already been reported or fixed](https://github.com/mui/material-ui/issues?utf8=%E2%9C%93&q=is%3Aopen+is%3Aclosed). +1. Please start by [making sure it hasn't already been reported or fixed](https://github.com/mui/material-ui/issues?q=is%3Aopen+is%3Aclosed). You can search through existing issues and pull requests to see if someone has reported one similar to yours. 2. Then, if no duplicates exist, [open an issue](https://github.com/mui/material-ui/issues/new/choose) in the MUIย System repository. diff --git a/docs/data/system/getting-started/usage/Demo.js b/docs/data/system/getting-started/usage/Demo.js index 1a667fb6092020..f07c23b3a7cc45 100644 --- a/docs/data/system/getting-started/usage/Demo.js +++ b/docs/data/system/getting-started/usage/Demo.js @@ -1,7 +1,5 @@ import * as React from 'react'; -import Box from '@mui/material/Box'; -import { alpha } from '@mui/material/styles'; -import ErrorOutlineIcon from '@mui/icons-material/ErrorOutline'; +import Box from '@mui/system/Box'; export default function Demo() { return ( @@ -10,11 +8,11 @@ export default function Demo() { display: 'flex', flexDirection: { xs: 'column', md: 'row' }, alignItems: 'center', - bgcolor: 'background.paper', - overflow: 'hidden', - borderRadius: '12px', - boxShadow: 1, - fontWeight: 'bold', + bgcolor: 'background.default', + border: '1px solid', + borderColor: 'divider', + borderRadius: 2, + overflow: 'clip', }} > - + 123 Main St, Phoenix AZ - + $280,000 โ€” $310,000 alpha(theme.palette.primary.main, 0.1), - borderRadius: '5px', - color: 'primary.main', - fontWeight: 'medium', + py: 0.5, + px: 1, + backgroundColor: 'rgba(46, 125, 50, 0.1)', + borderRadius: 10, display: 'flex', - fontSize: 12, alignItems: 'center', - '& svg': { - fontSize: 21, - mr: 0.5, - }, + gap: 0.5, + border: '1px solid', + borderColor: 'rgba(46, 125, 50, 0.1)', + fontSize: '0.7rem', + fontWeight: 'bold', + letterSpacing: '.05rem', + textTransform: 'uppercase', + color: 'success.main', }} > - - CONFIDENCE SCORE 85% + Confidence score: 85% diff --git a/docs/data/system/getting-started/usage/Demo.tsx b/docs/data/system/getting-started/usage/Demo.tsx index 1a667fb6092020..f07c23b3a7cc45 100644 --- a/docs/data/system/getting-started/usage/Demo.tsx +++ b/docs/data/system/getting-started/usage/Demo.tsx @@ -1,7 +1,5 @@ import * as React from 'react'; -import Box from '@mui/material/Box'; -import { alpha } from '@mui/material/styles'; -import ErrorOutlineIcon from '@mui/icons-material/ErrorOutline'; +import Box from '@mui/system/Box'; export default function Demo() { return ( @@ -10,11 +8,11 @@ export default function Demo() { display: 'flex', flexDirection: { xs: 'column', md: 'row' }, alignItems: 'center', - bgcolor: 'background.paper', - overflow: 'hidden', - borderRadius: '12px', - boxShadow: 1, - fontWeight: 'bold', + bgcolor: 'background.default', + border: '1px solid', + borderColor: 'divider', + borderRadius: 2, + overflow: 'clip', }} > - + 123 Main St, Phoenix AZ - + $280,000 โ€” $310,000 alpha(theme.palette.primary.main, 0.1), - borderRadius: '5px', - color: 'primary.main', - fontWeight: 'medium', + py: 0.5, + px: 1, + backgroundColor: 'rgba(46, 125, 50, 0.1)', + borderRadius: 10, display: 'flex', - fontSize: 12, alignItems: 'center', - '& svg': { - fontSize: 21, - mr: 0.5, - }, + gap: 0.5, + border: '1px solid', + borderColor: 'rgba(46, 125, 50, 0.1)', + fontSize: '0.7rem', + fontWeight: 'bold', + letterSpacing: '.05rem', + textTransform: 'uppercase', + color: 'success.main', }} > - - CONFIDENCE SCORE 85% + Confidence score: 85% diff --git a/docs/data/system/getting-started/usage/Why.js b/docs/data/system/getting-started/usage/Why.js index a2dc74962d8e61..dd6d81e8faa518 100644 --- a/docs/data/system/getting-started/usage/Why.js +++ b/docs/data/system/getting-started/usage/Why.js @@ -1,37 +1,41 @@ import * as React from 'react'; import TrendingUpIcon from '@mui/icons-material/TrendingUp'; -import Box from '@mui/material/Box'; +import Box from '@mui/system/Box'; export default function Why() { return ( Sessions - + 98.3 K - 18.77% + 18.7% - + vs. last week diff --git a/docs/data/system/getting-started/usage/Why.tsx b/docs/data/system/getting-started/usage/Why.tsx index a2dc74962d8e61..dd6d81e8faa518 100644 --- a/docs/data/system/getting-started/usage/Why.tsx +++ b/docs/data/system/getting-started/usage/Why.tsx @@ -1,37 +1,41 @@ import * as React from 'react'; import TrendingUpIcon from '@mui/icons-material/TrendingUp'; -import Box from '@mui/material/Box'; +import Box from '@mui/system/Box'; export default function Why() { return ( Sessions - + 98.3 K - 18.77% + 18.7% - + vs. last week diff --git a/docs/data/system/getting-started/usage/usage.md b/docs/data/system/getting-started/usage/usage.md index fe9bc02ec89078..611d8a91a22eba 100644 --- a/docs/data/system/getting-started/usage/usage.md +++ b/docs/data/system/getting-started/usage/usage.md @@ -152,18 +152,18 @@ It works with both Emotion and styled-components. #### Cons -- Runtime performance takes a hit. +Runtime performance takes a hit. - | Benchmark case | Code snippet | Time normalized | - | :-------------------------------- | :-------------------- | --------------: | - | a. Render 1,000 primitives | `
` | 100ms | - | b. Render 1,000 components | `
` | 112ms | - | c. Render 1,000 styled components | `` | 181ms | - | d. Render 1,000 Box | `` | 296ms | +| Benchmark case | Code snippet | Time normalized | +| :-------------------------------- | :-------------------- | --------------: | +| a. Render 1,000 primitives | `
` | 100ms | +| b. Render 1,000 components | `
` | 112ms | +| c. Render 1,000 styled components | `` | 181ms | +| d. Render 1,000 Box | `` | 296ms | -_Head to the [benchmark folder](https://github.com/mui/material-ui/tree/master/benchmark/browser) for a reproduction of these metrics._ +Visit the [benchmark folder](https://github.com/mui/material-ui/tree/master/benchmark/browser) for a reproduction of the metrics above. We believe that for most use cases it's fast enough, but there are simple workarounds when performance becomes critical. For instance, when rendering a list with many items, you can use a CSS child selector to have a single "style injection" point (using d. for the wrapper and a. for each item). @@ -183,7 +183,7 @@ The `sx` prop can be used in four different locations: ### Core components -All Materialย UI, and Joyย UI components support the `sx` prop. +All Materialย UI and Joy UI components support the `sx` prop. ### Box @@ -202,7 +202,7 @@ const Div = styled('div')``; ### Any element with the babel plugin -TODO [#23220](https://github.com/mui/material-ui/issues/23220). +Visit [the open GitHub issue](https://github.com/mui/material-ui/issues/23220) regarding this topic to learn more. ## How to use MUIย System diff --git a/docs/lib/sourcing.ts b/docs/lib/sourcing.ts index 3c3678f9810ea4..7ade883964584f 100644 --- a/docs/lib/sourcing.ts +++ b/docs/lib/sourcing.ts @@ -43,6 +43,7 @@ const ALLOWED_TAGS = [ 'Joy UI', 'MUI X', 'MUI System', + 'Toolpad', ]; export const getAllBlogPosts = () => { diff --git a/docs/notifications.json b/docs/notifications.json index 4b3431c0de8f13..2a2e958a32fb42 100644 --- a/docs/notifications.json +++ b/docs/notifications.json @@ -1,22 +1,22 @@ [ { "id": 68, - "title": "Check out Baseย UI today ๐Ÿ’ฅ", + "title": "Check out Baseย UI today ๐Ÿ’ฅ", "text": "Love Material UI, but don't need Material Design? Try Baseย UI, the new \"unstyled\" alternative. Read more in this announcement." }, { "id": 78, - "title": "MUI X v6.18.x and the latest improvements before the next major", + "title": "MUI X v6.18.x and the latest improvements before the next major", "text": "New stable components, polished features, better performance and more. Check out the details in our recent blog post." }, { "id": 79, - "title": "A new Developer Survey is open", + "title": "A new Developer Survey is open", "text": "Take a few minutes to share your feedback and expectations in the Developerย Survey." }, { "id": 80, - "title": "MUI X v7.0.0-beta.0", + "title": "MUI X v7.0.0-beta.0", "text": "Featuring new components and multiple enhancements for both developers and end-users. Discover all the specifics in the announcement blog post." } ] diff --git a/docs/package.json b/docs/package.json index de772dd1016c48..b70ec2b2d37c59 100644 --- a/docs/package.json +++ b/docs/package.json @@ -25,7 +25,7 @@ "@babel/runtime-corejs2": "^7.23.9", "@docsearch/react": "^3.5.2", "@emotion/cache": "^11.11.0", - "@emotion/react": "^11.11.3", + "@emotion/react": "^11.11.4", "@emotion/server": "^11.11.0", "@emotion/styled": "^11.11.0", "@fortawesome/fontawesome-svg-core": "^6.5.1", @@ -45,18 +45,18 @@ "@mui/system": "workspace:^", "@mui/types": "workspace:^", "@mui/utils": "workspace:^", - "@mui/x-charts": "6.19.4", - "@mui/x-data-grid": "6.19.4", - "@mui/x-data-grid-generator": "6.19.4", - "@mui/x-data-grid-premium": "6.19.4", - "@mui/x-data-grid-pro": "6.19.4", - "@mui/x-date-pickers": "6.19.4", - "@mui/x-date-pickers-pro": "6.19.4", + "@mui/x-charts": "6.19.5", + "@mui/x-data-grid": "6.19.6", + "@mui/x-data-grid-generator": "6.19.6", + "@mui/x-data-grid-premium": "6.19.6", + "@mui/x-data-grid-pro": "6.19.6", + "@mui/x-date-pickers": "6.19.6", + "@mui/x-date-pickers-pro": "6.19.6", "@mui/x-license-pro": "6.10.2", "@mui/x-tree-view": "6.17.0", "@popperjs/core": "^2.11.8", "@react-spring/web": "^9.7.3", - "autoprefixer": "^10.4.17", + "autoprefixer": "^10.4.18", "autosuggest-highlight": "^3.3.4", "babel-plugin-module-resolver": "^5.0.0", "babel-plugin-optimize-clsx": "^2.6.2", @@ -96,7 +96,7 @@ "react-imask": "^7.3.0", "react-intersection-observer": "^9.5.3", "react-is": "^18.2.0", - "react-number-format": "^5.3.1", + "react-number-format": "^5.3.3", "react-router-dom": "^6.21.3", "react-runner": "^1.0.3", "react-simple-code-editor": "^0.13.1", @@ -123,7 +123,7 @@ "@types/chai": "^4.3.12", "@types/css-mediaquery": "^0.1.4", "@types/json2mq": "^0.2.2", - "@types/node": "^18.19.19", + "@types/node": "^18.19.21", "@types/prop-types": "^15.7.11", "@types/react": "^18.2.55", "@types/react-dom": "^18.2.19", @@ -136,7 +136,7 @@ "cross-fetch": "^4.0.0", "gm": "^1.25.0", "marked": "^5.1.2", - "playwright": "^1.41.2", + "playwright": "^1.42.1", "prettier": "^3.2.5", "tailwindcss": "^3.4.1", "yargs": "^17.7.2" diff --git a/docs/pages/base-ui.tsx b/docs/pages/base-ui.tsx index 8ee2c44afd28d4..fd4b84b8965375 100644 --- a/docs/pages/base-ui.tsx +++ b/docs/pages/base-ui.tsx @@ -27,7 +27,7 @@ export default function BaseUI() { /> - +
diff --git a/docs/pages/base-ui/api/form-control.json b/docs/pages/base-ui/api/form-control.json index 5c6df584fe21b6..348977e689415a 100644 --- a/docs/pages/base-ui/api/form-control.json +++ b/docs/pages/base-ui/api/form-control.json @@ -22,6 +22,14 @@ "import { FormControl } from '@mui/base/FormControl';", "import { FormControl } from '@mui/base';" ], + "slots": [ + { + "name": "root", + "description": "The component that renders the root.", + "default": "'div'", + "class": "base-FormControl-root" + } + ], "classes": [ { "key": "disabled", @@ -52,12 +60,6 @@ "className": "base--required", "description": "State class applied to the root element if `required={true}`.", "isGlobal": true - }, - { - "key": "root", - "className": "base-FormControl-root", - "description": "Class applied to the root element.", - "isGlobal": false } ], "spread": true, diff --git a/docs/pages/base-ui/getting-started/roadmap.js b/docs/pages/base-ui/getting-started/roadmap.js new file mode 100644 index 00000000000000..1e515d70f47afb --- /dev/null +++ b/docs/pages/base-ui/getting-started/roadmap.js @@ -0,0 +1,12 @@ +import * as React from 'react'; +import MarkdownDocs from 'docs/src/modules/components/MarkdownDocsV2'; +import AppFrame from 'docs/src/modules/components/AppFrame'; +import * as pageProps from 'docs/data/base/getting-started/roadmap/roadmap.md?muiMarkdown'; + +export default function Page() { + return ; +} + +Page.getLayout = (page) => { + return {page}; +}; diff --git a/docs/pages/blog/2020-q3-update.md b/docs/pages/blog/2020-q3-update.md index 766def6092af2c..54e67b4bcb6b8b 100644 --- a/docs/pages/blog/2020-q3-update.md +++ b/docs/pages/blog/2020-q3-update.md @@ -118,7 +118,7 @@ Here are the most significant improvements since June 2020. This was a dense qua

Slider powered by styled-components

- โ™ฟ๏ธŽ We have kept investing in accessibility, we have fixed [13 bugs](https://github.com/mui/material-ui/pulls?q=is%3Apr+label%3Aaccessibility+is%3Aclosed+sort%3Aupdated-desc). -- ๐Ÿ—“ We have introduced public quarterly roadmaps, both for [MUIย Core](https://github.com/orgs/mui/projects/18/views/1) and [MUIย X](https://github.com/mui/mui-x/projects/1). +- ๐Ÿ—“ We have introduced public quarterly roadmaps, both for each [MUIย Core](https://github.com/mui/material-ui/projects?query=is%3Aopen) product and [MUIย X](https://github.com/mui/mui-x/projects/1). ## Company @@ -151,7 +151,7 @@ We'll do our best, no guarantee! ### Community -- ๐Ÿ—“ Execute on all the items of the [public roadmap](https://github.com/orgs/mui/projects/18/views/1). +- ๐Ÿ—“ Execute on all the items of the [public roadmap](https://github.com/orgs/mui/projects/23/views/12). - ๐Ÿ‘ฉโ€๐ŸŽจ Simplify the migration experience from v4 to v5. - โ“ Please upvote [GitHub issues](https://github.com/mui/material-ui/issues) if you want us to focus on a specific problem. The number of ๐Ÿ‘ helps us to prioritize. diff --git a/docs/pages/blog/2021-q1-update.md b/docs/pages/blog/2021-q1-update.md index 299b77649072b3..02be67b4f9947d 100644 --- a/docs/pages/blog/2021-q1-update.md +++ b/docs/pages/blog/2021-q1-update.md @@ -205,7 +205,7 @@ We have the following objectives: - ๐Ÿš€ Get v5-beta (no more breaking changes) out! The development of this new version started almost a year ago. It's time to aim for the stable release. - ๐Ÿ“… Start handling the issues with the date picker reported by developers. -- ๐Ÿ—“ Execute on all the items of the [public roadmap](https://github.com/orgs/mui/projects/18/views/1). +- ๐Ÿ—“ Execute on all the items of the [public roadmap](https://github.com/orgs/mui/projects/23/views/12). - โ“ Please upvote [GitHub issues](https://github.com/mui/material-ui/issues?q=is%3Aissue+is%3Aopen+sort%3Areactions-%2B1-desc) if you want us to focus on a specific problem. The number of ๐Ÿ‘ helps us to prioritize. ### Advanced components diff --git a/docs/pages/blog/2021-q2-update.md b/docs/pages/blog/2021-q2-update.md index 064857eacfbe39..a7650185843a22 100644 --- a/docs/pages/blog/2021-q2-update.md +++ b/docs/pages/blog/2021-q2-update.md @@ -220,7 +220,7 @@ We have the following objectives: You can follow our progress in the [umbrella issue](https://github.com/mui/material-ui/issues/27170). - ๐ŸŒˆ Do a proof of concept on supporting a second design system. Some of our users (and potential users) dislike Material Design. We will try to make the second design system one that they love! -- ๐Ÿ—“ Execute on all of the items in the [public roadmap](https://github.com/orgs/mui/projects/18/views/1). +- ๐Ÿ—“ Execute on all of the items in the [public roadmap](https://github.com/orgs/mui/projects/23/views/12). - โ“ Please upvote [GitHub issues](https://github.com/mui/material-ui/issues?q=is%3Aissue+is%3Aopen+sort%3Areactions-%2B1-desc) if you want us to focus on a specific problem. The number of ๐Ÿ‘ helps us to prioritize. ### Advanced components diff --git a/docs/pages/blog/2021-q3-update.md b/docs/pages/blog/2021-q3-update.md index 7268ab69dc23ca..5c5e582482b0db 100644 --- a/docs/pages/blog/2021-q3-update.md +++ b/docs/pages/blog/2021-q3-update.md @@ -200,7 +200,7 @@ We'll do our best, no guarantee! Since v5, Materialย UI is no longer actively supporting IE 11. Dropping this browser requirement unlocks new capabilities of the web platform. - ๐ŸŒˆ Resume work on the second design system. Some users (and potential users) dislike Material Design. We'll try to make the second design system one that they love! You can check our [first RFC](https://github.com/mui/material-ui/discussions/29024). -- ๐Ÿ—“ Execute on all of the items in the [public roadmap](https://github.com/orgs/mui/projects/18/views/1). +- ๐Ÿ—“ Execute on all of the items in the [public roadmap](https://github.com/orgs/mui/projects/23/views/12). - โ“ Please upvote [GitHub issues](https://github.com/mui/material-ui/issues?q=is%3Aissue+is%3Aopen+sort%3Areactions-%2B1-desc) if you want us to focus on a specific problem. The number of ๐Ÿ‘ helps us to prioritize. ### MUIย X diff --git a/docs/pages/blog/2023-toolpad-beta-announcement.md b/docs/pages/blog/2023-toolpad-beta-announcement.md index cb0522038237f4..318dfe94bfe1e9 100644 --- a/docs/pages/blog/2023-toolpad-beta-announcement.md +++ b/docs/pages/blog/2023-toolpad-beta-announcement.md @@ -4,18 +4,18 @@ description: Assemble admin panels and internal tools faster than ever before wi date: 2023-07-24T00:00:00.000Z authors: ['prakhargupta'] card: true -tags: ['Product'] +tags: ['Product', 'Toolpad'] --- -It's been over a year since we released the first version of Toolpad. Today, we're excited to take the next step on that journey with the release of Toolpad Beta. If you aren't familiar with Toolpad yet, it's an admin panel builder catering to the internal tooling needs of an organization, designed for developers who want to build a functional application quickly. It harnesses the speed of a UI builder for the front-end and closely integrates into your back-end. If this excites you, then read on! +It's been over a year since we released the first version of Toolpad. Today, we're excited to take the next step on that journey with the release of Toolpad Beta. If you aren't familiar with Toolpad yet, it's an admin panel builder catering to the internal tooling needs of an organization, designed for developers who want to build a functional application quickly. It harnesses the speed of a UI builder for the front end and closely integrates into your back end. If this excites you, then read on! -Introducing Toolpad +Introducing Toolpad ## Why did we decide to build Toolpad? -Toolpad was created to meet the needs of the Materialย UI community. As a result of surveys we conducted, and market research we undertook, we decided to develop an internal tool builder because the idea resonates with MUI's mission of empowering developers to build apps faster and more efficiently. +Toolpad was created to meet the needs of the Materialย UI community. As a result of the surveys we conducted, and the market research we undertook, we decided to develop an internal tool builder because the idea resonates with MUI's mission of empowering developers to build apps faster and more efficiently. Internal tools are software applications that are developed and used within an organization itself. They can automate tasks, manage data, and help foster collaboration. Internal tools are a valuable asset for businesses of all sizes, as they help to improve efficiency, productivity, and communication. @@ -28,16 +28,16 @@ Toolpad is an open-source, low-code, drag-and-drop admin builder. The primary pu Toolpad is not ideal for building static web pages, mobile apps, or customer-facing custom-designed front-ends. It's for building admin applications, CRUD interfaces, custom internal tools, and analytics dashboards. -Building an application on Toolpad + Building an application on Toolpad ## Who is Toolpad for? Before the arrival of Toolpad, the MUI organization primarily catered to the front-end needs of the development process. Our products were mostly useful for React engineers or designers, but we saw many full-stack engineers use our advanced components for data-intensive apps. These highly customizable components are well-suited for complex apps, but not all apps require the same level of customization: for example, internal tools just need basic theming. -Toolpad personas +Toolpad personas -Toolpad is for you if you're a full-stack or back-end developers who builds, manages, and integrate data pipelines, server-side logic, databases, microservices, and APIsโ€”and knows the most about them. Sharing these endpoints with and maintaining the internal documentation for the front-end teams is a hassle that lasts forever. Toolpad empowers you to take the next step and build the UI you need using our drag-and-drop editor, without losing any part of your normal development workflow. +Toolpad is for you if you're a full-stack or back-end developer who builds, manages, and integrates data pipelines, server-side logic, databases, microservices, and APIsโ€”and knows the most about them. Sharing these endpoints with and maintaining the internal documentation for the front-end teams is a hassle that lasts forever. Toolpad empowers you to take the next step and build the UI you need using our drag-and-drop editor, without losing any part of your normal development workflow. ## What are the main features available today? @@ -46,15 +46,15 @@ Toolpad is for you if you're a full-stack or back-end developers who builds, man Easily create user interfaces by dragging and dropping pre-built components onto the canvas. Utilize constraints to speed up the building process. -Dragging components to the canvas + Dragging components to the canvas ### 2. Query builder UI -A Postman-like query builder allows you to integrate any REST API quickly. A binding editor, which supports JavaScript, allows you to wire query response directly to the components. +A Postman-like query builder allows you to integrate any REST API quickly. A binding editor, which supports JavaScript, allows you to wire query responses directly to the components. -Building an application on Toolpad + Building an application on Toolpad ### 3. Bring your own components @@ -70,7 +70,7 @@ Directly integrate with your Node.js back-end and have your data available on th Toolpad runs completely locally. You're not stuck with an online code editor or a suboptimal GitHub integration. All configuration is stored in local files which you can version-control, edit, and deploy in any way you want. -Building an application on Toolpad + Building an application on Toolpad ### 6. A catalog of components powered by Materialย UI @@ -78,33 +78,38 @@ Toolpad runs completely locally. You're not stuck with an online code editor or Materialย UI provides production-ready React components; a chosen few are currently available inside Toolpad, and we're adding more all the time. -Building an application on Toolpad + Building an application on Toolpad ## How is Toolpad different from similar products on the market? In this domain, there are two categories of products: -1. **Visual first**: Retool, Appsmith, Budibase and the likes. While these are great tools, they don't integrate with the developer's local IDE nor offer a good git version control mechanism. Providing features that could have been hand-coded on a need basis makes the application heavy, and reports of slowness at runtime are common. +1. **Visual first**: Retool, Appsmith, Budibase and the like. While these are great tools, they don't integrate with the developer's local IDE nor offer a good git version control mechanism. Providing features that could have been hand-coded on a need basis makes the application heavy, and reports of slowness at runtime are common. -2. **Code first**: Airplane.dev, Interval and others. They also allow building internal tools but don't support a drag-and-drop UI builder. The components must be coded using their APIs, which comes with some learning curve. +2. **Code first**: Airplane.dev, Interval and others. They also allow building internal tools but don't support a drag-and-drop UI builder. + The components must be coded using their APIs, which comes with some learning curve. -Toolpad is solely focused on professional developers. As much as we are low-code, we are equally code-friendly. Providing the basic functionality that you expect from an open-source tool is non-negotiable for usโ€”we will always prioritize your best interests over all else. With nearly a decade of experience building developer tools, we understand the long-term benefits of cultivating a close relationship with our community of users. +Toolpad is solely focused on professional developers. As much as we are low-code, we are equally code-friendly. Providing the basic functionality that you expect from an open-source tool is non-negotiable for usโ€”we will always prioritize your best interests over all else. +With nearly a decade of experience building developer tools, we understand the long-term benefits of cultivating a close relationship with our community of users. Lastly, Toolpad is the only product that offers a drag-and-drop UI builder closely integrated with your favorite IDE, such as VSCode. It's the best of both worlds! ## How can I use Toolpad? -Toolpad is available as an npm package. Follow the [Installation guide](https://mui.com/toolpad/getting-started/installation/) in the docs to get started. You can learn more about Toolpad by visiting the [home page](https://mui.com/toolpad/). +Toolpad is available as an npm package. Follow the [Installation guide](https://mui.com/toolpad/getting-started/installation/) in the docs to get started. +You can learn more about Toolpad by visiting the [home page](https://mui.com/toolpad/). -Toolpad documentation and instructions on how to use it +Toolpad documentation and instructions on how to use it ## What's next? -We plan to continue to iterate on our vision of helping you as a developer to increase the speed and efficiency of your workflow. We want to optimize for the biggest pains that you face when building admin apps. Your input is crucial to helping us shape the roadmap from here. +We plan to continue to iterate on our vision of helping you as a developer to increase the speed and efficiency of your workflow. We want to optimize for the biggest pains that you face when building admin apps. +Your input is crucial to helping us shape the roadmap from here. The best places to stay up-to-date about what we're currently working on are [GitHub issues](https://github.com/mui/mui-toolpad) and our [public roadmap](https://github.com/orgs/mui/projects/9/views/1). -If you have any questions or would like to share feedback, you can directly contact the team at toolpad@mui.com or reach us on [X](https://twitter.com/MUI_Toolpad). You can also engage in conversation in our [Discord](https://mui.com/r/discord/) server. +If you have any questions or would like to share feedback, you can directly contact the team at toolpad@mui.com or reach us on [X/Twitter](https://twitter.com/MUI_Toolpad). +You can also engage in conversation on our [Discord](https://mui.com/r/discord/) server. If you'd like an in-depth demo to discuss your use case, please feel free to [schedule a meeting with me on Calendly](https://calendly.com/prakhar-mui). diff --git a/docs/pages/blog/base-ui-2024-plans.md b/docs/pages/blog/base-ui-2024-plans.md index f1c1dd0cc76ccf..ede47e3ba5611f 100644 --- a/docs/pages/blog/base-ui-2024-plans.md +++ b/docs/pages/blog/base-ui-2024-plans.md @@ -10,7 +10,7 @@ card: true The [story of Baseย UI](/blog/introducing-base-ui/) began several years agoโ€”long before headless React component libraries skyrocketed in popularityโ€”when we started to imagine a world in which Materialย UI could exist without Material Design. We're super excited to share that this dream is becoming a reality! -This year will see a lot of investment in Baseย UI as we expand the team ([we're hiring!](/careers/staff-ui-engineer-base-ui/)) and focus hard on a [stable release](https://github.com/mui/material-ui/milestone/46) (tentatively planned for late 2024), which will come full of new components, features, and improvements. +This year will see a lot of investment in Baseย UI as we expand the team and focus hard on a stable release (tentatively planned for late 2024), which will come full of new components, features, and improvements. Let's walk through some of the things we're cooking up. @@ -20,18 +20,18 @@ Baseย UI today offers a modest set of components and hooks, including some sligh However, we're aware that the package is still missing many primitive components that developers would need in order to adopt it for real-world applications. Fear not, because we're working hard to ship more components with the stable release, including: -| Components to be added | | -| :--------------------- | ---------------------------------------------------------------------------------------------: | -| Accordion | [View the GitHub issue โ†’](https://github.com/mui/material-ui/issues/38037) | -| Alert Dialog | [View the GitHub issue โ†’](https://github.com/mui/material-ui/issues/40886) | -| Checkbox | [View the GitHub issue โ†’](https://github.com/mui/material-ui/issues/38036) | -| Collapsible | [View the GitHub issue โ†’](https://github.com/mui/material-ui/issues/40959) | -| Drawer | [View the GitHub issue โ†’](https://github.com/mui/material-ui/issues/38181) | -| Radio Group | [View the GitHub issue โ†’](https://github.com/mui/material-ui/issues/38038) | -| Tooltip | [View the GitHub issue โ†’](https://github.com/mui/material-ui/issues/38045) | +| Components to be added | | +| :--------------------- | --------------------------------------------------------------------------------------: | +| Accordion | [View the GitHub issue โ†’](https://github.com/mui/base-ui/issues/25) | +| Alert Dialog | [View the GitHub issue โ†’](https://github.com/mui/base-ui/issues/83) | +| Checkbox | [View the GitHub issue โ†’](https://github.com/mui/base-ui/issues/24) | +| Collapsible | [View the GitHub issue โ†’](https://github.com/mui/base-ui/issues/84) | +| Drawer | [View the GitHub issue โ†’](https://github.com/mui/base-ui/issues/38) | +| Radio Group | [View the GitHub issue โ†’](https://github.com/mui/base-ui/issues/26) | +| Tooltip | [View the GitHub issue โ†’](https://github.com/mui/base-ui/issues/32) | And potentially more! -We'd love for you to chime in and help us prioritize, so keep an eye on open issues marked with the [`package: base-ui` and `waiting for ๐Ÿ‘`](https://github.com/mui/material-ui/issues?q=is:open+is:issue+label:%22package:+base-ui%22+label:%22waiting+for+%F0%9F%91%8D%22) labels. +We'd love for you to chime in and help us prioritize, so keep an eye on [the open issues](https://github.com/mui/base-ui/issues). ## Improved customization API @@ -57,7 +57,7 @@ To address these issues, we're considering adopting a new API that would assign This pattern has the potential to radically improve the customization experience, both for styles and structure. We are still fleshing out the API and implementation details. -If you have any questions or remarks about this change, chime in on [the RFC on GitHub](https://github.com/mui/material-ui/discussions/41085). +If you have any questions or remarks about this change, chime in on [the RFC on GitHub](https://github.com/mui/base-ui/discussions/157). We know that a significant number of projects depend on the existing API, and we want to assure you that one of our top priorities is to provide a smooth migration experience. @@ -81,10 +81,6 @@ They're currently available for use with the Popup, Menu, and Select, and the pl The core of what Baseย UI strives to deliver out of the box is first-class accessibility and an intuitive API for extensive customization. We've earmarked several issues we want to tackle before the stable release in areas such as keyboard navigation, better ARIA support, focus styles, and more. -A screenshot of the Baseย UI stable release milestone on GitHub as of January 2024. - -You can track our progress fixing any specific issues by checking out the list of [Baseย UI stable release milestones on GitHub](https://github.com/mui/material-ui/milestone/46). - ## A more independent product So far, all Baseย UI-related development has happened within the [Materialย UI GitHub repository](https://github.com/mui/material-ui). @@ -97,12 +93,14 @@ Rest assured that Baseย UI _is_ a standalone library, and it doesn't come packag Baseย UI is no longer _merely_ "Materialย UI without the styles"โ€”as we've seen with developer trends over the last few years, the potential for growth and adoption of headless components could actually dwarf Materialย UI in the near future. To acknowledge that Baseย UI has the potential to outgrow Materialย UI, we plan to move it to its own dedicated GitHub repository for more focused communication and collaboration with the community that's growing around it. -## Join us on the ride +:::success +The new repository is live๏ผ[check it out on GitHub](https://github.com/mui/base-ui)! +::: -If you're passionate about extending the web platform with powerful, accessible, unstyled components, [we're hiring UI Engineers](/careers/staff-ui-engineer-base-ui/) to work on the Baseย UI team and help us accelerate its growth. +## Help us on the ride -Lastly, we'd love to hear your feedback. -The best place to share your ideas and requests is in [the GitHub repository](https://github.com/mui/material-ui/issues?q=is:open+is:issue+label:%22package:+base-ui%22). +We'd love to hear your feedback. +The best place to share your ideas and requests is in [the GitHub repository](https://github.com/mui/base-ui/issues). Check out the existing issues and add your thoughts, and feel free to open your own issue if you don't see your concerns addressed elsewhere. Happy development! ๐Ÿ‘‹ diff --git a/docs/pages/blog/benny-joo-joining.md b/docs/pages/blog/benny-joo-joining.md index 13b160e2f0955f..4fac8d9b5f4338 100644 --- a/docs/pages/blog/benny-joo-joining.md +++ b/docs/pages/blog/benny-joo-joining.md @@ -17,6 +17,6 @@ He had a great start with his internship, implementing the [Masonry component](h As part of the Core team, he will help with the community support, as well as work on some of the new features we plan for the community version of the library, like the unstyled components and the second design system. I am excited to see what other valuable contributions he will make in the future. -The Core team will continue developing the foundations on which to build great design systems. Here's a quick view of [the community roadmap](https://github.com/orgs/mui/projects/18/views/1). +The Core team will continue developing the foundations on which to build great design systems. We couldn't be more excited to have Benny on the team! diff --git a/docs/pages/blog/marija-najdova-joining.md b/docs/pages/blog/marija-najdova-joining.md index 55ac7f80d567c0..344a665e26b27e 100644 --- a/docs/pages/blog/marija-najdova-joining.md +++ b/docs/pages/blog/marija-najdova-joining.md @@ -15,6 +15,6 @@ Marija is off to a running start, having made important changes happen during he She is now actively working on the unstyled components and [the update of the style engine](https://github.com/mui/material-ui/issues/22342). These are two items we've been eager to push forward since the release of v1 but that required someone to be dedicated to tackling them. -The community team will continue developing the foundations on which to build great design systems. Here's a quick view of [the community roadmap](https://github.com/orgs/mui/projects/18/views/1). +The community team will continue developing the foundations on which to build great design systems. We couldn't be more excited to have Marija on the team! You can follow her on [X](https://twitter.com/marijanajdova). diff --git a/docs/pages/blog/toolpad-use-cases.js b/docs/pages/blog/toolpad-use-cases.js new file mode 100644 index 00000000000000..3aeea7aec33f3d --- /dev/null +++ b/docs/pages/blog/toolpad-use-cases.js @@ -0,0 +1,7 @@ +import * as React from 'react'; +import TopLayoutBlog from 'docs/src/modules/components/TopLayoutBlog'; +import { docs } from './toolpad-use-cases.md?muiMarkdown'; + +export default function Page() { + return ; +} diff --git a/docs/pages/blog/toolpad-use-cases.md b/docs/pages/blog/toolpad-use-cases.md new file mode 100644 index 00000000000000..3c6d2a307fe899 --- /dev/null +++ b/docs/pages/blog/toolpad-use-cases.md @@ -0,0 +1,108 @@ +--- +title: How does MUI use Toolpad? +description: Explore how we use Toolpad for production use cases at MUI. +date: 2024-03-04T00:00:00.000Z +authors: ['prakhargupta'] +card: true +tags: ['Product', 'Toolpad'] +--- + +Toolpad helps full-stack engineers build internal tools quickly. +Internal tools encompass data-intensive CRUD interfaces, analytics dashboards, or custom apps that make teams productive. +Toolpad offers a low-code, GUI-based, code-friendly way of building apps and comes as an npm package that can be imported into an existing codebase. + +We've been dogfooding [Toolpad](https://mui.com/toolpad/) at MUI to build our internal tools, and it has proven beneficial for us to easily assemble well-organized, centrally located KPI dashboards and operations apps. +In this blog post, we'll discuss four such apps, and explain how we used Toolpad to turn our ideas into reality. + + +MUI public app for tracking KPIs + + +## Problems tackled through Toolpad + +Our internal tooling is easier to use and less prone to errors now; before we built these apps, some of these necessary functions were no more than a set of instructions in a Google doc or on Notion. +A user had to log into multiple services to manage their day-to-day chores. Now, one interface does it all. +We utilized Pipedream, Metabase, Google Sheets, and other tools to streamline our day-to-day operations. +This meant we had distributed code in multiple places, accessible to only a few. +Now we have everything on GitHub and collaboration is much simpler. + +Let's delve into four scenarios that Toolpad has successfully addressed: + +## 1. Support key validator + +We offer a priority support service to our MUI X premium customers: their queries get an expedited response within 24 hours. +They share their issue through a Priority Support template in our repository where they're directed to validate their license key, and once it's validated, the 24-hour countdown starts. + + + Premium key validator support app + + +Here's how we built an app for this: + +The [`updateMuiPaidSupport.ts`](https://github.com/mui/mui-public/blob/master/tools-public/toolpad/resources/updateMuiPaidSupport.ts) file hosts all functions that are called from Toolpad. +It uses the [custom function](https://mui.com/toolpad/concepts/custom-functions/) feature and combines GitHub Actions, Google Sheets, and Octokit to read and verify user information. +The fetched data is then bound to the UI components. +It uses Toolpad's [page parameters](https://mui.com/toolpad/concepts/page-properties/#page-parameters), [secrets handling](https://mui.com/toolpad/concepts/custom-functions/#secrets-handling), [shell removal](https://mui.com/toolpad/concepts/page-properties/#display-mode), and custom styling features. +This app took one developer just a few hours to build which otherwise would have taken much longer. + +## 2. Customer support KPI tracker + +The read-only page illustrated below uses [HTTP requests](https://mui.com/toolpad/concepts/http-requests/) for its data source. +Through the query builder UI we fetch the 100 latest support tickets from Zendesk to calculate the average time it takes us to respond to and resolve customer requests. +It uses a [custom component](https://mui.com/toolpad/concepts/custom-components/) which we call the "health badge." +Based on the metric value, the component shows three color-coded states: Problem (red), Warning (yellow), and OK (green). +Other KPI pages also use this health badge and pre-built Chart components to compare stats, observe trends, and spot anomalies. + +The video below demonstrates the usage of this app in dev mode: + + + +We opted for Toolpad since Metabase doesn't support importing data from REST APIs. +This is possible in Google Sheets but it requires writing a lot of JS code, and since we wanted to embed it in a [Notion page](https://mui-org.notion.site/KPIs-1ce9658b85ce4628a2a2ed2ae74ff69c?pvs=4#3974cb6ed12b4c5a9013bac63113e3bc), Toolpad was the ideal choice. +Toolpad handles state management and routing, and simplifies query building and data binding, removing the need to write glue code. + +You can explore both of the aforementioned apps in dev mode on your device by running the underlying [Node application](https://github.com/mui/mui-public/tree/HEAD/tools-public). +The next two apps discussed are internal to MUI. + +## 3. Manage overdue invoices + +We have an internal operations process to remind customers about overdue invoices: reminder emails are sent out at regular intervals following the due date. +In the Toolpad app, the operations team can view a table of all customers who need to be contacted. +They select one, email them from Zendesk, and update the status to `CONTACTED`, which is then written back to the database. +This is a private app for internal use that can't be shared, but the following video gives a quick demo: + + + +Before this, we relied on a combination of Metabase and Google Sheets to fetch and edit recordsโ€”but this was cumbersome to operate and sometimes caused data inconsistency issues. +Thanks to Toolpad we've managed to bring it all under one roof, dramatically improving our operations team's efficiency and productivity. + +## 4. Contributor payout + +We have a script to fetch monthly payout data for contributors to the MUI Store. +Our operations team is responsible for paying contributors, but the script proved too technically challenging for them to run without help from our engineers. +We solved this problem by importing the script into Toolpad and creating a UI for it. +The video below shows how a user can select the dates, run the script, and receive text that's properly formatted to copy and paste directly into Slack communications: + + + +## Conclusion + +As you've seen, at MUI we have streamlined our internal tooling through Toolpad, helping us stay lean and move fast. +Internal apps are often very specific to the needs of the organization, but hopefully, you've been inspired by some of our use cases here: + +- Have you come across any similar needs within your org regarding operations, administration, or analytics? +- Do you have existing code that you wish you could reuse in a low-code builder instead of starting fresh? +- Do you wish you didn't have to do any maintenance on the front ends of your internal tools? + +Toolpad handles state management, data fetching, routing, and UI creation, and it can be imported directly into your code base to save you time. +I encourage you to check out more [examples](https://mui.com/toolpad/examples/) and visit our [GitHub repository](https://github.com/mui/mui-toolpad/) to evaluate the product. +In case you need any further information, feel free to reach out to the team at toolpad@mui.com. diff --git a/docs/pages/careers.tsx b/docs/pages/careers.tsx index 0f1e1d90e3210c..dc3aeb54857037 100644 --- a/docs/pages/careers.tsx +++ b/docs/pages/careers.tsx @@ -146,24 +146,18 @@ const openRolesData = [ { title: 'Engineering', roles: [ - { - title: 'React Engineer โ€” xCharts', - description: - 'You will help form the xCharts team, build ambitious and complex new features, work on strategic problems, and help grow adoption.', - url: '/careers/react-engineer-x-charts/', - }, // { - // title: 'React Engineer - X', + // title: 'React Engineer โ€” xCharts', + // description: + // 'You will help form the xCharts team, build ambitious and complex new features, work on strategic problems, and help grow adoption.', + // url: '/careers/react-engineer-x-charts/', + // }, + // { + // title: 'React Engineer โ€” X', // description: // 'You will strengthen the MUI X product, build ambitious and complex new features, work on strategic problems, and help grow adoption.', // url: '/careers/react-engineer-x/', // }, - { - title: 'Staff UI Engineer โ€” Baseย UI', - description: - 'Research, build, document, and ship high-quality, unstyled UI components with a focus on a11y.', - url: '/careers/staff-ui-engineer-base-ui/', - }, ], }, { @@ -223,6 +217,12 @@ const nextRolesData = [ 'You will strengthen the MUI X product, build ambitious and complex new features, work on strategic problems, and help grow adoption.', url: '/careers/react-engineer-x/', }, + { + title: 'React Engineer โ€” xCharts', + description: + 'You will help form the xCharts team, build ambitious and complex new features, work on strategic problems, and help grow adoption.', + url: '/careers/react-engineer-x-charts/', + }, { title: 'React Tech Lead โ€” Core', description: diff --git a/docs/pages/careers/react-engineer-x-charts.md b/docs/pages/careers/react-engineer-x-charts.md index 3f5d58fd3af65f..49632707feefee 100644 --- a/docs/pages/careers/react-engineer-x-charts.md +++ b/docs/pages/careers/react-engineer-x-charts.md @@ -1,4 +1,4 @@ -# React Engineer โ€” xCharts +# React Engineer โ€” xCharts (future role)

You will help form the xCharts team, build ambitious and complex new features, work on strategic problems, and help grow adoption.

diff --git a/docs/pages/careers/react-engineer-x-grid.md b/docs/pages/careers/react-engineer-x-grid.md index 10c5c7530c57f3..af2477a07e4c63 100644 --- a/docs/pages/careers/react-engineer-x-grid.md +++ b/docs/pages/careers/react-engineer-x-grid.md @@ -1,4 +1,4 @@ -# React Engineer โ€” xGrid +# React Engineer โ€” xGrid (future role)

You will strengthen the Data Grid team, build ambitious and complex new features, work on strategic problems, and help grow adoption.

diff --git a/docs/pages/careers/react-engineer-x.md b/docs/pages/careers/react-engineer-x.md index 87e74cfee87de6..4a9364c7edf710 100644 --- a/docs/pages/careers/react-engineer-x.md +++ b/docs/pages/careers/react-engineer-x.md @@ -1,4 +1,4 @@ -# React Engineer โ€” X +# React Engineer โ€” X (future role)

You will strengthen the MUIย X product, build ambitious and complex new features, work on strategic problems, and help grow adoption.

diff --git a/docs/pages/experiments/base/components-gallery.tsx b/docs/pages/experiments/base/components-gallery.tsx index 084ce223ad1511..94c04408330fb0 100644 --- a/docs/pages/experiments/base/components-gallery.tsx +++ b/docs/pages/experiments/base/components-gallery.tsx @@ -143,7 +143,7 @@ export default function ComponentsGallery() { const [exited, setExited] = React.useState(true); const nodeRef = React.useRef(null); - const handleClose = (_: any, reason: SnackbarCloseReason) => { + const handleClose = (_: any, reason?: SnackbarCloseReason) => { if (reason === 'clickaway') { return; } @@ -208,7 +208,7 @@ export default function ComponentsGallery() { setCopySnackbarOpen(true); } - const handleCopyClose = (_: any, reason: SnackbarCloseReason) => { + const handleCopyClose = (_: any, reason?: SnackbarCloseReason) => { if (reason === 'clickaway') { return; } diff --git a/docs/public/static/base-ui/roadmap/github-roadmap.png b/docs/public/static/base-ui/roadmap/github-roadmap.png new file mode 100644 index 00000000000000..516d39e8879910 Binary files /dev/null and b/docs/public/static/base-ui/roadmap/github-roadmap.png differ diff --git a/docs/public/static/blog/base-ui-2024-plans/base-ui-milestone.png b/docs/public/static/blog/base-ui-2024-plans/base-ui-milestone.png deleted file mode 100644 index e643db697b28d6..00000000000000 Binary files a/docs/public/static/blog/base-ui-2024-plans/base-ui-milestone.png and /dev/null differ diff --git a/docs/public/static/blog/toolpad-use-cases/card.png b/docs/public/static/blog/toolpad-use-cases/card.png new file mode 100644 index 00000000000000..4c301019c3be65 Binary files /dev/null and b/docs/public/static/blog/toolpad-use-cases/card.png differ diff --git a/docs/public/static/blog/toolpad-use-cases/contributor-payout.mp4 b/docs/public/static/blog/toolpad-use-cases/contributor-payout.mp4 new file mode 100644 index 00000000000000..01431e0b72ed56 Binary files /dev/null and b/docs/public/static/blog/toolpad-use-cases/contributor-payout.mp4 differ diff --git a/docs/public/static/blog/toolpad-use-cases/overdue-invoice.mp4 b/docs/public/static/blog/toolpad-use-cases/overdue-invoice.mp4 new file mode 100644 index 00000000000000..0fdfa8fc181b4d Binary files /dev/null and b/docs/public/static/blog/toolpad-use-cases/overdue-invoice.mp4 differ diff --git a/docs/public/static/blog/toolpad-use-cases/tools-public.png b/docs/public/static/blog/toolpad-use-cases/tools-public.png new file mode 100644 index 00000000000000..f5038980713029 Binary files /dev/null and b/docs/public/static/blog/toolpad-use-cases/tools-public.png differ diff --git a/docs/public/static/blog/toolpad-use-cases/validate-support.png b/docs/public/static/blog/toolpad-use-cases/validate-support.png new file mode 100644 index 00000000000000..b988168f45bed3 Binary files /dev/null and b/docs/public/static/blog/toolpad-use-cases/validate-support.png differ diff --git a/docs/public/static/blog/toolpad-use-cases/zendesk-first-reply-dev.mp4 b/docs/public/static/blog/toolpad-use-cases/zendesk-first-reply-dev.mp4 new file mode 100644 index 00000000000000..711eb1b312afd6 Binary files /dev/null and b/docs/public/static/blog/toolpad-use-cases/zendesk-first-reply-dev.mp4 differ diff --git a/docs/public/static/branding/about/albert-yu.png b/docs/public/static/branding/about/albert-yu.png index f641161e5e3133..4153178364ace5 100644 Binary files a/docs/public/static/branding/about/albert-yu.png and b/docs/public/static/branding/about/albert-yu.png differ diff --git a/docs/public/static/branding/about/alexandre-fauquette.png b/docs/public/static/branding/about/alexandre-fauquette.png index 909cb3a3175a14..3e22f7d26c148d 100644 Binary files a/docs/public/static/branding/about/alexandre-fauquette.png and b/docs/public/static/branding/about/alexandre-fauquette.png differ diff --git a/docs/public/static/branding/about/bilal-shafi.png b/docs/public/static/branding/about/bilal-shafi.png index 9a3e5ccb0f76c5..7f91a2a932d41a 100644 Binary files a/docs/public/static/branding/about/bilal-shafi.png and b/docs/public/static/branding/about/bilal-shafi.png differ diff --git a/docs/public/static/branding/about/brijesh-bittu.png b/docs/public/static/branding/about/brijesh-bittu.png index 1a9f7dc8dd48ba..97e6a5018eed1e 100644 Binary files a/docs/public/static/branding/about/brijesh-bittu.png and b/docs/public/static/branding/about/brijesh-bittu.png differ diff --git a/docs/public/static/branding/about/david-cnoops.png b/docs/public/static/branding/about/david-cnoops.png index 3e723c509e7bc1..53c368adc2b0d4 100644 Binary files a/docs/public/static/branding/about/david-cnoops.png and b/docs/public/static/branding/about/david-cnoops.png differ diff --git a/docs/public/static/branding/about/james-nelson.png b/docs/public/static/branding/about/james-nelson.png new file mode 100644 index 00000000000000..0a99cb5a3b6063 Binary files /dev/null and b/docs/public/static/branding/about/james-nelson.png differ diff --git a/docs/public/static/branding/about/jan-potoms.png b/docs/public/static/branding/about/jan-potoms.png index d58ee4a6f8a761..e703755bc9f71e 100644 Binary files a/docs/public/static/branding/about/jan-potoms.png and b/docs/public/static/branding/about/jan-potoms.png differ diff --git a/docs/public/static/branding/about/lukas-tyla.png b/docs/public/static/branding/about/lukas-tyla.png index bde12f6f10479e..fa9d4765a1269b 100644 Binary files a/docs/public/static/branding/about/lukas-tyla.png and b/docs/public/static/branding/about/lukas-tyla.png differ diff --git a/docs/public/static/branding/about/michel-engelen.png b/docs/public/static/branding/about/michel-engelen.png index 360b5a61015e11..72572013203652 100644 Binary files a/docs/public/static/branding/about/michel-engelen.png and b/docs/public/static/branding/about/michel-engelen.png differ diff --git a/docs/public/static/branding/about/nora-leonte.png b/docs/public/static/branding/about/nora-leonte.png index 1490f1036d9151..0d76f5061bcf5a 100644 Binary files a/docs/public/static/branding/about/nora-leonte.png and b/docs/public/static/branding/about/nora-leonte.png differ diff --git a/docs/public/static/branding/about/raffaella-luzi.png b/docs/public/static/branding/about/raffaella-luzi.png index f0e8b274437f23..02763b93e1fff8 100644 Binary files a/docs/public/static/branding/about/raffaella-luzi.png and b/docs/public/static/branding/about/raffaella-luzi.png differ diff --git "a/docs/public/static/branding/about/romain-gr\303\251goire.png" "b/docs/public/static/branding/about/romain-gr\303\251goire.png" index 59b34c2363f182..5742150d319777 100644 Binary files "a/docs/public/static/branding/about/romain-gr\303\251goire.png" and "b/docs/public/static/branding/about/romain-gr\303\251goire.png" differ diff --git a/docs/public/static/branding/about/vadym-raksha.png b/docs/public/static/branding/about/vadym-raksha.png index 3d52ae6dfbdedc..b55b4f9b335a85 100644 Binary files a/docs/public/static/branding/about/vadym-raksha.png and b/docs/public/static/branding/about/vadym-raksha.png differ diff --git a/docs/public/static/branding/about/victor-zanivan.png b/docs/public/static/branding/about/victor-zanivan.png index 197768a23502d1..edc761192ee0fd 100644 Binary files a/docs/public/static/branding/about/victor-zanivan.png and b/docs/public/static/branding/about/victor-zanivan.png differ diff --git a/docs/public/static/material-ui/roadmap/github-project.png b/docs/public/static/material-ui/roadmap/github-project.png index 7c8e748a687289..4bfe25e1c6801e 100644 Binary files a/docs/public/static/material-ui/roadmap/github-project.png and b/docs/public/static/material-ui/roadmap/github-project.png differ diff --git a/docs/src/components/productBaseUI/BaseUIThemesDemo.tsx b/docs/src/components/productBaseUI/BaseUIThemesDemo.tsx index b8d24d54b97e9d..040742e06aa145 100644 --- a/docs/src/components/productBaseUI/BaseUIThemesDemo.tsx +++ b/docs/src/components/productBaseUI/BaseUIThemesDemo.tsx @@ -785,7 +785,7 @@ export default function BaseUIThemesDemo() { // Snackbar const [openSnackbar, setOpenSnackbar] = React.useState(false); - const handleCloseSnackbar = (_: any, reason: SnackbarCloseReason) => { + const handleCloseSnackbar = (_: any, reason?: SnackbarCloseReason) => { if (reason === 'clickaway') { return; } diff --git a/docs/src/components/showcase/TaskCard.tsx b/docs/src/components/showcase/TaskCard.tsx index 304e9e65788b54..d437f7a6f6b217 100644 --- a/docs/src/components/showcase/TaskCard.tsx +++ b/docs/src/components/showcase/TaskCard.tsx @@ -33,7 +33,7 @@ export default function TaskCard() { - + Customize every button and chip instance primary color diff --git a/docs/src/modules/brandingTheme.ts b/docs/src/modules/brandingTheme.ts index f593c252a3df1c..3fba71c44d36fa 100644 --- a/docs/src/modules/brandingTheme.ts +++ b/docs/src/modules/brandingTheme.ts @@ -65,6 +65,22 @@ declare module '@mui/material/Chip' { } } +declare module '@mui/material/SvgIcon' { + interface SvgIconPropsColorOverrides { + danger: true; + } + interface SvgIconPropsSizeOverrides { + xs: true; + sm: true; + md: true; + lg: true; + xl: true; + xl2: true; + xl3: true; + xl4: true; + } +} + // TODO: enable this once types conflict is fixed // declare module '@mui/material/Button' { // interface ButtonPropsVariantOverrides { @@ -505,7 +521,7 @@ export function getThemedComponents(): ThemeOptions { borderColor: (theme.vars || theme).palette.primaryDark[100], boxShadow: `${alpha(theme.palette.grey[50], 0.5)} 0 2px 0.5px inset, ${alpha( theme.palette.grey[100], - 0.8, + 0.5, )} 0 -2px 0 inset, ${alpha(theme.palette.grey[200], 0.5)} 0 1px 2px 0`, '&:hover': { backgroundColor: (theme.vars || theme).palette.primaryDark[50], @@ -514,10 +530,7 @@ export function getThemedComponents(): ThemeOptions { color: (theme.vars || theme).palette.primaryDark[100], borderColor: alpha(theme.palette.primaryDark[600], 0.5), backgroundColor: alpha(theme.palette.primaryDark[700], 0.4), - boxShadow: `${alpha(theme.palette.primaryDark[600], 0.2)} 0 2px 0 inset, ${alpha( - theme.palette.primaryDark[900], - 0.5, - )} 0 -3px 1px inset, ${theme.palette.common.black} 0 1px 2px 0`, + boxShadow: `${alpha(theme.palette.primaryDark[600], 0.1)} 0 2px 0 inset, ${alpha(theme.palette.primaryDark[900], 0.5)} 0 -2px 1px inset, ${theme.palette.common.black} 0 1px 2px 0`, '&:hover': { backgroundColor: (theme.vars || theme).palette.primaryDark[700], }, @@ -790,6 +803,9 @@ export function getThemedComponents(): ThemeOptions { '&:hover, &:focus': { backgroundColor: (theme.vars || theme).palette.grey[50], }, + '&:focus-visible': { + outline: 'none', + }, '&.Mui-selected': { fontWeight: 500, color: (theme.vars || theme).palette.primary[600], diff --git a/docs/src/modules/components/ApiPage.js b/docs/src/modules/components/ApiPage.js index 7bf385bf42e5d4..80781fd2724f25 100644 --- a/docs/src/modules/components/ApiPage.js +++ b/docs/src/modules/components/ApiPage.js @@ -247,7 +247,7 @@ export default function ApiPage(props) { `)} language="jsx" /> - +

{componentDescription ? (
diff --git a/docs/src/modules/components/ApiPage/list/ExpandableApiItem.tsx b/docs/src/modules/components/ApiPage/list/ExpandableApiItem.tsx index ff98536fdb0917..5f5a076ea250dc 100644 --- a/docs/src/modules/components/ApiPage/list/ExpandableApiItem.tsx +++ b/docs/src/modules/components/ApiPage/list/ExpandableApiItem.tsx @@ -56,8 +56,8 @@ const Root = styled('div')<{ ownerState: { type?: DescriptionType } }>( p: { marginBottom: theme.spacing(1.5) }, }, '& .MuiApi-item-note': { - fontSize: 11, - marginLeft: 6, + fontSize: 12, + marginLeft: 2, letterSpacing: '1px', textTransform: 'uppercase', color: `var(--muidocs-palette-success-800, ${lightTheme.palette.success[800]})`, diff --git a/docs/src/modules/components/ApiPage/sections/ToggleDisplayOption.tsx b/docs/src/modules/components/ApiPage/sections/ToggleDisplayOption.tsx index 753c0a5758c565..6c379397e6a41c 100644 --- a/docs/src/modules/components/ApiPage/sections/ToggleDisplayOption.tsx +++ b/docs/src/modules/components/ApiPage/sections/ToggleDisplayOption.tsx @@ -1,10 +1,10 @@ import * as React from 'react'; -import Tooltip, { TooltipProps } from '@mui/material/Tooltip'; -import ToggleButtonGroup from '@mui/material/ToggleButtonGroup'; -import ToggleButton, { ToggleButtonProps } from '@mui/material/ToggleButton'; -import CalendarViewDayRoundedIcon from '@mui/icons-material/CalendarViewDayRounded'; -import TableChartRoundedIcon from '@mui/icons-material/TableChartRounded'; -import ReorderRoundedIcon from '@mui/icons-material/ReorderRounded'; +import Box from '@mui/material/Box'; +import Button from '@mui/material/Button'; +import Menu from '@mui/material/Menu'; +import MenuItem from '@mui/material/MenuItem'; +import CheckIcon from '@mui/icons-material/Check'; +import ArrowDropDownRoundedIcon from '@mui/icons-material/ArrowDropDownRounded'; import useEnhancedEffect from '@mui/utils/useEnhancedEffect'; export type ApiDisplayOptions = 'collapsed' | 'expanded' | 'table'; @@ -71,26 +71,6 @@ export function useApiPageOption( return [option, updateOption]; } -// Fix Toggle buton highlight (taken from https://github.com/mui/material-ui/issues/18091) -type TooltipToggleButtonProps = ToggleButtonProps & { - /** - * The title passed to the Tooltip - */ - title: string; - TooltipProps?: Omit; -}; - -// Catch props and forward to ToggleButton -const TooltipToggleButton = React.forwardRef( - ({ title, TooltipProps: tooltipProps, ...props }, ref) => { - return ( - - - - ); - }, -); - interface ToggleDisplayOptionProps { displayOption: ApiDisplayOptions; setDisplayOption: (newValue: ApiDisplayOptions) => void; @@ -103,72 +83,90 @@ interface ToggleDisplayOptionProps { export default function ToggleDisplayOption(props: ToggleDisplayOptionProps) { const { displayOption, setDisplayOption, sectionType } = props; - const handleAlignment = ( - event: React.MouseEvent, - newDisplayOption: ApiDisplayOptions | null, - ) => { - if (newDisplayOption === null) { - return; - } + const [anchorEl, setAnchorEl] = React.useState(null); + const [open, setOpen] = React.useState(false); + + const handleMenuClick = (event: React.MouseEvent) => { + setAnchorEl(event.currentTarget); + setOpen(true); + }; + + const handleClose = () => { + setAnchorEl(null); + setOpen(false); + }; + + const handleMenuItemClick = (newDisplayOption: ApiDisplayOptions) => { setDisplayOption(newDisplayOption); + handleClose(); }; return ( - - - - - + +

- - - + handleMenuItemClick('table')} + selected={displayOption === 'table'} + data-ga-event-category="layout" + data-ga-event-action={sectionType} + data-ga-event-label="table" + > + + Table + + handleMenuItemClick('expanded')} + selected={displayOption === 'expanded'} + data-ga-event-category="layout" + data-ga-event-action={sectionType} + data-ga-event-label="expanded" + > + + Expanded list + + handleMenuItemClick('collapsed')} + selected={displayOption === 'collapsed'} + data-ga-event-category="layout" + data-ga-event-action={sectionType} + data-ga-event-label="collapsed" + > + + Collapsed list + + + ); } diff --git a/docs/src/modules/components/ApiPage/table/ClassesTable.tsx b/docs/src/modules/components/ApiPage/table/ClassesTable.tsx index d49d35f8cc7236..b2c98cf1674cf9 100644 --- a/docs/src/modules/components/ApiPage/table/ClassesTable.tsx +++ b/docs/src/modules/components/ApiPage/table/ClassesTable.tsx @@ -81,13 +81,13 @@ export default function ClassesTable(props: ClassesTableProps) { return ( - + .{className} {displayClassKeys && ( {!isGlobal && {key}} )} - + - + {propName} {isRequired ? '*' : ''} {isOptional ? '?' : ''} @@ -200,7 +200,7 @@ export default function PropertiesTable(props: PropertiesTableProps) { )} )} - + {description && } {seeMoreDescription && (

({ - padding: theme.spacing(1), - marginBottom: theme.spacing(1), - marginRight: theme.spacing(1), - fontWeight: 600, - minHeight: 32, + padding: theme.spacing(0.5), + border: '1px solid', + borderColor: 'transparent', + fontWeight: theme.typography.fontWeightSemiBold, + minHeight: 30, minWidth: 0, - borderRadius: '12px', + borderRadius: '8px', '&:hover': { background: (theme.vars || theme).palette.grey[50], + borderColor: (theme.vars || theme).palette.divider, + color: (theme.vars || theme).palette.text.primary, }, ...theme.applyDarkStyles({ '&:hover': { + borderColor: (theme.vars || theme).palette.divider, background: (theme.vars || theme).palette.primaryDark[700], }, '&.Mui-selected': { @@ -54,21 +57,16 @@ export default function ComponentPageTabs(props) { sx={{ position: 'sticky', top: 65, // to be positioned below the app bar - mt: 1, - pt: 1, - mx: { - xs: -2, - sm: 0, - }, - px: { - xs: 2, - sm: 0, - }, - backgroundColor: (theme) => - theme.palette.mode === 'dark' ? theme.palette.primaryDark[900] : 'rgba(255,255,255)', + mt: 2, + mx: -1, + backgroundColor: 'background.default', borderBottom: 1, borderColor: 'divider', zIndex: 1000, + [`& .${tabsClasses.flexContainer}`]: { + p: 1, + gap: 1, + }, [`& .${tabsClasses.indicator}`]: { transition: 'none', }, @@ -82,20 +80,11 @@ export default function ComponentPageTabs(props) { }, }} > - + {headers.components?.length > 0 && ( - +

- +

{Object.keys(parameters).length > 0 ? ( - + {message.title} required={true}" - }, - "root": { "description": "Class applied to the root element." } - } + } + }, + "slotDescriptions": { "root": "The component that renders the root." } } diff --git a/docs/translations/translations.json b/docs/translations/translations.json index a79583b7a2a6ba..8f2b913c50c525 100644 --- a/docs/translations/translations.json +++ b/docs/translations/translations.json @@ -38,6 +38,7 @@ "/base-ui/getting-started/usage": "Usage", "/base-ui/getting-started/customization": "Customization", "/base-ui/getting-started/accessibility": "Accessibility", + "/base-ui/getting-started/roadmap": "Roadmap", "/base-ui/getting-started/support": "Support", "/base-ui/react-": "Components", "/base-ui/all-components": "All components", diff --git a/examples/pigment-css-nextjs-ts/.gitignore b/examples/pigment-css-nextjs-ts/.gitignore new file mode 100644 index 00000000000000..28c8a5adb7c034 --- /dev/null +++ b/examples/pigment-css-nextjs-ts/.gitignore @@ -0,0 +1,36 @@ +# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. + +# dependencies +/node_modules +/.pnp +.pnp.js + +# testing +/coverage + +# next.js +/.next/ +/out/ + +# production +/build + +# misc +.DS_Store +*.pem + +# debug +npm-debug.log* +yarn-debug.log* +yarn-error.log* +.pnpm-debug.log* + +# local env files +.env*.local + +# vercel +.vercel + +# typescript +*.tsbuildinfo +# next-env.d.ts diff --git a/examples/pigment-css-nextjs-ts/README.md b/examples/pigment-css-nextjs-ts/README.md new file mode 100644 index 00000000000000..3449ebdbd149ec --- /dev/null +++ b/examples/pigment-css-nextjs-ts/README.md @@ -0,0 +1,38 @@ +# Pigment CSS - Next.js App Router with TypeScript example project + +This is a [Next.js](https://nextjs.org/) project bootstrapped using [`create-next-app`](https://github.com/vercel/next.js/tree/HEAD/packages/create-next-app), with TypeScript and MUI's zero-runtime CSS-in-JS installed. + +## How to use + +Download the example [or clone the repo](https://github.com/mui/material-ui): + + + +```bash +curl https://codeload.github.com/mui/material-ui/tar.gz/master | tar -xz --strip=2 material-ui-master/examples/pigment-css-nextjs-ts +cd pigment-css-nextjs-ts +``` + +Install it and run: + +```bash +npm install +npm run dev +``` + +Open [http://localhost:3000](http://localhost:3000) with your browser to see the result. + +or: + + + +[![Edit on StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/mui/material-ui/tree/master/examples/pigment-css-nextjs-ts) + +[![Edit on CodeSandbox](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/p/sandbox/github/mui/material-ui/tree/master/examples/pigment-css-nextjs-ts) + +## Learn more + +To learn more about this example: + +- [Pigment CSS documentation](https://github.com/mui/material-ui/blob/master/packages/pigment-react/README.md) - learn more about Pigment CSS features and APIs. +- [Next.js documentation](https://nextjs.org/docs) - learn about Next.js features and APIs. diff --git a/examples/pigment-css-nextjs-ts/next-env.d.ts b/examples/pigment-css-nextjs-ts/next-env.d.ts new file mode 100644 index 00000000000000..4f11a03dc6cc37 --- /dev/null +++ b/examples/pigment-css-nextjs-ts/next-env.d.ts @@ -0,0 +1,5 @@ +/// +/// + +// NOTE: This file should not be edited +// see https://nextjs.org/docs/basic-features/typescript for more information. diff --git a/examples/pigment-css-nextjs-ts/next.config.js b/examples/pigment-css-nextjs-ts/next.config.js new file mode 100644 index 00000000000000..2196cab8c75dda --- /dev/null +++ b/examples/pigment-css-nextjs-ts/next.config.js @@ -0,0 +1,28 @@ +const { withPigment, extendTheme } = require('@pigment-css/nextjs-plugin'); + +// To learn more about theming, visit https://github.com/mui/material-ui/blob/master/packages/zero-runtime/README.md#theming +const theme = extendTheme({ + colorSchemes: { + light: { + palette: { + background: '0 0% 100%', + foreground: '240 10% 3.9%', + primary: '240 5.9% 10%', + border: '240 5.9% 90%', + }, + }, + dark: { + palette: { + background: '240 10% 3.9%', + foreground: '0 0% 80%', + primary: '0 0% 98%', + border: '240 3.7% 15.9%', + }, + }, + }, +}); + +/** @type {import('next').NextConfig} */ +const nextConfig = {}; + +module.exports = withPigment(nextConfig, { theme }); diff --git a/examples/pigment-css-nextjs-ts/package.json b/examples/pigment-css-nextjs-ts/package.json new file mode 100644 index 00000000000000..b2579629a61906 --- /dev/null +++ b/examples/pigment-css-nextjs-ts/package.json @@ -0,0 +1,27 @@ +{ + "name": "pigment-css-nextjs-ts", + "version": "5.0.0", + "private": true, + "scripts": { + "dev": "next dev", + "build": "next build", + "start": "next start", + "lint": "next lint", + "post-update": "echo \"codesandbox preview only, need an update\" && pnpm update --latest" + }, + "dependencies": { + "@pigment-css/react": "latest", + "react": "latest", + "react-dom": "latest", + "next": "latest" + }, + "devDependencies": { + "@pigment-css/nextjs-plugin": "latest", + "@types/node": "latest", + "@types/react": "latest", + "@types/react-dom": "latest", + "eslint": "latest", + "eslint-config-next": "latest", + "typescript": "latest" + } +} diff --git a/examples/pigment-css-nextjs-ts/public/.gitkeep b/examples/pigment-css-nextjs-ts/public/.gitkeep new file mode 100644 index 00000000000000..e69de29bb2d1d6 diff --git a/examples/pigment-css-nextjs-ts/src/app/favicon.ico b/examples/pigment-css-nextjs-ts/src/app/favicon.ico new file mode 100644 index 00000000000000..e19f48f591206d Binary files /dev/null and b/examples/pigment-css-nextjs-ts/src/app/favicon.ico differ diff --git a/examples/pigment-css-nextjs-ts/src/app/globals.css b/examples/pigment-css-nextjs-ts/src/app/globals.css new file mode 100644 index 00000000000000..3dd82369c1b57d --- /dev/null +++ b/examples/pigment-css-nextjs-ts/src/app/globals.css @@ -0,0 +1,10 @@ +* { + box-sizing: border-box; + padding: 0; + margin: 0; +} + +a { + color: inherit; + text-decoration: none; +} diff --git a/examples/pigment-css-nextjs-ts/src/app/layout.tsx b/examples/pigment-css-nextjs-ts/src/app/layout.tsx new file mode 100644 index 00000000000000..fb3a3b8adb2db7 --- /dev/null +++ b/examples/pigment-css-nextjs-ts/src/app/layout.tsx @@ -0,0 +1,31 @@ +import * as React from 'react'; +import type { Metadata } from 'next'; +import '@pigment-css/react/styles.css'; +import { css } from '@pigment-css/react'; + +import './globals.css'; + +export const metadata: Metadata = { + title: 'Create Next App', + description: 'Generated by create next app', +}; + +export default function RootLayout(props: { children: React.ReactNode }) { + return ( + + ({ + color: 'hsl(var(--palette-foreground))', + backgroundColor: 'hsl(var(--palette-background))', + fontFamily: + "system-ui, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'", + ...theme.applyStyles('dark', { + colorScheme: 'dark', + }), + }))} + > + {props.children} + + + ); +} diff --git a/examples/pigment-css-nextjs-ts/src/app/page.tsx b/examples/pigment-css-nextjs-ts/src/app/page.tsx new file mode 100644 index 00000000000000..08a5fc7e6cb3fe --- /dev/null +++ b/examples/pigment-css-nextjs-ts/src/app/page.tsx @@ -0,0 +1,204 @@ +import * as React from 'react'; +import { Kalnia, Josefin_Sans } from 'next/font/google'; +import { styled, css, keyframes } from '@pigment-css/react'; + +const kalnia = Kalnia({ subsets: ['latin'] }); +const josefin = Josefin_Sans({ subsets: ['latin'] }); + +const scale = keyframes({ + to: { scale: 'var(--s2)' }, +}); + +const Link = styled('a', { shouldForwardProp: (prop) => prop !== 'outlined' })<{ + outlined?: boolean; +}>(({ theme }) => ({ + fontSize: '1rem', + background: 'rgba(0 0 0 / 0.04)', + padding: '0.5rem 1rem', + letterSpacing: '1px', + borderRadius: '4px', + textAlign: 'center', + ...theme.applyStyles('dark', { + background: 'rgba(255 255 255 / 0.1)', + }), + variants: [ + { + props: { outlined: true }, + style: { + background: 'transparent', + color: `hsl(${theme.vars.palette.primary})`, + border: `1px solid hsl(${theme.vars.palette.border})`, + }, + }, + ], +})); + +const Bubble = styled('span')({ + height: 'var(--size, 100%)', + aspectRatio: '1', + background: 'radial-gradient(hsl(var(--h) 100% 70%) 25%, transparent 50%)', + position: 'absolute', + display: 'inline-block', + left: 'var(--x, 0)', + top: 'var(--y, 0)', + scale: '0', + translate: '-50% -50%', + mixBlendMode: 'multiply', + filter: 'blur(2px)', + animation: `${scale} var(--s, 2s) var(--d, 0s) infinite alternate`, +}); + +function randomBetween(min: number, max: number) { + return Math.floor(Math.random() * (max - min + 1) + min); +} +function generateBubbleVars() { + return ` + --x: ${randomBetween(10, 90)}%; + --y: ${randomBetween(15, 85)}%; + --h: ${randomBetween(0, 360)}; + --s2: ${randomBetween(2, 6)}; + --d: -${randomBetween(250, 400) / 1000}s; + --s: ${randomBetween(3, 6)}s; + `; +} + +export default function Home() { + return ( +

+

({ + fontSize: 'clamp(3rem, 1.9503rem + 4.4789vw, 6.25rem)', + fontWeight: 500, + textAlign: 'center', + position: 'relative', + display: 'flex', + alignItems: 'center', + color: '#888', + marginBottom: '1rem', + ...theme.applyStyles('dark', { color: '#fff' }), + }))}`} + > + Pigment CSS + ({ + position: 'absolute', + inset: '0', + background: 'white', + mixBlendMode: 'color-burn', + overflow: 'hidden', + pointerEvents: 'none', + ...theme.applyStyles('dark', { + mixBlendMode: 'darken', + filter: 'brightness(2)', + }), + }))} + > + + + + + + + + + + + +

+
+ CSS-in-JS library with static extraction +
+ +
*': { flex: 'auto' }, + })} + > + + Documentation + + + Roadmap + +
+
+ ); +} diff --git a/examples/pigment-css-nextjs-ts/src/augment.d.ts b/examples/pigment-css-nextjs-ts/src/augment.d.ts new file mode 100644 index 00000000000000..d10b46e01d4da0 --- /dev/null +++ b/examples/pigment-css-nextjs-ts/src/augment.d.ts @@ -0,0 +1,19 @@ +import type {} from '@pigment-css/react/theme'; +import type { ExtendTheme } from '@pigment-css/react'; + +declare module '@pigment-css/react/theme' { + export interface ThemeArgs { + theme: ExtendTheme<{ + colorScheme: 'light' | 'dark'; + tokens: { + palette: { + background: string; + foreground: string; + primary: string; + primaryForeground: string; + border: string; + }; + }; + }>; + } +} diff --git a/examples/pigment-css-nextjs-ts/tsconfig.json b/examples/pigment-css-nextjs-ts/tsconfig.json new file mode 100644 index 00000000000000..6a9c1a2e7a02a6 --- /dev/null +++ b/examples/pigment-css-nextjs-ts/tsconfig.json @@ -0,0 +1,29 @@ +{ + "compilerOptions": { + "target": "es5", + "lib": ["dom", "dom.iterable", "esnext"], + "allowJs": true, + "skipLibCheck": true, + "strict": true, + "forceConsistentCasingInFileNames": true, + "noEmit": true, + "esModuleInterop": true, + "module": "esnext", + "moduleResolution": "node", + "resolveJsonModule": true, + "isolatedModules": true, + "jsx": "preserve", + "incremental": true, + "plugins": [ + { + "name": "next" + } + ], + "baseUrl": ".", + "paths": { + "@/*": ["./src/*"] + } + }, + "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"], + "exclude": ["node_modules"] +} diff --git a/examples/pigment-css-vite-ts/.gitignore b/examples/pigment-css-vite-ts/.gitignore new file mode 100644 index 00000000000000..a547bf36d8d11a --- /dev/null +++ b/examples/pigment-css-vite-ts/.gitignore @@ -0,0 +1,24 @@ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.vscode/* +!.vscode/extensions.json +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? diff --git a/examples/pigment-css-vite-ts/README.md b/examples/pigment-css-vite-ts/README.md new file mode 100644 index 00000000000000..ee0b8e25c330a7 --- /dev/null +++ b/examples/pigment-css-vite-ts/README.md @@ -0,0 +1,34 @@ +# Pigment CSS - Vite with TypeScript example project + +## How to use + +Download the example [or clone the repo](https://github.com/mui/material-ui): + + + +```bash +curl https://codeload.github.com/mui/material-ui/tar.gz/master | tar -xz --strip=2 material-ui-master/examples/pigment-css-vite-ts +cd pigment-css-vite-ts +``` + +Install it and run: + +```bash +npm install +npm run dev +``` + +or: + + + +[![Edit on StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/mui/material-ui/tree/master/examples/pigment-css-vite-ts) + +[![Edit on CodeSandbox](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/p/sandbox/github/mui/material-ui/tree/master/examples/pigment-css-vite-ts) + +## Learn more + +To learn more about this example: + +- [Pigment CSS documentation](https://github.com/mui/material-ui/blob/master/packages/pigment-react/README.md) - learn more about Pigment CSS features and APIs. +- [Vite documentation](https://vitejs.dev/guide/) - learn about Vite features and APIs. diff --git a/examples/pigment-css-vite-ts/index.html b/examples/pigment-css-vite-ts/index.html new file mode 100644 index 00000000000000..dac8779ebcdecb --- /dev/null +++ b/examples/pigment-css-vite-ts/index.html @@ -0,0 +1,20 @@ + + + + + + + + + + + Vite + Zero + TS + + +
+ + + diff --git a/examples/pigment-css-vite-ts/package.json b/examples/pigment-css-vite-ts/package.json new file mode 100644 index 00000000000000..8b61ac52d46cb2 --- /dev/null +++ b/examples/pigment-css-vite-ts/package.json @@ -0,0 +1,24 @@ +{ + "name": "pigment-css-vite-ts", + "private": true, + "version": "5.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@pigment-css/react": "latest", + "react": "latest", + "react-dom": "latest" + }, + "devDependencies": { + "@pigment-css/vite-plugin": "latest", + "@types/react": "latest", + "@types/react-dom": "latest", + "@vitejs/plugin-react": "latest", + "typescript": "latest", + "vite": "latest" + } +} diff --git a/examples/pigment-css-vite-ts/public/vite.svg b/examples/pigment-css-vite-ts/public/vite.svg new file mode 100644 index 00000000000000..e7b8dfb1b2a60b --- /dev/null +++ b/examples/pigment-css-vite-ts/public/vite.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/examples/pigment-css-vite-ts/src/App.tsx b/examples/pigment-css-vite-ts/src/App.tsx new file mode 100644 index 00000000000000..b3946c6bb8e9cd --- /dev/null +++ b/examples/pigment-css-vite-ts/src/App.tsx @@ -0,0 +1,202 @@ +import * as React from 'react'; +import { styled, css, keyframes } from '@pigment-css/react'; + +const scale = keyframes({ + to: { scale: 'var(--s2)' }, +}); + +const Link = styled('a', { shouldForwardProp: (prop) => prop !== 'outlined' })<{ + outlined?: boolean; +}>(({ theme }) => ({ + fontSize: '1rem', + background: 'rgba(0 0 0 / 0.04)', + padding: '0.5rem 1rem', + letterSpacing: '1px', + borderRadius: '4px', + textAlign: 'center', + ...theme.applyStyles('dark', { + background: 'rgba(255 255 255 / 0.1)', + }), + variants: [ + { + props: { outlined: true }, + style: { + background: 'transparent', + color: `hsl(${theme.vars.palette.primary})`, + border: `1px solid hsl(${theme.vars.palette.border})`, + }, + }, + ], +})); + +const Bubble = styled('span')({ + height: 'var(--size, 100%)', + aspectRatio: '1', + background: 'radial-gradient(hsl(var(--h) 100% 70%) 25%, transparent 50%)', + position: 'absolute', + display: 'inline-block', + left: 'var(--x, 0)', + top: 'var(--y, 0)', + scale: '0', + translate: '-50% -50%', + mixBlendMode: 'multiply', + filter: 'blur(2px)', + animation: `${scale} var(--s, 2s) var(--d, 0s) infinite alternate`, +}); + +function randomBetween(min: number, max: number) { + return Math.floor(Math.random() * (max - min + 1) + min); +} +function generateBubbleVars() { + return ` + --x: ${randomBetween(10, 90)}%; + --y: ${randomBetween(15, 85)}%; + --h: ${randomBetween(0, 360)}; + --s2: ${randomBetween(2, 6)}; + --d: -${randomBetween(250, 400) / 1000}s; + --s: ${randomBetween(3, 6)}s; + `; +} + +export default function Home() { + return ( +
+

({ + fontFamily: 'Kalnia, sans-serif', + fontSize: 'clamp(3rem, 1.9503rem + 4.4789vw, 6.25rem)', + fontWeight: 500, + textAlign: 'center', + position: 'relative', + display: 'flex', + alignItems: 'center', + color: '#888', + marginBottom: '1rem', + ...theme.applyStyles('dark', { color: '#fff' }), + }))}`} + > + Pigment CSS + ({ + position: 'absolute', + inset: '0', + background: 'white', + mixBlendMode: 'color-burn', + overflow: 'hidden', + pointerEvents: 'none', + ...theme.applyStyles('dark', { + mixBlendMode: 'darken', + filter: 'brightness(2)', + }), + }))} + > + + + + + + + + + + + +

+
+ CSS-JS library with static extraction +
+ +
*': { flex: 'auto' }, + })} + > + + Documentation + + + Roadmap + +
+
+ ); +} diff --git a/examples/pigment-css-vite-ts/src/augment.d.ts b/examples/pigment-css-vite-ts/src/augment.d.ts new file mode 100644 index 00000000000000..d10b46e01d4da0 --- /dev/null +++ b/examples/pigment-css-vite-ts/src/augment.d.ts @@ -0,0 +1,19 @@ +import type {} from '@pigment-css/react/theme'; +import type { ExtendTheme } from '@pigment-css/react'; + +declare module '@pigment-css/react/theme' { + export interface ThemeArgs { + theme: ExtendTheme<{ + colorScheme: 'light' | 'dark'; + tokens: { + palette: { + background: string; + foreground: string; + primary: string; + primaryForeground: string; + border: string; + }; + }; + }>; + } +} diff --git a/examples/pigment-css-vite-ts/src/globals.css b/examples/pigment-css-vite-ts/src/globals.css new file mode 100644 index 00000000000000..a1e5313f646dca --- /dev/null +++ b/examples/pigment-css-vite-ts/src/globals.css @@ -0,0 +1,16 @@ +* { + box-sizing: border-box; + padding: 0; + margin: 0; +} + +a { + color: inherit; + text-decoration: none; +} + +@media (prefers-color-scheme: dark) { + html { + color-scheme: dark; + } +} diff --git a/examples/pigment-css-vite-ts/src/main.tsx b/examples/pigment-css-vite-ts/src/main.tsx new file mode 100644 index 00000000000000..71b2cfa8aa8868 --- /dev/null +++ b/examples/pigment-css-vite-ts/src/main.tsx @@ -0,0 +1,11 @@ +import * as React from 'react'; +import * as ReactDOM from 'react-dom/client'; +import '@pigment-css/react/styles.css'; +import './globals.css'; +import App from './App'; + +ReactDOM.createRoot(document.getElementById('root')!).render( + + + , +); diff --git a/examples/pigment-css-vite-ts/src/vite-env.d.ts b/examples/pigment-css-vite-ts/src/vite-env.d.ts new file mode 100644 index 00000000000000..11f02fe2a0061d --- /dev/null +++ b/examples/pigment-css-vite-ts/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/examples/pigment-css-vite-ts/tsconfig.json b/examples/pigment-css-vite-ts/tsconfig.json new file mode 100644 index 00000000000000..3d0a51a86e2024 --- /dev/null +++ b/examples/pigment-css-vite-ts/tsconfig.json @@ -0,0 +1,21 @@ +{ + "compilerOptions": { + "target": "ESNext", + "useDefineForClassFields": true, + "lib": ["DOM", "DOM.Iterable", "ESNext"], + "allowJs": false, + "skipLibCheck": true, + "esModuleInterop": false, + "allowSyntheticDefaultImports": true, + "strict": true, + "forceConsistentCasingInFileNames": true, + "module": "ESNext", + "moduleResolution": "Node", + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "react-jsx" + }, + "include": ["src"], + "references": [{ "path": "./tsconfig.node.json" }] +} diff --git a/examples/pigment-css-vite-ts/tsconfig.node.json b/examples/pigment-css-vite-ts/tsconfig.node.json new file mode 100644 index 00000000000000..9d31e2aed93c87 --- /dev/null +++ b/examples/pigment-css-vite-ts/tsconfig.node.json @@ -0,0 +1,9 @@ +{ + "compilerOptions": { + "composite": true, + "module": "ESNext", + "moduleResolution": "Node", + "allowSyntheticDefaultImports": true + }, + "include": ["vite.config.ts"] +} diff --git a/examples/pigment-css-vite-ts/vite.config.ts b/examples/pigment-css-vite-ts/vite.config.ts new file mode 100644 index 00000000000000..1a6ee2cd2f8942 --- /dev/null +++ b/examples/pigment-css-vite-ts/vite.config.ts @@ -0,0 +1,35 @@ +import { defineConfig } from 'vite'; +import react from '@vitejs/plugin-react'; +import { pigment, extendTheme } from '@pigment-css/vite-plugin'; + +// To learn more about theming, visit https://github.com/mui/material-ui/blob/master/packages/zero-runtime/README.md#theming +const theme = extendTheme({ + colorSchemes: { + light: { + palette: { + background: '0 0% 100%', + foreground: '240 10% 3.9%', + primary: '240 5.9% 10%', + border: '240 5.9% 90%', + }, + }, + dark: { + palette: { + background: '240 10% 3.9%', + foreground: '0 0% 80%', + primary: '0 0% 98%', + border: '240 3.7% 15.9%', + }, + }, + }, +}); + +// https://vitejs.dev/config/ +export default defineConfig({ + plugins: [ + pigment({ + theme, + }), + react(), + ], +}); diff --git a/package.json b/package.json index 5bf7ea00537ae6..a8bf59a37a6a95 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mui/monorepo", - "version": "5.15.11", + "version": "5.15.12", "private": true, "scripts": { "preinstall": "npx only-allow pnpm", @@ -54,7 +54,7 @@ "test": "node scripts/test.mjs", "tc": "node test/cli.js", "test:extended": "pnpm eslint && pnpm typescript && pnpm test:coverage", - "test:pigment-react:ci": "pnpm nx run @pigmentcss/react:test:ci", + "test:pigment-react:ci": "pnpm nx run @pigment-css/react:test:ci", "test:coverage": "cross-env NODE_ENV=test BABEL_ENV=coverage nyc --reporter=text mocha 'packages/**/*.test.{js,ts,tsx}' 'docs/**/*.test.{js,ts,tsx}' --exclude 'packages/pigment-react/**/*.test.{js,ts,tsx}' && pnpm test:pigment-react", "test:coverage:ci": "cross-env NODE_ENV=test BABEL_ENV=coverage nyc --reporter=lcov mocha 'packages/**/*.test.{js,ts,tsx}' 'docs/**/*.test.{js,ts,tsx}' --exclude 'packages/pigment-react/**/*.test.{js,ts,tsx}' && pnpm test:pigment-react:ci", "test:coverage:html": "cross-env NODE_ENV=test BABEL_ENV=coverage nyc --reporter=html mocha 'packages/**/*.test.{js,ts,tsx}' 'docs/**/*.test.{js,ts,tsx}'", @@ -76,7 +76,7 @@ "test:unit": "cross-env NODE_ENV=test mocha 'packages/**/*.test.{js,ts,tsx}' 'docs/**/*.test.{js,ts,tsx}'", "test:argos": "node ./scripts/pushArgos.mjs", "typescript": "lerna run --no-bail --parallel typescript", - "typescript:ci": "lerna run --concurrency 5 --no-bail --no-sort typescript", + "typescript:ci": "lerna run --concurrency 3 --no-bail --no-sort typescript", "validate-declarations": "tsx scripts/validateTypescriptDeclarations.mts", "generate-codeowners": "node scripts/generateCodeowners.mjs", "watch:zero": "nx run-many -t watch --projects=\"@pigmentcss/*\" --parallel" @@ -112,14 +112,15 @@ "@mui/joy": "workspace:*", "@mui/material": "workspace:^", "@mui/utils": "workspace:^", - "@next/eslint-plugin-next": "^14.1.0", + "@pigment-css/react": "workspace:^", + "@next/eslint-plugin-next": "^14.1.1", "@octokit/rest": "^20.0.2", - "@playwright/test": "1.41.2", + "@playwright/test": "1.42.1", "@types/enzyme": "^3.10.18", "@types/fs-extra": "^11.0.4", "@types/lodash": "^4.14.202", "@types/mocha": "^10.0.6", - "@types/node": "^18.19.19", + "@types/node": "^18.19.21", "@types/prettier": "^2.7.3", "@types/react": "^18.2.55", "@types/yargs": "^17.0.32", @@ -150,13 +151,13 @@ "eslint-plugin-import": "^2.29.1", "eslint-plugin-jsx-a11y": "^6.7.1", "eslint-plugin-material-ui": "workspace:^", - "eslint-plugin-mocha": "^10.2.0", + "eslint-plugin-mocha": "^10.3.0", "eslint-plugin-react": "^7.33.2", "eslint-plugin-react-hooks": "^4.6.0", "fast-glob": "^3.3.2", "fs-extra": "^11.2.0", "globby": "^14.0.1", - "karma": "^6.4.2", + "karma": "^6.4.3", "karma-browserstack-launcher": "~1.6.0", "karma-chrome-launcher": "^3.2.0", "karma-coverage-istanbul-reporter": "^3.0.3", @@ -190,7 +191,7 @@ "webpack-cli": "^5.1.4", "yargs": "^17.7.2" }, - "packageManager": "pnpm@8.15.1", + "packageManager": "pnpm@8.15.4", "resolutions": { "@babel/core": "^7.23.9", "@babel/code-frame": "^7.23.5", @@ -209,7 +210,7 @@ "@definitelytyped/header-parser": "^0.2.6", "@definitelytyped/typescript-versions": "^0.1.0", "@definitelytyped/utils": "^0.1.5", - "@types/node": "^18.19.19", + "@types/node": "^18.19.21", "@types/react": "^18.2.55", "@types/react-dom": "18.2.19", "cross-fetch": "^4.0.0" diff --git a/packages-internal/scripts/package.json b/packages-internal/scripts/package.json index ae0511400a442b..dfdea9913a2cfe 100644 --- a/packages-internal/scripts/package.json +++ b/packages-internal/scripts/package.json @@ -42,7 +42,7 @@ "@types/chai": "^4.3.12", "@types/doctrine": "^0.0.9", "@types/lodash": "^4.14.202", - "@types/node": "^18.19.19", + "@types/node": "^18.19.21", "@types/prettier": "^2.7.3", "@types/react": "^18.2.55", "@types/uuid": "^9.0.8", diff --git a/packages/api-docs-builder-core/package.json b/packages/api-docs-builder-core/package.json index ff5a1e44eaea67..76d3feff4753e1 100644 --- a/packages/api-docs-builder-core/package.json +++ b/packages/api-docs-builder-core/package.json @@ -17,7 +17,7 @@ "devDependencies": { "@types/chai": "^4.3.12", "@types/mocha": "^10.0.6", - "@types/node": "^18.19.19", + "@types/node": "^18.19.21", "@types/sinon": "^10.0.20", "chai": "^4.4.1", "sinon": "^15.2.0", diff --git a/packages/api-docs-builder/package.json b/packages/api-docs-builder/package.json index 29df3d90e55c9b..6ed2ac331eccfe 100644 --- a/packages/api-docs-builder/package.json +++ b/packages/api-docs-builder/package.json @@ -20,7 +20,7 @@ "lodash": "^4.17.21", "prettier": "^3.2.5", "react-docgen": "^5.4.3", - "recast": "^0.23.4", + "recast": "^0.23.5", "remark": "^13.0.0", "typescript": "^5.3.3", "unist-util-visit": "^2.0.3" @@ -32,7 +32,7 @@ "@types/doctrine": "^0.0.9", "@types/mdast": "4.0.3", "@types/mocha": "^10.0.6", - "@types/node": "^18.19.19", + "@types/node": "^18.19.21", "@types/react-docgen": "workspace:*", "@types/sinon": "^10.0.20", "chai": "^4.4.1", diff --git a/packages/mui-babel-macros/package.json b/packages/mui-babel-macros/package.json index 4bee1ed2ba3585..1f579c02d1e4e6 100644 --- a/packages/mui-babel-macros/package.json +++ b/packages/mui-babel-macros/package.json @@ -32,7 +32,7 @@ "@types/babel-plugin-macros": "^3.1.3", "@types/chai": "^4.3.12", "@types/mocha": "^10.0.6", - "@types/node": "^18.19.19", + "@types/node": "^18.19.21", "babel-plugin-tester": "^11.0.4", "chai": "^4.4.1" }, diff --git a/packages/mui-base/package.json b/packages/mui-base/package.json index 1ac0292ef2e3cf..b7e86fdb4d5a82 100644 --- a/packages/mui-base/package.json +++ b/packages/mui-base/package.json @@ -1,6 +1,6 @@ { "name": "@mui/base", - "version": "5.0.0-beta.37", + "version": "5.0.0-beta.38", "private": false, "author": "MUI Team", "description": "Base UI is a library of headless ('unstyled') React components and low-level hooks. You gain complete control over your app's CSS and accessibility features.", @@ -50,8 +50,8 @@ "prop-types": "^15.8.1" }, "devDependencies": { - "@mui/internal-babel-macros": "workspace:^", "@mui-internal/test-utils": "workspace:^", + "@mui/internal-babel-macros": "workspace:^", "@mui/types": "workspace:^", "@testing-library/react": "^14.2.1", "@testing-library/user-event": "^14.5.2", diff --git a/packages/mui-base/src/FormControl/index.ts b/packages/mui-base/src/FormControl/index.ts index 8119bbdd4284bd..b722fbadccdc13 100644 --- a/packages/mui-base/src/FormControl/index.ts +++ b/packages/mui-base/src/FormControl/index.ts @@ -2,13 +2,7 @@ export { FormControl } from './FormControl'; export { FormControlContext } from './FormControlContext'; -export type { - FormControlProps, - FormControlRootSlotPropsOverrides, - FormControlState, - UseFormControlContextReturnValue, - FormControlOwnProps, -} from './FormControl.types'; +export * from './FormControl.types'; export * from './formControlClasses'; diff --git a/packages/mui-base/src/useAutocomplete/useAutocomplete.test.js b/packages/mui-base/src/useAutocomplete/useAutocomplete.test.js index 0386731e59eeb8..264f0ee8f67ce2 100644 --- a/packages/mui-base/src/useAutocomplete/useAutocomplete.test.js +++ b/packages/mui-base/src/useAutocomplete/useAutocomplete.test.js @@ -118,6 +118,7 @@ describe('useAutocomplete', () => { let filterOptions; let getOptionLabel; let options; + beforeEach(() => { filterOptions = createFilterOptions({ matchFrom: 'any' }); getOptionLabel = (option) => option.name; diff --git a/packages/mui-base/src/useInput/useInput.test.tsx b/packages/mui-base/src/useInput/useInput.test.tsx index a2ff388030c95a..9ece7ed65a20ad 100644 --- a/packages/mui-base/src/useInput/useInput.test.tsx +++ b/packages/mui-base/src/useInput/useInput.test.tsx @@ -7,6 +7,7 @@ import { UseInputParameters } from './useInput.types'; describe('useInput', () => { const { render } = createRenderer(); + describe('params: inputRef', () => { it('should be able to attach input ref passed through params', () => { const inputRef = React.createRef(); diff --git a/packages/mui-base/src/useList/listReducer.test.ts b/packages/mui-base/src/useList/listReducer.test.ts index 873be0f0f7430e..1a60ac1f74c42f 100644 --- a/packages/mui-base/src/useList/listReducer.test.ts +++ b/packages/mui-base/src/useList/listReducer.test.ts @@ -948,6 +948,7 @@ describe('listReducer', () => { describe('using custom item comparer', () => { type ItemType = { v: string }; + it('keeps the highlighted value if it is present among the new items', () => { const state: ListState = { highlightedValue: { v: '1' }, diff --git a/packages/mui-base/src/useList/useList.test.tsx b/packages/mui-base/src/useList/useList.test.tsx index 7e8ffa6f1ce2fb..1c225a474917bb 100644 --- a/packages/mui-base/src/useList/useList.test.tsx +++ b/packages/mui-base/src/useList/useList.test.tsx @@ -6,6 +6,7 @@ import { useList } from './useList'; describe('useList', () => { const { render } = createRenderer(); + describe('preventing default behavior on keyDown', () => { ['ArrowUp', 'ArrowDown', 'Home', 'End', 'PageUp', 'PageDown', 'Enter', ' '].forEach((key) => it(`prevents default behavior when ${key} is pressed in activeDescendant focus management mode`, () => { diff --git a/packages/mui-base/src/useMenu/useMenu.test.js b/packages/mui-base/src/useMenu/useMenu.test.js index d3973de7d06f3f..bca1913869d9a2 100644 --- a/packages/mui-base/src/useMenu/useMenu.test.js +++ b/packages/mui-base/src/useMenu/useMenu.test.js @@ -7,6 +7,7 @@ import { useMenu } from './useMenu'; describe('useMenu', () => { const { render } = createRenderer(); + describe('getListboxProps', () => { it('returns props for root slot', () => { function TestMenu() { diff --git a/packages/mui-base/src/useMenuButton/useMenuButton.test.tsx b/packages/mui-base/src/useMenuButton/useMenuButton.test.tsx index 9bf81af45f0a93..b58885e739495c 100644 --- a/packages/mui-base/src/useMenuButton/useMenuButton.test.tsx +++ b/packages/mui-base/src/useMenuButton/useMenuButton.test.tsx @@ -16,6 +16,7 @@ const testContext: DropdownContextValue = { describe('useMenuButton', () => { const { render } = createRenderer(); + describe('getRootProps', () => { it('returns props for root slot', () => { function TestMenuButton() { diff --git a/packages/mui-base/src/useMenuItem/useMenuItem.test.tsx b/packages/mui-base/src/useMenuItem/useMenuItem.test.tsx index a599bfb52ae110..81b8e9435b303e 100644 --- a/packages/mui-base/src/useMenuItem/useMenuItem.test.tsx +++ b/packages/mui-base/src/useMenuItem/useMenuItem.test.tsx @@ -7,6 +7,7 @@ import { useMenuItem } from './useMenuItem'; describe('useMenuItem', () => { const { render } = createRenderer(); + describe('getRootProps', () => { it('returns props for root slot', () => { function TestMenuItem() { diff --git a/packages/mui-base/src/useSlider/useSlider.test.js b/packages/mui-base/src/useSlider/useSlider.test.js index b717f0e934b57e..c7b964335e184e 100644 --- a/packages/mui-base/src/useSlider/useSlider.test.js +++ b/packages/mui-base/src/useSlider/useSlider.test.js @@ -6,6 +6,7 @@ import { useSlider } from './useSlider'; describe('useSlider', () => { const { render } = createRenderer(); + describe('getRootProps', () => { it('forwards external props including event handlers', () => { const rootRef = React.createRef(); diff --git a/packages/mui-base/src/useTab/useTab.test.tsx b/packages/mui-base/src/useTab/useTab.test.tsx index c20252849006af..047c739c137628 100644 --- a/packages/mui-base/src/useTab/useTab.test.tsx +++ b/packages/mui-base/src/useTab/useTab.test.tsx @@ -8,6 +8,7 @@ import { useTab } from './useTab'; describe('useTab', () => { const { render } = createRenderer(); + describe('getRootProps', () => { it('returns props for root slot', () => { function TestTab() { diff --git a/packages/mui-base/src/useTabPanel/useTabPanel.test.js b/packages/mui-base/src/useTabPanel/useTabPanel.test.js index e94b8bd283bbb9..c516c2ce9b860d 100644 --- a/packages/mui-base/src/useTabPanel/useTabPanel.test.js +++ b/packages/mui-base/src/useTabPanel/useTabPanel.test.js @@ -9,6 +9,7 @@ import { useTabPanel } from './useTabPanel'; describe('useTabPanel', () => { const { render } = createRenderer(); + describe('getRootProps', () => { it('returns props for root slot', () => { const rootRef = React.createRef(); diff --git a/packages/mui-base/src/useTabsList/useTabsList.test.tsx b/packages/mui-base/src/useTabsList/useTabsList.test.tsx index dc9d4630aff8cc..02fe3b020c6b1b 100644 --- a/packages/mui-base/src/useTabsList/useTabsList.test.tsx +++ b/packages/mui-base/src/useTabsList/useTabsList.test.tsx @@ -7,6 +7,7 @@ import { useTabsList } from './useTabsList'; describe('useTabsList', () => { const { render } = createRenderer(); + describe('getRootProps', () => { it('returns props for root slot', () => { function TestTabsList() { diff --git a/packages/mui-base/src/utils/prepareForSlot.test.tsx b/packages/mui-base/src/utils/prepareForSlot.test.tsx index 7b26144b2e6e79..fd6e36368502bc 100644 --- a/packages/mui-base/src/utils/prepareForSlot.test.tsx +++ b/packages/mui-base/src/utils/prepareForSlot.test.tsx @@ -6,6 +6,7 @@ import { prepareForSlot } from './prepareForSlot'; describe('prepareForSlot', () => { const { render } = createRenderer(); + it('should not warn about ownerState', () => { const ThirdPartyComponent = React.forwardRef((props, ref) => { // @ts-ignore just double checking that it is not defined diff --git a/packages/mui-codemod/package.json b/packages/mui-codemod/package.json index 79d4b32ab03e09..1bbfcdfc94ac7d 100644 --- a/packages/mui-codemod/package.json +++ b/packages/mui-codemod/package.json @@ -1,6 +1,6 @@ { "name": "@mui/codemod", - "version": "5.15.11", + "version": "5.15.12", "bin": "./codemod.js", "private": false, "author": "MUI Team", diff --git a/packages/mui-codemod/src/deprecations/alert-props/alert-props.test.js b/packages/mui-codemod/src/deprecations/alert-props/alert-props.test.js index d9741ce1a1e13c..761af47c09f51d 100644 --- a/packages/mui-codemod/src/deprecations/alert-props/alert-props.test.js +++ b/packages/mui-codemod/src/deprecations/alert-props/alert-props.test.js @@ -31,7 +31,7 @@ describe('@mui/codemod', () => { const actual = transform( { source: read('./test-cases/theme.actual.js') }, { jscodeshift }, - { printOptions: { trailingComma: true } }, + { printOptions: { trailingComma: false } }, ); const expected = read('./test-cases/theme.expected.js'); diff --git a/packages/mui-codemod/src/deprecations/alert-props/test-cases/actual.js b/packages/mui-codemod/src/deprecations/alert-props/test-cases/actual.js index 380a640bce04fc..fd952d3fa91fcf 100644 --- a/packages/mui-codemod/src/deprecations/alert-props/test-cases/actual.js +++ b/packages/mui-codemod/src/deprecations/alert-props/test-cases/actual.js @@ -16,3 +16,9 @@ import Alert from '@mui/material/Alert'; slotProps={{ closeIcon: slotsIconProps, closeButton: slotsButtonProps }} componentsProps={{ closeButton: componentsButtonProps }} />; +; diff --git a/packages/mui-codemod/src/deprecations/alert-props/test-cases/expected.js b/packages/mui-codemod/src/deprecations/alert-props/test-cases/expected.js index 1c1a02c7b7e601..0b05305960385b 100644 --- a/packages/mui-codemod/src/deprecations/alert-props/test-cases/expected.js +++ b/packages/mui-codemod/src/deprecations/alert-props/test-cases/expected.js @@ -17,4 +17,16 @@ import Alert from '@mui/material/Alert'; }} />; ; + slotProps={{ closeIcon: slotsIconProps, closeButton: { + ...componentsButtonProps, + ...slotsButtonProps + } }} />; +; diff --git a/packages/mui-codemod/src/deprecations/alert-props/test-cases/theme.actual.js b/packages/mui-codemod/src/deprecations/alert-props/test-cases/theme.actual.js index 53747aee31ea17..10591ba1dfb8b1 100644 --- a/packages/mui-codemod/src/deprecations/alert-props/test-cases/theme.actual.js +++ b/packages/mui-codemod/src/deprecations/alert-props/test-cases/theme.actual.js @@ -28,3 +28,14 @@ fn({ }, }, }); + +fn({ + MuiAlert: { + defaultProps: { + components: { CloseButton: ComponentsButton }, + slots: { closeIcon: SlotsIcon, closeButton: SlotsButton }, + componentsProps: { closeButton: componentsButtonProps, closeIcon: componentsIconProps }, + slotProps: { closeIcon: slotsIconProps, closeButton: slotsButtonProps }, + }, + }, +}); diff --git a/packages/mui-codemod/src/deprecations/alert-props/test-cases/theme.expected.js b/packages/mui-codemod/src/deprecations/alert-props/test-cases/theme.expected.js index dfab24532bd162..c3f2cb05133264 100644 --- a/packages/mui-codemod/src/deprecations/alert-props/test-cases/theme.expected.js +++ b/packages/mui-codemod/src/deprecations/alert-props/test-cases/theme.expected.js @@ -2,12 +2,12 @@ fn({ MuiAlert: { defaultProps: { slots: { - closeButton: ComponentsButton, + closeButton: ComponentsButton }, slotProps: { - closeButton: componentsButtonProps, - }, + closeButton: componentsButtonProps + } }, }, }); @@ -17,13 +17,13 @@ fn({ defaultProps: { slots: { closeButton: ComponentsButton, - closeIcon: SlotsIcon, + closeIcon: SlotsIcon }, slotProps: { closeButton: componentsButtonProps, - closeIcon: slotsIconProps, - }, + closeIcon: slotsIconProps + } }, }, }); @@ -33,13 +33,40 @@ fn({ defaultProps: { slots: { closeButton: SlotsButton, - closeIcon: SlotsIcon, + closeIcon: SlotsIcon }, slotProps: { - closeButton: slotsButtonProps, - closeIcon: slotsIconProps, + closeButton: { + ...componentsButtonProps, + ...slotsButtonProps + }, + + closeIcon: slotsIconProps + } + }, + }, +}); + +fn({ + MuiAlert: { + defaultProps: { + slots: { + closeButton: SlotsButton, + closeIcon: SlotsIcon }, + + slotProps: { + closeButton: { + ...componentsButtonProps, + ...slotsButtonProps + }, + + closeIcon: { + ...componentsIconProps, + ...slotsIconProps + } + } }, }, }); diff --git a/packages/mui-codemod/src/deprecations/slider-props/slider-props.test.js b/packages/mui-codemod/src/deprecations/slider-props/slider-props.test.js index b6d5682eb2a76a..033acf231969bd 100644 --- a/packages/mui-codemod/src/deprecations/slider-props/slider-props.test.js +++ b/packages/mui-codemod/src/deprecations/slider-props/slider-props.test.js @@ -31,7 +31,7 @@ describe('@mui/codemod', () => { const actual = transform( { source: read('./test-cases/theme.actual.js') }, { jscodeshift }, - { printOptions: { trailingComma: true } }, + { printOptions: { trailingComma: false } }, ); const expected = read('./test-cases/theme.expected.js'); diff --git a/packages/mui-codemod/src/deprecations/slider-props/test-cases/actual.js b/packages/mui-codemod/src/deprecations/slider-props/test-cases/actual.js index c73ad39187900b..1ac48c7504c528 100644 --- a/packages/mui-codemod/src/deprecations/slider-props/test-cases/actual.js +++ b/packages/mui-codemod/src/deprecations/slider-props/test-cases/actual.js @@ -16,3 +16,9 @@ import Slider from '@mui/material/Slider'; slotProps={{ rail: slotsRailProps, track: slotsTrackProps }} componentsProps={{ track: componentsTrackProps }} />; +; diff --git a/packages/mui-codemod/src/deprecations/slider-props/test-cases/expected.js b/packages/mui-codemod/src/deprecations/slider-props/test-cases/expected.js index c1809d70cfa6eb..20037c1639358c 100644 --- a/packages/mui-codemod/src/deprecations/slider-props/test-cases/expected.js +++ b/packages/mui-codemod/src/deprecations/slider-props/test-cases/expected.js @@ -17,4 +17,16 @@ import Slider from '@mui/material/Slider'; }} />; ; + slotProps={{ rail: slotsRailProps, track: { + ...componentsTrackProps, + ...slotsTrackProps + } }} />; +; diff --git a/packages/mui-codemod/src/deprecations/slider-props/test-cases/theme.actual.js b/packages/mui-codemod/src/deprecations/slider-props/test-cases/theme.actual.js index 5b68897f2ddc97..90df34bdd843f5 100644 --- a/packages/mui-codemod/src/deprecations/slider-props/test-cases/theme.actual.js +++ b/packages/mui-codemod/src/deprecations/slider-props/test-cases/theme.actual.js @@ -28,3 +28,14 @@ fn({ }, }, }); + +fn({ + MuiSlider: { + defaultProps: { + components: { Track: ComponentsTrack }, + slots: { rail: SlotsRail, track: SlotsTrack }, + componentsProps: { track: componentsTrackProps, rail: componentsRailProps }, + slotProps: { rail: slotsRailProps, track: slotsTrackProps }, + }, + }, +}); diff --git a/packages/mui-codemod/src/deprecations/slider-props/test-cases/theme.expected.js b/packages/mui-codemod/src/deprecations/slider-props/test-cases/theme.expected.js index 74c5dab30c7553..0ef10d93f7a880 100644 --- a/packages/mui-codemod/src/deprecations/slider-props/test-cases/theme.expected.js +++ b/packages/mui-codemod/src/deprecations/slider-props/test-cases/theme.expected.js @@ -2,12 +2,12 @@ fn({ MuiSlider: { defaultProps: { slots: { - track: ComponentsTrack, + track: ComponentsTrack }, slotProps: { - track: componentsTrackProps, - }, + track: componentsTrackProps + } }, }, }); @@ -17,13 +17,13 @@ fn({ defaultProps: { slots: { track: ComponentsTrack, - rail: SlotsRail, + rail: SlotsRail }, slotProps: { track: componentsTrackProps, - rail: slotsRailProps, - }, + rail: slotsRailProps + } }, }, }); @@ -33,13 +33,40 @@ fn({ defaultProps: { slots: { track: SlotsTrack, - rail: SlotsRail, + rail: SlotsRail }, slotProps: { - track: slotsTrackProps, - rail: slotsRailProps, + track: { + ...componentsTrackProps, + ...slotsTrackProps + }, + + rail: slotsRailProps + } + }, + }, +}); + +fn({ + MuiSlider: { + defaultProps: { + slots: { + track: SlotsTrack, + rail: SlotsRail }, + + slotProps: { + track: { + ...componentsTrackProps, + ...slotsTrackProps + }, + + rail: { + ...componentsRailProps, + ...slotsRailProps + } + } }, }, }); diff --git a/packages/mui-codemod/src/deprecations/utils/replaceComponentsWithSlots.js b/packages/mui-codemod/src/deprecations/utils/replaceComponentsWithSlots.js index fb1ee1d87edad4..eaac90c45e6b4c 100644 --- a/packages/mui-codemod/src/deprecations/utils/replaceComponentsWithSlots.js +++ b/packages/mui-codemod/src/deprecations/utils/replaceComponentsWithSlots.js @@ -69,6 +69,19 @@ function replaceJsxComponentsPropsProp(j, element) { key: prop.key.name, expression: prop.value, }); + } else { + attr.value.expression.properties = attr.value.expression.properties.filter( + (p) => p?.key?.name !== prop.key.name, + ); + + assignObject(j, { + target: attr, + key: prop.key.name, + expression: j.objectExpression([ + j.spreadElement(prop.value), + j.spreadElement(slotProps[prop.key.name]), + ]), + }); } }); } @@ -131,7 +144,15 @@ function replaceDefaultPropsComponentsPropsProp(j, defaultPropsPathCollection) { const slots = existingSlots ? existingSlots.value.properties.reduce((acc, prop) => { - return { ...acc, [prop.key.name]: prop.value }; + return { + ...acc, + [prop.key.name]: components[prop.key.name] + ? j.objectExpression([ + j.spreadElement(components[prop.key.name]), + j.spreadElement(prop.value), + ]) + : prop.value, + }; }, {}) : {}; diff --git a/packages/mui-codemod/src/v5.0.0/jss-to-styled.test.js b/packages/mui-codemod/src/v5.0.0/jss-to-styled.test.js index 932ff64687c877..2cbbd5fac8c9ba 100644 --- a/packages/mui-codemod/src/v5.0.0/jss-to-styled.test.js +++ b/packages/mui-codemod/src/v5.0.0/jss-to-styled.test.js @@ -24,6 +24,7 @@ describe('@mui/codemod', () => { const expected = read('./jss-to-styled.test/Anonymous.expected.js'); expect(actual).to.equal(expected, 'The transformed version should be correct'); }); + describe('first', () => { it('transforms as needed', () => { const actual = transform( @@ -534,6 +535,7 @@ describe('@mui/codemod', () => { expect(actual).to.equal(expected, 'The transformed version should be correct'); }); }); + describe('bugs - #28317 export class declaration', () => { it('transforms as needed', () => { const actual = transform( diff --git a/packages/mui-codemod/src/v5.0.0/jss-to-tss-react.test.js b/packages/mui-codemod/src/v5.0.0/jss-to-tss-react.test.js index 12a4ce281419fd..b0c6848a4b5fae 100644 --- a/packages/mui-codemod/src/v5.0.0/jss-to-tss-react.test.js +++ b/packages/mui-codemod/src/v5.0.0/jss-to-tss-react.test.js @@ -25,6 +25,7 @@ describe('@mui/codemod', () => { const expected = read('./jss-to-tss-react.test/expected-from-material-ui-core-styles.js'); expect(actual).to.equal(expected, 'The transformed version should be correct'); }); + it('should be idempotent', () => { const actual = transform( { @@ -40,6 +41,7 @@ describe('@mui/codemod', () => { const expected = read('./jss-to-tss-react.test/expected-from-material-ui-core-styles.js'); expect(actual).to.equal(expected, 'The transformed version should be correct'); }); + it('transforms @material-ui/core makeStyles to use tss-react', () => { const actual = transform( { @@ -53,6 +55,7 @@ describe('@mui/codemod', () => { const expected = read('./jss-to-tss-react.test/expected-from-material-ui-core.js'); expect(actual).to.equal(expected, 'The transformed version should be correct'); }); + it('adds todo comments for scenarios that are not supported', () => { const actual = transform( { @@ -66,6 +69,7 @@ describe('@mui/codemod', () => { const expected = read('./jss-to-tss-react.test/expected-todo-comments.js'); expect(actual).to.equal(expected, 'The transformed version should be correct'); }); + it('transforms makeStyles with style rules returned by function to use tss-react', () => { const actual = transform( { @@ -79,6 +83,7 @@ describe('@mui/codemod', () => { const expected = read('./jss-to-tss-react.test/expected-mixins-pattern.js'); expect(actual).to.equal(expected, 'The transformed version should be correct'); }); + it('transforms @mui/styles makeStyles to use tss-react', () => { const actual = transform( { @@ -92,6 +97,7 @@ describe('@mui/codemod', () => { const expected = read('./jss-to-tss-react.test/expected-from-mui-styles.js'); expect(actual).to.equal(expected, 'The transformed version should be correct'); }); + it('transforms @mui/styles/makeStyles to use tss-react', () => { const actual = transform( { @@ -105,6 +111,7 @@ describe('@mui/codemod', () => { const expected = read('./jss-to-tss-react.test/expected-from-mui-styles-makeStyles.js'); expect(actual).to.equal(expected, 'The transformed version should be correct'); }); + it('transforms typescript makeStyles with nested selectors to use tss-react', () => { const actual = transform( { @@ -118,6 +125,7 @@ describe('@mui/codemod', () => { const expected = read('./jss-to-tss-react.test/expected-typescript.tsx'); expect(actual).to.equal(expected, 'The transformed version should be correct'); }); + it('transforms typescript makeStyles example in docs to use tss-react', () => { const actual = transform( { @@ -131,6 +139,7 @@ describe('@mui/codemod', () => { const expected = read('./jss-to-tss-react.test/expected-typescript-docs-example.tsx'); expect(actual).to.equal(expected, 'The transformed version should be correct'); }); + it('transforms typescript makeStyles advanced example in docs with params to use tss-react', () => { const actual = transform( { @@ -148,6 +157,7 @@ describe('@mui/codemod', () => { ); expect(actual).to.equal(expected, 'The transformed version should be correct'); }); + it('transforms withStyles to use tss-react', () => { const actual = transform( { diff --git a/packages/mui-core-downloads-tracker/package.json b/packages/mui-core-downloads-tracker/package.json index fea026d1e65021..9d778304278211 100644 --- a/packages/mui-core-downloads-tracker/package.json +++ b/packages/mui-core-downloads-tracker/package.json @@ -1,6 +1,6 @@ { "name": "@mui/core-downloads-tracker", - "version": "5.15.11", + "version": "5.15.12", "private": false, "author": "MUI Team", "description": "Internal package to track number of downloads of our design system libraries", diff --git a/packages/mui-docs/package.json b/packages/mui-docs/package.json index 95eb8b24d496ef..cf0c7855e2caae 100644 --- a/packages/mui-docs/package.json +++ b/packages/mui-docs/package.json @@ -1,6 +1,6 @@ { "name": "@mui/docs", - "version": "5.15.11", + "version": "5.15.12", "private": false, "author": "MUI Team", "description": "MUI Docs - Documentation building blocks.", @@ -43,7 +43,7 @@ "prop-types": "^15.8.1" }, "devDependencies": { - "@types/node": "^18.19.19", + "@types/node": "^18.19.21", "@types/prop-types": "^15.7.11", "@types/react": "^18.2.55", "next": "^13.5.1", diff --git a/packages/mui-docs/src/translations/translations.json b/packages/mui-docs/src/translations/translations.json index 9b2462e0101c0f..8cdbb47cc9b8f0 100644 --- a/packages/mui-docs/src/translations/translations.json +++ b/packages/mui-docs/src/translations/translations.json @@ -15,7 +15,7 @@ "defaultComponent": "Default component", "defaultValue": "Default value", "defaultHTMLTag": "Default HTML tag", - "demos": "Component demos", + "demos": "Demos", "deprecated": "Deprecated", "description": "Description", "globalClass": "Global class", diff --git a/packages/mui-envinfo/test/package.json b/packages/mui-envinfo/test/package.json index e8ab131ef63a30..e63819d86b731c 100644 --- a/packages/mui-envinfo/test/package.json +++ b/packages/mui-envinfo/test/package.json @@ -3,7 +3,7 @@ "version": "1.0.0", "private": true, "dependencies": { - "@emotion/react": "^11.11.3", + "@emotion/react": "^11.11.4", "@emotion/styled": "^11.11.0", "@mui/base": "5.0.0-beta.30", "@mui/joy": "5.0.0-beta.22", diff --git a/packages/mui-icons-material/package.json b/packages/mui-icons-material/package.json index e9a0e6c4ad2e6d..7adc8f786fe252 100644 --- a/packages/mui-icons-material/package.json +++ b/packages/mui-icons-material/package.json @@ -1,6 +1,6 @@ { "name": "@mui/icons-material", - "version": "5.15.11", + "version": "5.15.12", "private": false, "author": "MUI Team", "description": "Material Design icons distributed as SVG React components.", diff --git a/packages/mui-icons-material/src/icon.d.ts b/packages/mui-icons-material/src/icon.d.ts new file mode 100644 index 00000000000000..72c99eef1a4c82 --- /dev/null +++ b/packages/mui-icons-material/src/icon.d.ts @@ -0,0 +1 @@ +export { default } from '@mui/material/SvgIcon'; diff --git a/packages/mui-icons-material/test/generated-types/tsconfig.json b/packages/mui-icons-material/test/generated-types/tsconfig.json index 112f552f4dfee6..1099b243812bac 100644 --- a/packages/mui-icons-material/test/generated-types/tsconfig.json +++ b/packages/mui-icons-material/test/generated-types/tsconfig.json @@ -42,12 +42,12 @@ "@mui/types": ["./mui-types"], "@mui/utils": ["./mui-utils/src"], "@mui/utils/*": ["./mui-utils/src/*"], - "@pigmentcss/nextjs-plugin": ["./pigment-nextjs-plugin/src"], - "@pigmentcss/nextjs-plugin/*": ["./pigment-nextjs-plugin/src/*"], - "@pigmentcss/react": ["./pigment-react/src"], - "@pigmentcss/react/*": ["./pigment-react/src/*"], - "@pigmentcss/vite-plugin": ["./pigment-vite-plugin/src"], - "@pigmentcss/vite-plugin/*": ["./pigment-vite-plugin/src/*"], + "@pigment-css/nextjs-plugin": ["./pigment-nextjs-plugin/src"], + "@pigment-css/nextjs-plugin/*": ["./pigment-nextjs-plugin/src/*"], + "@pigment-css/react": ["./pigment-react/src"], + "@pigment-css/react/*": ["./pigment-react/src/*"], + "@pigment-css/vite-plugin": ["./pigment-vite-plugin/src"], + "@pigment-css/vite-plugin/*": ["./pigment-vite-plugin/src/*"], "@mui/internal-scripts/typescript-to-proptypes": [ "../packages-internal/scripts/typescript-to-proptypes/src" ] diff --git a/packages/mui-icons-material/tsconfig.json b/packages/mui-icons-material/tsconfig.json index f762d7e08aeb2f..73a65ef2ef6e56 100644 --- a/packages/mui-icons-material/tsconfig.json +++ b/packages/mui-icons-material/tsconfig.json @@ -1,10 +1,5 @@ { "extends": "../../tsconfig.json", - "compilerOptions": { - "paths": { - "@mui/material": ["../mui-material/src"], - "@mui/material/*": ["../mui-material/src/*"] - } - }, + "compilerOptions": {}, "include": ["src/**/*"] } diff --git a/packages/mui-joy/package.json b/packages/mui-joy/package.json index 84e099c633a97d..170fb702806512 100644 --- a/packages/mui-joy/package.json +++ b/packages/mui-joy/package.json @@ -1,6 +1,6 @@ { "name": "@mui/joy", - "version": "5.0.0-beta.29", + "version": "5.0.0-beta.30", "private": false, "author": "MUI Team", "description": "Joy UI is an open-source React component library that implements MUI's own design principles. It's comprehensive and can be used in production out of the box.", diff --git a/packages/mui-joy/src/Autocomplete/Autocomplete.test.tsx b/packages/mui-joy/src/Autocomplete/Autocomplete.test.tsx index 09b874caa4c560..44b0ce311cb53f 100644 --- a/packages/mui-joy/src/Autocomplete/Autocomplete.test.tsx +++ b/packages/mui-joy/src/Autocomplete/Autocomplete.test.tsx @@ -1323,6 +1323,7 @@ describe('Joy ', () => { checkHighlightIs(autocompleteListbox, 'six'); expect(autocompleteListbox.scrollTop).to.greaterThan(0); }); + it('should keep focus on selected option and not reset to top option when options updated', () => { const { setProps } = render(); const textbox = screen.getByRole('combobox'); diff --git a/packages/mui-joy/src/Autocomplete/Autocomplete.tsx b/packages/mui-joy/src/Autocomplete/Autocomplete.tsx index a6a806dec0a1e0..696feacf1ea575 100644 --- a/packages/mui-joy/src/Autocomplete/Autocomplete.tsx +++ b/packages/mui-joy/src/Autocomplete/Autocomplete.tsx @@ -416,6 +416,7 @@ const Autocomplete = React.forwardRef(function Autocomplete( variant="soft" color="neutral" endDecorator={} + sx={{ minWidth: 0 }} > {getOptionLabel(option)} diff --git a/packages/mui-joy/src/Button/Button.test.tsx b/packages/mui-joy/src/Button/Button.test.tsx index 57bf78208efa38..590e7a7af67666 100644 --- a/packages/mui-joy/src/Button/Button.test.tsx +++ b/packages/mui-joy/src/Button/Button.test.tsx @@ -112,12 +112,14 @@ describe('Joy