From 6bbb56c386f58f994fde6d25b2219af09ee084ff Mon Sep 17 00:00:00 2001 From: Francis Lachapelle Date: Fri, 15 Jul 2016 14:03:16 -0400 Subject: [PATCH] (css,js) Improve progress feedback This ads a "ripple" effect that blocks the context when login in or sending a message. Generic enough to be used elsewhere. Fixes #3765 --- NEWS | 6 + UI/MailerUI/English.lproj/Localizable.strings | 7 +- UI/MainUI/English.lproj/Localizable.strings | 7 ++ UI/Templates/MailerUI/UIxMailEditor.wox | 43 ++++++- UI/Templates/MainUI/SOGoRootPage.wox | 68 ++++++++--- .../js/Common/sgRippleClick.directive.js | 108 ++++++++++++++++++ .../js/Mailer/Message.service.js | 8 +- .../js/Mailer/MessageEditorController.js | 27 ++++- UI/WebServerResources/js/Main/Main.app.js | 19 ++- .../scss/components/ripple/ripple.scss | 21 ++++ .../scss/core/structure.scss | 10 -- UI/WebServerResources/scss/styles.scss | 1 + UI/WebServerResources/scss/views/LoginUI.scss | 72 ++++++++---- 13 files changed, 334 insertions(+), 63 deletions(-) create mode 100644 UI/WebServerResources/js/Common/sgRippleClick.directive.js create mode 100644 UI/WebServerResources/scss/components/ripple/ripple.scss diff --git a/NEWS b/NEWS index 47ab709e5..ce0354bc8 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,9 @@ +3.1.5 (2016-MM-DD) +------------------ + +Enhancements + - [web] improve action progress when login in or sending a message (#3765, #3761) + 3.1.4 (2016-07-12) ------------------ diff --git a/UI/MailerUI/English.lproj/Localizable.strings b/UI/MailerUI/English.lproj/Localizable.strings index 33f3a0b28..074d17145 100644 --- a/UI/MailerUI/English.lproj/Localizable.strings +++ b/UI/MailerUI/English.lproj/Localizable.strings @@ -305,7 +305,12 @@ "Error while uploading the file \"%{0}\":" = "Error while uploading the file \"%{0}\":"; "There is an active file upload. Closing the window will interrupt it." = "There is an active file upload. Closing the window will interrupt it."; -/* Message sending */ +/* Appears while sending the message */ +"Sending" = "Sending"; + +/* Appears when the message is successfuly sent */ +"Sent" = "Sent"; + "cannot send message: (smtp) all recipients discarded" = "Cannot send message: all recipients are invalid."; "cannot send message (smtp) - recipients discarded" = "Cannot send message. The following addresses are invalid"; "cannot send message: (smtp) error when connecting" = "Cannot send message: error when connecting to the SMTP server."; diff --git a/UI/MainUI/English.lproj/Localizable.strings b/UI/MainUI/English.lproj/Localizable.strings index bcd236492..1b5376140 100644 --- a/UI/MainUI/English.lproj/Localizable.strings +++ b/UI/MainUI/English.lproj/Localizable.strings @@ -6,6 +6,13 @@ "Domain" = "Domain"; "Remember username" = "Remember username"; "Connect" = "Connect"; + +/* Appears while authentication is in progress */ +"Authenticating" = "Authenticating"; + +/* Appears when authentication succeeds */ +"Success" = "Success"; + "Authentication Failed" = "Authentication Failed"; "Wrong username or password." = "Wrong username or password."; "cookiesNotEnabled" = "You cannot login because your browser's cookies are disabled. Please enable cookies in your browser's settings and try again."; diff --git a/UI/Templates/MailerUI/UIxMailEditor.wox b/UI/Templates/MailerUI/UIxMailEditor.wox index fcf1f4c19..0978947d2 100644 --- a/UI/Templates/MailerUI/UIxMailEditor.wox +++ b/UI/Templates/MailerUI/UIxMailEditor.wox @@ -5,7 +5,7 @@ xmlns:const="http://www.skyrix.com/od/constant" xmlns:label="OGo:label"> -
+ ng-disabled="!(editor.message.editable.to.length > 0 || editor.message.editable.cc.length > 0 || editor.message.editable.bcc.length > 0) || editor.uploader.isUploading || messageForm.$invalid" + sg-ripple-click="mailEditor"> send @@ -254,5 +255,43 @@ + + + + +
+ +
+ +
+
+ + +
+ done +
+ +
+
+ + +
+ error +
+ {{editor.errorMessage}} +
+ +
+ +
+
diff --git a/UI/Templates/MainUI/SOGoRootPage.wox b/UI/Templates/MainUI/SOGoRootPage.wox index 8860a4101..b8fbacbfe 100644 --- a/UI/Templates/MainUI/SOGoRootPage.wox +++ b/UI/Templates/MainUI/SOGoRootPage.wox @@ -9,30 +9,31 @@ xmlns:label="OGo:label" const:jsFiles="Main.js, Common.js" > + + -
- -