Change cursor for current display and prevent option from being selected
This commit is contained in:
parent
c5424350ab
commit
f238cbbca0
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -222,6 +222,8 @@ p.wc-products-block-description {
|
|||
}
|
||||
|
||||
&--current {
|
||||
cursor: default;
|
||||
|
||||
.wc-products-display-options__option-title {
|
||||
color: $color__option-description;
|
||||
}
|
||||
|
|
|
@ -195,7 +195,7 @@ var ProductsBlockSettingsEditorDisplayOption = function (_React$Component) {
|
|||
return wp.element.createElement(
|
||||
'div',
|
||||
{ className: classes, onClick: function onClick() {
|
||||
_this2.props.update_display_callback(_this2.props.value);
|
||||
_this2.props.current !== _this2.props.value && _this2.props.update_display_callback(_this2.props.value);
|
||||
} },
|
||||
wp.element.createElement(
|
||||
'div',
|
||||
|
|
|
@ -83,7 +83,7 @@ class ProductsBlockSettingsEditorDisplayOption extends React.Component {
|
|||
}
|
||||
|
||||
return (
|
||||
<div className={ classes } onClick={ () => { this.props.update_display_callback( this.props.value ) } } >
|
||||
<div className={ classes } onClick={ () => { this.props.current !== this.props.value && this.props.update_display_callback( this.props.value ) } } >
|
||||
<div className="wc-products-display-options__option-content">
|
||||
<span className="wc-products-display-options__option-title">{ this.props.title }</span>
|
||||
<p className="wc-products-display-options__option-description">{ this.props.description }</p>
|
||||
|
|
Loading…
Reference in New Issue