@each $size, $headers in $header-sizes {
$header-map: ();
@each $header, $font-size in $headers {
- $header-map: map-merge($header-map, ($header: ('font-size': $font-size)));
+ $header-map: map-merge($header-map, ($header: ('font-size': $font-size)));
}
$header-styles: map-merge($header-styles, ($size: $header-map));
}
/// @type List
$blockquote-border: 1px solid $medium-gray !default;
-/// Text color for `<cite>` elements.
-/// @type Color
-$cite-color: $dark-gray !default;
+/// Use the `.cite-block` component as default for `<cite>` elements.
+/// @type Boolean
+$enable-cite-block: true;
/// Font family for `<kbd>` elements.
/// @type String | List
line-height: $paragraph-lineheight;
color: $blockquote-color;
}
-
- // Citations
- cite {
- @include block-citation;
- }
}
// Inline Citations
- cite {
- color: $cite-color;
+ @if ($enable-cite-block == true) {
+ cite {
+ // Extending a class is not recommanded.
+ // TODO: Break the typography-base/typography-helpers separation
+ @extend .cite-block;
+ }
}
// Abbreviations
figure {
margin: 0;
}
-
+
// Code
code {
padding: $code-padding;
/// @group typography-helpers
////
-
-/// Font size for `<cite>` elements.
-/// @type Number
-$cite-font-size: rem-calc(13) !default;
-
-/// Pseudo content for `<cite>` elements.
-/// @type String
-$cite-pseudo-content: '\2014 \0020' !default;
-
/// Default font size for lead paragraphs.
/// @type Number
$lead-font-size: $global-font-size * 1.25 !default;
/// @type Number
$stat-font-size: 2.5rem !default;
+/// Text color for `.cite-block` component.
+/// @type Color
+$cite-color: $dark-gray !default;
+
+/// Font size for `.cite-block` component.
+/// @type Number
+$cite-font-size: rem-calc(13) !default;
+
+/// Pseudo content for `.cite-block` component.
+/// @type String
+$cite-pseudo-content: '\2014 \0020' !default;
+
+
+@mixin cite-block {
+ display: block;
+ color: $cite-color;
+ font-size: $cite-font-size;
+
+ &:before {
+ content: $cite-pseudo-content;
+ }
+}
+
@mixin foundation-typography-helpers {
// Use to create a subheading under a main header
// Make sure you pair the two elements in a <header> element, like this:
list-style: none;
}
}
-}
-@mixin block-citation {
- // Use to restore the block version of cite elements
- display: block;
- font-size: $cite-font-size;
-
- &:before {
- content: $cite-pseudo-content;
+ .cite-block {
+ @include cite-block;
}
}