Skip to content

Commit

Permalink
Fix the item page
Browse files Browse the repository at this point in the history
  • Loading branch information
Genia Kazymova committed Sep 17, 2024
1 parent 2750c27 commit 6ea5c87
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 26 deletions.
Original file line number Diff line number Diff line change
@@ -1,16 +1,11 @@
# <dl>
# <!% @fields.each do |field| -%>
# <!%= @view_context.render(field_component(field).new(
# field: field,
# show: @show,
# layout: TrlnArgon::MetadataHeaderFieldLayoutComponent)) %>
# <!% end -%>
# </dl>

<% content = capture do %>
<% fields.each do |field| -%>
<%= field %>
<% end -%>
<% end %>
<dl>
<% @fields.each do |field| %>
<%= render field.component.new(
field: field,
show: @show,
layout: TrlnArgon::MetadataHeaderFieldLayoutComponent
) %>
<% end %>
</dl>

<%= @tag.nil? ? content : tag.public_send(@tag, content, class: @classes, **@component_args) %>
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
<dl class="document-metadata">
<% @fields.each do |field| -%>
# <!%= @view_context.render(field_component(field).new(field: field, show: @show, layout: TrlnArgon::MetadataFieldLayoutComponent)) %>
<%= render field.component.new(
field: field,
show: @show,
layout: TrlnArgon::MetadataFieldLayoutComponent
) %>
<% end -%>
</dl>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<dl>
<% @fields.each do |field| -%>
# <!%= @view_context.render(field_component(field).new(field: field, show: @show, layout: TrlnArgon::MetadataListFieldLayoutComponent)) %>
<%= render field.component.new(field: field, show: @show, layout: TrlnArgon::MetadataListFieldLayoutComponent) %>
<% end -%>
</dl>
14 changes: 4 additions & 10 deletions app/views/catalog/_show_main_content.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
</div>
</div>

<% @page_title = t('blacklight.search.show.title', :document_title => document_presenter(@document).html_title, :application_name => application_name).html_safe %>
<% @page_title = t('blacklight.search.show.title', document_title: document_presenter(@document).html_title, application_name: application_name).html_safe %>
<% content_for(:head) { render_link_rel_alternates } %>

<div id="document" class="document <%= render_document_class %>" itemscope itemtype="<%= @document.itemtype %>" data-document-id="<%= @document.id %>">
<div id="doc_<%= @document.id.to_s.parameterize %>">

<div class="row">

<div id="title-and-thumbnail" class="<%= show_main_content_heading_partials_class %>" aria-label="Title and thumbnail">
<!-- Title Display -->
<h1 class="document-title"><%= document_presenter(@document).html_title %></h1>
<%= render_document_partials @document, blacklight_config.view_config(:show).heading_partials %>
</div>
<div class="<%= show_main_content_partials_class %>">
Expand All @@ -25,14 +25,8 @@
the blacklight partials config. -->

</div>

<!-- <div class="marc-record">
<p><a href="#">View MARC record for this title</a></p>
</div> -->

</div>

</div>

</div>
</div>

0 comments on commit 6ea5c87

Please sign in to comment.