Breakpoint
functions
[private] _breakpoint-get-property-value-string
@function _breakpoint-get-property-value-string($list) { ... }
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$list | — none | List | — none |
Returns
String
Used by
- [mixin]
_breakpoint-queries
- [mixin]
_breakpoint-queries
Author
Calvin Davis
[private] _breakpoint-is-property-value-pair
@function _breakpoint-is-property-value-pair($list) { ... }
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$list | — none | List | — none |
Returns
Boolean
Used by
- [mixin]
_breakpoint-queries
Author
Calvin Davis
mixins
[private] _breakpoint-queries
@mixin _breakpoint-queries($queries) { ... }
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$queries | — none | List | — none |
Requires
- [function]
_breakpoint-is-property-value-pair
- [function]
_breakpoint-get-property-value-string
- [function]
_breakpoint-get-property-value-string
Used by
- [mixin]
breakpoint
- [mixin]
breakpoint
- [mixin]
breakpoint
- [mixin]
breakpoint
Author
Calvin Davis
breakpoint
@mixin breakpoint($query) { ... }
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$query | — none | List | — none |
Example
Input
$mobile: max-width 560px;
$tablet: 561px 1024px;
$desktop: 1025px;
body {
@include breakpoint($mobile) {
font-size: 14px;
}
@include breakpoint($tablet) {
font-size: 16px;
}
@include breakpoint($desktop) {
font-size: 18px;
}
}
Output
@media (max-width: 560px) {
body {
font-size: 14px;
}
}
@media (min-width: 561px) and (max-width: 1024px) {
body {
font-size: 16px;
}
}
@media (min-width: 1025px) {
body {
font-size: 18px;
}
}
Requires
- [mixin]
_breakpoint-queries
- [mixin]
_breakpoint-queries
- [mixin]
_breakpoint-queries
- [mixin]
_breakpoint-queries
Author
Calvin Davis
Layout
mixins
absolute
@mixin absolute($values: ()) { ... }
Description
Sets position absolute
, and top
, right
, bottom
, and left
values.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$values | — none | List<number> | () |
Requires
- [mixin]
position
Used by
- [mixin]
absolute-top-left
Author
Calvin Davis
absolute-top-left
@mixin absolute-top-left($top: 0, $left: $top) { ... }
Description
Sets position absolute
, and top
and left
values.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$top | — none | Number | 0 |
$left | — none | Number | $top |
Requires
- [mixin]
absolute
Used by
- [mixin]
absolute-fill
Author
Calvin Davis
absolute-fill
@mixin absolute-fill() { ... }
Description
Sets position absolute
, and width
and height
to 100%
.
Parameters
None.
Requires
- [mixin]
absolute-top-left
- [mixin]
size
Author
Calvin Davis
child-margins-x
@mixin child-margins-x($margin: 0) { ... }
Description
Sets margin-left
and margin-right
of first and last child respectively.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$margin | — none | Number | 0 |
Author
Calvin Davis
child-margins-y
@mixin child-margins-y($margin: 0) { ... }
Description
Sets margin-top
and margin-bottom
of first and last child respectively.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$margin | — none | Number | 0 |
Author
Calvin Davis
fixed
@mixin fixed($values: ()) { ... }
Description
Sets position fixed
, and top
, right
, bottom
, and left
values.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$values | — none | List<number> | () |
Requires
- [mixin]
position
Used by
- [mixin]
fixed-top-left
Author
Calvin Davis
fixed-top-left
@mixin fixed-top-left($top: 0, $left: $top) { ... }
Description
Sets position fixed
, and top
and left
values.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$top | — none | Number | 0 |
$left | — none | Number | $top |
Requires
- [mixin]
fixed
Used by
- [mixin]
fixed-fill
Author
Calvin Davis
fixed-fill
@mixin fixed-fill() { ... }
Description
Sets position fixed
, and width
and height
to 100%
.
Parameters
None.
Requires
- [mixin]
fixed-top-left
- [mixin]
size
Author
Calvin Davis
flex
@mixin flex($justify-content, $align-items, $flex-wrap, $flex-direction) { ... }
Description
Sets flex
, justify-content
, align-items
, flex-wrap
and flex-direction
properties.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$justify-content | [""] Justify content | String | — none |
$align-items | [""] Align items | String | — none |
$flex-wrap | [""] Flex wrap | String | — none |
$flex-direction | [""] Flex direction | String | — none |
Author
Zed Barker-Flower
position
@mixin position($position, $values: ()) { ... }
Description
Sets position
, and top
, right
, bottom
, and left
values.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$position | — none | Position | — none |
$values | — none | List<number> | () |
Requires
- [function]
to-trbl
Used by
Author
Calvin Davis
functions
columns
@function columns($columns, $column-count) { ... }
Description
Returns percentage size values for columns.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$columns | Columns | Number | — none |
$column-count | [$gort-default-column-count] Column count | Number | — none |
Author
Mike Masey
to-trbl
@function to-trbl($values) { ... }
Description
Returns list of sizes in TRBL (top, right, bottom, left) format.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$values | — none | Number[] | — none |
Returns
Number[]
Example
to-trbl(1em)
// (1em 1em 1em 1em)
to-trbl(1em 0)
// (1em 0 1em 0)
to-trbl(1em 0 100px)
// (1em 0 100px 0)
to-trbl(1em 0 100px 50%)
// (1em 0 100px 50%)
Used by
- [mixin]
position
Author
Calvin Davis
variables
gort-default-column-count
$gort-default-column-count: 24 !default;
Description
Default column count.
Author
Mike Masey
Typography
mixins
[private] _font-face-content
@mixin _font-face-content($family, $path, $weight: null, $formats: $gort-default-font-face-formats) { ... }
Description
Outputs @font-face
directive. Splitting of font-face content into own mixin is necessary because of a True bug.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$family | Font family | String | — none |
$path | Path to font files (not including file extensions) | String | — none |
$weight | Font weight | Weight | null |
$formats | List of formats | List | $gort-default-font-face-formats |
Used by
- [mixin]
font-face
Author
Calvin Davis
font-face
@mixin font-face($family, $path, $weight: null, $formats: $gort-default-font-face-formats) { ... }
Description
Outputs @font-face
directive.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$family | Font family | String | — none |
$path | Path to font files (not including file extensions) | String | — none |
$weight | Font weight | Weight | null |
$formats | List of formats | List | $gort-default-font-face-formats |
Requires
- [mixin]
_font-face-content
Author
Calvin Davis
font-sizing
@mixin font-sizing($font-size, $line-height, $letter-spacing: undefined) { ... }
Description
Applies font-size, line-height and letter-spacing all at once.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$font-size | [undefined] Font size | Number | — none |
$line-height | [undefined] Line height | Number | — none |
$letter-spacing | Letter spacing | Number | undefined |
Requires
- [function]
rem
- [function]
letter-spacing
Author
Zed Barker-Flower
font
@mixin font($settings) { ... }
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$settings | A map of key value pairs for the properties to set for your font | Map | — none |
Example
Input
$font-h1: (
font-family: (Arial, sans-serif),
font-size: 2em,
text-transform: uppercase
)
$font-h2: map-merge($font-h1, (
font-size: 1.5em,
font-style: italic
))
h1 {
@include font($font-h1);
}
h2 {
@include font($font-h2);
}
Output
h1 {
font-family: Arial, sans-serif;
font-size: 2em;
text-transform: uppercase;
}
h2 {
font-family: Arial, sans-serif;
font-size: 1.5em;
font-style: italic;
text-transform: uppercase;
}
Authors
Tom (Alfie) Gaskill
Calvin Davis
variables
gort-default-font-face-formats
$gort-default-font-face-formats: (woff2: woff2, woff: woff) !default;
Description
Default @font-face
formats.
Author
Calvin Davis
functions
letter-spacing
@function letter-spacing($px, $browser-context) { ... }
Description
Applies font-size, line-height and letter-spacing all at once.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$px | Font size | Number | — none |
$browser-context | [$gort-default-base-font-size] Base font size | Number | — none |
Used by
- [mixin]
font-sizing
Author
Mike Masey
General
mixins
align-center
@mixin align-center($axis: "xy", $position: null) { ... }
Description
Applies center alignment styles.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$axis | Alignment type. Can be | String | "xy" |
$position | Position value. Can be any css position value, e.g. | Position | null |
Example
Input
.feeb {
@include align-center;
}
.foo {
@include align-center("x");
}
.bar {
@include align-center("y", relative);
}
.foo-bar {
@include align-center($position: absolute);
}
Output
.feeb {
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}
.foo {
left: 50%;
transform: translateX(-50%);
}
.bar {
position: relative;
top: 50%;
transform: translateY(-50%);
}
.foo-bar {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}
Author
Mike Masey
arrow
@mixin arrow($direction: "right", $width: 10px, $height: $width, $color: currentColor) { ... }
Description
Creates a CSS arrow.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$direction | Arrow direction. Can be | String | "right" |
$width | Base length of arrow | Number | 10px |
$height | Height of arrow | Number | $width |
$color | Color of arrow | Color | currentColor |
Requires
- [mixin]
size
Links
Author
Calvin Davis
aspect-ratio
@mixin aspect-ratio($ratio: 100%) { ... }
Description
Add a percentage value for padding-bottom on the ::after pseudo element to maintain the aspect ratio of the parent e.g. 56.25% would be an aspect ratio of 16:9.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$ratio | Aspect ratio as a percentage | Percentage | 100% |
Links
Author
Tom (Alfie) Gaskill
audio-only
@mixin audio-only() { ... }
Description
Applies audio-only styling.
Parameters
None.
Used by
- [mixin]
audio-only-class
Authors
Calvin Davis
Mike Masey
audio-only-class
@mixin audio-only-class($selector: ".audio-only") { ... }
Description
Renders audio-only class.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$selector | Optional selector string | String | ".audio-only" |
Requires
- [mixin]
audio-only
Authors
Calvin Davis
Mike Masey
boost
@mixin boost($count: 1) { ... }
Description
Multiplies the specificity of a selector.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$count | The number of times to increase the specificity of the selector. | Number | 1 |
Example
Input
.foo {
@include boost() {
color: red;
}
@include boost(2) {
color: green;
}
}
Output
.foo.foo {
color: red;
}
.foo.foo.foo {
color: green;
}
Author
Calvin Davis
clearfix
@mixin clearfix() { ... }
Description
Applies clearfix styling.
Parameters
None.
Used by
- [mixin]
clearfix-class
Links
Author
Calvin Davis
clearfix-class
@mixin clearfix-class($selector: ".clearfix") { ... }
Description
Renders clearfix class.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$selector | Optional selector string | String | ".clearfix" |
Requires
- [mixin]
clearfix
Author
Calvin Davis
margin-x
@mixin margin-x($value: 0) { ... }
Description
Applies margin-right and -left at once.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$value | — none | Value | 0 |
Requires
- [mixin]
property-x
Author
Calvin Davis
margin-y
@mixin margin-y($value: 0) { ... }
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$value | — none | Value | 0 |
Requires
- [mixin]
property-y
Author
Calvin Davis
normalize
@mixin normalize() { ... }
Description
Outputs Normalize rules.
Parameters
None.
Links
Author
Calvin Davis
padding-x
@mixin padding-x($value: 0) { ... }
Description
Applies padding-right and -left at once.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$value | — none | Value | 0 |
Requires
- [mixin]
property-x
Author
Calvin Davis
padding-y
@mixin padding-y($value: 0) { ... }
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$value | — none | Value | 0 |
Requires
- [mixin]
property-y
Author
Calvin Davis
property-multi
@mixin property-multi($property, $list, $value) { ... }
Description
Sets multiple subproperties at once.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$property | Property name | Property | — none |
$list | List of subproperties | List | — none |
$value | Value to be assigned to all subproperties | Value | — none |
Used by
- [mixin]
property-x
- [mixin]
property-y
Author
Calvin Davis
property-x
@mixin property-x($property, $value) { ... }
Description
Set -right and -left properties at once.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$property | Property name | Property | — none |
$value | Value to be assigned to -right and -left | Value | — none |
Requires
- [mixin]
property-multi
Used by
Author
Calvin Davis
property-y
@mixin property-y($property, $value) { ... }
Description
Set -top and -bottom properties at once.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$property | Property name | Property | — none |
$value | Value to be assigned to -top and -bottom | Value | — none |
Requires
- [mixin]
property-multi
Used by
Author
Calvin Davis
reset
@mixin reset() { ... }
Description
Outputs frequently used reset rules.
Parameters
None.
Authors
Calvin Davis
Tom (Alfie) Gaskill
Mike Masey
size
@mixin size($width: 0, $height: $width) { ... }
Description
Sets width
and height
.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$width | — none | Number | 0 |
$height | — none | Number | $width |
Example
Input
.square {
@include size(1em);
}
.rectangle {
@include size(2em, 1em);
}
Output
.square {
width: 1em;
height: 1em;
}
.rectangle {
width: 2em;
height: 1em;
}
Used by
- [mixin]
absolute-fill
- [mixin]
fixed-fill
- [mixin]
arrow
Author
Calvin Davis
variables
gort-default-base-font-size
$gort-default-base-font-size: 16 !default;
Description
Default base font-size
px value.
Author
Mike Masey
functions
em
@function em($px, $browser-context: $gort-default-base-font-size) { ... }
Description
Converts a px value to em value.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$px | Pixel value | Number | — none |
$browser-context | Base font size | Number | $gort-default-base-font-size |
Author
Mike Masey
rem
@function rem($px, $browser-context: $gort-default-base-font-size) { ... }
Description
Converts a px value to rem value.
Parameters
parameter Name | parameter Description | parameter Type | parameter Default value |
---|---|---|---|
$px | Pixel value | Number | — none |
$browser-context | Base font size | Number | $gort-default-base-font-size |
Used by
- [mixin]
font-sizing
Author
Mike Masey