Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scrolling to the wrong position #111

Open
vinismarques opened this issue Apr 3, 2023 · 1 comment
Open

Scrolling to the wrong position #111

vinismarques opened this issue Apr 3, 2023 · 1 comment
Labels
bug Something isn't working planned Will be actioned

Comments

@vinismarques
Copy link

Found a website where it is not working correctly. This one isn't a big deal because I don't use it daily as Notion, but sharing because you might be able to troubleshoot and make the extension more compatible overall.

https://www.sqlstyle.guide/#reserved-keyword-reference

I tried finding the "ROLE" text that is inside the "Reserved keyword reference" section with Mark My Search, but the page was scrolled to the wrong position. Ctrl + F works fine but finds many other non-whole-word matches.

@ator-dev ator-dev added bug Something isn't working planned Will be actioned labels Apr 3, 2023
@ator-dev
Copy link
Member

ator-dev commented Apr 3, 2023

Thank you for your report! This is interesting and has led me to another problem that seems to be Firefox-specific.

  • (Firefox only) Element.scrollIntoView() method is flawed. I probably won't replace this, but have filed this behaviour as a bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1826158

  • The problem with "jumping" (scrolling) is it only scrolls to the middle of a 'container' element. A container can hold any number of keywords; in your case, only ROLE in a list of text items. I am planning to update this so that it specifically puts the first keyword in view.

  • There is an alternate way of scrolling called "stepping". I recommend trying it!

    • Go to chrome://extensions/shortcuts
    • Find "Step to and select next highlight", and assign a shortcut like Alt+G; then another for "previous highlight"
    • "Stepping" will select (highlight) the next single match from the current point
    • Jumping and stepping are compatible: you can mix them, and they will continue from the same point in the page

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working planned Will be actioned
Projects
None yet
Development

No branches or pull requests

2 participants