Skip to content

chore: upgrade MUI to v9 and Storybook to v10#370

Open
braianj wants to merge 7 commits into
masterfrom
feat/upgrade-mui-and-storybook
Open

chore: upgrade MUI to v9 and Storybook to v10#370
braianj wants to merge 7 commits into
masterfrom
feat/upgrade-mui-and-storybook

Conversation

@braianj

@braianj braianj commented Jan 16, 2026

Copy link
Copy Markdown
Collaborator
  • Upgrade MUI from 5.16 to 9.1.0 (peer dependency with ^9.1.0 range; v8 was skipped upstream)
  • Upgrade Storybook from 7.6 to 10.4.3 and update addons/config for the new addon set
  • Migrate theme system to MUI createTheme with CSS variables (colorSchemes light/dark, colorSchemeSelector: data); light/dark now share a single theme and mode is controlled via defaultMode/useColorScheme
  • Migrate MUI 9 breaking changes: removed system props moved to sx (Banner, SceneRow, Button/DownloadButton/SceneCard stories), MenuListProps -> slotProps.list (LanguageDropdown)
  • Remove Hidden and Unstable_Grid2 re-exports (deleted in MUI 7+)
  • Set moduleResolution: bundler in tsconfig so Storybook 10 type exports resolve
  • Fix stories typings for Storybook 10 (satisfies Meta, defaultValue.summary as string) and drop the custom docs page in Atlas stories (the addon-docs/blocks import broke the preview chunk; autodocs covers it)
  • Export missing components (AssetImage, Atlas) and add dclButton namespace
  • Merge latest master (60 commits, including the new navbar and DownloadModal)

Verified: tsc build, unit tests, lint, package.json lint and build-storybook all green. All 331 stories render without errors in both light and dark modes, including interactive flows (navbar submenus, user menu panel, download modals, Atlas tile map).

- Upgrade Storybook to 9.0.18 and update addons/config
- Upgrade MUI to 7.3.7 and remove deep imports / deprecated entrypoints
- Fix stories typings for SB9 (blocks, ArgTypes, defaultValue summaries)
- Fix build/test configs (ignore dist tests in Jest)
- Export missing components (AssetImage, Atlas) and add dclButton namespace
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jan 16, 2026

Copy link
Copy Markdown

Deploying ui2 with  Cloudflare Pages  Cloudflare Pages

Latest commit: 0bae546
Status: ✅  Deploy successful!
Preview URL: https://e640f61e.ui2-423.pages.dev
Branch Preview URL: https://feat-upgrade-mui-and-storybo.ui2-423.pages.dev

View logs

- Replace extendTheme with createTheme({ cssVariables: true, colorSchemes })
- Update ThemeProvider from CssVarsProvider to MuiThemeProvider
- Update Storybook preview to use useColorScheme hook for theme switching
- Migrate styled imports from @emotion/styled to @mui/material
- Add shouldForwardProp to prevent custom props from reaching DOM
- Add color fallbacks for RarityBadge when theme.palette.rarities is undefined
@braianj braianj changed the title chore: upgrade MUI to v7 and Storybook to v9 chore: upgrade MUI to v7 and Storybook to v10 Jan 20, 2026
Comment thread src/components/Navbar/Navbar.styled.ts Outdated
Comment thread src/components/Navbar/MainMenu/MainMenu.styled.tsx Outdated
braianj added 2 commits June 10, 2026 14:42
…d-storybook

# Conflicts:
#	.storybook/main.ts
#	.storybook/preview.ts
#	jest.config.js
#	package-lock.json
#	package.json
#	src/components/Atlas/Atlas.stories.tsx
#	src/components/Blockie/Blockie.styled.ts
#	src/components/Blockie/Blockie.tsx
#	src/components/CatalogCard/CatalogCard.styled.ts
#	src/components/JumpIn/JumpIn.stories.tsx
#	src/components/Modal/DownloadModal/DownloadModal.stories.tsx
#	src/components/Modal/DownloadModal/index.ts
#	src/components/Modal/index.ts
#	src/components/Navbar/MainMenu/MainMenu.styled.tsx
#	src/components/Navbar/Navbar.styled.ts
#	src/components/Navbar/SubMenu/SubMenu.styled.ts
#	src/components/Profile/Profile.styled.ts
#	src/components/RarityBadge/RarityBadge.stories.tsx
#	src/components/RarityBadge/RarityBadge.styled.ts
#	src/components/UserMenu/UserMenu.styled.tsx
#	src/components/WearablePreview/AnimationControls/AnimationControls.styled.ts
#	src/index.ts
#	src/theme/index.ts
#	src/theme/provider.tsx
- @mui/material and @mui/icons-material 7.3.7 -> 9.1.0 (v8 was skipped upstream)
- storybook packages 10.1.11 -> 10.4.3
- migrate removed system props (display, gap, textAlign, fontWeight, fontSize) to sx
- Menu MenuListProps -> slotProps.list
- drop custom docs page in Atlas stories (addon-docs/blocks import broke the preview chunk; autodocs covers it)
@braianj braianj changed the title chore: upgrade MUI to v7 and Storybook to v10 chore: upgrade MUI to v9 and Storybook to v10 Jun 10, 2026
- build one theme per mode again: component overrides were receiving the
  light palette in both modes, breaking every styled component in dark
- migrate Button compound CSS classes removed in MUI 9
  (textSecondary, containedPrimary, etc.) to variant + color atomic classes
  in theme overrides, ChainSelector, FooterLanding, DownloadButton, JumpIn
  and ManaBalances
- wrap UserMenu actions in MenuList (MenuItem outside Menu/MenuList throws
  in MUI 9)
- migrate backgrounds addon config to Storybook 10 API (options + globals)
  in preview, EventSmallCard and Icons stories
- drop actions argTypesRegex: SB10 injects spies for onClose/onBack that
  made Modal render back/close buttons production does not show
- drop ScenesTable red background override that SB7 never applied

Verified by pixel-diffing all 331 stories against ui2.decentraland.org:
light 331/331 identical; dark 305/331 identical, remaining 26 are live
external content (Atlas tiles fetch, WearablePreview 3D iframe, Beehiiv
embed) re-verified identical with longer waits
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants