You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@annotator.apache.org by Benjamin Young <by...@bigbluehat.com> on 2024/07/30 21:25:31 UTC

Highlight and HighlightRegistry API in Chrome (etc.)

I'm pretty confident these have been mentioned before, but thought I'd resurface them in a new thread:
https://developer.mozilla.org/en-US/docs/Web/API/Highlight
https://developer.mozilla.org/en-US/docs/Web/API/HighlightRegistry

Highlight takes ranges...which are hard for any mere mortal to create...unless they use Apache Annotator! ;)

At any rate, I think putting a demo together that uses the Highlight API instead of <mark> would be useful, educational, and awesome.

Cheers!
Benjamin

--
https://bigbluehat.com/
https://linkedin.com/in/benjaminyoung



Re: Highlight and HighlightRegistry API in Chrome (etc.)

Posted by Gerben <ge...@treora.com.INVALID>.
On 30/07/2024 23:25, Benjamin Young wrote:
> I'm pretty confident these have been mentioned before, but thought I'd resurface them in a new thread:
> https://developer.mozilla.org/en-US/docs/Web/API/Highlight
> https://developer.mozilla.org/en-US/docs/Web/API/HighlightRegistry
>
> Highlight takes ranges...which are hard for any mere mortal to create...unless they use Apache Annotator! ;)
>
> At any rate, I think putting a demo together that uses the Highlight API instead of <mark> would be useful, educational, and awesome.

Note Randall had ambitions around this Highlight API: 
https://github.com/apache/incubator-annotator/pull/135#issuecomment-2081254311 


I had not looked into it yet, but it seems a good match indeed. Mark 
elements could indeed be used as a fallback.