+ Use sizing function for things like margins, + padding, and borders. Sizes are returned in rem units rather than + pixels, but have been calibrated with pixel equivalents in mind. +
++ To use the rems sizing function, first import the sizing module, + then use it in your code wherever you normally specify a size: +
++@import "variables/sizing"; +border: sizing.rems(xxxxs) solid;+
| Name | +PX Equiv. | +SCSS | +
|---|---|---|
+ {{size.code}}
+ |
+ {{size.pixels}} | +
+ sizing.rems({{size.code}})
+ |
+
+ Paragraphs and headings are preconfigured for typography and margin. +
+
+ To specify custom typography, use the SCSS variables and mixin.
+ The type mixin accepts two parameters: a font size name
+ (required) and an optional font weight name (normal, semibold, bold).
+ This mixin sets both font size and line height, and optionally weight.
+
+@import "utilities/type";
+.my-component {
+ @include type.type(m, bold);
+}
+ | Name | +Font Size | +SCSS | +Note | +
|---|---|---|---|
+ {{size.code}}
+ |
+ {{size.pixels}} | +
+ @include type.type({{size.code}});
+ |
+ + {{size.note}} + | +