Deprecation Warning: This mixin has been deprecated and will be removed in v5.0.
The animation mixin supports comma separated lists of values, which allows different transitions for individual properties to be described in a single style rule. Each value in the list corresponds to the value at that same position in the other properties.
Deprecation Warning: This mixin has been deprecated and will be removed in v5.0.
The CSS backface-visibility property determines whether or not the back face of the element is visible when facing the user. The back face of an element always is a transparent background, letting, when visible, a mirror image of the front face be displayed.
Deprecation Warning: This mixin has been deprecated and will be removed in v5.0.
The background-image mixin is helpful for chaining multiple comma delimited background images and/or linear/radial-gradients into one background-image property. The background-image mixin supports up to 10 background-images.
All CSS background properties support comma delimited values. For multiple background images you can specify the background properties like position, repeat, etc. for each image. For example:
Deprecation Warning: This mixin has been deprecated and will be removed in v5.0.
The hidpi mixin allows you to generate a media query that targets HiDPI devices. It accepts an optional ratio argument, with the default ratio being 1.3. Find my device pixel ratio.
Deprecation Warning: This mixin has been deprecated and will be removed in v5.0.
The hyphens property tells the browser how to split words when wrapping lines. The mixin accepts either none, manual, or auto, and defaults to none if left blank.
Deprecation Warning: This mixin has been deprecated and will be removed in v5.0.
The perspective CSS property determines the distance between the z=0 plane and the user in order to give to the 3D-positioned element some perspective.
The perspective-origin CSS property determines the position the viewer is looking at. It is used as the vanishing point by the perspective property.
Deprecation Warning: This mixin has been deprecated and will be removed in v5.0.
The CSS transform property lets you modify the coordinate space of the CSS visual formatting model. Using it, elements can be translated, rotated, scaled, and skewed according to the values set
The transform-origin CSS property lets you modify the origin for transformations of an element.
The transform-style CSS property determines if the children of the element are positioned in the 3D-space or are flattened in the plane of the element.
Deprecation Warning: This mixin has been deprecated and will be removed in v5.0.
This mixin provides a shorthand syntax and supports multiple transitions.
To transition vendor-prefixed properties, e.g. -webkit-transform and -moz-transform, do not use the shorthand mixin. Instead, use the individual transition mixins:
Deprecation Warning: This mixin has been deprecated and will be removed in v5.0.
Controls the appearance (only) of selection. This does not have any affect on actual selection operation.
Functions
Flex Grid
Deprecation Warning: The flex-grid has been moved to Neat and will be removed in v5.0.
Use this mixin to easily create a flexible-grid layout.
The $fg-column, $fg-gutter and $fg-max-columns variables must be defined in your base stylesheet to properly use the flex-grid function.
This function takes the fluid grid equation (target / context = result) and uses columns to help define each.
Golden Ratio
Deprecation Warning: The golden-ratio function has been deprecated and will be removed in v5.0. Use the modular-scale function instead.
Returns the golden ratio of a given number. Must provide a pixel or em value for the first argument. Also takes a required integer for an increment value: ...-3, -2, -1, 0, 1, 2, 3...
Note: The golden-ratio function can be wrapped in Sass’s abs(), floor(), or ceil() functions to get the absolute value, round down, or round up, respectively.
This function increments up or down a defined scale, then returns an adjusted value. This helps establish consistent measurements and spacial relationships throughout your project. We provide a list of commonly used scales as pre-defined variables.
The default scale is the perfect fourth (1.333), which you can globally override:
The function also supports double-stranded scales by passing it two base values.
Note: The function can be wrapped in Sass’s abs(), floor(), or ceil() functions to get the absolute value, round down or round up, respectively.
Deprecation Warning: This function has been deprecated and will be removed in v5.0.
Convert pixels to ems.
For a relational value, the input is calculated based on a parent value. The default parent is 16px. The parent can be changed by passing an optional second value. Accepts unitless and pixel values for size.
The border-width mixin accepts up to four widths, including null, and uses the directional-property mixin to map them to their respective directions.
CSS Output
Button
Deprecation Warning: The button mixin has been deprecated and will be removed in v5.0. Take a look at Bitters, which includes basic styles for buttons.
The button add-on provides well-designed buttons with a single line in your CSS.
The mixin supports a style parameter and an optional color argument. The available button styles are:
simple (default)
shiny
pill
Simple Button Style
The mixin can be called with no arguments, which will render a blue button with the simple style.
Pill Button Style
Shiny Button Style
Create beautiful buttons by defining a style and color argument; using a single color, the mixin calculates the gradient, borders, box shadow, text shadow and text color of the button. The mixin will change the text to be light when on a dark background, and dark when on a light background.
Deprecation Warning: This mixin has been deprecated and will be removed in v5.0.
A helper mixin enabling short-hand notation for directional properties. It accepts a prefix, suffix, and array of up to four values that map to top, right, bottom, and left, respectively. You can optionally pass in null for the suffix argument to ignore it. You can optionally pass a null argument for a directional value to ignore it.
The first argument is optional and defaults to relative. The second argument is a space-delimited list of values for top, right, bottom and left; it follows the standard CSS shorthand notation.
Note:null values will be ignored. In the example below, this means that declarations will not be generated for the right and bottom properties.
Deprecation Warning: This mixin has been deprecated and will be removed in v5.0.
The retina-image mixin is a helper to generate a retina background image and non-retina background image. The retina background image will output to a HiDPI media query. The mixin uses a _2x.png filename suffix by default.
$filename will resolve a path to the image, e.g. "../../home-icon". For Rails, you can use the Asset Pipeline by passing true to the argument.
Set width and height in a single statement. Accepts all units, including auto and inherit, unitless numbers, and intrinsic keywords like fill, max-content, min-content & fit-content. You can also use this mixin with the calc() CSS function.
These CSS cubic-bezier timing functions are variables that can be used with CSS3 animations and transitions. The provided timing functions are the same as the jQuery UI demo: easing functions.
By default, Bourbon outputs all vendor-prefixes specified by each mixin. You can optionally overwrite these global defaults by setting any of these variables to false at the top of your stylesheet.
Complete List
All Supported Functions, Mixins, and Addons
@ denotes a mixin and must be prefaced with @include.