set focus to a certain position in the input
so I have this [input ] ( https://toddle.dev/projects/moccasin_palpatine_chief_rook/branches/start/components/test13?canvas-height=800&canvas-width=455.2&selection=nodes.EL_PzKJDA3Dg9z5gaRPRm.events.click.actions.0.data&rightpanel=events ) , and , when clicking the button , in the current cursor position , I want to : 1 . add a certain text 2 . refocus the cursor at the end of this added textthe I manage to complete 1 , but with point 2 I am finding some difficulties as I think it needs some code . it should be sth like the below but not sure how to implement it in toddle as I am not sure how can I refer to the input function insertTextAtCursor (input , text ) { const start = input .selectionStart ; const end = input .selectionEnd ; input .value = input .value .slice (0 , start ) + text + input .value .slice (end ) ; const newPosition = start + text .length ; input .setSelectionRange (newPosition , newPosition ) ; input .focus ( ) ; }