Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions app/assets/stylesheets/partials/_results.scss
Original file line number Diff line number Diff line change
Expand Up @@ -118,4 +118,25 @@
font-size: 1.8rem;
line-height: 1.1;
}
}

/* USE Specific Overrides */
#content-wrapper {
padding-top: 12px;

.results-context {
padding-left: 0;
margin-top: 0;
margin-bottom: 4px;
}

.results-context-description {
color: $color-text-secondary;
margin-bottom: 32px;
}

#results {
padding: 16px 0 0 0;
}

}
1 change: 1 addition & 0 deletions app/assets/stylesheets/partials/_search.scss
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
font-weight: $fw-medium;
display: block;
line-height: 1;
color: $color-text-oncolor;
}

.form-wrapper {
Expand Down
2 changes: 1 addition & 1 deletion app/assets/stylesheets/partials/_suggestion-panel.scss
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#hint {padding-top: 24px;} //Temporary spacing above panel until we can revisit entire page layout
#hint {padding-bottom: 24px;}

.mitlib-suggestion-panel {

Expand Down
7 changes: 7 additions & 0 deletions app/assets/stylesheets/partials/_typography.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// Override fonts from the theme gem, done temporarily for USE UI
body {
font-family: $base-font;
color: $color-text-primary;
}

h1, h2, h3, h4, h5, h6 {
Expand Down Expand Up @@ -37,3 +38,9 @@ h1, h2, h3, h4, h5, h6 {
.hd-6 {
line-height: $lh-base;
}

/* Theme Gem Overrides */

//Font color set to black in theme gem, breaking cascade from local body style rule
.wrap-outer-content { color: $color-text-primary; }
.wrap-outer-footer-institute a, .wrap-footer a, a, .js .expand-collapse-control .button { color: $color-text-primary; }
7 changes: 0 additions & 7 deletions app/views/search/_search_summary.html.erb

This file was deleted.

12 changes: 4 additions & 8 deletions app/views/search/results.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,19 @@
<meta name="robots" content="noindex, nofollow" />
<% end %>

<div class="space-wrap">

<%= render partial: "shared/site_title" %>

<%= render partial: "search_summary" %>

<div id="content-wrapper" class="space-wrap">
<%= render(partial: 'shared/error', collection: @errors) %>

<%= render(partial: 'trigger_tacos') if tacos_enabled? %>

<%= turbo_frame_tag "search-results", data: { turbo_action: "advance" } do %>
<div class="layout-3q1q layout-band top-space">
<div class="layout-3q1q layout-band">
<main id="results" class="col3q wrap-results">
<% if @show_primo_continuation %>
<%= render partial: 'search/primo_continuation' %>
<% elsif @results.present? && @errors.blank? %>
<h2 class="hd-3 results-context"><%= results_summary(@pagination[:hits]) %> returned</h2>
<h2 class="results-context"><%= results_summary(@pagination[:hits]) %></h2>
<p class="results-context-description">From all MIT Libraries sources</p>
<ol class="results-list" start="<%= @pagination[:start] %>">
<% case @active_tab %>
<% when 'primo' %>
Expand Down
2 changes: 0 additions & 2 deletions app/views/shared/_site_title.html.erb
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
<% if Feature.enabled?(:geodata) %>
<h2>Search for geospatial/GIS data</h2>
<p id="site-desc">Find GIS data held at MIT and other institutions</p>
<% else %>
<h2>Search the MIT Libraries</h2>
<% end %>
5 changes: 3 additions & 2 deletions test/controllers/search_controller_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -623,8 +623,9 @@ def source_filter_count(controller)

get '/results?q=test'
assert_response :success
assert_select 'aside.search-summary', count: 1
assert_select 'aside.search-summary', text: /You searched for: test/
assert_select '.results-context', text: /0 results/
assert_select '.results-context-description', count: 1
assert_select '.results-context-description', text: /From all MIT Libraries sources/
end

test 'primo results shows continuation partial when page exceeds API offset limit' do
Expand Down