Skip to content

[docs] Fix scrollbar on snackbar page#37657

Merged
oliviertassinari merged 2 commits intomui:masterfrom
oliviertassinari:docs-fix-snackbar-mobile
Jun 21, 2023
Merged

[docs] Fix scrollbar on snackbar page#37657
oliviertassinari merged 2 commits intomui:masterfrom
oliviertassinari:docs-fix-snackbar-mobile

Conversation

@oliviertassinari
Copy link
Member

@oliviertassinari oliviertassinari commented Jun 20, 2023

@oliviertassinari oliviertassinari added docs Improvements or additions to the documentation. type: regression A bug, but worse, it used to behave as expected. labels Jun 20, 2023
import Box from '@mui/material/Box';

export interface State extends SnackbarOrigin {
interface State extends SnackbarOrigin {
Copy link
Member Author

Choose a reason for hiding this comment

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

No need to export


const handleClick = (newState: SnackbarOrigin) => () => {
setState({ open: true, ...newState });
setState({ ...newState, open: true });
Copy link
Member Author

Choose a reason for hiding this comment

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

To be easier to scan, matching the code below

Comment on lines -28 to -30
<React.Fragment>
<Grid container justifyContent="center">
<Grid item>
Copy link
Member Author

@oliviertassinari oliviertassinari Jun 20, 2023

Choose a reason for hiding this comment

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

Removed one <div>

Comment on lines -48 to -50
</Grid>

<Grid container justifyContent="center">
Copy link
Member Author

Choose a reason for hiding this comment

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

Code convention, no empty lines in JSX.

@oliviertassinari oliviertassinari added the type: bug It doesn't behave as expected. label Jun 20, 2023
@mui-bot
Copy link

mui-bot commented Jun 20, 2023

Netlify deploy preview

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

Bundle size report

No bundle size changes

Generated by 🚫 dangerJS against cdb9ea4

@oliviertassinari oliviertassinari force-pushed the docs-fix-snackbar-mobile branch from e1f1bec to 1ea900c Compare June 20, 2023 21:41
Copy link
Member

@ZeeshanTamboli ZeeshanTamboli left a comment

Choose a reason for hiding this comment

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

Nice. I also pushed cdb9ea4 to fix the Direction Snackbar demo which was also changed in #37389.

@oliviertassinari oliviertassinari merged commit a089112 into mui:master Jun 21, 2023
@oliviertassinari oliviertassinari deleted the docs-fix-snackbar-mobile branch June 21, 2023 11:42
@oliviertassinari
Copy link
Member Author

oliviertassinari commented Jun 21, 2023

Perfect, thanks

@oliviertassinari oliviertassinari removed the type: bug It doesn't behave as expected. label Apr 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to the documentation. type: regression A bug, but worse, it used to behave as expected.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants