diff options
| author | Armand Philippot <git@armandphilippot.com> | 2022-05-09 18:19:38 +0200 |
|---|---|---|
| committer | Armand Philippot <git@armandphilippot.com> | 2022-05-09 19:41:02 +0200 |
| commit | 0d59a6d2995b4119865271ed1908ede0bb96497c (patch) | |
| tree | 67688e41b7aa253aa58cc08aa360431b07382f9d /src/components/atoms/lists/description-list.module.scss | |
| parent | 339c6957fe92c4ec1809159f09c55201d3794c18 (diff) | |
refactor: rewrite DescriptionList and Meta components
The meta can have different layout. The previous implementation was not
enough to easily change the layout. Also, I prefer to restrict the meta
types and it prevents me to repeat myself for the labels.
Diffstat (limited to 'src/components/atoms/lists/description-list.module.scss')
| -rw-r--r-- | src/components/atoms/lists/description-list.module.scss | 49 |
1 files changed, 6 insertions, 43 deletions
diff --git a/src/components/atoms/lists/description-list.module.scss b/src/components/atoms/lists/description-list.module.scss index caa2711..9e913d4 100644 --- a/src/components/atoms/lists/description-list.module.scss +++ b/src/components/atoms/lists/description-list.module.scss @@ -2,53 +2,16 @@ .list { display: flex; - flex-flow: column wrap; - gap: var(--spacing-2xs); + column-gap: var(--spacing-md); + row-gap: var(--spacing-2xs); margin: 0; - &__term { - flex: 0 0 max-content; - color: var(--color-fg-light); - font-weight: 600; + &--inline { + flex-flow: row wrap; + align-items: baseline; } - &__description { - flex: 0 0 auto; - margin: 0; - } - - &__item { - display: flex; - } - - &--inline &__item { - flex-flow: column wrap; - - @include mix.media("screen") { - @include mix.dimensions("xs") { - flex-flow: row wrap; - gap: var(--spacing-2xs); - - .list__description:not(:first-of-type) { - &::before { - content: "/"; - margin-right: var(--spacing-2xs); - } - } - } - } - } - - &--column#{&}--responsive { - @include mix.media("screen") { - @include mix.dimensions("xs") { - flex-flow: row wrap; - gap: var(--spacing-lg); - } - } - } - - &--column &__item { + &--column { flex-flow: column wrap; } } |
