Sha256: 46b989a86fbeda231bfebbb645f6a50d1d20052c5ca6d83b31e2031fed25fd01

Contents?: true

Size: 1.38 KB

Versions: 20

Compression:

Stored size: 1.38 KB

Contents

<div class="bg-red-50 h-[calc(100vh_-_40px)] w-full overflow-y-auto">
  <div>
    <header class="px-8 py-6">
      <h2 class="text-xl font-bold text-red-700"><%= @error.type %></h2>
    </header>

    <div class="px-8 py-6 mb-8 border-t border-b border-red-200 bg-red-100 text-base leading-relaxed">
      <pre class="whitespace-pre-wrap font-ui leading-tight text-red-900"><%= @error.message %></pre>
    </div>

    <% if @error.file_path %>
      <div class="text-sm mx-8 mb-3 font-mono">
        <span><%= @error.relative_file_path %></span>
        <% if @error.line_number %>
          <span>[line <strong><%= @error.line_number %></strong>]</span>
        <% end %>
      </div>

      <div class="px-8">
        <%= lookbook_render :file_source,
          file_path: @error.file_path,
          highlight_lines: [@error.line_number],
          lines_around_highlight: 5,
          source: @error.source,
          class: "border border-red-200" %>
      </div>
    <% end %>

    <h3 class="font-bold mb-2 px-8 py-2 mt-8">Full stack trace:</h3>
    <div class="text-xs font-mono w-full overflow-auto">
      <div class="px-8 pb-10 text-gray-400 leading-relaxed whitespace-nowrap">
        <% @error.backtrace.each do |line| %>
          <div class="hover:text-gray-900 transition-colors duration-100">
            <%= line %>
          </div>
        <% end %>
      </div>
    </div>
  </div>
</div>

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
lookbook-2.3.4 app/views/lookbook/errors/default.html.erb
lookbook-2.3.3 app/views/lookbook/errors/default.html.erb
lookbook-2.3.2 app/views/lookbook/errors/default.html.erb
lookbook-2.3.0 app/views/lookbook/errors/default.html.erb
lookbook-2.2.2 app/views/lookbook/errors/default.html.erb
lookbook-2.2.1 app/views/lookbook/errors/default.html.erb
lookbook-2.2.0 app/views/lookbook/errors/default.html.erb
lookbook-2.1.1 app/views/lookbook/errors/default.html.erb
lookbook-2.1.0 app/views/lookbook/errors/default.html.erb
lookbook-2.0.5 app/views/lookbook/errors/default.html.erb
lookbook-2.0.4 app/views/lookbook/errors/default.html.erb
lookbook-2.0.3 app/views/lookbook/errors/default.html.erb
lookbook-2.0.2 app/views/lookbook/errors/default.html.erb
lookbook-2.0.1 app/views/lookbook/errors/default.html.erb
lookbook-2.0.0 app/views/lookbook/errors/default.html.erb
lookbook-2.0.0.rc.3 app/views/lookbook/errors/default.html.erb
lookbook-2.0.0.rc.2 app/views/lookbook/errors/default.html.erb
lookbook-2.0.0.rc.1 app/views/lookbook/errors/default.html.erb
lookbook-2.0.0.beta.9 app/views/lookbook/errors/default.html.erb
lookbook-2.0.0.beta.8 app/views/lookbook/errors/default.html.erb