mirror of
https://github.com/status-im/consul.git
synced 2025-02-21 18:08:23 +00:00
We've always had this idea of being able to markup up information semantically without thinking about what it should look like, then applying our %h* placeholder styles to control what the information should look like. Back when we originally made our set of %h* placeholders, we tried to follow Structure as much as possible, which defined the largest header (which we thought would have been the h1 style) as a super large 3.5rem. Therefore we made our set of %h* placeholders the same as Structure beginning at a huge 3.5 size. We then re-overwrote those sizes only in Consul specific CSS files thinking that this was due to us existing before Structure did. Lately we saw an extra clue in Structure - the extra large 3.5 header was called 'h0'. This commit moves all our headers to use a zero based scale, and additionally uses our 3 digit scale as opposed to 1 digit (h1 vs h100), similar to our color scales (note we don't use a hypen, which we can alter later if need be), which means we can insert additional h150 etc if need be. Additional we stop styling our headers globally (h1 { @extend %h100; } ). This means there is no reason not to use headers for marking up content depending on what it is rather than what it should look like, and as a consequence means we can be more purposeful in ordering h* tags. Lastly, we use the new scale over the entire codebase and update a couple of places where we were using using header tags due to what the styleing for them looked like rather than what the meaning/order was.
51 lines
1019 B
SCSS
51 lines
1019 B
SCSS
%empty-state {
|
|
color: $gray-500;
|
|
background-color: $gray-010;
|
|
}
|
|
%empty-state > ul {
|
|
border-color: $gray-300;
|
|
}
|
|
%empty-state-header {
|
|
border-bottom: none;
|
|
}
|
|
%empty-state-header {
|
|
@extend %h200;
|
|
}
|
|
/* Icons */
|
|
%empty-state header::before {
|
|
font-size: 2.6em;
|
|
position: relative;
|
|
top: -3px;
|
|
float: left;
|
|
margin-right: 10px;
|
|
}
|
|
%empty-state-anchor::before {
|
|
margin-right: 0.5em;
|
|
font-size: 0.9em;
|
|
}
|
|
%empty-state[class*='status-'] header::before {
|
|
@extend %as-pseudo;
|
|
}
|
|
%empty-state header::before {
|
|
@extend %with-alert-circle-outline-mask;
|
|
}
|
|
%empty-state.status-404 header::before {
|
|
@extend %with-help-circle-outline-mask;
|
|
}
|
|
%empty-state.status-403 header::before {
|
|
@extend %with-disabled-mask;
|
|
}
|
|
%empty-state li[class*='-link'] > *::after {
|
|
@extend %as-pseudo;
|
|
margin-left: 5px;
|
|
}
|
|
%empty-state .docs-link > *::after {
|
|
@extend %with-docs-mask;
|
|
}
|
|
%empty-state .back-link > *::after {
|
|
@extend %with-chevron-left-mask;
|
|
}
|
|
%empty-state .learn-link > *::after {
|
|
@extend %with-learn-mask;
|
|
}
|