From 1b22ff461ba443fba46c9e13bc7cf16867bef21b Mon Sep 17 00:00:00 2001 From: Keegan George Date: Mon, 17 Oct 2022 11:40:03 -0700 Subject: [PATCH] FIX: Prevent layout shift while traversing dropdown (#18624) --- .../select-kit/addon/components/select-kit/select-kit-filter.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/assets/javascripts/select-kit/addon/components/select-kit/select-kit-filter.js b/app/assets/javascripts/select-kit/addon/components/select-kit/select-kit-filter.js index a59224bb6f5..d8782f9ec9f 100644 --- a/app/assets/javascripts/select-kit/addon/components/select-kit/select-kit-filter.js +++ b/app/assets/javascripts/select-kit/addon/components/select-kit/select-kit-filter.js @@ -83,11 +83,13 @@ export default Component.extend(UtilsMixin, { if (event.key === "ArrowUp") { this.selectKit.highlightLast(); + event.preventDefault(); return false; } if (event.key === "ArrowDown") { this.selectKit.highlightFirst(); + event.preventDefault(); return false; }