Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Keydown and Keyup not working as expected in Vertical mode
- This topic has 3 replies, 2 voices, and was last updated 7 years, 3 months ago by
Ernest Marcinko.
-
AuthorPosts
-
February 27, 2019 at 10:25 pm #21320
tavy87
ParticipantI’m wondering why in vertical mode the keyboard Down and Up presses do not scroll the page. I noticed in one of the JS files that there is some code that checks if the mode is vertical, and if so, checks for certain keypresses:
if (keycode == 40) { e.stopPropagation(); e.preventDefault(); $this.n.text.blur(); if ($this.post != null) $this.post.abort(); if ($('.item.hovered', $this.n.resultsDiv).length == 0) { $('.item', $this.n.resultsDiv).first().addClass('hovered'); } else { $('.item.hovered', $this.n.resultsDiv).removeClass('hovered').next().next('.item').addClass('hovered'); } if ($this.is_scroll) { $this.scroll.mCustScr("scrollTo", ".resdrg .item.hovered",{ scrollInertia: 200, callbacks: false }); } } if (keycode == 38) { e.stopPropagation(); e.preventDefault(); $this.n.text.blur(); if ($this.post != null) $this.post.abort(); if ($('.item.hovered', $this.n.resultsDiv).length == 0) { $('.item', $this.n.resultsDiv).last().addClass('hovered'); } else { $('.item.hovered', $this.n.resultsDiv).removeClass('hovered').prev().prev('.item').addClass('hovered'); if ($this.is_scroll) { $this.scroll.mCustScr("scrollTo", ".resdrg .item.hovered", { scrollInertia: 200, callbacks: false }); } } }I removed this code manually, and it seems to fix my issue, but I’m wondering if there is a simpler fix that will protect me from plugin updates overwriting it?
February 28, 2019 at 10:08 am #21322Ernest Marcinko
KeymasterHi,
It is an intended feature, to scroll the results window automatically, when the scrollbar is visible. However it does not seem to work correctly, when the viewport is high, and the scrolling occurs on the window itself.
This is definitely a bug I am going to address in the upcoming release, so you don’t have to worry about it anymore.
February 28, 2019 at 10:17 pm #21328tavy87
ParticipantThank you! I wasn’t sure if it was because I customized the vertical template or not, but that makes sense that it only seems to be an issue at high viewport sizes. Do you know when you expect the fix to occur approximately? I don’t mind waiting, I just want to be aware of when I should test it again.
Thank you
March 1, 2019 at 10:07 am #21331Ernest Marcinko
KeymasterHi,
Well, I am hoping within 10 working days. It is going to be a major update, the testing will take a couple of days unfortunately.
-
AuthorPosts
- You must be logged in to reply to this topic.