Skip to content

Commit

Permalink
naming to BootstrapDialogTitle
Browse files Browse the repository at this point in the history
  • Loading branch information
vicasas committed May 6, 2021
1 parent 8264f14 commit 5a86483
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
14 changes: 7 additions & 7 deletions docs/src/pages/components/dialogs/CustomizedDialogs.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@ import * as React from 'react';
import PropTypes from 'prop-types';
import Button from '@material-ui/core/Button';
import Dialog from '@material-ui/core/Dialog';
import MuiDialogTitle from '@material-ui/core/DialogTitle';
import DialogTitle from '@material-ui/core/DialogTitle';
import DialogContent from '@material-ui/core/DialogContent';
import DialogActions from '@material-ui/core/DialogActions';
import IconButton from '@material-ui/core/IconButton';
import CloseIcon from '@material-ui/icons/Close';
import Typography from '@material-ui/core/Typography';

const DialogTitle = (props) => {
const BootstrapDialogTitle = (props) => {
const { children, onClose, ...other } = props;

return (
<MuiDialogTitle disableTypography sx={{ m: 0, p: 2 }} {...other}>
<DialogTitle disableTypography sx={{ m: 0, p: 2 }} {...other}>
<Typography variant="h6" component="div">
{children}
</Typography>
Expand All @@ -31,11 +31,11 @@ const DialogTitle = (props) => {
<CloseIcon />
</IconButton>
) : null}
</MuiDialogTitle>
</DialogTitle>
);
};

DialogTitle.propTypes = {
BootstrapDialogTitle.propTypes = {
children: PropTypes.node,
onClose: PropTypes.func.isRequired,
};
Expand All @@ -60,9 +60,9 @@ export default function CustomizedDialogs() {
aria-labelledby="customized-dialog-title"
open={open}
>
<DialogTitle id="customized-dialog-title" onClose={handleClose}>
<BootstrapDialogTitle id="customized-dialog-title" onClose={handleClose}>
Modal title
</DialogTitle>
</BootstrapDialogTitle>
<DialogContent dividers sx={{ p: 2 }}>
<Typography gutterBottom>
Cras mattis consectetur purus sit amet fermentum. Cras justo odio,
Expand Down
12 changes: 6 additions & 6 deletions docs/src/pages/components/dialogs/CustomizedDialogs.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as React from 'react';
import Button from '@material-ui/core/Button';
import Dialog from '@material-ui/core/Dialog';
import MuiDialogTitle from '@material-ui/core/DialogTitle';
import DialogTitle from '@material-ui/core/DialogTitle';
import DialogContent from '@material-ui/core/DialogContent';
import DialogActions from '@material-ui/core/DialogActions';
import IconButton from '@material-ui/core/IconButton';
Expand All @@ -14,11 +14,11 @@ export interface DialogTitleProps {
onClose: () => void;
}

const DialogTitle = (props: DialogTitleProps) => {
const BootstrapDialogTitle = (props: DialogTitleProps) => {
const { children, onClose, ...other } = props;

return (
<MuiDialogTitle disableTypography sx={{ m: 0, p: 2 }} {...other}>
<DialogTitle disableTypography sx={{ m: 0, p: 2 }} {...other}>
<Typography variant="h6" component="div">
{children}
</Typography>
Expand All @@ -36,7 +36,7 @@ const DialogTitle = (props: DialogTitleProps) => {
<CloseIcon />
</IconButton>
) : null}
</MuiDialogTitle>
</DialogTitle>
);
};

Expand All @@ -60,9 +60,9 @@ export default function CustomizedDialogs() {
aria-labelledby="customized-dialog-title"
open={open}
>
<DialogTitle id="customized-dialog-title" onClose={handleClose}>
<BootstrapDialogTitle id="customized-dialog-title" onClose={handleClose}>
Modal title
</DialogTitle>
</BootstrapDialogTitle>
<DialogContent dividers sx={{ p: 2 }}>
<Typography gutterBottom>
Cras mattis consectetur purus sit amet fermentum. Cras justo odio,
Expand Down

0 comments on commit 5a86483

Please sign in to comment.