Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit f6475bf

Browse files
committedMar 31, 2021
naming convention other > rest
1 parent 0d3e5d1 commit f6475bf

File tree

12 files changed

+24
-24
lines changed

12 files changed

+24
-24
lines changed
 

‎docs/src/pages/components/cards/RecipeReviewCard.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
1616
import MoreVertIcon from '@material-ui/icons/MoreVert';
1717

1818
const ExpandMore = styled((props) => {
19-
const { expand, ...rest } = props;
20-
return <IconButton {...rest} />;
19+
const { expand, ...other } = props;
20+
return <IconButton {...other} />;
2121
})(({ theme, expand }) => ({
2222
transform: !expand ? 'rotate(0deg)' : 'rotate(180deg)',
2323
marginLeft: 'auto',

‎docs/src/pages/components/cards/RecipeReviewCard.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ interface ExpandMoreProps extends IconButtonProps {
2020
}
2121

2222
const ExpandMore = styled((props: ExpandMoreProps) => {
23-
const { expand, ...rest } = props;
24-
return <IconButton {...rest} />;
23+
const { expand, ...other } = props;
24+
return <IconButton {...other} />;
2525
})(({ theme, expand }) => ({
2626
transform: !expand ? 'rotate(0deg)' : 'rotate(180deg)',
2727
marginLeft: 'auto',

‎packages/material-ui-unstyled/src/BackdropUnstyled/BackdropUnstyled.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ describe('<BackdropUnstyled />', () => {
2727
let theme = null;
2828

2929
const Root = React.forwardRef(
30-
({ styleProps: stylePropsProp, theme: themeProp, ...rest }, ref) => {
30+
({ styleProps: stylePropsProp, theme: themeProp, ...other }, ref) => {
3131
styleProps = stylePropsProp;
3232
theme = themeProp;
33-
return <span ref={ref} {...rest} />;
33+
return <span ref={ref} {...other} />;
3434
},
3535
);
3636

‎packages/material-ui-unstyled/src/BadgeUnstyled/BadgeUnstyled.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ describe('<BadgeUnstyled />', () => {
2727
let theme = null;
2828

2929
const Root = React.forwardRef(
30-
({ styleProps: stylePropsProp, theme: themeProp, ...rest }, ref) => {
30+
({ styleProps: stylePropsProp, theme: themeProp, ...other }, ref) => {
3131
styleProps = stylePropsProp;
3232
theme = themeProp;
33-
return <span ref={ref} {...rest} />;
33+
return <span ref={ref} {...other} />;
3434
},
3535
);
3636

‎packages/material-ui-unstyled/src/ModalUnstyled/ModalUnstyled.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,10 @@ describe('<ModalUnstyled />', () => {
3737
let theme = null;
3838

3939
const Root = React.forwardRef(
40-
({ styleProps: stylePropsProp, theme: themeProp, ...rest }, ref) => {
40+
({ styleProps: stylePropsProp, theme: themeProp, ...other }, ref) => {
4141
styleProps = stylePropsProp;
4242
theme = themeProp;
43-
return <span ref={ref} {...rest} />;
43+
return <span ref={ref} {...other} />;
4444
},
4545
);
4646

‎packages/material-ui-utils/src/integerPropType.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,14 +46,14 @@ function requiredInteger(props, propName, componentName, location) {
4646
return null;
4747
}
4848

49-
function validator(props, propName, ...rest) {
49+
function validator(props, propName, ...other) {
5050
const propValue = props[propName];
5151

5252
if (propValue === undefined) {
5353
return null;
5454
}
5555

56-
return requiredInteger(props, propName, ...rest);
56+
return requiredInteger(props, propName, ...other);
5757
}
5858

5959
function validatorNoop() {

‎packages/material-ui/src/StepContent/StepContent.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,12 @@ describe('<StepContent />', () => {
2424
muiName: 'MuiStepContent',
2525
refInstanceof: window.HTMLDivElement,
2626
render: (node) => {
27-
const { container, ...rest } = render(
27+
const { container, ...other } = render(
2828
<Stepper orientation="vertical">
2929
<Step>{node}</Step>
3030
</Stepper>,
3131
);
32-
return { container: container.firstChild.firstChild, ...rest };
32+
return { container: container.firstChild.firstChild, ...other };
3333
},
3434
skip: ['componentProp', 'componentsProp', 'themeVariants', 'reactTestRenderer'],
3535
}));

‎packages/material-ui/src/TableBody/TableBody.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ describe('<TableBody />', () => {
2121
return wrapper.find('table').childAt(0);
2222
},
2323
render: (node) => {
24-
const { container, ...rest } = render(<table>{node}</table>);
25-
return { container: container.firstChild, ...rest };
24+
const { container, ...other } = render(<table>{node}</table>);
25+
return { container: container.firstChild, ...other };
2626
},
2727
muiName: 'MuiTableBody',
2828
testVariantProps: { variant: 'foo' },

‎packages/material-ui/src/TableCell/TableCell.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,14 @@ describe('<TableCell />', () => {
2121
classes,
2222
inheritComponent: 'td',
2323
render: (node) => {
24-
const { container, ...rest } = render(
24+
const { container, ...other } = render(
2525
<table>
2626
<tbody>
2727
<tr>{node}</tr>
2828
</tbody>
2929
</table>,
3030
);
31-
return { container: container.firstChild.firstChild.firstChild, ...rest };
31+
return { container: container.firstChild.firstChild.firstChild, ...other };
3232
},
3333
mount: (node) => {
3434
const wrapper = mount(

‎packages/material-ui/src/TableFooter/TableFooter.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ describe('<TableFooter />', () => {
1717
classes,
1818
inheritComponent: 'tfoot',
1919
render: (node) => {
20-
const { container, ...rest } = render(<table>{node}</table>);
21-
return { container: container.firstChild, ...rest };
20+
const { container, ...other } = render(<table>{node}</table>);
21+
return { container: container.firstChild, ...other };
2222
},
2323
mount: (node) => {
2424
const wrapper = mount(<table>{node}</table>);

‎packages/material-ui/src/TableHead/TableHead.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ describe('<TableHead />', () => {
2020
return wrapper.find('table').childAt(0);
2121
},
2222
render: (node) => {
23-
const { container, ...rest } = render(<table>{node}</table>);
24-
return { container: container.firstChild, ...rest };
23+
const { container, ...other } = render(<table>{node}</table>);
24+
return { container: container.firstChild, ...other };
2525
},
2626
muiName: 'MuiTableHead',
2727
testVariantProps: { variant: 'foo' },

‎packages/material-ui/src/TableRow/TableRow.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,12 @@ describe('<TableRow />', () => {
2020
classes,
2121
inheritComponent: 'tr',
2222
render: (node) => {
23-
const { container, ...rest } = render(
23+
const { container, ...other } = render(
2424
<table>
2525
<tbody>{node}</tbody>
2626
</table>,
2727
);
28-
return { container: container.firstChild.firstChild, ...rest };
28+
return { container: container.firstChild.firstChild, ...other };
2929
},
3030
mount: (node) => {
3131
const wrapper = mount(

0 commit comments

Comments
 (0)
Please sign in to comment.