Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Highlight matches within the page #49

Closed
SebastianZ opened this issue Jan 7, 2016 · 4 comments
Closed

Highlight matches within the page #49

SebastianZ opened this issue Jan 7, 2016 · 4 comments

Comments

@SebastianZ
Copy link
Collaborator

It should be possible to somehow highlight the part of the page related to an error.

E.g. this could happen when hovering the match or by clicking an icon next to it. The matched part should then be scrolled to and highlighted like Firebug's or the DevTools' inspector does it.

Sebastian

@SebastianZ
Copy link
Collaborator Author

Mentioned by @a2sheppy in issue #130:

This might be tricky to do although I think CKEditor offers functions we should be able to exploit to do it. At a minimum, some kind of automated triggering of search to get to it would be better than nothing...

I think this can be done without any special API, but if CKEditor already offers functions for this, that'd even better. This statement refers to scrolling to the match.

Highlighting the match should be done without page interaction if possible, i.e. like the DevTools do it.

Sebastian

@a2sheppy
Copy link
Contributor

See CKEDITOR.dom.selection.scrollIntoView() here, for starters: http://docs.ckeditor.com/#!/api/CKEDITOR.dom.selection-method-scrollIntoView

In general, there's a lot of stuff in the CKEditor API which is useful when writing tools to help with editing MDN -- http://docs.ckeditor.com/#!/api

@SebastianZ
Copy link
Collaborator Author

Highlighting the match should be done without page interaction if possible, i.e. like the DevTools do it.

And that's described here:
https://wiki.mozilla.org/DevTools/Highlighter

Sebastian

@Elchi3
Copy link
Owner

Elchi3 commented Jul 13, 2017

Re-filed as mdn/doc-linter-webextension#23

@Elchi3 Elchi3 closed this as completed Jul 13, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants