You are viewing version 6.0.0 of the library, the latest version is
<table class="responsive-table">
    <caption>Personen</caption>
    <thead>
        <tr>
            <th>Voornaam</th>
            <th>Achternaam</th>
            <th>Beschrijving</th>
            <th>Lorem Ipsum</th>
        </tr>
    </thead>
    <tbody>
        <tr>
            <td>James</td>
            <td>Matman</td>
            <td>eget etiam</td>
            <td>pede nullam nascetur habitasse</td>
        </tr>
        <tr>
            <td>The</td>
            <td>Tick</td>
            <td>accumsan non</td>
            <td>sit viverra aenean bibendum</td>
        </tr>
        <tr>
            <td>Jokey</td>
            <td>Smurf</td>
            <td>maecenas pretium</td>
            <td>nascetur risus aliquet ipsum</td>
        </tr>
        <tr>
            <td>Cindy</td>
            <td>Beyler</td>
            <td>consectetur mi</td>
            <td>metus est dictum mollis elementum torquent. Ad ligula quis convallis per natoque</td>
        </tr>
        <tr>
            <td>Captain</td>
            <td>Cool</td>
            <td>porta non</td>
            <td>aenean lorem pulvinar eros</td>
        </tr>
    </tbody>
</table>

Responsive Table

A custom component created for Nijmegen, based on this CSS-Tricks demo.

Notes

  • The caption element functions as a heading for the table. Captions help (screen-reader) users to find a table and understand what it’s about.
  • If the table is hard to interpret it can help to add a summary in the caption as wel.
  • If the caption is not wanted visually you can hide this by applying the class sr-only. It is also possible to hide only the summary.