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

feat: adapt to pre-processed styles #243

Merged
merged 2 commits into from
Sep 19, 2024

Conversation

romgrk
Copy link
Contributor

@romgrk romgrk commented Sep 18, 2024

Adapt to pre-processed styles to match mui/material-ui#43412

@@ -619,7 +619,11 @@ export class StyledProcessor extends BaseProcessor {
})),
);
}
delete styleObj.variants;
if (styleObj.isProcessed) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Should this check instead be for the presence of the key isProcessed instead of checking for true?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This feels good to me, any reason for checking that way instead of this one?

Copy link
Contributor

Choose a reason for hiding this comment

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

checking for key's presence makes sure that this object is coming from the new processor regardless of the value.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The value can only be true, it makes more sense to check for true than for the key presence.

@zannager zannager added the package: system Specific to @mui/system label Sep 18, 2024
@brijeshb42 brijeshb42 merged commit 3cfa69c into mui:master Sep 19, 2024
13 checks passed
@romgrk romgrk deleted the feat-serialized-styles branch September 19, 2024 10:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package: system Specific to @mui/system
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants