Extract only part of the text

Hello, I’m new to this platform I have one question, how can I extract part of the text in the same ID…
I used before to use this code in another program " ```
SET VAR1 eval(""{{!EXTRACT}}".match(/^\s*\S+/)[0]")

is there is something similar here??

second question:
is there is an option to make wait till verify that there is a letter in a box appear??