When searching for text in a web page, Firefox currently also finds occurences of text invisible to the user, e.g. by means of CSS.
This is very irritating.
I propose to only consider text as found being rendered with at least 3*3 pixels in the event of the search being performed. This will also make sure the web page will be getting scrolled to the region where the text has been found.
When I search good, there are two results in areas that are displayed persistently, and three in carousels. The carousels sometimes scroll to the match when I use next or previous on the Find bar and sometimes do not. When the carousel does not scroll, there is no explanation for where the match is.
This reminds me of some problems with Firefox finding matches in text that is styled away on other sites:
That’s why I suggest to check whether the caret surrounding a matching text is actually rendered (with 3*3 pixels at least). If it isn’t, I propose not to count that occurance as a hit.
Visible results should be listed separately from invisible results in the find bar, e.g. “1 of 2 visible matches (3 hidden matches found)”. The visible/invisible enumeration status text should be updated appropriately (either when DOM is updated or frequently once every 500 ms).
Optionally a checkbox could be added: |_| find visible matches only.
Is this the right place to suggest such feature? Or where would you suggest to shove my suggestion?
Yes, that would be great. Yet, from a programmer’s point of view that wouldn’t be possible.
Imagine a text rendered with point size of 0.01 pt. You wouldn’t still see the result.
And a carousel is a proprietary implementation. Imagine a “hidden” panel to be positioned at -10,000;-10,000 pixels left and above the page’s dimensions. Or somewhere else beyond a clipped region. The browser couldn’t possibly go there.
That’s why I suggest to accept the fact that a page source may contain non-rendered text that should be omitted from find results because that’s not what the user is searching for. A note explaining that invisible occurances exist should suffice, I believe.