From eab59be7825f96a09b7af3a368a1c7f283ae8673 Mon Sep 17 00:00:00 2001 From: Marija Najdova Date: Tue, 19 Nov 2024 10:49:47 +0100 Subject: [PATCH] [styled-engine] Add back removed internal function (#44421) --- packages/mui-styled-engine-sc/src/index.d.ts | 8 ++++++++ packages/mui-styled-engine-sc/src/index.js | 7 +++++++ 2 files changed, 15 insertions(+) diff --git a/packages/mui-styled-engine-sc/src/index.d.ts b/packages/mui-styled-engine-sc/src/index.d.ts index 9b1de0cdb5b650..594f7b84acddc2 100644 --- a/packages/mui-styled-engine-sc/src/index.d.ts +++ b/packages/mui-styled-engine-sc/src/index.d.ts @@ -81,6 +81,14 @@ export function internal_mutateStyles( processor: (styles: any) => any, ): void; +// Not needed anymore, but fixes https://github.com/mui/material-ui/issues/44112 +// TODO: Remove it in v7 +// eslint-disable-next-line @typescript-eslint/naming-convention +export function internal_processStyles( + tag: React.ElementType, + processor: (styles: any) => any, +): void; + // eslint-disable-next-line @typescript-eslint/naming-convention export function internal_serializeStyles

(styles: Interpolation

): object; diff --git a/packages/mui-styled-engine-sc/src/index.js b/packages/mui-styled-engine-sc/src/index.js index 435e22b95d07e4..ef12d36e310751 100644 --- a/packages/mui-styled-engine-sc/src/index.js +++ b/packages/mui-styled-engine-sc/src/index.js @@ -48,6 +48,13 @@ export function internal_mutateStyles(tag, processor) { } } +// Not needed anymore, but fixes https://github.com/mui/material-ui/issues/44112 +// TODO: Remove it in v7 +// eslint-disable-next-line @typescript-eslint/naming-convention +export function internal_processStyles(tag, processor) { + return internal_mutateStyles(tag, processor); +} + // eslint-disable-next-line @typescript-eslint/naming-convention export function internal_serializeStyles(styles) { return styles;