Aspect Ratio
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
ratio | <int>:<int> |
16:9 |
Yes |
References
Border Color
Provides a quick method for targeting border-color
on specific sides of a box.
- Use a
null
value to “skip” a side. - You can define a list of color by a CSS shorthand.
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
colors | color values separated by spaces | - | No |
Border Radius
Provides a shorthand syntax to add border-radius
to both the top-left and top-right of an element.
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
radius | border radius size | 3px |
Yes |
Border Style
Provides a quick method for targeting border-style
on specific sides of a box.
- Use a
null
value to “skip” a side. - You can define a list of border styles by a CSS shorthand.
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
border styles | border styles values separated by spaces | - | No |
Border Width
Provides a quick method for targeting border-width
on specific sides of a box.
- Use a
null
value to “skip” a side. - You can define a list of sizes by a CSS shorthand.
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
sizes | sizes values separated by spaces | - | No |
Center
Block-level element of an unknown height and width, centered vertically within his parent.
Transform Method (default)
Note: You should add position: relative
to the parent element.
Flexbox Method
Add to options: { centerMethod: 'flexbox' }
to use this method.
Center Block
Center block with a width.
Circle
Create a simple circle figure.
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
radius | size | 100px |
Yes |
color | color | #000 |
Yes |
Clear Fix
The clearfix hack is a popular way to contain floats without resorting to using presentational markup.
Clear Fix for IE8
Add to options: { ie8: true }
to use this method.
References
HD Breakpoint
Style adjustments for high resolution devices.
Parameters
Parameter | Type | Default | Optional | |
---|---|---|---|---|
min-resolution | resolution value (dpi | dppx) | 120dpi |
Yes |
Note: If you set dpi
the utility will calculate the dppx
equivalent, and vice versa.
References
Hide Visually
Only display content to screen readers.
References
Horizontal rule
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
color | color | #ccc |
Yes |
vertical-margin | size | 1em |
Yes |
style | border style | solid |
Yes |
height | size | 1px |
Yes |
Margin
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
sizes | sizes values separated by spaces | No |
No Hover
Note: You should add .no-hover
class to the html
tag when the browser or device doesn’t support hover
.
Change noHoverSelector
option to use your own selector:
{ noHoverSelector: '.my-selector' }
References
No JS
Note: You should add .no-js
class to the html
tag when the browser or device doesn’t support JavaScript.
Change noJsSelector
option to use your own selector:
{ noJsSelector: '.my-selector' }
Padding
Provides a quick method for targeting padding
on specific sides of a box.
- Use a
null
value to “skip” a side. - You can define a list of sizes by a CSS shorthand.
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
sizes | size values separated by spaces | - | No |
Position
Provides a quick method for setting an element’s position. Use a null
value to “skip” a side.
- Use a
null
value to “skip” a side. - You can define a list of sizes by a CSS shorthand.
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
position | CSS position value | - | No |
lengths | lengths values separated by spaces | - | No |
Reset list
Remove default styles for lists.
Reset text
Remove default styles for text.
Size
Sets the width
and height
of the element in one statement.
Parameter | Type | Default | Optional |
---|---|---|---|
width | unit size or auto |
- | No |
height | unit size or auto |
width | Yes |
Sticky Footer
Ensures that the fixed height footer is kept down at the bottom of the viewport, even if the content is short.
Parameter | Type | Default | Optional |
---|---|---|---|
footer height | size unit | - | No |
wrapper selector | string | "body" |
Yes |
Note: You should set position: relative;
and min-height: 100%;
fot html
tag.
References
Text hide
CSS image replacement.
Indent technique (default)
Note: It should be a block element.
Font technique
Add to options: { textHideMethod: 'font' }
to use this method.
References
Text stroke
Add text stroke with text shadow effect: Example on CodePen
Parameter | Type | Default | Optional |
---|---|---|---|
size | unit size | 1px |
No |
color | color value | #000 |
No |
smooth | string | - | Yes |
References
Triangle
Create triangle figures.
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
size | size | 12px |
Yes |
color | color | #000 |
Yes |
orientation | {up , down , left , right , up-left , up-right , down-left , down-right } |
down |
Yes |
Truncate
This mixin will truncate text, adding an ellipsis to represent overflow.
Single line
Multiline
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
lines | int |
3 |
Yes |
line-height | unitless line-height value | 1 |
Yes |
Note: Multiline ellipsis is not supported by Firefox, Edge & IE.
References
Word Wrap
Easy way to change the word-wrap
property.
Parameters
Parameter | Type | Default | Optional |
---|---|---|---|
wrap | normal | break-word | initial | inherit |
break-word |
Yes |