From 602675142cdc39e494c79e2bcfe97767c297ce9b Mon Sep 17 00:00:00 2001 From: jazairi <16103405+jazairi@users.noreply.github.com> Date: Tue, 20 Feb 2024 11:08:58 -0500 Subject: [PATCH] Add site title partial Why these changes are being introduced: The GeoData visual design includes a heading at the top of each page, along with some descriptive text. Relevant ticket(s): https://mitlibraries.atlassian.net/browse/GDT-182 How this addresses that need: This adds the requested element as a partial, with conditional copy for GDT versus non-GDT applications. It also moves the label text to the `title` attribute, as the label is is now visually redundant but may still be useful to screen reader users. Side effects of this change: * The input label before form submit is now the same as the placeholder text. This feels fine since screen readers might not read placeholder text, but they do consistently rely on labels. * The copy for non-GDT titles did not come from UXWS and is subject to change. * The conditional title-in-nav has been removed from `site_nav`. This seems superfluous since we now have h1 tags. --- app/assets/stylesheets/partials/_search.scss | 2 +- app/views/basic_search/index.html.erb | 1 + app/views/layouts/_site_nav.html.erb | 5 ----- app/views/record/view.html.erb | 1 + app/views/search/_form.html.erb | 2 +- app/views/search/results.html.erb | 2 ++ app/views/shared/_site_title.html.erb | 6 ++++++ app/views/static/_forms.html.erb | 2 +- 8 files changed, 13 insertions(+), 8 deletions(-) create mode 100644 app/views/shared/_site_title.html.erb diff --git a/app/assets/stylesheets/partials/_search.scss b/app/assets/stylesheets/partials/_search.scss index cfba3f46..9683b0fd 100644 --- a/app/assets/stylesheets/partials/_search.scss +++ b/app/assets/stylesheets/partials/_search.scss @@ -6,7 +6,7 @@ .basic-search { background-color: #989898; margin-bottom: 0rem; - padding: 1.6rem 2rem; + padding: 2.4rem 2rem 1rem 2.4rem; details { margin-top: 1rem; diff --git a/app/views/basic_search/index.html.erb b/app/views/basic_search/index.html.erb index 2d32e800..f79a07d0 100644 --- a/app/views/basic_search/index.html.erb +++ b/app/views/basic_search/index.html.erb @@ -1,6 +1,7 @@ <%= content_for(:title, "Search | MIT Libraries") %>