From 43d8fdd300800b4988f413dd5d9c61bd5e206893 Mon Sep 17 00:00:00 2001 From: Brijesh Bittu <717550+brijeshb42@users.noreply.github.com> Date: Fri, 5 Sep 2025 14:09:55 +0530 Subject: [PATCH 1/8] [infra] Migrate error code extraction to code-infra --- babel.config.mjs | 18 +- docs/public/static/error-codes.json | 1 - docs/src/error-codes.json | 74 +++++ package.json | 4 +- packages/react/package.json | 3 +- packages/utils/package.json | 3 + packages/utils/src/formatErrorMessage.ts | 14 + packages/utils/src/store/createSelector.ts | 4 +- packages/utils/src/useEventCallback.ts | 4 +- pnpm-lock.yaml | 366 +++++++++++---------- 10 files changed, 298 insertions(+), 193 deletions(-) delete mode 100644 docs/public/static/error-codes.json create mode 100644 docs/src/error-codes.json create mode 100644 packages/utils/src/formatErrorMessage.ts diff --git a/babel.config.mjs b/babel.config.mjs index f12e85cc3c2..31648ccdc38 100644 --- a/babel.config.mjs +++ b/babel.config.mjs @@ -1,20 +1,22 @@ import getBaseConfig from '@mui/internal-code-infra/babel-config'; +import * as path from 'node:path'; +import { fileURLToPath } from 'node:url'; -const errorCodesPath = new URL(import.meta.resolve('./docs/public/static/error-codes.json')) - .pathname; -const missingError = process.env.MUI_EXTRACT_ERROR_CODES === 'true' ? 'write' : 'annotate'; +const dirname = path.dirname(fileURLToPath(import.meta.url)); + +const errorCodesPath = path.join(dirname, 'docs/src/error-codes.json'); export default function getBabelConfig(api) { const baseConfig = getBaseConfig(api); const plugins = [ [ - 'babel-plugin-macros', + '@mui/internal-babel-plugin-minify-errors', { - muiError: { - errorCodesPath, - missingError, - }, + missingError: 'annotate', + runtimeModule: '#formatErrorMessage', + detection: 'opt-out', + errorCodesPath, }, ], ]; diff --git a/docs/public/static/error-codes.json b/docs/public/static/error-codes.json deleted file mode 100644 index 0967ef424bc..00000000000 --- a/docs/public/static/error-codes.json +++ /dev/null @@ -1 +0,0 @@ -{} diff --git a/docs/src/error-codes.json b/docs/src/error-codes.json new file mode 100644 index 00000000000..86c074aae95 --- /dev/null +++ b/docs/src/error-codes.json @@ -0,0 +1,74 @@ +{ + "1": "Unsupported number of selectors", + "2": "Unsupported number of arguments", + "3": "Base UI: CheckboxGroupContext is missing. CheckboxGroup parts must be placed within .", + "4": "Base UI: DirectionContext is missing.", + "5": "Base UI: MenubarContext is missing. Menubar parts must be placed within .", + "6": "Base UI: useToast must be used within .", + "7": "Base UI: ToggleGroupContext is missing. ToggleGroup parts must be placed within .", + "8": "Base UI: Render element or function are not defined.", + "9": "Base UI: AccordionItemContext is missing. Accordion parts must be placed within .", + "10": "Base UI: AccordionRootContext is missing. Accordion parts must be placed within .", + "11": "Base UI: is missing.", + "12": "Base UI: AlertDialogRootContext is missing. AlertDialog parts must be placed within .", + "13": "Base UI: AvatarRootContext is missing. Avatar parts must be placed within .", + "14": "Base UI: CheckboxRootContext is missing. Checkbox parts must be placed within .", + "15": "Base UI: CollapsibleRootContext is missing. Collapsible parts must be placed within .", + "16": "Base UI: CompositeRootContext is missing. Composite parts must be placed within .", + "17": "useComboboxChipContext must be used within a ComboboxChip", + "18": "Base UI: ComboboxGroupContext is missing. ComboboxGroup parts must be placed within .", + "19": "Base UI: ComboboxItemContext is missing. ComboboxItem parts must be placed within .", + "20": "Base UI: is missing.", + "21": "Base UI: and must be used within the component", + "22": "Base UI: ComboboxRootContext is missing. Combobox parts must be placed within .", + "23": "Base UI: ComboboxFloatingContext is missing. Combobox parts must be placed within .", + "24": "Base UI: ComboboxItemsContext is missing. Combobox parts must be placed within .", + "25": "Base UI: ContextMenuRootContext is missing. ContextMenu parts must be placed within .", + "26": "Base UI: is missing.", + "27": "Base UI: DialogRootContext is missing. Dialog parts must be placed within .", + "28": "Base UI: FieldRootContext is missing. Field parts must be placed within .", + "29": "[Floating UI]: Invalid grid - item width at index %s is greater than grid columns", + "30": "Base UI: MenuCheckboxItemContext is missing. MenuCheckboxItem parts must be placed within .", + "31": "Base UI: MenuGroupRootContext is missing. Menu group parts must be used within .", + "32": "Base UI: is missing.", + "33": "Base UI: MenuPositionerContext is missing. MenuPositioner parts must be placed within .", + "34": "Base UI: MenuRadioGroupContext is missing. MenuRadioGroup parts must be placed within .", + "35": "Base UI: MenuRadioItemContext is missing. MenuRadioItem parts must be placed within .", + "36": "Base UI: MenuRootContext is missing. Menu parts must be placed within .", + "37": "Base UI: must be placed in .", + "38": "Base UI: MeterRootContext is missing. Meter parts must be placed within .", + "39": "Base UI: NavigationMenuItem parts must be used within a .", + "40": "Base UI: is missing.", + "41": "Base UI: NavigationMenuRootContext is missing. Navigation Menu parts must be placed within .", + "42": "Base UI: NavigationMenuPositionerContext is missing. NavigationMenuPositioner parts must be placed within .", + "43": "Base UI: NumberFieldRootContext is missing. NumberField parts must be placed within .", + "44": "Base UI: NumberFieldScrubAreaContext is missing. NumberFieldScrubArea parts must be placed within .", + "45": "Base UI: is missing.", + "46": "Base UI: PopoverPositionerContext is missing. PopoverPositioner parts must be placed within .", + "47": "Base UI: PopoverRootContext is missing. Popover parts must be placed within .", + "48": "Base UI: is missing.", + "49": "Base UI: and must be used within the component", + "50": "Base UI: PreviewCardRootContext is missing. PreviewCard parts must be placed within .", + "51": "Base UI: ProgressRootContext is missing. Progress parts must be placed within .", + "52": "Base UI: RadioRootContext is missing. Radio parts must be placed within .", + "53": "Base UI: ScrollAreaRootContext is missing. ScrollArea parts must be placed within .", + "54": "Base UI: ScrollAreaScrollbarContext is missing. ScrollAreaScrollbar parts must be placed within .", + "55": "Base UI: ScrollAreaViewportContext missing. ScrollAreaViewport parts must be placed within .", + "56": "Base UI: SelectGroupContext is missing. SelectGroup parts must be placed within .", + "57": "Base UI: SelectItemContext is missing. SelectItem parts must be placed within .", + "58": "Base UI: is missing.", + "59": "Base UI: SelectPositionerContext is missing. SelectPositioner parts must be placed within .", + "60": "Base UI: SelectRootContext is missing. Select parts must be placed within .", + "61": "Base UI: SelectFloatingContext is missing. Select parts must be placed within .", + "62": "Base UI: SliderRootContext is missing. Slider parts must be placed within .", + "63": "Base UI: SwitchRootContext is missing. Switch parts must be placed within .", + "64": "Base UI: TabsRootContext is missing. Tabs parts must be placed within .", + "65": "Base UI: TabsListContext is missing. TabsList parts must be placed within .", + "66": "Base UI: ToastRootContext is missing. Toast parts must be used within .", + "67": "Base UI: ToastViewportContext is missing. Toast parts must be placed within .", + "68": "Base UI: ToolbarGroupContext is missing. ToolbarGroup parts must be placed within .", + "69": "Base UI: ToolbarRootContext is missing. Toolbar parts must be placed within .", + "70": "Base UI: is missing.", + "71": "Base UI: TooltipPositionerContext is missing. TooltipPositioner parts must be placed within .", + "72": "Base UI: TooltipRootContext is missing. Tooltip parts must be placed within ." +} diff --git a/package.json b/package.json index 8b5f9a4c7df..029b81d0f09 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,7 @@ "docs:start": "pnpm --filter docs serve", "docs:link-check": "pnpm --filter docs link-check", "docs:generate-llms": "pnpm --filter docs run generate-llms", - "extract-error-codes": "cross-env MUI_EXTRACT_ERROR_CODES=true lerna run --concurrency 1 build:stable", + "extract-error-codes": "code-infra extract-error-codes --errorCodesPath docs/src/error-codes.json --detection opt-out", "jsonlint": "code-infra jsonlint", "eslint": "eslint . --cache --report-unused-disable-directives --ext .js,.ts,.tsx,.mts --max-warnings 0 && pnpm -r lint", "eslint:ci": "eslint . --report-unused-disable-directives --ext .js,.ts,.tsx,.mts --max-warnings 0 && pnpm -r lint", @@ -62,7 +62,7 @@ "@arethetypeswrong/cli": "^0.18.2", "@babel/plugin-transform-react-constant-elements": "^7.27.1", "@base-ui-components/monorepo-tests": "workspace:*", - "@mui/internal-code-infra": "^0.0.3-canary.10", + "@mui/internal-code-infra": "^0.0.3-canary.14", "@mui/internal-test-utils": "^2.0.10", "@mui/monorepo": "github:mui/material-ui#v7.3.2", "@octokit/rest": "^22.0.0", diff --git a/packages/react/package.json b/packages/react/package.json index 84a5badaaeb..65b5432e07d 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -69,7 +69,8 @@ "./use-render": "./src/use-render/index.ts" }, "imports": { - "#test-utils": "./test/index.ts" + "#test-utils": "./test/index.ts", + "#formatErrorMessage": "@base-ui-components/utils/formatErrorMessage" }, "type": "commonjs", "scripts": { diff --git a/packages/utils/package.json b/packages/utils/package.json index a25fa7477f4..1036acf3dbb 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -12,6 +12,9 @@ "./store": "./src/store/index.ts", "./*": "./src/*.ts" }, + "imports": { + "#formatErrorMessage": "./src/formatErrorMessage.ts" + }, "type": "commonjs", "scripts": { "prebuild": "rimraf --glob build build-tests \"*.tsbuildinfo\"", diff --git a/packages/utils/src/formatErrorMessage.ts b/packages/utils/src/formatErrorMessage.ts new file mode 100644 index 00000000000..04eaa1d05b7 --- /dev/null +++ b/packages/utils/src/formatErrorMessage.ts @@ -0,0 +1,14 @@ +/** + * WARNING: Don't import this directly. It's imported by the code generated by + * `@mui/interal-babel-plugin-minify-errors`. Make sure to always use string literals in `Error` + * constructors to ensure the plugin works as expected. Supported patterns include: + * throw new Error('My message'); + * throw new Error(`My message: ${foo}`); + * throw new Error(`My message: ${foo}` + 'another string'); + * ... + */ +export default function formatErrorMessage(code: number, ...args: string[]): string { + const url = new URL(`https://base-ui.com/production-error/${code}`); + args.forEach((arg) => url.searchParams.append('args[]', arg)); + return `Base UI error #${code}; visit ${url} for the full message.`; +} diff --git a/packages/utils/src/store/createSelector.ts b/packages/utils/src/store/createSelector.ts index 107b46d883a..1af16b7f8fb 100644 --- a/packages/utils/src/store/createSelector.ts +++ b/packages/utils/src/store/createSelector.ts @@ -125,7 +125,7 @@ export const createSelector = (( } else if (a) { selector = a; } else { - throw new Error('Missing arguments'); + throw /* minify-error-disabled */ new Error('Missing arguments'); } return selector; @@ -206,7 +206,7 @@ export const createSelectorMemoized: CreateSelectorFunction = (...selectors: any case 2: return fn(state, a1, a2); case 3: return fn(state, a1, a2, a3); default: - throw new Error('unreachable'); + throw /* minify-error-disabled */ new Error('unreachable'); } }; diff --git a/packages/utils/src/useEventCallback.ts b/packages/utils/src/useEventCallback.ts index 12f06214fa6..3b006cd4c57 100644 --- a/packages/utils/src/useEventCallback.ts +++ b/packages/utils/src/useEventCallback.ts @@ -46,6 +46,8 @@ function createStableCallback() { function assertNotCalled() { if (process.env.NODE_ENV !== 'production') { - throw new Error('Base UI: Cannot call an event handler while rendering.'); + throw /* minify-error-disabled */ new Error( + 'Base UI: Cannot call an event handler while rendering.', + ); } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index ff7012dda3d..abd1012ed99 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -29,8 +29,8 @@ importers: specifier: workspace:* version: link:test '@mui/internal-code-infra': - specifier: ^0.0.3-canary.10 - version: 0.0.3-canary.10(eslint@9.35.0(jiti@2.5.1))(prettier@3.6.2)(typescript@5.9.2) + specifier: ^0.0.3-canary.14 + version: 0.0.3-canary.14(eslint@9.35.0(jiti@2.5.1))(postcss@8.5.6)(prettier@3.6.2)(stylelint@16.24.0(typescript@5.9.2))(typescript@5.9.2) '@mui/internal-test-utils': specifier: ^2.0.10 version: 2.0.13(@babel/core@7.28.4)(@playwright/test@1.55.1)(@types/react-dom@19.1.9(@types/react@19.1.13))(@types/react@19.1.13)(chai@5.3.3)(react-dom@19.1.1(react@19.1.1))(react@19.1.1) @@ -729,12 +729,12 @@ packages: resolution: {integrity: sha512-GiwTmBFOU1/+UVNqqCGzFJYfBXEytUkiI+iRZ6Qx7KmUVtLm00sYySkfe203C9QtPG11yOz1ZaMek8dT/xnlgg==} engines: {node: '>=20'} - '@argos-ci/api-client@0.11.0': - resolution: {integrity: sha512-mv7LWrJfEDjjs+CmAJaM1GIexpb3A8TwuyTUCTKgDp/SHdbU0uF8uC6lV4P/mfeGIvBYZzIRKq/frd+IETlC2g==} + '@argos-ci/api-client@0.11.1': + resolution: {integrity: sha512-AYchqf//lyrzwmZi0KflB5uND9/+GDVQ7rpvf36pvIlSdwFNv825kIR5pYn+65kmi39780tCDsQgQJZj6Jj4CQ==} engines: {node: '>=20.0.0'} - '@argos-ci/core@4.1.4': - resolution: {integrity: sha512-CNQR+C2okfDfpvi43aWaQCviUmVskUdbs5AIpNM7r74ZxIz/jXHA4yap5d1Dlz24HQ+q/ZhSMXZi6PkZgGImvA==} + '@argos-ci/core@4.1.6': + resolution: {integrity: sha512-VXtdLub7BXSDZSQQPJa+5b1Z0y1Zai9kmOj/jZPywdwg3Csw5C9mC67To77A/ZRb2Uy6sJnQDf2IIrP+lf/wCg==} engines: {node: '>=20.0.0'} '@argos-ci/util@3.1.0': @@ -1918,124 +1918,128 @@ packages: resolution: {integrity: sha512-H9XAx3hc0BQHY6l+IFSWHDySypcXsvsuLhgYLUGywmJ5pswRVQJUHpOsobnLYp2ZUaUlKiKDrgWWhosOwAEM8Q==} engines: {node: '>=6.9.0'} - '@img/sharp-darwin-arm64@0.34.3': - resolution: {integrity: sha512-ryFMfvxxpQRsgZJqBd4wsttYQbCxsJksrv9Lw/v798JcQ8+w84mBWuXwl+TT0WJ/WrYOLaYpwQXi3sA9nTIaIg==} + '@img/colour@1.0.0': + resolution: {integrity: sha512-A5P/LfWGFSl6nsckYtjw9da+19jB8hkJ6ACTGcDfEJ0aE+l2n2El7dsVM7UVHZQ9s2lmYMWlrS21YLy2IR1LUw==} + engines: {node: '>=18'} + + '@img/sharp-darwin-arm64@0.34.4': + resolution: {integrity: sha512-sitdlPzDVyvmINUdJle3TNHl+AG9QcwiAMsXmccqsCOMZNIdW2/7S26w0LyU8euiLVzFBL3dXPwVCq/ODnf2vA==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm64] os: [darwin] - '@img/sharp-darwin-x64@0.34.3': - resolution: {integrity: sha512-yHpJYynROAj12TA6qil58hmPmAwxKKC7reUqtGLzsOHfP7/rniNGTL8tjWX6L3CTV4+5P4ypcS7Pp+7OB+8ihA==} + '@img/sharp-darwin-x64@0.34.4': + resolution: {integrity: sha512-rZheupWIoa3+SOdF/IcUe1ah4ZDpKBGWcsPX6MT0lYniH9micvIU7HQkYTfrx5Xi8u+YqwLtxC/3vl8TQN6rMg==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [x64] os: [darwin] - '@img/sharp-libvips-darwin-arm64@1.2.0': - resolution: {integrity: sha512-sBZmpwmxqwlqG9ueWFXtockhsxefaV6O84BMOrhtg/YqbTaRdqDE7hxraVE3y6gVM4eExmfzW4a8el9ArLeEiQ==} + '@img/sharp-libvips-darwin-arm64@1.2.3': + resolution: {integrity: sha512-QzWAKo7kpHxbuHqUC28DZ9pIKpSi2ts2OJnoIGI26+HMgq92ZZ4vk8iJd4XsxN+tYfNJxzH6W62X5eTcsBymHw==} cpu: [arm64] os: [darwin] - '@img/sharp-libvips-darwin-x64@1.2.0': - resolution: {integrity: sha512-M64XVuL94OgiNHa5/m2YvEQI5q2cl9d/wk0qFTDVXcYzi43lxuiFTftMR1tOnFQovVXNZJ5TURSDK2pNe9Yzqg==} + '@img/sharp-libvips-darwin-x64@1.2.3': + resolution: {integrity: sha512-Ju+g2xn1E2AKO6YBhxjj+ACcsPQRHT0bhpglxcEf+3uyPY+/gL8veniKoo96335ZaPo03bdDXMv0t+BBFAbmRA==} cpu: [x64] os: [darwin] - '@img/sharp-libvips-linux-arm64@1.2.0': - resolution: {integrity: sha512-RXwd0CgG+uPRX5YYrkzKyalt2OJYRiJQ8ED/fi1tq9WQW2jsQIn0tqrlR5l5dr/rjqq6AHAxURhj2DVjyQWSOA==} + '@img/sharp-libvips-linux-arm64@1.2.3': + resolution: {integrity: sha512-I4RxkXU90cpufazhGPyVujYwfIm9Nk1QDEmiIsaPwdnm013F7RIceaCc87kAH+oUB1ezqEvC6ga4m7MSlqsJvQ==} cpu: [arm64] os: [linux] - '@img/sharp-libvips-linux-arm@1.2.0': - resolution: {integrity: sha512-mWd2uWvDtL/nvIzThLq3fr2nnGfyr/XMXlq8ZJ9WMR6PXijHlC3ksp0IpuhK6bougvQrchUAfzRLnbsen0Cqvw==} + '@img/sharp-libvips-linux-arm@1.2.3': + resolution: {integrity: sha512-x1uE93lyP6wEwGvgAIV0gP6zmaL/a0tGzJs/BIDDG0zeBhMnuUPm7ptxGhUbcGs4okDJrk4nxgrmxpib9g6HpA==} cpu: [arm] os: [linux] - '@img/sharp-libvips-linux-ppc64@1.2.0': - resolution: {integrity: sha512-Xod/7KaDDHkYu2phxxfeEPXfVXFKx70EAFZ0qyUdOjCcxbjqyJOEUpDe6RIyaunGxT34Anf9ue/wuWOqBW2WcQ==} + '@img/sharp-libvips-linux-ppc64@1.2.3': + resolution: {integrity: sha512-Y2T7IsQvJLMCBM+pmPbM3bKT/yYJvVtLJGfCs4Sp95SjvnFIjynbjzsa7dY1fRJX45FTSfDksbTp6AGWudiyCg==} cpu: [ppc64] os: [linux] - '@img/sharp-libvips-linux-s390x@1.2.0': - resolution: {integrity: sha512-eMKfzDxLGT8mnmPJTNMcjfO33fLiTDsrMlUVcp6b96ETbnJmd4uvZxVJSKPQfS+odwfVaGifhsB07J1LynFehw==} + '@img/sharp-libvips-linux-s390x@1.2.3': + resolution: {integrity: sha512-RgWrs/gVU7f+K7P+KeHFaBAJlNkD1nIZuVXdQv6S+fNA6syCcoboNjsV2Pou7zNlVdNQoQUpQTk8SWDHUA3y/w==} cpu: [s390x] os: [linux] - '@img/sharp-libvips-linux-x64@1.2.0': - resolution: {integrity: sha512-ZW3FPWIc7K1sH9E3nxIGB3y3dZkpJlMnkk7z5tu1nSkBoCgw2nSRTFHI5pB/3CQaJM0pdzMF3paf9ckKMSE9Tg==} + '@img/sharp-libvips-linux-x64@1.2.3': + resolution: {integrity: sha512-3JU7LmR85K6bBiRzSUc/Ff9JBVIFVvq6bomKE0e63UXGeRw2HPVEjoJke1Yx+iU4rL7/7kUjES4dZ/81Qjhyxg==} cpu: [x64] os: [linux] - '@img/sharp-libvips-linuxmusl-arm64@1.2.0': - resolution: {integrity: sha512-UG+LqQJbf5VJ8NWJ5Z3tdIe/HXjuIdo4JeVNADXBFuG7z9zjoegpzzGIyV5zQKi4zaJjnAd2+g2nna8TZvuW9Q==} + '@img/sharp-libvips-linuxmusl-arm64@1.2.3': + resolution: {integrity: sha512-F9q83RZ8yaCwENw1GieztSfj5msz7GGykG/BA+MOUefvER69K/ubgFHNeSyUu64amHIYKGDs4sRCMzXVj8sEyw==} cpu: [arm64] os: [linux] - '@img/sharp-libvips-linuxmusl-x64@1.2.0': - resolution: {integrity: sha512-SRYOLR7CXPgNze8akZwjoGBoN1ThNZoqpOgfnOxmWsklTGVfJiGJoC/Lod7aNMGA1jSsKWM1+HRX43OP6p9+6Q==} + '@img/sharp-libvips-linuxmusl-x64@1.2.3': + resolution: {integrity: sha512-U5PUY5jbc45ANM6tSJpsgqmBF/VsL6LnxJmIf11kB7J5DctHgqm0SkuXzVWtIY90GnJxKnC/JT251TDnk1fu/g==} cpu: [x64] os: [linux] - '@img/sharp-linux-arm64@0.34.3': - resolution: {integrity: sha512-QdrKe3EvQrqwkDrtuTIjI0bu6YEJHTgEeqdzI3uWJOH6G1O8Nl1iEeVYRGdj1h5I21CqxSvQp1Yv7xeU3ZewbA==} + '@img/sharp-linux-arm64@0.34.4': + resolution: {integrity: sha512-YXU1F/mN/Wu786tl72CyJjP/Ngl8mGHN1hST4BGl+hiW5jhCnV2uRVTNOcaYPs73NeT/H8Upm3y9582JVuZHrQ==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm64] os: [linux] - '@img/sharp-linux-arm@0.34.3': - resolution: {integrity: sha512-oBK9l+h6KBN0i3dC8rYntLiVfW8D8wH+NPNT3O/WBHeW0OQWCjfWksLUaPidsrDKpJgXp3G3/hkmhptAW0I3+A==} + '@img/sharp-linux-arm@0.34.4': + resolution: {integrity: sha512-Xyam4mlqM0KkTHYVSuc6wXRmM7LGN0P12li03jAnZ3EJWZqj83+hi8Y9UxZUbxsgsK1qOEwg7O0Bc0LjqQVtxA==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm] os: [linux] - '@img/sharp-linux-ppc64@0.34.3': - resolution: {integrity: sha512-GLtbLQMCNC5nxuImPR2+RgrviwKwVql28FWZIW1zWruy6zLgA5/x2ZXk3mxj58X/tszVF69KK0Is83V8YgWhLA==} + '@img/sharp-linux-ppc64@0.34.4': + resolution: {integrity: sha512-F4PDtF4Cy8L8hXA2p3TO6s4aDt93v+LKmpcYFLAVdkkD3hSxZzee0rh6/+94FpAynsuMpLX5h+LRsSG3rIciUQ==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [ppc64] os: [linux] - '@img/sharp-linux-s390x@0.34.3': - resolution: {integrity: sha512-3gahT+A6c4cdc2edhsLHmIOXMb17ltffJlxR0aC2VPZfwKoTGZec6u5GrFgdR7ciJSsHT27BD3TIuGcuRT0KmQ==} + '@img/sharp-linux-s390x@0.34.4': + resolution: {integrity: sha512-qVrZKE9Bsnzy+myf7lFKvng6bQzhNUAYcVORq2P7bDlvmF6u2sCmK2KyEQEBdYk+u3T01pVsPrkj943T1aJAsw==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [s390x] os: [linux] - '@img/sharp-linux-x64@0.34.3': - resolution: {integrity: sha512-8kYso8d806ypnSq3/Ly0QEw90V5ZoHh10yH0HnrzOCr6DKAPI6QVHvwleqMkVQ0m+fc7EH8ah0BB0QPuWY6zJQ==} + '@img/sharp-linux-x64@0.34.4': + resolution: {integrity: sha512-ZfGtcp2xS51iG79c6Vhw9CWqQC8l2Ot8dygxoDoIQPTat/Ov3qAa8qpxSrtAEAJW+UjTXc4yxCjNfxm4h6Xm2A==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [x64] os: [linux] - '@img/sharp-linuxmusl-arm64@0.34.3': - resolution: {integrity: sha512-vAjbHDlr4izEiXM1OTggpCcPg9tn4YriK5vAjowJsHwdBIdx0fYRsURkxLG2RLm9gyBq66gwtWI8Gx0/ov+JKQ==} + '@img/sharp-linuxmusl-arm64@0.34.4': + resolution: {integrity: sha512-8hDVvW9eu4yHWnjaOOR8kHVrew1iIX+MUgwxSuH2XyYeNRtLUe4VNioSqbNkB7ZYQJj9rUTT4PyRscyk2PXFKA==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm64] os: [linux] - '@img/sharp-linuxmusl-x64@0.34.3': - resolution: {integrity: sha512-gCWUn9547K5bwvOn9l5XGAEjVTTRji4aPTqLzGXHvIr6bIDZKNTA34seMPgM0WmSf+RYBH411VavCejp3PkOeQ==} + '@img/sharp-linuxmusl-x64@0.34.4': + resolution: {integrity: sha512-lU0aA5L8QTlfKjpDCEFOZsTYGn3AEiO6db8W5aQDxj0nQkVrZWmN3ZP9sYKWJdtq3PWPhUNlqehWyXpYDcI9Sg==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [x64] os: [linux] - '@img/sharp-wasm32@0.34.3': - resolution: {integrity: sha512-+CyRcpagHMGteySaWos8IbnXcHgfDn7pO2fiC2slJxvNq9gDipYBN42/RagzctVRKgxATmfqOSulgZv5e1RdMg==} + '@img/sharp-wasm32@0.34.4': + resolution: {integrity: sha512-33QL6ZO/qpRyG7woB/HUALz28WnTMI2W1jgX3Nu2bypqLIKx/QKMILLJzJjI+SIbvXdG9fUnmrxR7vbi1sTBeA==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [wasm32] - '@img/sharp-win32-arm64@0.34.3': - resolution: {integrity: sha512-MjnHPnbqMXNC2UgeLJtX4XqoVHHlZNd+nPt1kRPmj63wURegwBhZlApELdtxM2OIZDRv/DFtLcNhVbd1z8GYXQ==} + '@img/sharp-win32-arm64@0.34.4': + resolution: {integrity: sha512-2Q250do/5WXTwxW3zjsEuMSv5sUU4Tq9VThWKlU2EYLm4MB7ZeMwF+SFJutldYODXF6jzc6YEOC+VfX0SZQPqA==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm64] os: [win32] - '@img/sharp-win32-ia32@0.34.3': - resolution: {integrity: sha512-xuCdhH44WxuXgOM714hn4amodJMZl3OEvf0GVTm0BEyMeA2to+8HEdRPShH0SLYptJY1uBw+SCFP9WVQi1Q/cw==} + '@img/sharp-win32-ia32@0.34.4': + resolution: {integrity: sha512-3ZeLue5V82dT92CNL6rsal6I2weKw1cYu+rGKm8fOCCtJTR2gYeUfY3FqUnIJsMUPIH68oS5jmZ0NiJ508YpEw==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [ia32] os: [win32] - '@img/sharp-win32-x64@0.34.3': - resolution: {integrity: sha512-OWwz05d++TxzLEv4VnsTz5CmZ6mI6S05sfQGEMrNrQcOEERbX46332IvE7pO/EUiw7jUrrS40z/M7kPyjfl04g==} + '@img/sharp-win32-x64@0.34.4': + resolution: {integrity: sha512-xIyj4wpYs8J18sVN3mSQjwrw7fKUqRw+Z5rnHNCy5fYTxigBz81u5mOMPmFumwjcn8+ld1ppptMBCLic1nz6ig==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [x64] os: [win32] @@ -2151,8 +2155,8 @@ packages: peerDependencies: '@babel/core': ^7.28.4 - '@mui/internal-babel-plugin-resolve-imports@2.0.7-canary.21': - resolution: {integrity: sha512-cz9b6azRLNiylkOUVuFnI51YcEU8FEGmRCE6p7WFiPogV7Zf39EwW4y9F21xSoAr4YrHWJWwLDDfrZ8b34hhlw==} + '@mui/internal-babel-plugin-resolve-imports@2.0.7-canary.22': + resolution: {integrity: sha512-UyPWxB1dv+2ed8MLhU/SAaVretfPSbcKGLmtGc8alieREKuxf+ui9t8b1aer2C5w82FmzoOVQaIJ9OT4KZQW8Q==} peerDependencies: '@babel/core': ^7.28.4 @@ -2160,8 +2164,8 @@ packages: resolution: {integrity: sha512-9hqDvOezGxIztw/9FdWmg+M+jzM8fspsR/MqssBUHYUvLxYUy3P0MO3iTy/GJHkZvvL53hJTI3XD6NjSuaeIgw==} hasBin: true - '@mui/internal-code-infra@0.0.3-canary.10': - resolution: {integrity: sha512-ZrVfgfpeZiy5V7FmbzC+83qJoiFLNA90kyaio3G2g9cEwkiRir8MK1bgwA+GkYeHdRiUkvCeMpZYIldjg3wqRw==} + '@mui/internal-code-infra@0.0.3-canary.14': + resolution: {integrity: sha512-mKMNNN4Zz2fYxxugIIHKxxMli7shMf9luK3OHpER6eZitFy9+W79q/UjNjaJKRq8M2B53tCvAPeT9zLDmRQ7eg==} hasBin: true peerDependencies: eslint: ^9.0.0 @@ -5183,10 +5187,6 @@ packages: color@3.2.1: resolution: {integrity: sha512-aBl7dZI9ENN6fUGC7mWpMTPNHmWUSNan9tuWN6ahh5ZLNk9baLJOnSMlrQkHcrfFgz2/RigjUVAjdx36VcemKA==} - color@4.2.3: - resolution: {integrity: sha512-1rXeuUUiGGrykh+CeBdu5Ie7OJwinCgQY0bc7GCRxy5xVHy+moaqkpL/jqQq0MtQOeYcrqEz4abc5f0KtU7W4A==} - engines: {node: '>=12.5.0'} - colord@2.9.3: resolution: {integrity: sha512-jeC1axXpnb0/2nn/Y1LPuLdgXBLH7aDcHu4KEKfqw3CUhX7ZpfBSlPKyqXE6btIgEzfWtrX3/tyBCaCvXvMkOw==} @@ -5469,8 +5469,8 @@ packages: supports-color: optional: true - debug@4.4.1: - resolution: {integrity: sha512-KcKCqiftBJcZr++7ykoDIEwSa3XWowTfNPo92BYxjXiyYEVrUQh2aLyhxBCwww+heortUFxEJYcRzosstTEBYQ==} + debug@4.4.3: + resolution: {integrity: sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==} engines: {node: '>=6.0'} peerDependencies: supports-color: '*' @@ -5556,8 +5556,8 @@ packages: resolution: {integrity: sha512-rlpvsxUtM0PQvy9iZe640/IWwWYyBsTApREbA1pHOpmOUIl9MkP/U4z7vTtg4Oaojvqhxt7sdufnT0EzGaR31g==} engines: {node: '>=4'} - detect-libc@2.0.4: - resolution: {integrity: sha512-3UDv+G9CsCKO1WKMGw9fwq/SWJYbI0c5Y7LU1AXYoDdbhE2AHQ6N6Nb34sG8Fj7T5APy8qXDCKuuIHd1BR0tVA==} + detect-libc@2.1.1: + resolution: {integrity: sha512-ecqj/sy1jcK1uWrwpR67UhYrIFQ+5WlGxth34WquCbamhFA6hkkwiu37o6J5xCHdo1oixJRfVRw+ywV+Hq/0Aw==} engines: {node: '>=8'} detect-node-es@1.1.0: @@ -7347,9 +7347,6 @@ packages: resolution: {integrity: sha512-gvVijfZvn7R+2qyPX8mAuKcFGDf6Nc61GdvGafQsHL0sBIxfKzA+usWn4GFC/bk+QdwPUD4kWFJLhElipq+0VA==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - lodash-es@4.17.21: - resolution: {integrity: sha512-mKnC+QJ9pWVzv+C4/U3rRsHapFfHvQFoFB92e52xeyGMcX6/OlIl78je1u8vePzYZSkkogMPJ2yjxxsb89cxyw==} - lodash.clonedeep@4.5.0: resolution: {integrity: sha512-H5ZhCF25riFd9uB5UCkVKo61m3S/xZk1x4wA6yp/L3RFP6Z/eHH1ymQcGLo7J3GMPfm0V/7m1tryHuGVxpqEBQ==} @@ -8960,6 +8957,10 @@ packages: regex@6.0.1: resolution: {integrity: sha512-uorlqlzAKjKQZ5P+kTJr3eeJGSVroLKoHmquUj4zHWuR+hEyNqlXsSKlYYF5F4NI6nl7tWCs0apKJ0lmfsXAPA==} + regexp.escape@2.0.1: + resolution: {integrity: sha512-JItRb4rmyTzmERBkAf6J87LjDPy/RscIwmaJQ3gsFlAzrmZbZU8LwBw5IydFZXW9hqpgbPlGbMhtpqtuAhMgtg==} + engines: {node: '>= 0.4'} + regexp.prototype.flags@1.5.4: resolution: {integrity: sha512-dYqgNSZbDwkaJ2ceRd9ojCGjBq+mOm9LmtXnAnEGyHhN/5R7iDW2TRw3h+o/jCFxus3P2LfWIIiwowAjANm7IA==} engines: {node: '>= 0.4'} @@ -9246,8 +9247,8 @@ packages: resolution: {integrity: sha512-/6KqX+GVUdqPuPPd2LxDDxzX6CAbjJehAAOKlNpqqUpAqPM6HeL8f+o3a+JsyGjn2lv0WY8UsTgUJjU9Ok55NA==} engines: {node: '>=8'} - sharp@0.34.3: - resolution: {integrity: sha512-eX2IQ6nFohW4DbvHIOLRB3MHFpYqaqvXd3Tp5e/T/dSH83fxaNJQRvDMhASmkNTsNTVF2/OOopzRCt7xokgPfg==} + sharp@0.34.4: + resolution: {integrity: sha512-FUH39xp3SBPnxWvd5iib1X8XY7J0K0X7d93sie9CJg2PO8/7gmg89Nve6OjItK53/MlAushNNxteBYfM6DEuoA==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} shebang-command@2.0.0: @@ -10448,21 +10449,21 @@ snapshots: typescript: 5.6.1-rc validate-npm-package-name: 5.0.1 - '@argos-ci/api-client@0.11.0': + '@argos-ci/api-client@0.11.1': dependencies: - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) openapi-fetch: 0.14.0 transitivePeerDependencies: - supports-color - '@argos-ci/core@4.1.4': + '@argos-ci/core@4.1.6': dependencies: - '@argos-ci/api-client': 0.11.0 + '@argos-ci/api-client': 0.11.1 '@argos-ci/util': 3.1.0 convict: 6.2.4 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) fast-glob: 3.3.3 - sharp: 0.34.3 + sharp: 0.34.4 tmp: 0.2.5 transitivePeerDependencies: - supports-color @@ -11056,7 +11057,7 @@ snapshots: '@babel/types': 7.28.4 '@jridgewell/remapping': 2.3.5 convert-source-map: 2.0.0 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) gensync: 1.0.0-beta.2 json5: 2.2.3 semver: 6.3.1 @@ -11108,7 +11109,7 @@ snapshots: '@babel/core': 7.28.4 '@babel/helper-compilation-targets': 7.27.2 '@babel/helper-plugin-utils': 7.27.1 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) lodash.debounce: 4.0.8 resolve: 1.22.10 transitivePeerDependencies: @@ -11802,7 +11803,7 @@ snapshots: '@babel/parser': 7.28.4 '@babel/template': 7.27.2 '@babel/types': 7.28.4 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) transitivePeerDependencies: - supports-color @@ -12094,7 +12095,7 @@ snapshots: '@eslint/config-array@0.21.0': dependencies: '@eslint/object-schema': 2.1.6 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) minimatch: 3.1.2 transitivePeerDependencies: - supports-color @@ -12108,7 +12109,7 @@ snapshots: '@eslint/eslintrc@3.3.1': dependencies: ajv: 6.12.6 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) espree: 10.4.0 globals: 14.0.0 ignore: 5.3.2 @@ -12160,90 +12161,92 @@ snapshots: '@hutson/parse-repository-url@3.0.2': {} - '@img/sharp-darwin-arm64@0.34.3': + '@img/colour@1.0.0': {} + + '@img/sharp-darwin-arm64@0.34.4': optionalDependencies: - '@img/sharp-libvips-darwin-arm64': 1.2.0 + '@img/sharp-libvips-darwin-arm64': 1.2.3 optional: true - '@img/sharp-darwin-x64@0.34.3': + '@img/sharp-darwin-x64@0.34.4': optionalDependencies: - '@img/sharp-libvips-darwin-x64': 1.2.0 + '@img/sharp-libvips-darwin-x64': 1.2.3 optional: true - '@img/sharp-libvips-darwin-arm64@1.2.0': + '@img/sharp-libvips-darwin-arm64@1.2.3': optional: true - '@img/sharp-libvips-darwin-x64@1.2.0': + '@img/sharp-libvips-darwin-x64@1.2.3': optional: true - '@img/sharp-libvips-linux-arm64@1.2.0': + '@img/sharp-libvips-linux-arm64@1.2.3': optional: true - '@img/sharp-libvips-linux-arm@1.2.0': + '@img/sharp-libvips-linux-arm@1.2.3': optional: true - '@img/sharp-libvips-linux-ppc64@1.2.0': + '@img/sharp-libvips-linux-ppc64@1.2.3': optional: true - '@img/sharp-libvips-linux-s390x@1.2.0': + '@img/sharp-libvips-linux-s390x@1.2.3': optional: true - '@img/sharp-libvips-linux-x64@1.2.0': + '@img/sharp-libvips-linux-x64@1.2.3': optional: true - '@img/sharp-libvips-linuxmusl-arm64@1.2.0': + '@img/sharp-libvips-linuxmusl-arm64@1.2.3': optional: true - '@img/sharp-libvips-linuxmusl-x64@1.2.0': + '@img/sharp-libvips-linuxmusl-x64@1.2.3': optional: true - '@img/sharp-linux-arm64@0.34.3': + '@img/sharp-linux-arm64@0.34.4': optionalDependencies: - '@img/sharp-libvips-linux-arm64': 1.2.0 + '@img/sharp-libvips-linux-arm64': 1.2.3 optional: true - '@img/sharp-linux-arm@0.34.3': + '@img/sharp-linux-arm@0.34.4': optionalDependencies: - '@img/sharp-libvips-linux-arm': 1.2.0 + '@img/sharp-libvips-linux-arm': 1.2.3 optional: true - '@img/sharp-linux-ppc64@0.34.3': + '@img/sharp-linux-ppc64@0.34.4': optionalDependencies: - '@img/sharp-libvips-linux-ppc64': 1.2.0 + '@img/sharp-libvips-linux-ppc64': 1.2.3 optional: true - '@img/sharp-linux-s390x@0.34.3': + '@img/sharp-linux-s390x@0.34.4': optionalDependencies: - '@img/sharp-libvips-linux-s390x': 1.2.0 + '@img/sharp-libvips-linux-s390x': 1.2.3 optional: true - '@img/sharp-linux-x64@0.34.3': + '@img/sharp-linux-x64@0.34.4': optionalDependencies: - '@img/sharp-libvips-linux-x64': 1.2.0 + '@img/sharp-libvips-linux-x64': 1.2.3 optional: true - '@img/sharp-linuxmusl-arm64@0.34.3': + '@img/sharp-linuxmusl-arm64@0.34.4': optionalDependencies: - '@img/sharp-libvips-linuxmusl-arm64': 1.2.0 + '@img/sharp-libvips-linuxmusl-arm64': 1.2.3 optional: true - '@img/sharp-linuxmusl-x64@0.34.3': + '@img/sharp-linuxmusl-x64@0.34.4': optionalDependencies: - '@img/sharp-libvips-linuxmusl-x64': 1.2.0 + '@img/sharp-libvips-linuxmusl-x64': 1.2.3 optional: true - '@img/sharp-wasm32@0.34.3': + '@img/sharp-wasm32@0.34.4': dependencies: '@emnapi/runtime': 1.5.0 optional: true - '@img/sharp-win32-arm64@0.34.3': + '@img/sharp-win32-arm64@0.34.4': optional: true - '@img/sharp-win32-ia32@0.34.3': + '@img/sharp-win32-ia32@0.34.4': optional: true - '@img/sharp-win32-x64@0.34.3': + '@img/sharp-win32-x64@0.34.4': optional: true '@inquirer/external-editor@1.0.1(@types/node@22.18.6)': @@ -12403,7 +12406,7 @@ snapshots: '@mapbox/node-pre-gyp@2.0.0(encoding@0.1.13)': dependencies: consola: 3.4.2 - detect-libc: 2.0.4 + detect-libc: 2.1.1 https-proxy-agent: 7.0.6 node-fetch: 2.7.0(encoding@0.1.13) nopt: 8.1.0 @@ -12475,7 +12478,7 @@ snapshots: transitivePeerDependencies: - supports-color - '@mui/internal-babel-plugin-resolve-imports@2.0.7-canary.21(@babel/core@7.28.4)': + '@mui/internal-babel-plugin-resolve-imports@2.0.7-canary.22(@babel/core@7.28.4)': dependencies: '@babel/core': 7.28.4 resolve: 1.22.10 @@ -12510,9 +12513,9 @@ snapshots: - tsx - yaml - '@mui/internal-code-infra@0.0.3-canary.10(eslint@9.35.0(jiti@2.5.1))(prettier@3.6.2)(typescript@5.9.2)': + '@mui/internal-code-infra@0.0.3-canary.14(eslint@9.35.0(jiti@2.5.1))(postcss@8.5.6)(prettier@3.6.2)(stylelint@16.24.0(typescript@5.9.2))(typescript@5.9.2)': dependencies: - '@argos-ci/core': 4.1.4 + '@argos-ci/core': 4.1.6 '@babel/cli': 7.28.3(@babel/core@7.28.4) '@babel/core': 7.28.4 '@babel/plugin-syntax-jsx': 7.27.1(@babel/core@7.28.4) @@ -12525,7 +12528,7 @@ snapshots: '@eslint/js': 9.35.0 '@mui/internal-babel-plugin-display-name': 1.0.4-canary.7(@babel/core@7.28.4)(@babel/preset-react@7.27.1(@babel/core@7.28.4)) '@mui/internal-babel-plugin-minify-errors': 2.0.8-canary.10(@babel/core@7.28.4) - '@mui/internal-babel-plugin-resolve-imports': 2.0.7-canary.21(@babel/core@7.28.4) + '@mui/internal-babel-plugin-resolve-imports': 2.0.7-canary.22(@babel/core@7.28.4) '@next/eslint-plugin-next': 15.5.3 '@octokit/auth-action': 6.0.1 '@octokit/rest': 22.0.0 @@ -12539,7 +12542,7 @@ snapshots: eslint-config-prettier: 10.1.8(eslint@9.35.0(jiti@2.5.1)) eslint-import-resolver-typescript: 4.4.4(eslint-plugin-import@2.32.0(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)) eslint-module-utils: 2.12.1(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)) - eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4)(eslint@9.35.0(jiti@2.5.1)) + eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)) eslint-plugin-jsx-a11y: 6.10.2(eslint@9.35.0(jiti@2.5.1)) eslint-plugin-mocha: 11.1.0(eslint@9.35.0(jiti@2.5.1)) eslint-plugin-react: 7.37.5(eslint@9.35.0(jiti@2.5.1)) @@ -12550,10 +12553,13 @@ snapshots: git-url-parse: 16.1.0 globals: 16.4.0 globby: 14.1.0 - lodash-es: 4.17.21 minimatch: 10.0.3 + postcss-styled-syntax: 0.7.1(postcss@8.5.6) prettier: 3.6.2 + regexp.escape: 2.0.1 + resolve-pkg-maps: 1.0.0 semver: 7.7.2 + stylelint-config-standard: 39.0.0(stylelint@16.24.0(typescript@5.9.2)) typescript: 5.9.2 typescript-eslint: 8.44.0(eslint@9.35.0(jiti@2.5.1))(typescript@5.9.2) yargs: 18.0.0 @@ -12562,6 +12568,8 @@ snapshots: - eslint-import-resolver-node - eslint-import-resolver-webpack - eslint-plugin-import-x + - postcss + - stylelint - supports-color '@mui/internal-docs-utils@2.0.2': @@ -14655,7 +14663,7 @@ snapshots: '@tailwindcss/oxide@4.1.13': dependencies: - detect-libc: 2.0.4 + detect-libc: 2.1.1 tar: 7.4.3 optionalDependencies: '@tailwindcss/oxide-android-arm64': 4.1.13 @@ -14938,7 +14946,7 @@ snapshots: '@typescript-eslint/types': 8.44.0 '@typescript-eslint/typescript-estree': 8.44.0(typescript@5.9.2) '@typescript-eslint/visitor-keys': 8.44.0 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) eslint: 9.35.0(jiti@2.5.1) typescript: 5.9.2 transitivePeerDependencies: @@ -14948,7 +14956,7 @@ snapshots: dependencies: '@typescript-eslint/tsconfig-utils': 8.44.0(typescript@5.9.2) '@typescript-eslint/types': 8.44.0 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) typescript: 5.9.2 transitivePeerDependencies: - supports-color @@ -14967,7 +14975,7 @@ snapshots: '@typescript-eslint/types': 8.44.0 '@typescript-eslint/typescript-estree': 8.44.0(typescript@5.9.2) '@typescript-eslint/utils': 8.44.0(eslint@9.35.0(jiti@2.5.1))(typescript@5.9.2) - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) eslint: 9.35.0(jiti@2.5.1) ts-api-utils: 2.1.0(typescript@5.9.2) typescript: 5.9.2 @@ -14982,7 +14990,7 @@ snapshots: '@typescript-eslint/tsconfig-utils': 8.44.0(typescript@5.9.2) '@typescript-eslint/types': 8.44.0 '@typescript-eslint/visitor-keys': 8.44.0 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) fast-glob: 3.3.3 is-glob: 4.0.3 minimatch: 9.0.5 @@ -15122,7 +15130,7 @@ snapshots: '@vitest/coverage-istanbul@3.2.4(vitest@3.2.4)': dependencies: '@istanbuljs/schema': 0.1.3 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) istanbul-lib-coverage: 3.2.2 istanbul-lib-instrument: 6.0.3 istanbul-lib-report: 3.0.1 @@ -15736,7 +15744,7 @@ snapshots: dependencies: bytes: 3.1.2 content-type: 1.0.5 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) http-errors: 2.0.0 iconv-lite: 0.6.3 on-finished: 2.4.1 @@ -16060,11 +16068,6 @@ snapshots: color-convert: 1.9.3 color-string: 1.9.1 - color@4.2.3: - dependencies: - color-convert: 2.0.1 - color-string: 1.9.1 - colord@2.9.3: {} colorspace@1.1.4: @@ -16355,7 +16358,7 @@ snapshots: dependencies: ms: 2.1.3 - debug@4.4.1(supports-color@8.1.1): + debug@4.4.3(supports-color@8.1.1): dependencies: ms: 2.1.3 optionalDependencies: @@ -16422,7 +16425,7 @@ snapshots: detect-indent@5.0.0: {} - detect-libc@2.0.4: {} + detect-libc@2.1.1: {} detect-node-es@1.1.0: {} @@ -16794,7 +16797,7 @@ snapshots: eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)): dependencies: - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) eslint: 9.35.0(jiti@2.5.1) eslint-import-context: 0.1.9(unrs-resolver@1.11.1) get-tsconfig: 4.10.1 @@ -16803,7 +16806,7 @@ snapshots: tinyglobby: 0.2.15 unrs-resolver: 1.11.1 optionalDependencies: - eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4)(eslint@9.35.0(jiti@2.5.1)) + eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)) transitivePeerDependencies: - supports-color @@ -16817,7 +16820,7 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-plugin-import@2.32.0(eslint-import-resolver-typescript@4.4.4)(eslint@9.35.0(jiti@2.5.1)): + eslint-plugin-import@2.32.0(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)): dependencies: '@rtsao/scc': 1.1.0 array-includes: 3.1.9 @@ -16964,7 +16967,7 @@ snapshots: ajv: 6.12.6 chalk: 4.1.2 cross-spawn: 7.0.6 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) escape-string-regexp: 4.0.0 eslint-scope: 8.4.0 eslint-visitor-keys: 4.2.1 @@ -17122,7 +17125,7 @@ snapshots: content-type: 1.0.5 cookie: 0.7.2 cookie-signature: 1.2.2 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) encodeurl: 2.0.0 escape-html: 1.0.3 etag: 1.8.1 @@ -17150,7 +17153,7 @@ snapshots: extract-zip@2.0.1: dependencies: - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) get-stream: 5.2.0 yauzl: 2.10.0 optionalDependencies: @@ -17242,7 +17245,7 @@ snapshots: finalhandler@2.1.0: dependencies: - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) encodeurl: 2.0.0 escape-html: 1.0.3 on-finished: 2.4.1 @@ -17798,14 +17801,14 @@ snapshots: http-proxy-agent@7.0.2: dependencies: agent-base: 7.1.4 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) transitivePeerDependencies: - supports-color https-proxy-agent@7.0.6: dependencies: agent-base: 7.1.4 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) transitivePeerDependencies: - supports-color @@ -18153,7 +18156,7 @@ snapshots: istanbul-lib-source-maps@5.0.6: dependencies: '@jridgewell/trace-mapping': 0.3.30 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) istanbul-lib-coverage: 3.2.2 transitivePeerDependencies: - supports-color @@ -18521,7 +18524,7 @@ snapshots: lightningcss@1.30.1: dependencies: - detect-libc: 2.0.4 + detect-libc: 2.1.1 optionalDependencies: lightningcss-darwin-arm64: 1.30.1 lightningcss-darwin-x64: 1.30.1 @@ -18582,8 +18585,6 @@ snapshots: dependencies: p-locate: 6.0.0 - lodash-es@4.17.21: {} - lodash.clonedeep@4.5.0: {} lodash.debounce@4.0.8: {} @@ -19238,7 +19239,7 @@ snapshots: micromark@4.0.2: dependencies: '@types/debug': 4.1.12 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) decode-named-character-reference: 1.2.0 devlop: 1.1.0 micromark-core-commonmark: 2.0.3 @@ -19377,7 +19378,7 @@ snapshots: dependencies: browser-stdout: 1.3.1 chokidar: 4.0.3 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) diff: 7.0.0 escape-string-regexp: 4.0.0 find-up: 5.0.0 @@ -19480,7 +19481,7 @@ snapshots: '@next/swc-win32-arm64-msvc': 15.5.3 '@next/swc-win32-x64-msvc': 15.5.3 '@playwright/test': 1.55.1 - sharp: 0.34.3 + sharp: 0.34.4 transitivePeerDependencies: - '@babel/core' - babel-plugin-macros @@ -20635,6 +20636,15 @@ snapshots: dependencies: regex-utilities: 2.3.0 + regexp.escape@2.0.1: + dependencies: + call-bind: 1.0.8 + define-properties: 1.2.1 + es-abstract: 1.24.0 + es-errors: 1.3.0 + for-each: 0.3.5 + safe-regex-test: 1.1.0 + regexp.prototype.flags@1.5.4: dependencies: call-bind: 1.0.8 @@ -20866,7 +20876,7 @@ snapshots: router@2.2.0: dependencies: - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) depd: 2.0.0 is-promise: 4.0.0 parseurl: 1.3.3 @@ -20942,7 +20952,7 @@ snapshots: send@1.2.0: dependencies: - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) encodeurl: 2.0.0 escape-html: 1.0.3 etag: 1.8.1 @@ -21029,34 +21039,34 @@ snapshots: dependencies: kind-of: 6.0.3 - sharp@0.34.3: + sharp@0.34.4: dependencies: - color: 4.2.3 - detect-libc: 2.0.4 + '@img/colour': 1.0.0 + detect-libc: 2.1.1 semver: 7.7.2 optionalDependencies: - '@img/sharp-darwin-arm64': 0.34.3 - '@img/sharp-darwin-x64': 0.34.3 - '@img/sharp-libvips-darwin-arm64': 1.2.0 - '@img/sharp-libvips-darwin-x64': 1.2.0 - '@img/sharp-libvips-linux-arm': 1.2.0 - '@img/sharp-libvips-linux-arm64': 1.2.0 - '@img/sharp-libvips-linux-ppc64': 1.2.0 - '@img/sharp-libvips-linux-s390x': 1.2.0 - '@img/sharp-libvips-linux-x64': 1.2.0 - '@img/sharp-libvips-linuxmusl-arm64': 1.2.0 - '@img/sharp-libvips-linuxmusl-x64': 1.2.0 - '@img/sharp-linux-arm': 0.34.3 - '@img/sharp-linux-arm64': 0.34.3 - '@img/sharp-linux-ppc64': 0.34.3 - '@img/sharp-linux-s390x': 0.34.3 - '@img/sharp-linux-x64': 0.34.3 - '@img/sharp-linuxmusl-arm64': 0.34.3 - '@img/sharp-linuxmusl-x64': 0.34.3 - '@img/sharp-wasm32': 0.34.3 - '@img/sharp-win32-arm64': 0.34.3 - '@img/sharp-win32-ia32': 0.34.3 - '@img/sharp-win32-x64': 0.34.3 + '@img/sharp-darwin-arm64': 0.34.4 + '@img/sharp-darwin-x64': 0.34.4 + '@img/sharp-libvips-darwin-arm64': 1.2.3 + '@img/sharp-libvips-darwin-x64': 1.2.3 + '@img/sharp-libvips-linux-arm': 1.2.3 + '@img/sharp-libvips-linux-arm64': 1.2.3 + '@img/sharp-libvips-linux-ppc64': 1.2.3 + '@img/sharp-libvips-linux-s390x': 1.2.3 + '@img/sharp-libvips-linux-x64': 1.2.3 + '@img/sharp-libvips-linuxmusl-arm64': 1.2.3 + '@img/sharp-libvips-linuxmusl-x64': 1.2.3 + '@img/sharp-linux-arm': 0.34.4 + '@img/sharp-linux-arm64': 0.34.4 + '@img/sharp-linux-ppc64': 0.34.4 + '@img/sharp-linux-s390x': 0.34.4 + '@img/sharp-linux-x64': 0.34.4 + '@img/sharp-linuxmusl-arm64': 0.34.4 + '@img/sharp-linuxmusl-x64': 0.34.4 + '@img/sharp-wasm32': 0.34.4 + '@img/sharp-win32-arm64': 0.34.4 + '@img/sharp-win32-ia32': 0.34.4 + '@img/sharp-win32-x64': 0.34.4 shebang-command@2.0.0: dependencies: @@ -21167,7 +21177,7 @@ snapshots: socks-proxy-agent@8.0.5: dependencies: agent-base: 7.1.4 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) socks: 2.8.7 transitivePeerDependencies: - supports-color @@ -21400,7 +21410,7 @@ snapshots: cosmiconfig: 9.0.0(typescript@5.9.2) css-functions-list: 3.2.3 css-tree: 3.1.0 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) fast-glob: 3.3.3 fastest-levenshtein: 1.0.16 file-entry-cache: 10.1.4 @@ -21652,7 +21662,7 @@ snapshots: tuf-js@2.2.1: dependencies: '@tufjs/models': 2.0.1 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) make-fetch-happen: 13.0.1 transitivePeerDependencies: - supports-color @@ -21963,7 +21973,7 @@ snapshots: vite-node@3.2.4(@types/node@22.18.6)(jiti@2.5.1)(lightningcss@1.30.1)(terser@5.44.0)(tsx@4.20.5)(yaml@2.8.1): dependencies: cac: 6.7.14 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) es-module-lexer: 1.7.0 pathe: 2.0.3 vite: 7.1.5(@types/node@22.18.6)(jiti@2.5.1)(lightningcss@1.30.1)(terser@5.44.0)(tsx@4.20.5)(yaml@2.8.1) @@ -22019,7 +22029,7 @@ snapshots: '@vitest/spy': 3.2.4 '@vitest/utils': 3.2.4 chai: 5.3.3 - debug: 4.4.1(supports-color@8.1.1) + debug: 4.4.3(supports-color@8.1.1) expect-type: 1.2.2 magic-string: 0.30.18 pathe: 2.0.3 From 4e4f10c58b0a959d6a3a99bfdf0f2191cf921fba Mon Sep 17 00:00:00 2001 From: Janpot <2109932+Janpot@users.noreply.github.com> Date: Tue, 30 Sep 2025 11:53:54 +0200 Subject: [PATCH 2/8] Add docs --- docs/README.md | 17 ++++++++ .../(content)/production-error/ErrorCode.tsx | 14 +++++++ .../production-error/ErrorDisplay.tsx | 42 +++++++++++++++++++ .../(content)/production-error/page.mdx | 16 +++++++ docs/types.d.ts | 5 +++ 5 files changed, 94 insertions(+) create mode 100644 docs/src/app/(public)/(content)/production-error/ErrorCode.tsx create mode 100644 docs/src/app/(public)/(content)/production-error/ErrorDisplay.tsx create mode 100644 docs/src/app/(public)/(content)/production-error/page.mdx diff --git a/docs/README.md b/docs/README.md index c0f3f713f9b..9b48e080258 100644 --- a/docs/README.md +++ b/docs/README.md @@ -16,3 +16,20 @@ Package managers other than pnpm (like npm or Yarn) are not supported and will n [You can follow this guide](https://github.com/mui/base-ui/blob/HEAD/CONTRIBUTING.md) on how to get started contributing to Base UI. + +## Error code extraction + +Errors in production are minified. They are extracted out of the source code by running the command + +```bash +pnpm extract-error-codes +``` + +This updates the `./src/error-codes.json` file with the newly extracted errors. + +Important: If you just altered the text of an error, you are allowed to update the existing error code with the new text in `./src/error-codes.json`, but only under the following conditions: + +1. There hasn't been an update to the semantic meaning of the error message. Error codes need to outlive Base UI versions, so the same code must mean the same thing across versions. +2. There hasn't been a change in parameters, no added and no removed. + +In both of those cases, always create a new error code lline in `./src/error-codes.json`. diff --git a/docs/src/app/(public)/(content)/production-error/ErrorCode.tsx b/docs/src/app/(public)/(content)/production-error/ErrorCode.tsx new file mode 100644 index 00000000000..bc20820eb0f --- /dev/null +++ b/docs/src/app/(public)/(content)/production-error/ErrorCode.tsx @@ -0,0 +1,14 @@ +'use client'; +import { useSearchParams } from 'next/navigation'; + +export interface ErrorDisplayProps { + msg: string; +} + +/** + * Client component that interpolates arguments in an error message. Must be + * a client component because it reads the search params. + */ +export default function ErrorDisplay() { + return useSearchParams().get('code') ?? ''; +} diff --git a/docs/src/app/(public)/(content)/production-error/ErrorDisplay.tsx b/docs/src/app/(public)/(content)/production-error/ErrorDisplay.tsx new file mode 100644 index 00000000000..5b1d144bcf0 --- /dev/null +++ b/docs/src/app/(public)/(content)/production-error/ErrorDisplay.tsx @@ -0,0 +1,42 @@ +'use client'; +import * as React from 'react'; +import { useSearchParams } from 'next/navigation'; +import codes from 'docs/src/error-codes.json'; + +export interface ErrorDisplayProps { + msg: string; +} + +function ErrorMessageWithArgs({ msg }: ErrorDisplayProps) { + const searchParams = useSearchParams(); + return React.useMemo(() => { + const args = searchParams.getAll('args[]'); + let index = 0; + return msg.replace(/%s/g, () => { + const replacement = args[index]; + index += 1; + return replacement === undefined ? '[missing argument]' : replacement; + }); + }, [msg, searchParams]); +} + +/** + * Client component that interpolates arguments in an error message. Must be + * a client component because it reads the search params. + */ +export default function ErrorDisplay() { + const code = useSearchParams().get('code'); + const msg = + (code ? (codes as Partial>)[code ?? ''] : null) ?? + `Unknown error code: ${code}`; + + const fallbackMsg = React.useMemo(() => msg.replace(/%s/g, '…'), [msg]); + + return ( + + + + + + ); +} diff --git a/docs/src/app/(public)/(content)/production-error/page.mdx b/docs/src/app/(public)/(content)/production-error/page.mdx new file mode 100644 index 00000000000..76278cf350c --- /dev/null +++ b/docs/src/app/(public)/(content)/production-error/page.mdx @@ -0,0 +1,16 @@ +import ErrorCode from './ErrorCode'; +import ErrorDisplay from './ErrorDisplay'; + +# Production error # + +Explanation for minified production error message. + + +A minified Base UI error occurred in the production build of React. + +The full error message: + + diff --git a/docs/types.d.ts b/docs/types.d.ts index 1898b0b8bd5..24af70452fe 100644 --- a/docs/types.d.ts +++ b/docs/types.d.ts @@ -2,3 +2,8 @@ declare module 'gtag.js'; declare module '@mui/monorepo/docs/nextConfigDocsInfra.js'; + +declare module '*.mdx' { + const MDXComponent: (props) => JSX.Element; + export default MDXComponent; +} From 81c053be2f3840e5aac18be05a613543e1b64576 Mon Sep 17 00:00:00 2001 From: Janpot <2109932+Janpot@users.noreply.github.com> Date: Tue, 30 Sep 2025 11:57:37 +0200 Subject: [PATCH 3/8] Update ErrorCode.tsx --- .../(content)/production-error/ErrorCode.tsx | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/docs/src/app/(public)/(content)/production-error/ErrorCode.tsx b/docs/src/app/(public)/(content)/production-error/ErrorCode.tsx index bc20820eb0f..d934fc68d75 100644 --- a/docs/src/app/(public)/(content)/production-error/ErrorCode.tsx +++ b/docs/src/app/(public)/(content)/production-error/ErrorCode.tsx @@ -1,14 +1,23 @@ 'use client'; +import * as React from 'react'; import { useSearchParams } from 'next/navigation'; export interface ErrorDisplayProps { msg: string; } +function ErrorCodeContent() { + return useSearchParams().get('code') ?? ''; +} + /** * Client component that interpolates arguments in an error message. Must be * a client component because it reads the search params. */ -export default function ErrorDisplay() { - return useSearchParams().get('code') ?? ''; +export default function ErrorCode() { + return ( + + + + ); } From 3505a82e4e2f1aa23e0d8c71d4accc8858aefbbd Mon Sep 17 00:00:00 2001 From: Janpot <2109932+Janpot@users.noreply.github.com> Date: Tue, 30 Sep 2025 12:01:02 +0200 Subject: [PATCH 4/8] Update pnpm-lock.yaml --- pnpm-lock.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index abd1012ed99..3e572532372 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -12542,7 +12542,7 @@ snapshots: eslint-config-prettier: 10.1.8(eslint@9.35.0(jiti@2.5.1)) eslint-import-resolver-typescript: 4.4.4(eslint-plugin-import@2.32.0(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)) eslint-module-utils: 2.12.1(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)) - eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)) + eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4)(eslint@9.35.0(jiti@2.5.1)) eslint-plugin-jsx-a11y: 6.10.2(eslint@9.35.0(jiti@2.5.1)) eslint-plugin-mocha: 11.1.0(eslint@9.35.0(jiti@2.5.1)) eslint-plugin-react: 7.37.5(eslint@9.35.0(jiti@2.5.1)) @@ -16806,7 +16806,7 @@ snapshots: tinyglobby: 0.2.15 unrs-resolver: 1.11.1 optionalDependencies: - eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)) + eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4)(eslint@9.35.0(jiti@2.5.1)) transitivePeerDependencies: - supports-color @@ -16820,7 +16820,7 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-plugin-import@2.32.0(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)))(eslint@9.35.0(jiti@2.5.1)): + eslint-plugin-import@2.32.0(eslint-import-resolver-typescript@4.4.4)(eslint@9.35.0(jiti@2.5.1)): dependencies: '@rtsao/scc': 1.1.0 array-includes: 3.1.9 From 6308dd28c26ea4a33e54b529a54f8beaa14d1f8b Mon Sep 17 00:00:00 2001 From: Janpot <2109932+Janpot@users.noreply.github.com> Date: Tue, 30 Sep 2025 12:07:13 +0200 Subject: [PATCH 5/8] Update ErrorDisplay.tsx --- .../production-error/ErrorDisplay.tsx | 24 +++++++------------ 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/docs/src/app/(public)/(content)/production-error/ErrorDisplay.tsx b/docs/src/app/(public)/(content)/production-error/ErrorDisplay.tsx index 5b1d144bcf0..227ce513a8e 100644 --- a/docs/src/app/(public)/(content)/production-error/ErrorDisplay.tsx +++ b/docs/src/app/(public)/(content)/production-error/ErrorDisplay.tsx @@ -3,13 +3,14 @@ import * as React from 'react'; import { useSearchParams } from 'next/navigation'; import codes from 'docs/src/error-codes.json'; -export interface ErrorDisplayProps { - msg: string; -} - -function ErrorMessageWithArgs({ msg }: ErrorDisplayProps) { +function ErrorMessageWithArgs() { const searchParams = useSearchParams(); + return React.useMemo(() => { + const code = searchParams.get('code'); + const msg = + (code ? (codes as Partial>)[code ?? ''] : null) ?? + `Unknown error code: ${code}`; const args = searchParams.getAll('args[]'); let index = 0; return msg.replace(/%s/g, () => { @@ -17,7 +18,7 @@ function ErrorMessageWithArgs({ msg }: ErrorDisplayProps) { index += 1; return replacement === undefined ? '[missing argument]' : replacement; }); - }, [msg, searchParams]); + }, [searchParams]); } /** @@ -25,17 +26,10 @@ function ErrorMessageWithArgs({ msg }: ErrorDisplayProps) { * a client component because it reads the search params. */ export default function ErrorDisplay() { - const code = useSearchParams().get('code'); - const msg = - (code ? (codes as Partial>)[code ?? ''] : null) ?? - `Unknown error code: ${code}`; - - const fallbackMsg = React.useMemo(() => msg.replace(/%s/g, '…'), [msg]); - return ( - - + + ); From 885dbb968630b41d1d1783f05a59d9dfbcfb3723 Mon Sep 17 00:00:00 2001 From: Janpot <2109932+Janpot@users.noreply.github.com> Date: Tue, 30 Sep 2025 16:24:04 +0200 Subject: [PATCH 6/8] Update reportBrokenLinks.mts --- docs/scripts/reportBrokenLinks.mts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/scripts/reportBrokenLinks.mts b/docs/scripts/reportBrokenLinks.mts index c4df837563d..74ddfbc2621 100644 --- a/docs/scripts/reportBrokenLinks.mts +++ b/docs/scripts/reportBrokenLinks.mts @@ -1,6 +1,6 @@ /* eslint-disable no-console */ import path from 'node:path'; -import { fileURLToPath } from 'node:url'; +import { fileURLToPath, pathToFileURL } from 'node:url'; import { readFile, writeFile } from 'node:fs/promises'; import { globby } from 'globby'; import * as jsxRuntime from 'react/jsx-runtime'; @@ -108,6 +108,7 @@ async function getLinksAndAnchors( const { tableOfContents } = await evaluate(mdxSource, { ...jsxRuntime, + baseUrl: pathToFileURL(filePath), remarkPlugins: [remarkGfm], rehypePlugins: [ rehypeReference, From 52d715e3c4d6f3fe3c5c28282368f531e25a592a Mon Sep 17 00:00:00 2001 From: Janpot <2109932+Janpot@users.noreply.github.com> Date: Tue, 30 Sep 2025 16:44:12 +0200 Subject: [PATCH 7/8] Update .markdownlint-cli2.mjs --- .markdownlint-cli2.mjs | 1 + 1 file changed, 1 insertion(+) diff --git a/.markdownlint-cli2.mjs b/.markdownlint-cli2.mjs index 4d5f8f3805a..c833a8dbc72 100644 --- a/.markdownlint-cli2.mjs +++ b/.markdownlint-cli2.mjs @@ -7,5 +7,6 @@ export default { config: { ...baseline.config, MD038: false, // false positives in MDX + MD041: false, // false positives in MDX }, }; From 4e1c9869c51a1e3decd399d9560b7895d365f6b2 Mon Sep 17 00:00:00 2001 From: Brijesh Bittu <717550+brijeshb42@users.noreply.github.com> Date: Fri, 10 Oct 2025 14:26:41 +0530 Subject: [PATCH 8/8] Update error-codes file --- docs/src/error-codes.json | 6 +++++- pnpm-lock.yaml | 6 +++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/docs/src/error-codes.json b/docs/src/error-codes.json index 86c074aae95..b8b7a798604 100644 --- a/docs/src/error-codes.json +++ b/docs/src/error-codes.json @@ -70,5 +70,9 @@ "69": "Base UI: ToolbarRootContext is missing. Toolbar parts must be placed within .", "70": "Base UI: is missing.", "71": "Base UI: TooltipPositionerContext is missing. TooltipPositioner parts must be placed within .", - "72": "Base UI: TooltipRootContext is missing. Tooltip parts must be placed within ." + "72": "Base UI: TooltipRootContext is missing. Tooltip parts must be placed within .", + "73": "Base UI: useToastManager must be used within .", + "74": "Base UI: PopoverTrigger must be either used within a PopoverRoot component or have the `handle` prop set.", + "75": "Base UI: PopoverTrigger must have an `id` prop specified.", + "76": "Base UI: selectors are required to call useState." } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index de920a701ea..453a8eaa7d0 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -12736,7 +12736,7 @@ snapshots: eslint-config-prettier: 10.1.8(eslint@9.37.0(jiti@2.6.1)) eslint-import-resolver-typescript: 4.4.4(eslint-plugin-import@2.32.0(eslint@9.37.0(jiti@2.6.1)))(eslint@9.37.0(jiti@2.6.1)) eslint-module-utils: 2.12.1(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.37.0(jiti@2.6.1)))(eslint@9.37.0(jiti@2.6.1)))(eslint@9.37.0(jiti@2.6.1)) - eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.37.0(jiti@2.6.1)))(eslint@9.37.0(jiti@2.6.1)))(eslint@9.37.0(jiti@2.6.1)) + eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4)(eslint@9.37.0(jiti@2.6.1)) eslint-plugin-jsx-a11y: 6.10.2(eslint@9.37.0(jiti@2.6.1)) eslint-plugin-mocha: 11.2.0(eslint@9.37.0(jiti@2.6.1)) eslint-plugin-react: 7.37.5(eslint@9.37.0(jiti@2.6.1)) @@ -17032,7 +17032,7 @@ snapshots: tinyglobby: 0.2.15 unrs-resolver: 1.11.1 optionalDependencies: - eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.37.0(jiti@2.6.1)))(eslint@9.37.0(jiti@2.6.1)))(eslint@9.37.0(jiti@2.6.1)) + eslint-plugin-import: 2.32.0(eslint-import-resolver-typescript@4.4.4)(eslint@9.37.0(jiti@2.6.1)) transitivePeerDependencies: - supports-color @@ -17046,7 +17046,7 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-plugin-import@2.32.0(eslint-import-resolver-typescript@4.4.4(eslint-plugin-import@2.32.0(eslint@9.37.0(jiti@2.6.1)))(eslint@9.37.0(jiti@2.6.1)))(eslint@9.37.0(jiti@2.6.1)): + eslint-plugin-import@2.32.0(eslint-import-resolver-typescript@4.4.4)(eslint@9.37.0(jiti@2.6.1)): dependencies: '@rtsao/scc': 1.1.0 array-includes: 3.1.9