diff options
| author | Armand Philippot <git@armandphilippot.com> | 2022-04-05 23:10:44 +0200 | 
|---|---|---|
| committer | Armand Philippot <git@armandphilippot.com> | 2022-04-05 23:10:44 +0200 | 
| commit | 655ed38c6cd53a19c6ba1ebab5f2429441b99a58 (patch) | |
| tree | b7107d8c89580b7b13a35c6d4453bb6362e56a63 /src/components/atoms/lists/list.module.scss | |
| parent | 57568e61c22c41c073f4db59992735387e8372fe (diff) | |
chore: add a List component
Diffstat (limited to 'src/components/atoms/lists/list.module.scss')
| -rw-r--r-- | src/components/atoms/lists/list.module.scss | 39 | 
1 files changed, 39 insertions, 0 deletions
| diff --git a/src/components/atoms/lists/list.module.scss b/src/components/atoms/lists/list.module.scss new file mode 100644 index 0000000..c6fbf53 --- /dev/null +++ b/src/components/atoms/lists/list.module.scss @@ -0,0 +1,39 @@ +.list { +  margin: 0; + +  ::marker { +    color: var(--color-primary-dark); +  } + +  & & { +    margin-top: var(--spacing-2xs); +  } + +  &__item { +    &:not(:last-child) { +      margin-bottom: var(--spacing-2xs); +    } +  } + +  &--ordered { +    padding: 0; +    counter-reset: li; +    list-style-type: none; +  } + +  &--ordered &__item { +    display: table; +    counter-increment: li; + +    &::before { +      content: counters(li, ".") ". "; +      display: table-cell; +      padding-right: var(--spacing-2xs); +      color: var(--color-secondary); +    } +  } + +  &--unordered { +    padding: 0 0 0 var(--spacing-sm); +  } +} | 
