Update LiveView html form before sending (implement reCAPTCHA v3 )

Tested several times, I discovered, my form is updated in JS file, but my LiveView form (phx_trigger_action) skips it and does not send hidden form value which is recreated

How can I fix this?

I have read these posts, but I couldn’t fix this