mirror of
https://github.com/twbs/bootstrap-sass.git
synced 2022-11-09 12:27:02 -05:00
converter: "$var" => "#{$var}" interpolation (clean diff with convert)
This commit is contained in:
parent
386ab0201a
commit
d5ccfc8976
3 changed files with 13 additions and 9 deletions
|
@ -295,7 +295,8 @@ class Converter
|
|||
|
||||
def replace_escaping(less)
|
||||
less = less.gsub(/\~"([^"]+)"/, '#{\1}') # Get rid of ~"" escape
|
||||
less.gsub!(/\${([^}]+)}/, '$\1') # Get rid of @{} escape
|
||||
less.gsub!(/\$\{([^}]+)\}/, '$\1') # Get rid of @{} escape
|
||||
less.gsub!(/"([^"\n]*)(\$[\w\-]+)([^"\n]*)"/, '"\1#{\2}\3"') # interpolate variable in string, e.g. url("$file-1x") => url("#{$file-1x}")
|
||||
less.gsub(/(\W)e\(%\("?([^"]*)"?\)\)/, '\1\2') # Get rid of e(%("")) escape
|
||||
end
|
||||
|
||||
|
|
|
@ -123,7 +123,7 @@
|
|||
.btn-large {
|
||||
padding: $padding-large-vertical $padding-large-horizontal;
|
||||
font-size: $font-size-large;
|
||||
line-height: 1.33; // ensure even-numbered height of butotn next to large input
|
||||
line-height: 1.33; // ensure even-numbered height of button next to large input
|
||||
border-radius: $border-radius-large;
|
||||
}
|
||||
.btn-small,
|
||||
|
|
17
vendor/assets/stylesheets/bootstrap/_mixins.scss
vendored
17
vendor/assets/stylesheets/bootstrap/_mixins.scss
vendored
|
@ -158,9 +158,9 @@
|
|||
// Default value is `visible`, but can be changed to `hidden`
|
||||
// See git pull https://github.com/dannykeane/bootstrap.git backface-visibility for examples
|
||||
@mixin backface-visibility($visibility){
|
||||
-webkit-backface-visibility: $visibility;
|
||||
-moz-backface-visibility: $visibility;
|
||||
backface-visibility: $visibility;
|
||||
-webkit-backface-visibility: $visibility;
|
||||
-moz-backface-visibility: $visibility;
|
||||
backface-visibility: $visibility;
|
||||
}
|
||||
|
||||
// Background clipping
|
||||
|
@ -230,6 +230,7 @@
|
|||
// --------------------------------------------------
|
||||
|
||||
|
||||
|
||||
// Horizontal gradient, from left to right
|
||||
//
|
||||
// Creates two color stops, start and end, by specifying a color and position for each color stop.
|
||||
|
@ -300,6 +301,7 @@
|
|||
background-image: linear-gradient($angle, rgba(255,255,255,.15) 25%, transparent 25%, transparent 50%, rgba(255,255,255,.15) 50%, rgba(255,255,255,.15) 75%, transparent 75%, transparent);
|
||||
}
|
||||
|
||||
|
||||
// Reset filters for IE
|
||||
//
|
||||
// When you need to remove a gradient background, don't forget to use this to reset
|
||||
|
@ -315,7 +317,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),
|
||||
|
@ -324,7 +326,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;
|
||||
}
|
||||
}
|
||||
|
@ -403,7 +405,7 @@
|
|||
// Navbar vertical align
|
||||
// -------------------------
|
||||
// Vertically center elements in the navbar.
|
||||
// Example: an element has a height of 30px, so write out `@include navbarVerticalAlign(30px);` to calculate the appropriate top margin.
|
||||
// Example: an element has a height of 30px, so write out `.navbar-vertical-align(30px);` to calculate the appropriate top margin.
|
||||
@mixin navbar-vertical-align($element-height) {
|
||||
margin-top: (($navbar-height - $element-height) / 2);
|
||||
margin-bottom: (($navbar-height - $element-height) / 2);
|
||||
|
@ -421,7 +423,7 @@
|
|||
// Responsive utilities
|
||||
// -------------------------
|
||||
// More easily include all the states for responsive-utilities.less.
|
||||
// $parent hack because sass doesn't support tr& (without space)
|
||||
// [converter] $parent hack
|
||||
@mixin responsive-visibility($parent) {
|
||||
#{$parent} { display: block !important; }
|
||||
tr#{$parent} { display: table-row !important; }
|
||||
|
@ -429,6 +431,7 @@
|
|||
td#{$parent} { display: table-cell !important; }
|
||||
}
|
||||
|
||||
// [converter] $parent hack
|
||||
@mixin responsive-invisibility($parent) {
|
||||
#{$parent} { display: none !important; }
|
||||
tr#{$parent} { display: none !important; }
|
||||
|
|
Loading…
Add table
Reference in a new issue