After upgrading to Mantine v7, our Storybook will no longer build. The build fails with the following errors:
✘ [ERROR] No matching export in "global-externals:react" for import "useId"
node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected][email protected][email protected]/node_modules/@mantine/core/esm/core/Box/use-random-classname/use-random-classname.mjs:2:9:
2 │ import { useId } from 'react';
╵ ~~~~~
✘ [ERROR] No matching export in "global-externals:react" for import "useId"
node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected][email protected][email protected]/node_modules/@mantine/core/esm/components/Combobox/ComboboxOption/ComboboxOption.mjs:2:16:
2 │ import React, { useId } from 'react';
╵ ~~~~~
✘ [ERROR] No matching export in "global-externals:react" for import "useSyncExternalStore"
node_modules/.pnpm/@[email protected][email protected]/node_modules/@mantine/store/esm/store.mjs:2:9:
2 │ import { useSyncExternalStore } from 'react';
╵ ~~~~~~~~~~~~~~~~~~~~
Error: Build failed with 3 errors:
node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected][email protected][email protected]/node_modules/@mantine/core/esm/components/Combobox/ComboboxOption/ComboboxOption.mjs:2:16: ERROR: No matching export in "global-externals:react" for import "useId"
node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected][email protected][email protected]/node_modules/@mantine/core/esm/core/Box/use-random-classname/use-random-classname.mjs:2:9: ERROR: No matching export in "global-externals:react" for import "useId"
node_modules/.pnpm/@[email protected][email protected]/node_modules/@mantine/store/esm/store.mjs:2:9: ERROR: No matching export in "global-externals:react" for import "useSyncExternalStore"
I've tried replacing our preview.tsx with the example here: https://v7.mantine.dev/guides/storybook#storybook-preview but no luck.