Implement IconOnly button type
This commit is contained in:
parent
7131f484a6
commit
4998072475
2 changed files with 3 additions and 1 deletions
|
|
@ -81,7 +81,8 @@ class Button extends React.Component<Props, State> {
|
|||
|
||||
return <button className={classes} disabled={this.props.disabled} onClick={this.props.click}>
|
||||
{icon}
|
||||
<span className='text'>{this.props.children}</span>
|
||||
{ (this.props.type != ButtonType.IconOnly) ?
|
||||
<span className='text'>{this.props.children}</span> : '' }
|
||||
</button>
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
export enum ButtonType {
|
||||
Base,
|
||||
IconOnly,
|
||||
Destructive
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue