From ebbb058ac4a05bc7ff3edbc5c35c41197b538b2d Mon Sep 17 00:00:00 2001 From: Justin Coyne Date: Thu, 20 Jun 2024 10:44:38 -0500 Subject: [PATCH] Explictly add the form-control class to the auto-complete This will make it possible to run blacklight without a sass dependency --- app/assets/stylesheets/blacklight/_search_form.scss | 1 - app/components/blacklight/search_bar_component.html.erb | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/app/assets/stylesheets/blacklight/_search_form.scss b/app/assets/stylesheets/blacklight/_search_form.scss index 3e8c6939d8..20cbe65bf4 100644 --- a/app/assets/stylesheets/blacklight/_search_form.scss +++ b/app/assets/stylesheets/blacklight/_search_form.scss @@ -5,7 +5,6 @@ } .input-group > .search-autocomplete-wrapper { - @extend .form-control; display: inline-block; flex-grow: 4; padding: 0; diff --git a/app/components/blacklight/search_bar_component.html.erb b/app/components/blacklight/search_bar_component.html.erb index 934c9a080c..43e47af863 100644 --- a/app/components/blacklight/search_bar_component.html.erb +++ b/app/components/blacklight/search_bar_component.html.erb @@ -22,7 +22,7 @@ <%= f.label @query_param, scoped_t('search.label'), class: 'sr-only visually-hidden' %> <% if autocomplete_path.present? %> - + <%= f.search_field @query_param, value: @q, placeholder: scoped_t('search.placeholder'), class: "search-q q form-control rounded-#{search_fields.length > 1 ? '0' : 'left'}", autofocus: @autofocus, aria: { label: scoped_t('search.label'), autocomplete: 'list', controls: 'autocomplete-popup' } %>