1
1
mirror of https://github.com/primer/css.git synced 2024-11-30 11:17:05 +03:00

Merge pull request #27 from iamphill/remove-gradient-mixin

Deprecated gradient mixin
This commit is contained in:
Mark Otto 2015-03-29 14:17:56 -07:00
commit 0584f73f00
4 changed files with 24 additions and 16 deletions

View File

@ -7,17 +7,17 @@
### css/primer.css ### css/primer.css
- **Total Stylesheets:** 1 - **Total Stylesheets:** 1
- **Total Stylesheet Size:** 30831 - **Total Stylesheet Size:** 30697
- **Total Media Queries:** 1 - **Total Media Queries:** 1
- **Total Rules:** 404 - **Total Rules:** 405
- **Selectors Per Rule:** 1.4405940594059405 - **Selectors Per Rule:** 1.4419753086419753
- **Total Selectors:** 582 - **Total Selectors:** 584
- **Identifiers Per Selector:** 2.1460481099656357 - **Identifiers Per Selector:** 2.1455479452054793
- **Specificity Per Selector:** 16.6786941580756 - **Specificity Per Selector:** 16.690068493150687
- **Top Selector Specificity:** 50 - **Top Selector Specificity:** 50
- **Top Selector Specificity Selector:** .fullscreen-overlay-enabled.dark-theme .tooltipped .tooltipped-s:before - **Top Selector Specificity Selector:** .fullscreen-overlay-enabled.dark-theme .tooltipped .tooltipped-s:before
- **Total Id Selectors:** 0 - **Total Id Selectors:** 0
- **Total Identifiers:** 1249 - **Total Identifiers:** 1253
- **Total Declarations:** 1004 - **Total Declarations:** 997
- **Total Unique Colors:** 78 - **Total Unique Colors:** 78
- **Total Important Keywords:** 1 - **Total Important Keywords:** 1

File diff suppressed because one or more lines are too long

View File

@ -10,7 +10,8 @@
white-space: nowrap; white-space: nowrap;
vertical-align: middle; vertical-align: middle;
cursor: pointer; cursor: pointer;
@include gradient(#fcfcfc, #eee); background-color: #eee;
background-image: linear-gradient(#fcfcfc, #eee);
border: 1px solid #d5d5d5; border: 1px solid #d5d5d5;
border-radius: 3px; border-radius: 3px;
user-select: none; user-select: none;
@ -38,7 +39,8 @@
&.zeroclipboard-is-hover, &.zeroclipboard-is-hover,
&.zeroclipboard-is-active { &.zeroclipboard-is-active {
text-decoration: none; text-decoration: none;
@include gradient(#eee, #ddd); background-color: #ddd;
background-image: linear-gradient(#eee, #ddd);
border-color: #ccc; border-color: #ccc;
} }
@ -70,12 +72,14 @@
.btn-primary { .btn-primary {
color: #fff; color: #fff;
text-shadow: 0 -1px 0 rgba(0,0,0,0.15); text-shadow: 0 -1px 0 rgba(0,0,0,0.15);
@include gradient(#8add6d, #60b044); background-color: #60b044;
background-image: linear-gradient(#8add6d, #60b044);
border-color: darken(#60b044, 2%); border-color: darken(#60b044, 2%);
&:hover { &:hover {
color: #fff; color: #fff;
@include gradient(darken(#8add6d, 5%), darken(#60b044, 5%)); background-color: darken(#60b044, 5%);
background-image: linear-gradient(darken(#8add6d, 5%), darken(#60b044, 5%));
border-color: #4a993e; border-color: #4a993e;
} }
@ -92,7 +96,8 @@
&, &,
&:hover { &:hover {
color: #fefefe; color: #fefefe;
@include gradient(#c3ecb4, #add39f); background-color: #add39f;
background-image: linear-gradient(#c3ecb4, #add39f);
border-color: #b9dcac #b9dcac #a7c89b; border-color: #b9dcac #b9dcac #a7c89b;
} }
} }
@ -104,7 +109,8 @@
&:hover { &:hover {
color: #fff; color: #fff;
@include gradient(#dc5f59, #b33630); background-color: #b33630;
background-image: linear-gradient(#dc5f59, #b33630);
border-color: #cd504a; border-color: #cd504a;
} }
@ -121,7 +127,8 @@
&, &,
&:hover { &:hover {
color: #cb7f7f; color: #cb7f7f;
@include gradient(#fefefe, #efefef); background-color: #efefef;
background-image: linear-gradient(#fefefe, #efefef);
border-color: #e1e1e1; border-color: #e1e1e1;
} }
} }

View File

@ -21,6 +21,7 @@
// $end - The color hex at the bottom. // $end - The color hex at the bottom.
@mixin gradient($start: #fafafa, $end: #eaeaea) { @mixin gradient($start: #fafafa, $end: #eaeaea) {
@warn "Gradient mixin is deprecated.";
background-color: $end; background-color: $end;
// FF 3.6+ // FF 3.6+
background-image: -moz-linear-gradient($start, $end); background-image: -moz-linear-gradient($start, $end);