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

md-tabs md-dynamic-height issue #3184

Closed
hodeyp opened this issue Jun 9, 2015 · 7 comments
Closed

md-tabs md-dynamic-height issue #3184

hodeyp opened this issue Jun 9, 2015 · 7 comments

Comments

@hodeyp
Copy link

hodeyp commented Jun 9, 2015

md-dynamic-height should be a boolean as per the docs but it is just looking for the existence of the attribute and then setting the dynamic height to true.

    if (!$scope.dynamicHeight) return $element.css('height', '');

should this not be

   if (!$scope.dynamicHeight=="true") return $element.css('height', '');
@robertmesserle
Copy link
Contributor

There is an issue here, but it is not as you described. The JS has a step where it converts optional scope variables to boolean, so the first code sample is correct; however, the CSS was not tied to that same logic. I'm adding a fix right now.

@dolohow
Copy link

dolohow commented Jun 27, 2015

So from now, you need to add md-dynamic-height='true' attribute to md-tabs element?
I guess the answer is true, because after recent upgrade I was oblique to modify my code as follow (simplified diff):

- md-tabs(md-dynamic-height md-border-bottom)
+ md-tabs(md-dynamic-height='true' md-border-bottom)

@robertmesserle
Copy link
Contributor

@dolohow This is definitely not the case, as seen here:

http://codepen.io/robertmesserle/pen/ad61c7175f501cdb3c6196605607af9e

@dolohow
Copy link

dolohow commented Jun 28, 2015

I modified resources to point to https://ajax.googleapis.com/ajax/libs/angular_material/0.10.0/angular-material.min.js and now the tabs are aligned to center and there is a weird behaviour of animation when changing the active tab, take a look.

Anyway it's not related with this issue and definetely not with my issue.

@robertmesserle
Copy link
Contributor

Hm, that's really weird - good catch! Oddly, it only seems to happen with the version in googleapis, so if you pull v0.10.0 from bower or npm, it works fine. I'll have to look into what went wrong with the deploy to google cdn.

@dolohow
Copy link

dolohow commented Jul 1, 2015

Well, I tried the version from bower and it looks like it's also affected, the only one that works is https://gitcdn.xyz/repo/angular/bower-material/v0.10.0/angular-material.min.js

@LexFrench
Copy link

Yeah, I'm noticing the same problem and as dolohow said the version at gitcdn.xyz seems to be unaffected.

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

4 participants