Skip to content

Commit

Permalink
fix(list): left align numbers (#5100)
Browse files Browse the repository at this point in the history
  • Loading branch information
tw15egan authored and asudoh committed Jan 21, 2020
1 parent 00f87f8 commit d36f6ba
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions packages/components/src/components/list/_list.scss
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,21 @@
margin-top: 0;
}

.#{$prefix}--list--ordered {
list-style-type: decimal;
.#{$prefix}--list--ordered:not(.#{$prefix}--list--nested) {
counter-reset: item;
}

.#{$prefix}--list--ordered:not(.#{$prefix}--list--nested)
> .#{$prefix}--list__item {
position: relative;
}

.#{$prefix}--list--ordered:not(.#{$prefix}--list--nested)
> .#{$prefix}--list__item::before {
content: counter(item) '.';
counter-increment: item;
position: absolute;
left: rem(-24px);
}

.#{$prefix}--list--ordered.#{$prefix}--list--nested {
Expand Down

0 comments on commit d36f6ba

Please sign in to comment.