Added ability to delete newly created invalid rule.
This commit is contained in:
parent
42338b0afa
commit
e6bd9cd943
4 changed files with 36 additions and 71 deletions
7
client/src/lib/bootstrap-components.js
vendored
7
client/src/lib/bootstrap-components.js
vendored
|
@ -51,7 +51,8 @@ class Button extends Component {
|
|||
onClickAsync: PropTypes.func,
|
||||
label: PropTypes.string,
|
||||
icon: PropTypes.string,
|
||||
className: PropTypes.string
|
||||
className: PropTypes.string,
|
||||
type: PropTypes.string
|
||||
}
|
||||
|
||||
@withAsyncErrorHandler
|
||||
|
@ -70,6 +71,8 @@ class Button extends Component {
|
|||
className = className + ' ' + props.className;
|
||||
}
|
||||
|
||||
let type = props.type || 'button';
|
||||
|
||||
let icon;
|
||||
if (props.icon) {
|
||||
icon = <Icon name={props.icon}/>
|
||||
|
@ -81,7 +84,7 @@ class Button extends Component {
|
|||
}
|
||||
|
||||
return (
|
||||
<button type="button" className={className} onClick={::this.onClick}>{icon}{iconSpacer}{props.label}</button>
|
||||
<button type={type} className={className} onClick={::this.onClick}>{icon}{iconSpacer}{props.label}</button>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue