list: inline

view source

De-style a list and inline its items.

use-name
scut-list-inline
type
mixin, with default-values placeholder
arguments
  1. $space
    default
    false

    Spacing to separate the inline list items.

  2. $no-margin
    default
    true

    If true, top and bottom margins will be removed from the list.

Use an inline list if you don't mind that your list items might be spaced out a little extra, like inline words. If you need them flush, with no interstitial space, try a floated list.

Only the list's immediate children are inlined (ul > li): Scut does not presume to know what you might plan to do with sub-lists.

example

SCSS

.eg-list-inline-1 {
  @include scut-list-inline;
  // or @extend %scut-list-inline;
  }
.eg-list-inline-2 {
  @include scut-list-inline(1em, false);
}

Result

  • list item 1
  • list item 2
  • list item 3
  • list item 1
  • list item 2
  • list item 3