Lists

THE BUTTER

  • .normal
  • .nestedlist
  • .alist
  • .blist
  • .rowlist
  • .commalist

By default, ul and ol are normalized to display no type, and no paddings and margins.

Normal list

<ul class="normal">
    <li>Normal list</li>
    <li>With disc style type</li>
</ul>

<ol class="normal">
    <li>Normal ordered list</li>
    <li>With decimal style type</li>
</ol>
  • Normal list
  • With disc style type
  1. Normal ordered list
  2. With decimal style type

Nested

<ul class="nestedlist">
    <li>First element
        <ul>
            <li>Sub list</li>
        </ul>
    </li>
    <li>Second element</li>
</ul>

<div class="nestedlist">
    Paragraph
    <ul>
        <li>Sub list</li>
    </ul>
</div>
  • First element
    • Sub list
  • Second element
Paragraph
  • Sub list

A list

A list adds margin bottom, and padding bottom (logical properties) to every list item, defined by @list-spacing, the quickest way to place items in a list.

<ul class="alist">
    <li>A list item</li>
    <li>A list item</li>
    <li>A list item</li>
    <li>A list item</li>
</ul>
  • A list item
  • A list item
  • A list item
  • A list item

Bordered list

A list with border bottom (logical property) added for every list item, color of which is defined by @rowlist-border.

<ul class="blist">
    <li>A list item</li>
    <li>A list item</li>
    <li>A list item</li>
    <li>A list item</li>
</ul>
  • A list item
  • A list item
  • A list item
  • A list item

Row list

A list, and bordered list, combined.

<ul class="rowlist">
    <li>A list item</li>
    <li>A list item</li>
    <li>A list item</li>
    <li>A list item</li>
</ul>
  • A list item
  • A list item
  • A list item
  • A list item

Bonus: comma list

A list of items, comma seperated, inline.

<ul class="commalist">
    <li>A list item</li>
    <li>A list item</li>
    <li>A list item</li>
    <li>A list item</li>
</ul>
  • A list item
  • A list item
  • A list item
  • A list item