Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Login form errors should use the nice material design look #10563

Closed
mattab opened this issue Sep 26, 2016 · 2 comments · Fixed by #10565
Closed

Login form errors should use the nice material design look #10563

mattab opened this issue Sep 26, 2016 · 2 comments · Fixed by #10565
Assignees
Labels
answered For when a question was asked and we referred to forum or answered it. c: Design / UI For issues that impact Matomo's user interface or the design overall. Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc.
Milestone

Comments

@mattab
Copy link
Member

mattab commented Sep 26, 2016

Currently the Login form errors don't use the material design notifications.

Our goal is to be consistent in the UI and so it would look much nicer to use the material error notification.

Current look

current

Material look

material

Not trivial?!

This was probably not done during redesign because there is some code that depends on the CSS error class names to detect whether there was an error during password reset. here: https://github.com/piwik/piwik/blob/3.x-dev/plugins/Login/javascripts/login.js#L63-L75

Patch that does not work yet

--- plugins/Login/templates/login.twig  (revision 35c43385307c6621bd479640fa2cff9a5ca85c2f)
+++ plugins/Login/templates/login.twig  (revision )
@@ -72,7 +72,9 @@
                         {{ include('@Login/_formErrors.twig', {formErrors: form_data.errors } )  }}

                         {% if AccessErrorString %}
-                            <div class="message_error">
+                            <div piwik-notification
+                                 noclear="true"
+                                 context="error">
                                 <strong>{{ 'General_Error'|translate }}</strong>: {{ AccessErrorString|raw }}<br/>
                             </div>
                         {% endif %}
Index: plugins/Login/templates/_formErrors.twig
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- plugins/Login/templates/_formErrors.twig    (revision 35c43385307c6621bd479640fa2cff9a5ca85c2f)
+++ plugins/Login/templates/_formErrors.twig    (revision )
@@ -1,6 +1,8 @@

 {% if formErrors is defined and formErrors is not empty %}
-    <div class="message_error">
+    <div piwik-notification
+         noclear="true"
+         context="error">
@mattab mattab added Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. c: Design / UI For issues that impact Matomo's user interface or the design overall. labels Sep 26, 2016
@mattab mattab added this to the 3.0.0-b1 milestone Sep 26, 2016
@mattab
Copy link
Member Author

mattab commented Sep 26, 2016

@sgiehl Could you maybe help with this issue?

@mattab
Copy link
Member Author

mattab commented Sep 26, 2016

(Note: just noticed that during installation, the Form errors/warnings could also similarly use the material design. But this should be another issue.)

@sgiehl sgiehl self-assigned this Sep 26, 2016
mattab pushed a commit that referenced this issue Sep 26, 2016
* fixes #10563 - materialize login form errors

* updates expected screenshots

* cleanup css
@mattab mattab closed this as completed Sep 27, 2016
@mattab mattab added the answered For when a question was asked and we referred to forum or answered it. label Oct 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
answered For when a question was asked and we referred to forum or answered it. c: Design / UI For issues that impact Matomo's user interface or the design overall. Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants