Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[core] Fix missing CSSProperties/MixinOptions types #45706

Merged
merged 4 commits into from
Mar 28, 2025

Conversation

Janpot
Copy link
Member

@Janpot Janpot commented Mar 27, 2025

Fixes #45703
Fixes #45713

Also noticed several imports that should be relative.

I'm sure there will be others reported the coming days

@Janpot Janpot added the core Infrastructure work going on behind the scenes label Mar 27, 2025
@@ -27,28 +28,6 @@ export interface FontStyle {
htmlFontSize: number;
}

export type NormalCssProperties = CSS.Properties<number | string>;
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mui/core Am I right in thinking this shouldn't be duplicated?

Copy link
Member

@DiegoAndai DiegoAndai Mar 27, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems to me that it shouldn't be duplicated. I don't have the context as to why it is duplicated in the first place.

@mnajdova do you know?

For reference, the duplication is here: https://github.com/mui/material-ui/blob/51663eba0e020daa6b494c31391560f0dd107489/packages/mui-material/src/styles/createMixins.d.ts

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tl;dr yes, it should be safe for these to be removed

From what I remember these were initially copied from @mui/styles to make the JSS <-> Emotion interoperability work. They may have been accidently copied in two locations, so it's safe to be removed from here. Eventually we could likely drop these, especially now that the @mui/styles package is deprecated.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@mui-bot
Copy link

mui-bot commented Mar 27, 2025

Netlify deploy preview

https://deploy-preview-45706--material-ui.netlify.app/

Bundle size report

Details of bundle changes (Toolpad)
Details of bundle changes

Generated by 🚫 dangerJS against 106d5f0

@aarongarciah aarongarciah requested a review from Copilot March 27, 2025 11:30
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This pull request fixes the missing CSSProperties type issue and updates import statements to use relative paths for unstable_useId.

  • Updated unstable_useId import in IconButton from '@mui/material/utils' to '../utils'.
  • Updated unstable_useId import in Button from '@mui/material/utils' to '../utils'.

Reviewed Changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.

File Description
packages/mui-material/src/IconButton/IconButton.js Changed unstable_useId import to a relative path.
packages/mui-material/src/Button/Button.js Changed unstable_useId import to a relative path.

@Janpot Janpot marked this pull request as ready for review March 27, 2025 18:40
@Janpot Janpot changed the title [core] Fix missing CSSProperties type [core] Fix missing CSSProperties/MixinOptions types Mar 27, 2025
@DiegoAndai DiegoAndai merged commit 383c813 into mui:master Mar 28, 2025
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Infrastructure work going on behind the scenes
Projects
None yet
5 participants