Thank you very much for your response WackyToaster.
So I tried your solution:
var textObject = runtime.objects.H1.getPickedInstances();
var content = textObject.text;
navigator.clipboard.writeText(content)
And I no longer have any error messages in the console. However, where it should copy my text to the clipboard, all it returns is:
undefined
I can't seem to get any other results...
Did I make a syntax error?"