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

(#101) Avoid flicker of login/logout/denied buttons #103

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

YannDoW
Copy link

@YannDoW YannDoW commented Oct 17, 2015

Currently, the 3 login, logout and denied buttons are shown before that 2 of them are hidden, which causes an unpleasant flicker. This happens because the AngularJS code takes time to kick-in.
Adding the "ng-hide" class to them hide them by default. This way, only the correct button will appear, after a short moment.

Currently, the 3 login, logout and denied buttons are shown before that 2 of them are hidden, which causes an unpleasant flicker. This happens because the AngularJS code takes time to kick-in.
Adding the "ng-hide" class to them hide them by default. This way, only the correct button will appear, after a short moment.
@bramski
Copy link
Member

bramski commented Jun 29, 2016

I believe you are looking to us ng-cloak which does this exactly. NgHide is made for generally hiding elements. NgCloak could be applied to the root element on the template to prevent this.
https://docs.angularjs.org/api/ng/directive/ngCloak

@YannDoW
Copy link
Author

YannDoW commented Jun 30, 2016

Thanks for your answer @bramski ! As I recall (this was last year), I did try to use ng-cloak. But it did not work because these buttons are part of a fragment that is included quite late in the construction process. At least, this was my theory (I'm not an AngularJS expert!). So this was the only working solution I found.

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

Successfully merging this pull request may close these issues.

2 participants