
<table class='standard'>
  <thead>
    <tr>
      <th>Age (days)</th>
      <th>Issue</th>
      <th>Summary</th>
      <th>Status</th>
    </tr>
  </thead>
  <tbody>
    <% tree_organizer.flattened_nodes.each do |node, depth| %>
      <% issue = node.issue %>
      <tr>
        <td style="text-align: right;"><%= issue.board.cycletime.age(issue, today: @today) || 'Not started' %></td>
        <td>
          <% color = "var(--hierarchy-table-#{ 'in' if node.children? }active-item-text-color)" %>
          <span style="padding-left: <%= depth - 1 %>em;" />
          <span style="white-space: nowrap;">
            <img src="<%= issue.type_icon_url %>" title="<%= issue.type %>"/>
            <%= link_to_issue issue, style: "color: #{color}" %>
          </span>
        </td>
        <td><span style="color: <%= color %>; font-style: italic;"><%= issue.summary[0..80] %></span></td>
        <td><%= format_status issue.status, board: issue.board %></td>
      </tr>
    <% end %>
  </tbody>
</table>
