Skip to content

Commit

Permalink
look into the build fail
Browse files Browse the repository at this point in the history
  • Loading branch information
oliviertassinari committed Feb 10, 2019
1 parent af3d812 commit ef1e87a
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 42 deletions.
4 changes: 2 additions & 2 deletions packages/material-ui/src/Collapse/Collapse.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,13 +161,13 @@ class Collapse extends React.Component {
classes.container,
{
[classes.entered]: state === 'entered',
[classes.exited]: state === 'exited',
[classes.exited]: state === 'exited' && collapsedHeight === '0px',
},
className,
)}
style={{
...style,
minHeight: collapsedHeight,
...style,
}}
{...childProps}
>
Expand Down
18 changes: 8 additions & 10 deletions packages/material-ui/src/Fade/Fade.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,22 +55,20 @@ class Fade extends React.Component {
};

render() {
const { children, onEnter, onExit, style: styleProp, theme, ...other } = this.props;
const { children, onEnter, onExit, style, theme, ...other } = this.props;

return (
<Transition appear onEnter={this.handleEnter} onExit={this.handleExit} {...other}>
{(state, childProps) => {
const style = {
opacity: 0,
...styles[state],
...styleProp,
...childProps.style,
};

return React.cloneElement(children, {
...childProps,
'aria-hidden': state === 'exited',
style,
style: {
opacity: 0,
...styles[state],
...style,
...children.props.style,
},
...childProps,
});
}}
</Transition>
Expand Down
20 changes: 9 additions & 11 deletions packages/material-ui/src/Grow/Grow.js
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ class Grow extends React.Component {
};

render() {
const { children, onEnter, onExit, style: styleProp, theme, timeout, ...other } = this.props;
const { children, onEnter, onExit, style, theme, timeout, ...other } = this.props;

return (
<Transition
Expand All @@ -118,18 +118,16 @@ class Grow extends React.Component {
{...other}
>
{(state, childProps) => {
const style = {
opacity: 0,
transform: getScale(0.75),
...styles[state],
...styleProp,
...children.props.style,
};

return React.cloneElement(children, {
...childProps,
'aria-hidden': state === 'exited',
style,
style: {
opacity: 0,
transform: getScale(0.75),
...styles[state],
...style,
...children.props.style,
},
...childProps,
});
}}
</Transition>
Expand Down
16 changes: 7 additions & 9 deletions packages/material-ui/src/Slide/Slide.js
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ class Slide extends React.Component {
onEntering,
onExit,
onExited,
style: styleProp,
style,
theme,
...other
} = this.props;
Expand All @@ -210,16 +210,14 @@ class Slide extends React.Component {
{...other}
>
{(state, childProps) => {
const style = {
visibility: state === 'exited' ? 'hidden' : undefined,
...styleProp,
...children.props.style,
};

return React.cloneElement(children, {
...childProps,
'aria-hidden': state === 'exited',
style,
style: {
visibility: state === 'exited' ? 'hidden' : undefined,
...style,
...children.props.style,
},
...childProps,
});
}}
</Transition>
Expand Down
18 changes: 8 additions & 10 deletions packages/material-ui/src/Zoom/Zoom.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,22 +54,20 @@ class Zoom extends React.Component {
};

render() {
const { children, onEnter, onExit, style: styleProp, theme, ...other } = this.props;
const { children, onEnter, onExit, style, theme, ...other } = this.props;

return (
<Transition appear onEnter={this.handleEnter} onExit={this.handleExit} {...other}>
{(state, childProps) => {
const style = {
transform: 'scale(0)',
...styles[state],
...styleProp,
...children.props.style,
};

return React.cloneElement(children, {
...childProps,
'aria-hidden': state === 'exited',
style,
style: {
transform: 'scale(0)',
...styles[state],
...style,
...children.props.style,
},
...childProps,
});
}}
</Transition>
Expand Down

0 comments on commit ef1e87a

Please sign in to comment.