Skip to content
This repository has been archived by the owner on Sep 5, 2024. It is now read-only.

md-button + class="md-fab" + ng-show #949

Closed
djindjic opened this issue Dec 16, 2014 · 2 comments
Closed

md-button + class="md-fab" + ng-show #949

djindjic opened this issue Dec 16, 2014 · 2 comments

Comments

@djindjic
Copy link

I have some strange md-button behavior if add md-fab class to get rounded button. Below is my plunker sample which shows toggling authentication state. There is half a second period while both buttons are shown. If I just remove md-fab class everything is working fine and I see just one button at the moment.

http://plnkr.co/edit/uGhHq2nmQasgciBoECgz?p=preview

this issue could be related with:
#678
#936

@PaulMougel
Copy link
Contributor

As mentioned in the related issues, a temporary workaround is to use a <div> that surrounds your buttons, and apply the ng-show on it:

<div ng-show="!authenticated">
  <md-button class="md-fab" ng-click="toggleState()">login</md-button>
</div>
<div ng-show="authenticated">
  <md-button class="md-fab" ng-click="toggleState()">out</md-button>
</div>

@djindjic
Copy link
Author

Sorry, I didn't see it.
Thanks!

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

No branches or pull requests

2 participants