Commit a7bf27d2 authored by Randall Leeds's avatar Randall Leeds

Revert "Merge pull request #258 from jtremback/truncating-tabs"

This reverts commit 297b2b95ce01b7e6dd6754a8cb0cae75a22323a3, reversing
changes made to 1b96738a53ca3f233b6950bfc3177e04665170b6.
parent 9ce9f318
...@@ -155,6 +155,22 @@ $em: 14 / 1em !default; ...@@ -155,6 +155,22 @@ $em: 14 / 1em !default;
} }
} }
@mixin tabbox {
@include box-shadow(2px -10px 13px -8px hsla(0, 0%, 0%, .1) inset);
background: hsla(0, 0%, 99%, 1);
border-top-right-radius: 2em 5em;
border-top-left-radius: 2em 5em;
color: #999;
border: 1px solid $grayLighter;
border-bottom: none;
&:hover {
background: white;
}
&:active {
@include box-shadow( none );
}
}
//ICON IMAGES//////////////////////////////// //ICON IMAGES////////////////////////////////
......
...@@ -350,88 +350,28 @@ blockquote { ...@@ -350,88 +350,28 @@ blockquote {
//TABS//////////////////////////////// //TABS////////////////////////////////
.nav-tabs { .nav-tabs {
width: 100%; @include pie-clearfix;
font-family: sans-serif; margin: 0 .5em;
& > li {
position: relative; & > li > a {
display: inline-block; cursor: pointer;
overflow: hidden; float: left;
line-height: 1;
padding: .5em 1em;
padding-top: .25em;
margin-right: -.5em; margin-right: -.5em;
background: hsla(0, 0%, 99%, 1); margin-bottom: 0px;
border-top-right-radius: 2em 5em; position: relative;
border-top-left-radius: 2em 5em; text-decoration: none;
border: 1px solid $grayLighter; @include tabbox;
border-bottom: none; }
& > a {
overflow: hidden; & > .active > a {
display: inline-block; @include box-shadow(none);
white-space: nowrap; color: #333;
padding: .5em 1em; font-weight: bold;
color: #999; background: hsla(0, 0%, 100%, 1);
text-decoration: none; z-index: 90;
}
&::before {
content: "";
@include background( linear-gradient(right, hsla(0, 0%, 99%, 1), hsla(0, 0%, 99%, 1), hsla(0, 0%, 99%, 0)) );
width: 1em;
height: 100%;
position: absolute;
right: 0;
top: 0;
border-top-right-radius: 2em 5em;
}
&::after {
content: "";
@include box-shadow(0px -10px 13px -8px hsla(0, 0%, 0%, .1) inset);
border-top-right-radius: 2em 5em;
border-top-left-radius: 2em 5em;
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
}
&:hover {
background: white;
}
&.active {
background: hsla(0, 0%, 100%, 1);
z-index: 90;
& > a {
color: #333;
font-weight: bold;
}
&::before {
@include background( linear-gradient(right, hsla(0, 0%, 100%, 1), hsla(0, 0%, 100%, 1), hsla(0, 0%, 100%, 0)) );
}
&::after {
@include box-shadow( none );
}
}
.tabs-below & {
border: 1px solid $grayLighter;
border-top: none;
border-top-right-radius: 0;
border-top-left-radius: 0;
border-bottom-right-radius: 2em 5em;
border-bottom-left-radius: 2em 5em;
&::before {
border-top-right-radius: 0;
border-bottom-right-radius: 2em 5em;
}
&::after {
@include box-shadow(0px 10px 13px -8px hsla(0, 0%, 0%, .1) inset);
border-top-right-radius: 0;
border-top-left-radius: 0;
border-bottom-right-radius: 2em 5em;
border-bottom-left-radius: 2em 5em;
}
&.active {
&::after {
@include box-shadow( none );
}
}
}
} }
} }
...@@ -442,6 +382,7 @@ blockquote { ...@@ -442,6 +382,7 @@ blockquote {
margin-top: -1px; // Pull up and under tabs margin-top: -1px; // Pull up and under tabs
padding: 1em; padding: 1em;
position: relative; position: relative;
&.active { &.active {
display: inherit !important; display: inherit !important;
} }
...@@ -449,6 +390,7 @@ blockquote { ...@@ -449,6 +390,7 @@ blockquote {
//PAPER//////////////////////////////// //PAPER////////////////////////////////
//Provides the white background upon which items sit //Provides the white background upon which items sit
.paper { .paper {
......
...@@ -129,17 +129,6 @@ tabReveal = ['$parse', ($parse) -> ...@@ -129,17 +129,6 @@ tabReveal = ['$parse', ($parse) ->
] ]
tabTruncate = ->
link: (scope, iElement) ->
angular.element(iElement).addClass("truncate")
tabs = angular.element(iElement.children()[0].childNodes)
percentage = 100 / tabs.length + "%"
for i in [0..tabs.length-1]
angular.element(tabs[i]).css "width", percentage
a_width = tabs[i].childNodes[0].clientWidth
angular.element(tabs[i]).css "max-width", a_width
thread = -> thread = ->
link: (scope, iElement, iAttrs, controller) -> link: (scope, iElement, iAttrs, controller) ->
scope.collapsed = false scope.collapsed = false
...@@ -153,4 +142,3 @@ angular.module('h.directives', ['ngSanitize']) ...@@ -153,4 +142,3 @@ angular.module('h.directives', ['ngSanitize'])
.directive('resettable', resettable) .directive('resettable', resettable)
.directive('tabReveal', tabReveal) .directive('tabReveal', tabReveal)
.directive('thread', thread) .directive('thread', thread)
.directive('tabTruncate', tabTruncate)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment