Skip to content

Commit

Permalink
Merge pull request #108 from scientist-softserv/theming-part2
Browse files Browse the repository at this point in the history
changed collection show page and added related css
  • Loading branch information
summer-cook authored Jul 10, 2023
2 parents 3194f7b + 079ae11 commit d52cd3b
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 22 deletions.
27 changes: 26 additions & 1 deletion app/assets/stylesheets/atla-overrides.scss
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
html, body {
html, body.public-facing {
font-family: 'Muli', Helvetica, sans-serif;
font-size:1em;
}

body {font-size:0.875em;}

img {max-width:100%;}


Expand All @@ -16,6 +18,8 @@ img {max-width:100%;}
/* hide work type on work show pages */
.works-show .work-type-tag {display:none;}

.social-media{display:none;}

/* Collection show layout */

.hyc-banner .hyc-title h1, .hyc-banner .hyc-bugs div{
Expand All @@ -31,7 +35,28 @@ img {max-width:100%;}

.hyc-banner {min-height:95px;}

.hyc-bugs {
padding: 0 1em 0 2em;
text-align:right;
}

.hyc-header {margin-bottom:0;}
.hyc-banner .hyc-title h1 {margin-bottom: 0.25em;}
.hyc-description h2 {font-size: 1.5em;}

.hyc-bl-results {margin:0 0 1em 0;}
.hyc-blacklight.hyc-bl-title {padding: 0;}
.hyc-blacklight.hyc-bl-results {padding-left: 0;}
body.hyrax-collections .hyc-bl-search .col-sm-8 {float: right;}

/* search resulsts */
div.facets h3 {font-size: 1em;}


/* admin dashboard available works ETD all caps*/
.dashboard label[for="input-Etd"] {text-transform: uppercase;}


@media only screen and (min-width: 768px) {
.hyc-banner .hyc-title h1 {margin-bottom: 0em;}
}
40 changes: 19 additions & 21 deletions app/views/hyrax/collections/show.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<div class="hyc-container" itemscope itemtype="http://schema.org/CollectionPage">
<div class="row hyc-header">
<div class="col-md-12">

<% if @presenter.banner_file.present? %>
<div class="hyc-banner" style="background-image:url(<%= @presenter.banner_file[:relative_path] %>)" title="<%= @presenter.banner_file[:alt_text] %>">
<% else %>
Expand All @@ -30,18 +30,7 @@
<% end %>
</div>
<% end %>
<% unless @presenter.total_viewable_items.blank? %>
<div class="hyc-bugs">
<div class="hyc-item-count">
<%= pluralize(@presenter.total_viewable_items, t('.item_count')) %></div>
<% unless @presenter.creator.blank? %>
<div class="hyc-created-by">Created by: <%= @presenter.creator.first %></div>
<% end %>
<% unless @presenter.modified_date.blank? %>
<div class="hyc-last-updated">Last Updated: <%= @presenter.modified_date %></div>
<% end %>
</div>
<% end %>


</div>

Expand All @@ -63,8 +52,15 @@
</div>
<%# end OVERRIDE %>
<div class="row hyc-body">
<div class="col-md-4 hyc-metadata">
<%= render 'hyrax/collections/media_display', presenter: @presenter %>
</div>
<div class="col-md-8 hyc-description">
<%= render 'collection_description', presenter: @presenter %>
<% unless collection_search_parameters? %>
<h2><%= t('hyrax.dashboard.collections.show.metadata_header') %></h2>
<%= render 'show_descriptions' %>
<% end %>
<% if @presenter.collection_type_is_nestable? && @presenter.total_parent_collections > 0 %>
<div class="hyc-blacklight hyc-bl-title">
<h2>
Expand All @@ -75,15 +71,17 @@
<%= render 'show_parent_collections', presenter: @presenter %>
</div>
<% end %>

</div>
<div class="col-md-4 hyc-metadata">
<%= render 'hyrax/collections/media_display', presenter: @presenter %>
<% unless collection_search_parameters? %>
<h2><%= t('hyrax.dashboard.collections.show.metadata_header') %></h2>
<%= render 'show_descriptions' %>
<% end %>
</div>
<% unless @presenter.total_viewable_items.blank? %>
<div class="hyc-bugs">
<% unless @presenter.creator.blank? %>
<div class="hyc-created-by">Created by: <%= @presenter.creator.first %></div>
<% end %>
<% unless @presenter.modified_date.blank? %>
<div class="hyc-last-updated">Last Updated: <%= @presenter.modified_date %></div>
<% end %>
</div>
<% end %>
</div>

<!-- Search results label -->
Expand Down

0 comments on commit d52cd3b

Please sign in to comment.