Skip to content

Commit

Permalink
Remove dfe-autocomplete
Browse files Browse the repository at this point in the history
The custom CSS seems to not be as accessible as the upstream one when
using VoiceOver. It doesn't allow choosing from a list of options by
swiping left/right in the focus order.
  • Loading branch information
tvararu committed Sep 27, 2024
1 parent b52fd57 commit 14f2e75
Show file tree
Hide file tree
Showing 7 changed files with 0 additions and 50 deletions.
3 changes: 0 additions & 3 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,6 @@ gem "cssbundling-rails"
gem "csv"
gem "devise"
gem "devise-pwned_password"
gem "dfe-autocomplete",
require: "dfe/autocomplete",
github: "DFE-Digital/dfe-autocomplete"
gem "factory_bot_rails"
gem "faker"
gem "faraday"
Expand Down
12 changes: 0 additions & 12 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,14 +1,3 @@
GIT
remote: https://github.com/DFE-Digital/dfe-autocomplete.git
revision: 8e7389ff62a38bc8880323f6c58eed9c8d10f080
specs:
dfe-autocomplete (0.1.0)
actionview (>= 7.0.2.3)
activemodel (>= 7.0.2.3)
govuk-components
rails (>= 7.0.2.3)
view_component

GIT
remote: https://github.com/citizensadvice/capybara_accessible_selectors
revision: 347bbe06cb420416855e80bb4e3a3016b2d5872c
Expand Down Expand Up @@ -672,7 +661,6 @@ DEPENDENCIES
debug
devise
devise-pwned_password
dfe-autocomplete!
dockerfile-rails (>= 1.0.0)
factory_bot_rails
faker
Expand Down
1 change: 0 additions & 1 deletion app/assets/stylesheets/application.scss
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ $mq-breakpoints: (
);

@import "nhsuk-frontend/packages/nhsuk";
@import "dfe-autocomplete/src/dfe-autocomplete";

// App options
$app-page-width: 1160px;
Expand Down
14 changes: 0 additions & 14 deletions app/javascript/application.js
Original file line number Diff line number Diff line change
@@ -1,21 +1,7 @@
import "@hotwired/turbo-rails";
// import { initServiceWorker } from "./serviceworker-companion";
import "./controllers";
import dfeAutocomplete from "dfe-autocomplete";

Turbo.session.drive = false;

// initServiceWorker();
function shimAutocomplete() {
document
.querySelectorAll('[data-module="app-dfe-autocomplete"]')
.forEach((element) => {
const nhsukFormGroup = element.querySelector("div.nhsuk-form-group");
if (nhsukFormGroup) {
nhsukFormGroup.classList.add("govuk-form-group");
}
});
}

shimAutocomplete();
dfeAutocomplete({});
1 change: 0 additions & 1 deletion config/initializers/inflections.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
inflect.acronym "NHS"
inflect.acronym "ODS"
inflect.acronym "PDS"
inflect.acronym "DfE"

inflect.irregular "batch", "batches"
inflect.irregular "child", "children"
Expand Down
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
"dependencies": {
"@hotwired/stimulus": "^3.2.2",
"@hotwired/turbo-rails": "^8.0.10",
"dfe-autocomplete": "github:DFE-Digital/dfe-autocomplete",
"esbuild": "^0.24.0",
"govuk-frontend": "^5.6.0",
"idb": "^8.0.0",
Expand Down
18 changes: 0 additions & 18 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1895,13 +1895,6 @@ abab@^2.0.6:
resolved "https://registry.yarnpkg.com/abab/-/abab-2.0.6.tgz#41b80f2c871d19686216b82309231cfd3cb3d291"
integrity sha512-j2afSsaIENvHZN2B8GOpF566vZ5WVk5opAiMTvWgaQT8DkbOqsTfvNAvHoRGU2zzP8cPoqys+xHTRDWW8L+/BA==

accessible-autocomplete@^2.0.4:
version "2.0.4"
resolved "https://registry.yarnpkg.com/accessible-autocomplete/-/accessible-autocomplete-2.0.4.tgz#e295256c8d268b97c5ab456a1cb084b553ed3eb0"
integrity sha512-2p0txrSpvs5wXFUeQJHMheDPTZVSEmiUHWlEPb7vJnv2Dd1xPfoLnBQQMfNbTSit2pL/9sSQYESuD2Yyohd4Yw==
dependencies:
preact "^8.3.1"

acorn-globals@^7.0.0:
version "7.0.1"
resolved "https://registry.yarnpkg.com/acorn-globals/-/acorn-globals-7.0.1.tgz#0dbf05c44fa7c94332914c02066d5beff62c40c3"
Expand Down Expand Up @@ -2624,12 +2617,6 @@ detect-newline@^3.0.0:
resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-3.1.0.tgz#576f5dfc63ae1a192ff192d8ad3af6308991b651"
integrity sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA==

"dfe-autocomplete@github:DFE-Digital/dfe-autocomplete":
version "0.0.1"
resolved "https://codeload.github.com/DFE-Digital/dfe-autocomplete/tar.gz/8e7389ff62a38bc8880323f6c58eed9c8d10f080"
dependencies:
accessible-autocomplete "^2.0.4"

diff-sequences@^29.6.3:
version "29.6.3"
resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-29.6.3.tgz#4deaf894d11407c51efc8418012f9e70b84ea921"
Expand Down Expand Up @@ -4686,11 +4673,6 @@ posix-character-classes@^0.1.0:
resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab"
integrity sha512-xTgYBc3fuo7Yt7JbiuFxSYGToMoz8fLoE6TC9Wx1P/u+LfeThMOAqmuyECnlBaaJb+u1m9hHiXUEtwW4OzfUJg==

preact@^8.3.1:
version "8.5.3"
resolved "https://registry.yarnpkg.com/preact/-/preact-8.5.3.tgz#78c2a5562fcecb1fed1d0055fa4ac1e27bde17c1"
integrity sha512-O3kKP+1YdgqHOFsZF2a9JVdtqD+RPzCQc3rP+Ualf7V6rmRDchZ9MJbiGTT7LuyqFKZqlHSOyO/oMFmI2lVTsw==

prelude-ls@~1.1.2:
version "1.1.2"
resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54"
Expand Down

0 comments on commit 14f2e75

Please sign in to comment.