Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/bootstrap-rubygem.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'assets/stylesheets/bootstrap/mixins')
-rw-r--r--assets/stylesheets/bootstrap/mixins/_buttons.scss32
-rw-r--r--assets/stylesheets/bootstrap/mixins/_clearfix.scss19
-rw-r--r--assets/stylesheets/bootstrap/mixins/_image.scss4
-rw-r--r--assets/stylesheets/bootstrap/mixins/_list-group.scss6
4 files changed, 28 insertions, 33 deletions
diff --git a/assets/stylesheets/bootstrap/mixins/_buttons.scss b/assets/stylesheets/bootstrap/mixins/_buttons.scss
index 75d2847..c64f0e8 100644
--- a/assets/stylesheets/bootstrap/mixins/_buttons.scss
+++ b/assets/stylesheets/bootstrap/mixins/_buttons.scss
@@ -4,36 +4,46 @@
// and disabled options for all buttons
@mixin button-variant($color, $background, $border) {
+ $active-background: darken($background, 10%);
+ $active-border: darken($border, 12%);
+
color: $color;
background-color: $background;
border-color: $border;
-// $shadow: inset 0 1px 0 rgba(255,255,255,.15), 0 1px 1px rgba(0,0,0,.075);
-// .box-shadow($shadow);
-
- $active-background: darken($background, 10%);
- $active-border: darken($border, 12%);
+ @include box-shadow(inset 0 1px 0 rgba(255,255,255,.15), 0 1px 1px rgba(0,0,0,.075));
- &:focus,
- &.focus,
- &:active,
- &.active,
- .open > &.dropdown-toggle {
+ @include hover {
color: $color;
background-color: $active-background;
border-color: $active-border;
}
- @include hover {
+
+ &:focus,
+ &.focus {
color: $color;
background-color: $active-background;
border-color: $active-border;
}
+
&:active,
&.active,
.open > &.dropdown-toggle {
+ color: $color;
+ background-color: $active-background;
+ border-color: $active-border;
// Remove the gradient for the pressed/active state
background-image: none;
@include box-shadow(inset 0 3px 5px rgba(0,0,0,.125));
+
+ &:hover,
+ &:focus,
+ &.focus {
+ color: $color;
+ background-color: darken($background, 17%);
+ border-color: darken($border, 25%);
+ }
}
+
&.disabled,
&:disabled,
fieldset[disabled] & {
diff --git a/assets/stylesheets/bootstrap/mixins/_clearfix.scss b/assets/stylesheets/bootstrap/mixins/_clearfix.scss
index dc3e2ab..439455f 100644
--- a/assets/stylesheets/bootstrap/mixins/_clearfix.scss
+++ b/assets/stylesheets/bootstrap/mixins/_clearfix.scss
@@ -1,22 +1,7 @@
-// Clearfix
-//
-// For modern browsers
-// 1. The space content is one way to avoid an Opera bug when the
-// contenteditable attribute is included anywhere else in the document.
-// Otherwise it causes space to appear at the top and bottom of elements
-// that are clearfixed.
-// 2. The use of `table` rather than `block` is only necessary if using
-// `:before` to contain the top-margins of child elements.
-//
-// Source: http://nicolasgallagher.com/micro-clearfix-hack/
-
@mixin clearfix() {
- &:before,
- &:after {
- content: " "; // 1
- display: table; // 2
- }
&:after {
+ content: "";
+ display: table;
clear: both;
}
}
diff --git a/assets/stylesheets/bootstrap/mixins/_image.scss b/assets/stylesheets/bootstrap/mixins/_image.scss
index bec9626..e5ae10a 100644
--- a/assets/stylesheets/bootstrap/mixins/_image.scss
+++ b/assets/stylesheets/bootstrap/mixins/_image.scss
@@ -19,7 +19,7 @@
// Short retina mixin for setting background-image and -size.
@mixin img-retina($file-1x, $file-2x, $width-1x, $height-1x) {
- background-image: url("#{file-1x}");
+ background-image: url($file-1x);
@media
only screen and (-webkit-min-device-pixel-ratio: 2),
@@ -27,7 +27,7 @@
only screen and ( min-device-pixel-ratio: 2),
only screen and ( min-resolution: 192dpi),
only screen and ( min-resolution: 2dppx) {
- background-image: url("#{file-2x}");
+ background-image: url($file-2x);
background-size: $width-1x $height-1x;
}
}
diff --git a/assets/stylesheets/bootstrap/mixins/_list-group.scss b/assets/stylesheets/bootstrap/mixins/_list-group.scss
index a40dda9..81b0f16 100644
--- a/assets/stylesheets/bootstrap/mixins/_list-group.scss
+++ b/assets/stylesheets/bootstrap/mixins/_list-group.scss
@@ -1,13 +1,13 @@
// List Groups
@mixin list-group-item-variant($state, $background, $color) {
- .list-group-item-#{state} {
+ .list-group-item-#{$state} {
color: $color;
background-color: $background;
}
- a.list-group-item-#{state},
- button.list-group-item-#{state} {
+ a.list-group-item-#{$state},
+ button.list-group-item-#{$state} {
color: $color;
.list-group-item-heading {