File tree Expand file tree Collapse file tree 1 file changed +17
-7
lines changed Expand file tree Collapse file tree 1 file changed +17
-7
lines changed Original file line number Diff line number Diff line change @@ -68,13 +68,23 @@ export default class AlertView extends React.Component {
68
68
< >
69
69
< Title name = { name } alert = { alert } >
70
70
< DynamicComponent name = "AlertView.HeaderExtra" alert = { alert } />
71
- < Tooltip title = { canEdit ? "" : "You do not have sufficient permissions to edit this alert" } >
72
- < Button type = "default" onClick = { canEdit ? onEdit : null } className = { cx ( { disabled : ! canEdit } ) } >
73
- < i className = "fa fa-edit m-r-5" aria-hidden = "true" />
74
- Edit
75
- </ Button >
76
- { menuButton }
77
- </ Tooltip >
71
+ { canEdit ? (
72
+ < >
73
+ < Button type = "default" onClick = { canEdit ? onEdit : null } className = { cx ( { disabled : ! canEdit } ) } >
74
+ < i className = "fa fa-edit m-r-5" aria-hidden = "true" />
75
+ Edit
76
+ </ Button >
77
+ { menuButton }
78
+ </ >
79
+ ) : (
80
+ < Tooltip title = "You do not have sufficient permissions to edit this alert" >
81
+ < Button type = "default" onClick = { canEdit ? onEdit : null } className = { cx ( { disabled : ! canEdit } ) } >
82
+ < i className = "fa fa-edit m-r-5" aria-hidden = "true" />
83
+ Edit
84
+ </ Button >
85
+ { menuButton }
86
+ </ Tooltip >
87
+ ) }
78
88
</ Title >
79
89
< div className = "bg-white tiled p-20" >
80
90
< Grid . Row type = "flex" gutter = { 16 } >
You can’t perform that action at this time.
0 commit comments