hackertours-theme/assets/sass/components/list-straight-left/_list-straight-left.scss

52 lines
814 B
SCSS

// Lists with a straight left margin.
%ul-straight-left {
display: table;
list-style: none;
padding: 0;
& > li {
display: table-row;
&::before {
@include padding-right(.5);
display: table-cell;
content: '\2022';
font-size: var(--fs-s);
}
}
}
%ol-straight-left {
display: table;
list-style: none;
padding: 0;
& > li {
display: table-row;
counter-increment: table-ol;
&::before {
@include padding-right(.5);
display: table-cell;
content: counter(table-ol) '.';
font-size: var(--fs-s);
text-align: right;
}
}
}
%ul-straight-left--off {
display: block;
list-style: inherit;
& > li {
display: list-item;
&::before {
content: '';
display: inline;
padding: inherit;
}
}
}