From a08a1c55aa4a28ae8c82c825631e1f3ca32c0092 Mon Sep 17 00:00:00 2001 From: Gabriel Albo Date: Mon, 28 Dec 2015 16:33:09 -0200 Subject: #563 - Adding arrows up and down to indicate the state of the cc and bcc fields --- web-ui/app/js/mail_view/ui/compose_box.js | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'web-ui/app/js') diff --git a/web-ui/app/js/mail_view/ui/compose_box.js b/web-ui/app/js/mail_view/ui/compose_box.js index 48a7c23f..993cf880 100644 --- a/web-ui/app/js/mail_view/ui/compose_box.js +++ b/web-ui/app/js/mail_view/ui/compose_box.js @@ -73,12 +73,24 @@ define( this.trigger(events.dispatchers.rightPane.openNoMessageSelected); }; + this.toggleRecipientsArrows = function () { + if ($('#cc-bcc-collapse').hasClass('fa-angle-down')) { + $('#cc-bcc-collapse').removeClass('fa-angle-down'); + $('#cc-bcc-collapse').addClass('fa-angle-up'); + } else { + $('#cc-bcc-collapse').removeClass('fa-angle-up'); + $('#cc-bcc-collapse').addClass('fa-angle-down'); + } + }; + + this.after('initialize', function () { this.renderComposeBox(); this.select('toBox').focus(); this.on(document, events.mail.deleted, this.mailDeleted); this.on(document, events.mail.sent, this.showNoMessageSelected); + this.on($('#cc-bcc-collapse'), 'click', this.toggleRecipientsArrows); }); } } -- cgit v1.2.3