File tree Expand file tree Collapse file tree
skins/vector/css/molecules Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -57,25 +57,42 @@ module.exports = React.createClass({
5757 if ( this . props . onFinished ) this . props . onFinished ( ) ;
5858 } ,
5959
60+ onCancelSendClick : function ( ) {
61+ Resend . removeFromQueue ( this . props . mxEvent ) ;
62+ if ( this . props . onFinished ) this . props . onFinished ( ) ;
63+ } ,
64+
6065 render : function ( ) {
66+ var eventStatus = this . props . mxEvent . status ;
6167 var resendButton ;
6268 var viewSourceButton ;
6369 var redactButton ;
70+ var cancelButton ;
6471
65- if ( this . props . mxEvent . status == 'not_sent' ) {
72+ if ( eventStatus = == 'not_sent' ) {
6673 resendButton = (
6774 < div className = "mx_ContextualMenu_field" onClick = { this . onResendClick } >
6875 Resend
6976 </ div >
7077 ) ;
7178 }
72- else {
79+
80+ if ( ! eventStatus ) { // sent
7381 redactButton = (
7482 < div className = "mx_ContextualMenu_field" onClick = { this . onRedactClick } >
7583 Redact
7684 </ div >
7785 ) ;
7886 }
87+
88+ if ( eventStatus === "queued" || eventStatus === "not_sent" ) {
89+ cancelButton = (
90+ < div className = "mx_ContextualMenu_field" onClick = { this . onCancelSendClick } >
91+ Cancel Sending
92+ </ div >
93+ ) ;
94+ }
95+
7996 viewSourceButton = (
8097 < div className = "mx_ContextualMenu_field" onClick = { this . onViewSourceClick } >
8198 View Source
@@ -86,6 +103,7 @@ module.exports = React.createClass({
86103 < div >
87104 { resendButton }
88105 { redactButton }
106+ { cancelButton }
89107 { viewSourceButton }
90108 </ div >
91109 ) ;
Original file line number Diff line number Diff line change @@ -111,7 +111,7 @@ limitations under the License.
111111}
112112
113113. mx_EventTile_notSent {
114- color : # ddd ;
114+ color : # f44 ;
115115}
116116
117117. mx_EventTile_highlight ,
You can’t perform that action at this time.
0 commit comments