Skip to content
Open
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
6 changes: 1 addition & 5 deletions app/assets/stylesheets/partials/_header.scss
Original file line number Diff line number Diff line change
Expand Up @@ -92,11 +92,7 @@
font-size: 1.8rem;
font-weight: $fw-medium;
@include text-decoration-animation;

&:hover {
text-decoration: underline;
color: $color-white;
}
@include headerUnderlinedLinks;
}
}
}
Expand Down
17 changes: 2 additions & 15 deletions app/assets/stylesheets/partials/_search.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,6 @@
// #SEARCH BITS
// ------------------------

/* Shared link styling */
@mixin searchUnderlinedLinks {
color: $color-text-oncolor;
font-weight: $fw-medium;
text-decoration: underline;
text-decoration-color: $color-red-500;
text-underline-offset: 0.5rem;

&:hover {
color: $color-red-400;
}
}

/* New USE UI search styles */
#search-form {
margin: 0;
Expand Down Expand Up @@ -299,7 +286,7 @@
gap: 24px;

a {
@include searchUnderlinedLinks();
@include headerUnderlinedLinks();
}

.semantic-search-toggle {
Expand All @@ -310,7 +297,7 @@
background-color: transparent;
border: none;
cursor: pointer;
@include searchUnderlinedLinks();
@include headerUnderlinedLinks();

&::before {
background-color: $color-gray-800;
Expand Down
4 changes: 2 additions & 2 deletions app/assets/stylesheets/partials/_source_tabs.scss
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
border-bottom: 0;
white-space: nowrap;

@include searchUnderlinedLinks;
@include headerUnderlinedLinks;

&:hover {
border-color: $color-gray-700;
Expand Down Expand Up @@ -87,7 +87,7 @@
width: 100%;

&.active {
@include searchUnderlinedLinks;
@include headerUnderlinedLinks;
}

&:hover {
Expand Down
13 changes: 13 additions & 0 deletions app/assets/stylesheets/partials/_typography.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,19 @@
}
}

/* Shared link styling */
@mixin headerUnderlinedLinks {
color: $color-text-oncolor;
font-weight: $fw-medium;
text-decoration: underline;
text-decoration-color: $color-red-500;
text-underline-offset: 0.5rem;

&:hover {
color: $color-red-400;
}
}

// Override fonts from the theme gem, done temporarily for USE UI
body {
font-family: $base-font;
Expand Down
14 changes: 8 additions & 6 deletions app/views/layouts/_site_header.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,14 @@
<a href="/" class="platform-name"><%= ENV.fetch('PLATFORM_NAME') %></a>
<% end %>
</h1>
<% if Feature.enabled?(:geodata) %>
<nav class="main-navigation" aria-label="Main navigation">
<%= nav_link_to("GIS at MIT", "https://libraries.mit.edu/gis") %>
<%= nav_link_to("Ask GIS", "https://libraries.mit.edu/ask-gis") %>
</nav>
<% end %>
<nav class="main-navigation" aria-label="Main navigation">
<% if Feature.enabled?(:geodata) %>
<%= nav_link_to("GIS at MIT", "https://libraries.mit.edu/gis") %>
<%= nav_link_to("Ask GIS", "https://libraries.mit.edu/ask-gis") %>
<% else %>
<%= nav_link_to("About", "https://libraries.mit.edu/new-search/") %>
<% end %>
</nav>
</header>
<%= render partial: 'search/form' unless Feature.enabled?(:geodata) %>
</div>
Expand Down