Build an Availability Table - Build an Availability Table

Tell us what’s happening:

Test 35 isn’t passing. I don’t know what the problem is. It all has to do with the #legend-gradient.

Your code so far

<!-- file: index.html -->
<!DOCTYPE html>
<html lang="en">

<head>
  <link rel="stylesheet" href="styles.css">
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Availability Table</title>
</head>

<body>
  <table>
    <thead>
      <th></th>
      <th></th>
      <th>Monday</th>
      <th>Tuesday</th>
      <th>Wednesday</th>
      <th>Thursday</th>
      <th>Friday</th>
    </thead>
    <tbody>
      <tr class="sharp">
        <th class="time">8am</th>
        <td class="available-0"></td>
        <td class="available-1"></td>
        <td class="available-2"></td>
        <td class="available-3"></td>
        <td class="available-4"></td>
        <td class="available-5"></td>
      </tr>
      <tr class="half">
        <th class="time">9am</th>
        <td class="available-0"></td>
        <td class="available-1"></td>
        <td class="available-2"></td>
        <td class="available-3"></td>
        <td class="available-4"></td>
        <td class="available-5"></td>
      </tr>
      <tr class="sharp">
        <th class="time">10am</th>
        <td class="available-0"></td>
        <td class="available-1"></td>
        <td class="available-2"></td>
        <td class="available-3"></td>
        <td class="available-4"></td>
        <td class="available-5"></td>
      </tr>
      <tr class="half">
        <th class="time">11am</th>
        <td class="available-0"></td>
        <td class="available-1"></td>
        <td class="available-2"></td>
        <td class="available-3"></td>
        <td class="available-4"></td>
        <td class="available-5"></td>
      </tr>
    </tbody>
  </table>
  <div id="legend">
    <span>Availability</span>
    <div id="legend-gradient"></div>
  </div>

</body>

</html>
/* file: styles.css */
:root {
  --color0: white;
  --color1: #e5f5e0;
  --color2: #c7e9c0;
  --color3: #a1d99b;
  --color4: #74c476;
  --color5: #31a354;
  --solid-border: 2px solid purple;
  --dashed-border: 2px dashed orange;
}

.available-0 {
  background-color: var(--color0);
}

.available-1 {
  background-color: var(--color1);
}

.available-2 {
  background-color: var(--color2);
}

.available-3 {
  background-color: var(--color3);
}

.available-4 {
  background-color: var(--color4);
}

.available-5 {
  background-color: var(--color5);
}

.sharp td {
  border-bottom: var(--solid-border);
}

.half td {
  border-bottom: var(--dashed-border);
}

#legend-gradient {
  height: 20px;
  width: 100%;
  background-image: linear-gradient(to right, var(--color0) 0%, var(--color0) 16.66%, var(--color1) 16.66%, var(--color1) 33.33%, var(--color2) 33.33%, var(--color2) 50%, var(--color3) 50%, var(--color3) 66.66%, var(--color4) 66.66%, var(--color4) 83.33%, var(--color5) 83.33%, var(--color5) 100%); 
}

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/143.0.0.0 Safari/537.36

Challenge Information:

Build an Availability Table - Build an Availability Table

see this example for a Gradient with multi-position color-stops, also use whole numbers

Thanks, it was the whole numbers. My formatting was correct.

in the code you posted you are not using the multi-color stops tho