domestic-ui GitHub

People list

A list of people, each with a name, an email and a role badge at the end of the row.

Our choice: A composition, not a component: a .stack list whose items are .cluster rows with --cluster-justify: space-between, the name in <strong> above a small muted email.

Where a people list is used A people list sits in a card in the content area, one row per person with their name and email and a role badge at the end.

Live example

People list

<section data-card aria-labelledby="team-title">
  <h3 id="team-title">Team</h3>
  <ul class="stack">
    <li class="cluster" style="--cluster-justify: space-between">
      <p>
        <strong>Maria Santos</strong><br>
        <span data-text="small muted">maria@northwind.example</span>
      </p>
      <span data-badge>Owner</span>
    </li>
    <li class="cluster" style="--cluster-justify: space-between">
      <p>
        <strong>Kenji Watanabe</strong><br>
        <span data-text="small muted">kenji@northwind.example</span>
      </p>
      <span data-badge>Admin</span>
    </li>
    <li class="cluster" style="--cluster-justify: space-between">
      <p>
        <strong>Amara Okafor</strong><br>
        <span data-text="small muted">amara@northwind.example</span>
      </p>
      <span data-badge="accent">Invited</span>
    </li>
  </ul>
</section>

Accessibility

  • The role is text in a badge, never a colour alone (WCAG 1.4.1).
  • When people need sorting, filtering or bulk actions, use a data table instead.

Specifications

See also

How other systems do it

For comparison only; these are not the standard this system follows.

Search