forked from mui/material-ui
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[system] Make @emotion/* fully supported in the System (mui#33205)
Co-authored-by: Marija Najdova <[email protected]> Co-authored-by: Michał Dudak <[email protected]>
- Loading branch information
1 parent
216bf1c
commit 48290dd
Showing
8 changed files
with
98 additions
and
10 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import * as React from 'react'; | ||
import { ClassNames } from '@emotion/react'; | ||
import Button from '@mui/material/Button'; | ||
|
||
export default function EmotionCompat() { | ||
return ( | ||
<ClassNames> | ||
{({ css }) => ( | ||
<React.Fragment> | ||
<Button color="primary" classes={{ root: css({ color: 'pink' }) }}> | ||
This text should be pink | ||
</Button> | ||
<Button | ||
color="primary" | ||
className={css({ color: 'red' })} | ||
classes={{ root: css({ color: 'pink' }) }} | ||
> | ||
This text should be red | ||
</Button> | ||
<Button color="primary" classes={{ text: css({ color: 'pink' }) }}> | ||
This text should be pink | ||
</Button> | ||
</React.Fragment> | ||
)} | ||
</ClassNames> | ||
); | ||
} |