build: upgrade material-table to v8 - #1710
Draft
shivoomiess wants to merge 2 commits into
Draft
Conversation
shivoomiess
force-pushed
the
build/frontend-material-table-8
branch
from
August 6, 2026 08:47
4ca8a8f to
42d5454
Compare
shivoomiess
force-pushed
the
build/frontend-material-table-8
branch
from
August 6, 2026 09:20
42d5454 to
2bce325
Compare
shivoomiess
force-pushed
the
build/frontend-material-table-8
branch
from
August 6, 2026 11:41
2bce325 to
1b76c81
Compare
The exact `6.4.4` pin existed because the package was built against MUI v5 and could not be moved without moving MUI. v8 targets `@mui/material ^9.2.0`, `@mui/x-date-pickers ^9.10.0` and `@hello-pangea/dnd ^18.0.1`, all of which the earlier layers of this stack already satisfy, so the pin becomes a normal range. Removes three coupled workarounds: - **The nested MUI v5 tree.** 6.4.4 dragged in its own `@mui/material@5.18.0` and `@mui/x-date-pickers@6.20.2`, which produced the standing `@mui/system@9.2.0 deduped invalid: "^5.8.0"` peer conflict. `npm ls @mui/system` is now a single 9.2.0. - **The Vite `DeleteOutline` alias.** 6.4.4 imported an icon name removed in @mui/icons-material v9; v8 imports `DeleteOutlined` directly. - **The `@types/react` / `@types/react-dom` overrides.** Those were added in the React 19 commit purely because material-table pinned `@types/react@18.3.31` alongside ours. v8 has no `@types/react` dependency, so there is a single copy without forcing one. All 19 type errors had one cause: MUI v9 removed `inputProps` from Checkbox in favour of `slotProps.input`, and v8 types `selectionProps` / `headerSelectionProps` as MUI v9 `CheckboxProps`. The v9 prop sweep on `chore/mui-upgrade-pt1` could not reach these, because 6.4.4 typed them against MUI v5 and they silently type-checked. 22 sites migrated. Other `inputProps` uses - `min`/`max` on number inputs, and `slotProps.input.inputProps` - are untouched and still correct. Side effect worth recording: the vendor chunk drops from 4,084 kB to 3,385 kB (gzip 1,274 kB to 1,093 kB), which is the duplicated MUI v5 tree going away. Two expectations this upgrade did *not* meet, recorded so they are not assumed again: - **The `forwardRef` wrappers in `materialIcons.tsx` still have to stay.** v8's `Icons` type still declares every icon as `ForwardRefExoticComponent<any> & RefAttributes<SVGSVGElement>`, which an ordinary function component does not satisfy. - **The 5 deferred `react-hooks/exhaustive-deps` warnings are still there.** v8 did not rewrite those components. `useExpandCollapseAll` keeps working because `MaterialTable` is still `class extends React.Component` with a `dataManager` field, and rows still carry `tableData` - but it is still reaching into internals through an `any` ref, which no type will protect. `zustand` resolves to a nested 5.0.14 for material-table while reactflow keeps 4.5.2 at the top level; the two stores are independent. `tsc --noEmit`, `eslint` and `vite build` pass. Not exercised at runtime.
`npm ci` warned on every clean install:
peer react@"^16.8.0 || ^17.0.0 || ^18.0.0" from use-sync-external-store@1.2.0
node_modules/zustand/node_modules/use-sync-external-store
The chain is reactflow@11 -> @reactflow/* -> zustand -> use-sync-external-store.
zustand up to 4.5.4 pinned that dependency at exactly `1.2.0`, whose peer range
predates React 19. **zustand 4.5.6 changed the pin to the range `^1.2.2`**, and
4.5.7 is already inside reactflow's declared `^4.4.1` - the lockfile was simply
holding a stale 4.5.2. Updating within the existing range resolves
use-sync-external-store to 1.6.0, which declares React 19 support.
No `overrides` entry and no dependency migration: the range already allowed the
fix. A clean `npm ci` is now silent - zero warnings, no ERESOLVE.
Worth recording, because it is the obvious-looking fix and it is wrong:
**migrating reactflow to @xyflow/react would not have solved this.** v12.11.2
still declares `zustand ^4.4.0`, so it lands on the same 4.x line. Only
@material-table/core v8 is on zustand 5, which dropped the
use-sync-external-store dependency entirely because React has the hook built in.
The warning was cosmetic rather than a latent crash. The shim picks React's own
implementation when it exists (`React.useSyncExternalStore !== undefined ?
React.useSyncExternalStore : shim`), so on React 19 its body is dead code. That
matters because the 1.2.0 shim reads
`React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED` at module scope, which
React 19 renamed and no longer exports - had anything reached its `error()` path,
`printWarning` would have thrown on `undefined`.
Committed on this branch rather than the React 19 one, where the peer conflict
originates, because the resolution is computed against the final dependency tree
including material-table v8's zustand 5.
shivoomiess
force-pushed
the
build/frontend-material-table-8
branch
from
August 10, 2026 12:22
1b76c81 to
79c511d
Compare
yoganandaness
marked this pull request as ready for review
August 21, 2026 08:29
yoganandaness
requested review from
ellen-wright
and removed request for
a team
August 21, 2026 08:29
yoganandaness
approved these changes
Aug 21, 2026
This was referenced Aug 25, 2026
shivoomiess
marked this pull request as draft
August 25, 2026 20:46
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This pull request upgrades the
@material-table/corepackage from version 6.4.4 to 8.0.3 in our frontend application.Motivation and Context
This upgrade is required to keep our dependencies up-to-date, ensure we benefit from the latest features, improvements, and bug fixes provided by the package. It also helps in maintaining the overall health and security of our codebase.
Changes
@material-table/coreversion inpackage-lock.jsonhas been updated to^8.0.3.@material-table/core.@material-table/corepackage.These changes have been thoroughly tested to ensure that they do not introduce any breaking changes or negatively impact the functionality of our application.
How Has This Been Tested?
Fixes Jira Issue
https://jira.ess.eu//browse/
Depends On
Tests included/Docs Updated?