<% title_key = recent ? :label_ux_toolkit_recently_visited_projects : :label_ux_toolkit_favorite_projects %>
<details class="box ux-toolkit-dashboard-block" data-dashboard-block="<%= block %>" open>
  <%= render 'block_header', block: block, title_key: title_key %>
  <div class="ux-toolkit-dashboard-block-body">
    <% if projects.any? %>
      <ul class="ux-toolkit-dashboard-list">
        <% projects.each do |entry| %>
          <% project = recent ? entry.project : entry %>
          <% next unless project %>
          <li>
            <%= link_to_project(project) %>
            <span class="meta"><%= h(project.identifier) %></span>
            <% if recent %><span class="meta"><%= format_time(entry.last_visited_at) %></span><% end %>
          </li>
        <% end %>
      </ul>
    <% else %>
      <p class="nodata"><%= l(recent ? :text_ux_toolkit_no_recent_projects : :text_ux_toolkit_no_favorite_projects) %></p>
    <% end %>
    <%= render 'block_footer', block: block %>
  </div>
</details>
