From 0b97d3d4318ee93fc27b4f5bc1354a61253d5d7c Mon Sep 17 00:00:00 2001 From: Lex Lavnikov Date: Tue, 25 Apr 2017 10:58:54 +0200 Subject: [PATCH 1/2] Replaced 'not-allowed' with 'default' cursor for disabled component states --- src/DatePicker/DateDisplay.js | 2 +- src/IconButton/IconButton.js | 2 +- src/MenuItem/MenuItem.js | 2 +- src/Stepper/StepLabel.js | 2 +- src/Table/TableBody.js | 2 +- src/Table/TableHeader.js | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/DatePicker/DateDisplay.js b/src/DatePicker/DateDisplay.js index bd0e6a11428775..8a37bd14a30fea 100644 --- a/src/DatePicker/DateDisplay.js +++ b/src/DatePicker/DateDisplay.js @@ -49,7 +49,7 @@ function getStyles(props, context, state) { marginBottom: 10, }, yearTitle: { - cursor: props.disableYearSelection ? 'not-allowed' : (!selectedYear ? 'pointer' : 'default'), + cursor: props.disableYearSelection || selectedYear ? 'default' : 'pointer', }, }; diff --git a/src/IconButton/IconButton.js b/src/IconButton/IconButton.js index 64a5d6ccfe8342..121b75e42eac53 100644 --- a/src/IconButton/IconButton.js +++ b/src/IconButton/IconButton.js @@ -26,7 +26,7 @@ function getStyles(props, context) { disabled: { color: baseTheme.palette.disabledColor, fill: baseTheme.palette.disabledColor, - cursor: 'not-allowed', + cursor: 'default', }, }; } diff --git a/src/MenuItem/MenuItem.js b/src/MenuItem/MenuItem.js index 8cbca98b50f96d..d2d17fb8c2f92a 100644 --- a/src/MenuItem/MenuItem.js +++ b/src/MenuItem/MenuItem.js @@ -21,7 +21,7 @@ function getStyles(props, context) { const styles = { root: { color: props.disabled ? disabledColor : textColor, - cursor: props.disabled ? 'not-allowed' : 'pointer', + cursor: props.disabled ? 'default' : 'pointer', minHeight: props.desktop ? '32px' : '48px', lineHeight: props.desktop ? '32px' : '48px', fontSize: props.desktop ? 15 : 16, diff --git a/src/Stepper/StepLabel.js b/src/Stepper/StepLabel.js index 4df02c06d4ef35..534bad94266687 100644 --- a/src/Stepper/StepLabel.js +++ b/src/Stepper/StepLabel.js @@ -47,7 +47,7 @@ const getStyles = ({active, completed, disabled}, {muiTheme, stepper}) => { if (disabled) { styles.icon.color = inactiveIconColor; styles.root.color = disabledTextColor; - styles.root.cursor = 'not-allowed'; + styles.root.cursor = 'default'; } return styles; diff --git a/src/Table/TableBody.js b/src/Table/TableBody.js index 9b571d9ef58ad6..613ad9dd5f10b8 100644 --- a/src/Table/TableBody.js +++ b/src/Table/TableBody.js @@ -210,7 +210,7 @@ class TableBody extends Component { columnNumber={0} style={{ width: 24, - cursor: disabled ? 'not-allowed' : 'inherit', + cursor: disabled ? 'default' : 'inherit', }} > ); From 70c0800ba4ee00df71bc72b9e1afafeedc1732a7 Mon Sep 17 00:00:00 2001 From: Lex Lavnikov Date: Thu, 27 Apr 2017 11:09:38 +0200 Subject: [PATCH 2/2] fix Travis CI build error: Trailing spaces not allowed no-trailing-spaces --- src/Stepper/StepLabel.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Stepper/StepLabel.js b/src/Stepper/StepLabel.js index 534bad94266687..93ce1932a8f4c3 100644 --- a/src/Stepper/StepLabel.js +++ b/src/Stepper/StepLabel.js @@ -47,7 +47,7 @@ const getStyles = ({active, completed, disabled}, {muiTheme, stepper}) => { if (disabled) { styles.icon.color = inactiveIconColor; styles.root.color = disabledTextColor; - styles.root.cursor = 'default'; + styles.root.cursor = 'default'; } return styles;