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

Admin panel link style in main dropdown menu #627

Closed
SarahBaghdadi opened this issue Jan 26, 2017 · 6 comments
Closed

Admin panel link style in main dropdown menu #627

SarahBaghdadi opened this issue Jan 26, 2017 · 6 comments

Comments

@SarahBaghdadi
Copy link
Member

The "Admin panel" link looks like plain text compared to the other buttons around it. I like how it looks, but I wonder if its not clear enough to a new user. When I first logged in, I felt like "how do I get to the admin panel".

screen shot 2017-01-26 at 1 41 09 am

@lcharette
Copy link
Member

It's actually the default AdminLTE look:

capture d ecran 2017-01-26 a 06 38 20

I do agree it look weird, but it doesn't fit between "my account" and "logout" without resizing the box awkwardly. It's even worst when in french locale since all the strings are longer.

Not sure how to it could be fixed. If you have any suggestions it could be merged.

@alexweissman
Copy link
Member

Yeah we need to make it more prominent. Also, we should probably redirect people directly to the dashboard by default when they log in, if they have access.

@lcharette
Copy link
Member

Also, we should probably redirect people directly to the dashboard by default when they log in, if they have access.

This goes back to the "dev being able to define where a user can go after login" feature...

@alexweissman
Copy link
Member

Ok, I've implemented this in develop. See c82c28. You can define a determineRedirectOnLogin service in your Sprinkle, which returns a callback that adds a custom UF-Redirect header to the response. This callback is automatically invoked by AccountController::login() after the user successfully logs in. I've already defined this callback in both the account and admin sprinkles (admin tries to forward to dashboard, account tries to forward to account settings). So, all a dev needs to do to change the behavior, is override this callback in their own sprinkle.

Meanwhile, on the client side of things, the pages/sign-in-or-register.js code will check for the UF-Redirect header in the response and forward to that page on success (unless a redirect was specified in the URL for the login page, in which case it will redirect to that instead).

@alexweissman
Copy link
Member

Still need to fix dat button tho

lcharette added a commit that referenced this issue Jan 27, 2017
@lcharette
Copy link
Member

lcharette commented Jan 27, 2017

Done ! This should be better. Let me know if you have another suggestion.

capture d ecran 2017-01-27 a 09 08 51

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants