picocss / pico

Minimal CSS Framework for semantic HTML
https://picocss.com
MIT License
13.82k stars 406 forks source link

Table has unexpected background color when in `<article>` in dark theme #497

Open carlreinke opened 8 months ago

carlreinke commented 8 months ago

Describe the issue

A table not in <article> has the same background color as the page. A table in <article> has a darker background color than the card in the dark theme.

Seems to be a regression of #78.

Current Behavior

image

Expected Behavior

image

Reproduction URL

<head>
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@picocss/pico@2.0.6/css/pico.min.css" />
</head>
<body class="container">
  <article>
    <header>Header</header>
    <table>
      <thead>
        <tr>
          <th scope="col">Planet</th>
          <th scope="col">Diameter (km)</th>
          <th scope="col">Distance to Sun (AU)</th>
          <th scope="col">Orbit (days)</th>
        </tr>
      </thead>
      <tbody>
        <tr>
          <th scope="row">Mercury</th>
          <td>4,880</td>
          <td>0.39</td>
          <td>88</td>
        </tr>
        <tr>
          <th scope="row">Venus</th>
          <td>12,104</td>
          <td>0.72</td>
          <td>225</td>
        </tr>
        <tr>
          <th scope="row">Earth</th>
          <td>12,742</td>
          <td>1.00</td>
          <td>365</td>
        </tr>
      </tfoot>
    </table>
  </article>
</body>

Environment

Firefox on Windows 10