The collation of common functions of SASS

Source: Internet
Author: User
@charset "Utf-8"; @import "Compass/css3/inline-block"; @import "Compass/css3/border-radius"; @import "compass/  Utilities/sprites "; @import" compass/utilities/general "; @mixin position ($top, $right, $bottom, $left) {top: $top;  Right: $right;  Bottom: $bottom; Left: $left;}  Size @mixin mysize ($width, $height: $width) {width: $width; Height: $height;}  /* Row height, compatible with ie8*/@mixin lineheight ($value) {line-height: $value;  Line-height: $value \9; Line-height: $value;} The background is transparent and the text is opaque.  Compatible with Ie8@mixin bettertransparentize ($color, $alpha) {$c: Rgba ($color, $alpha);  $ie _c:ie_hex_str ($c);  Background:rgba ($color, 1);  Background: $c;  Background:transparent \9;  Zoom:1;  Filter:progid:DXImageTransform.Microsoft.gradient (startcolorstr=#{$ie _c}, endcolorstr=#{$ie _c}); -ms-filter: "Progid:DXImageTransform.Microsoft.gradient (startcolorstr=#{$ie _c}, endcolorstr=#{$ie _c})"; Add browser prefix @mixin browserprefix ($propertyName, $value) {@each $prefix in-webkit-,-Moz-,-Ms-,-O, ' {#{$prefix}#{$p Ropertyname}: $vaLue  }}//min. height @mixin minheight ($height) {min-height: $height;  Height:auto!important;  @if $legacy-support-for-ie {_height: $height;    }}//Fixed-width sub-elements, horizontally vertically centered @mixin center ($width: null, $height: null) {@if $width and $height {position:absolute;    left:50%;    top:50%;    Display:block;    Margin-left:-($width/2);  Margin-top:-($height/2);  }//@if not $width and not $height {//@include Browserprefix (-transform,translate (-50%,-50%));  } @else if $width and $height {//margin:-($width/2) #{0 0}-($height/2);  } @else if not $height {//width: $width;  Margin-left:-($width/2);  @include Browserprefix (Transform,translatey (-50%));  } @else {//Margin-top:-($height/2);  @include Browserprefix (Transform,translatex (-50%));  }}//fillet, compatible with ie8@mixin radius ($value) {@include Border-radius ($value); -ms-behavior:url (./css/pie-1.0.0/pie.htc);}
  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.