<div class="row border-bottom">
  <nav class="navbar navbar-static-top layouts-navbar" role="navigation">
    <ul class="nav navbar-top-links navbar-left">
      <li>
        <%= link_to dashboard_path, :class => 'navbar-link left-layout-link' do %>
          <span><img src="/assets/logos/kuwinda_thumbnail.png" alt="" class="logo-thumbnail"></span>
        <% end %>
      </li>

      <li>
        <ol class="breadcrumb layouts-layout_builder_topnavbar-breadcrumb">
          <li>
            <%= link_to 'Dashboard', dashboard_path %>
          </li>

          <% if @view_builder.table_name.blank? %>
            <li>
              new layout
            </li>
          <% else %>
            <li>
              <%= link_to "Table: #{@view_builder.table_name.humanize}", table_path(@view_builder.database_id, table: @view_builder.table_name) %>
            </li>
            <% if @view_builder.persisted? %>
              <li>
                <%= link_to "Layout: #{@view_builder.table_name.humanize}", table_record_preview_path(table: @view_builder.table_name, table_name: @view_builder.table_name.downcase, record_id: @row) %>
              </li>
            <% end %>
          <% end %>
        </ol>
      </li>
    </ul>

    <ul class="nav navbar-top-links navbar-right">
      <li>
        <% if admin_user_signed_in? %>
          <%= link_to destroy_admin_user_session_path, method: :delete, :class => 'navbar-link' do %>
            <span><i class="fa fa-sign-out" aria-hidden="true"></i>Log out</span>
          <% end %>
        <% end %>
      </li>
    </ul>
  </nav>
</div>
