From b14936766612f2545880561a34a474b9e245b69e Mon Sep 17 00:00:00 2001 From: Christian Sutter Date: Tue, 30 Jul 2024 11:40:33 +0000 Subject: [PATCH] Disable corrections for homepage search field As part of our work on site search, we've discovered a pain point where mobile browsers' autocorrection features mess up user queries, especially when it comes to domain specific terminology. For example, searches for "HMRC" are frequently autocorrected to "Hercules", or searches for "SORN" to "sworn". - Bump `govuk_publishing_components` to 40.1.0 - Set `disable_corrections` parameter to `search` component in homepage header See: https://github.com/alphagov/govuk_publishing_components/pull/4112 --- Gemfile.lock | 4 +--- app/views/homepage/_homepage_header.html.erb | 3 ++- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index bdb972f4cb..b886f5cfb4 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -162,7 +162,7 @@ GEM govuk_personalisation (0.16.0) plek (>= 1.9.0) rails (>= 6, < 8) - govuk_publishing_components (40.0.0) + govuk_publishing_components (40.1.0) govuk_app_config govuk_personalisation (>= 0.7.0) kramdown @@ -237,8 +237,6 @@ GEM mini_mime (1.1.5) mini_portile2 (2.8.7) minitest (5.24.1) - mocha (2.4.4) - ruby2_keywords (>= 0.0.5) msgpack (1.7.2) multi_xml (0.7.1) bigdecimal (~> 3.1) diff --git a/app/views/homepage/_homepage_header.html.erb b/app/views/homepage/_homepage_header.html.erb index c3e6497131..6e15236e2e 100644 --- a/app/views/homepage/_homepage_header.html.erb +++ b/app/views/homepage/_homepage_header.html.erb @@ -33,9 +33,10 @@ homepage: true, on_govuk_blue: true, margin_top: 5, + disable_corrections: true, } %> - \ No newline at end of file +