Skip to content

Commit

Permalink
Merge pull request WICG#159 from josepharhar/master
Browse files Browse the repository at this point in the history
Added wikipedia example to beforematch explainer
  • Loading branch information
chrishtr authored May 2, 2020
2 parents a5706e5 + c785e03 commit 3a8820c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions explainer-beforematch.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,11 @@ relevant sections. For instance, navigating to
observing the `beforematch` event for that section as a result of the
scroll-to-text fragment navigation match.

One possible real-world application of this is the collapsed sections on mobile
wikipedia pages. find-in-page and scroll-to-text currently can't find text inside
of the collapsed sections, but with beforematch and content-visibility they
could be searchable and automatically expanded.

Also note that developer adoption of the `beforematch` event in these use-cases should be
straight-forward, since the typical page that provides content in collapsed
sections already has an event handler to expand and show the section. With the
Expand Down

0 comments on commit 3a8820c

Please sign in to comment.