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

Commit

Permalink
update(tabs): fixes tab styles, reduces size of getLabel method
Browse files Browse the repository at this point in the history
  • Loading branch information
Robert Messerle committed Mar 27, 2015
1 parent 76f627c commit 0e1820c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
8 changes: 1 addition & 7 deletions src/components/tabs/js/tabDirective.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,13 +92,7 @@
scope.$on('$destroy', function () { ctrl.removeTab(data); });

function getLabel () {
//-- if label provided, then send label
if (attr.label) return attr.label;
//-- otherwise, we have to search for the `md-tab-label` element
var label = element.find('md-tab-label');
if (label.length) return label.html();
//-- otherwise, we have no label.
return element.html();
return attr.label || (element.find('md-tab-label')[0] || element[0]).innerHTML;
}

function getTemplate () {
Expand Down
2 changes: 1 addition & 1 deletion src/components/tabs/tabs.scss
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ md-tabs {
border-radius: 2px;
overflow: hidden;
position: relative;
&:not('.md-no-tab-content') {
&:not(.md-no-tab-content) {
min-height: 200 + $tabs-header-height;
}
&[md-align-tabs="bottom"] {
Expand Down

0 comments on commit 0e1820c

Please sign in to comment.