Skip to content

Commit

Permalink
[IconButton] Better follow the spec (#9967)
Browse files Browse the repository at this point in the history
  • Loading branch information
oliviertassinari authored Jan 20, 2018
1 parent 70078cc commit 0724dad
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 9 deletions.
1 change: 0 additions & 1 deletion pages/api/icon-button.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ This property accepts the following keys:
- `disabled`
- `label`
- `icon`
- `keyboardFocused`

Have a look at [overriding with classes](/customization/overrides#overriding-with-classes) section
and the [implementation of the component](https://github.com/mui-org/material-ui/tree/v1-beta/src/IconButton/IconButton.js)
Expand Down
4 changes: 2 additions & 2 deletions src/ButtonBase/TouchRipple.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export const styles = theme => ({
display: 'block',
width: '100%',
height: '100%',
animation: `mui-ripple-pulsate 1500ms ${theme.transitions.easing.easeInOut} 200ms infinite`,
animation: `mui-ripple-pulsate 2500ms ${theme.transitions.easing.easeInOut} 200ms infinite`,
},
'@keyframes mui-ripple-enter': {
'0%': {
Expand All @@ -59,7 +59,7 @@ export const styles = theme => ({
transform: 'scale(1)',
},
'50%': {
transform: 'scale(0.9)',
transform: 'scale(0.92)',
},
'100%': {
transform: 'scale(1)',
Expand Down
3 changes: 1 addition & 2 deletions src/IconButton/IconButton.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ export type IconButtonClassKey =
| 'colorSecondary'
| 'colorInherit'
| 'label'
| 'icon'
| 'keyboardFocused';
| 'icon';

declare const IconButton: React.ComponentType<IconButtonProps>;

Expand Down
5 changes: 1 addition & 4 deletions src/IconButton/IconButton.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,6 @@ export const styles = theme => ({
width: '1em',
height: '1em',
},
keyboardFocused: {
backgroundColor: theme.palette.text.divider,
},
});

/**
Expand All @@ -69,7 +66,7 @@ function IconButton(props) {
className,
)}
centerRipple
keyboardFocusedClassName={classes.keyboardFocused}
focusRipple
disabled={disabled}
rootRef={buttonRef}
ref={rootRef}
Expand Down

0 comments on commit 0724dad

Please sign in to comment.