Highlight text to trigger actions

What I’m trying to do:
Hi Anvil Community. Is there a way on the user side to highlight text to trigger actions? I see this similar post but did not find the answer. Appreciate if anyone can shine more light on this. Thanks.

Did you figure this out? I am looking to do the same thing.