element-hq / element-hq/element-call
Recaptcha needs support for recapture v2 (check box)
- Dominant language
- TypeScript
- Stars
- 996
- Forks
- 213
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 55
Description
### Steps to reproduce
hello @robintown ,
as we have already written in chat #webrtc:matrix.org.
i have enabled recapture on [matrix.envs.net](http://matrix.envs.net/). (recapture v2 (check box))
but it looks like element-call used recapture v2 (invisible).
https://github.com/matrix-org/synapse/blob/develop/docs/CAPTCHA_SETUP.md
> Set the type to reCAPTCHA v2 using the "I'm not a robot" Checkbox option. This is the only type of captcha that works with Synapse.
```diff
--- a/src/auth/useRecaptcha.ts
+++ b/src/auth/useRecaptcha.ts
@@ -47,7 +47,7 @@ export const useRecaptcha = (sitekey: string) => {
window.grecaptcha.render(recaptchaId, {
sitekey,
- size: "invisible",
+ size: "normal",
callback: (response: string) => promiseRef.current?.resolve(response),
// eslint-disable-next-line @typescript-eslint/naming-convention
"error-callback": () => promiseRef.current?.reject(new Error()),
```
seems this was implemented with invisible captchas in mind in general.
`"grecaptcha.execute only works with invisible reCAPTCHA.`

maybe someone has an idea in the future how the problem can be fixed. Thank you very much
### Outcome
#### What did you expect?
#### What happened instead?
### Operating system
_No response_
### Browser information
_No response_
### URL for webapp
element-call.envs.net
### Will you send logs?
No
Contributor guide
Assessment
This issue has not been assessed yet.