Editable TextBox2 component does not register keypresses

Hi there,

I had to make a few tweaks but this should work: https://pavlovia.org/lpxrh6/spaanstest

I have no idea why but even though the ‘editable’ box was ticked that didn’t seem to translate to your JS code (so when I used console.log(typedText.editable) it returned false).

Manually resetting this at the start of your routine fixed this. (in your ‘typedSentence’ component you will see I have added typedText.editable = true; )

Following this though I also had to make your mouse click used to end the routine a bit more specific to allow the user to click on the textbox and type without immediately ending the routine (so you will see I added a component called ‘endButton’ and made it so that only this is clickable)

Hopefully this should work for what you need now :slight_smile:

Becca

PS. the reason I renamed your ‘text’ component was because I tried a few bug fixes before finding the solution - you can check over the commit history of my fork if you are curious.

2 Likes