captcha: recaptcha respects dark mode

also removed the ugly border around it.
This commit is contained in:
Harvey Tindall
2023-06-15 17:35:51 +01:00
parent 4014e93155
commit 07564bbde3
3 changed files with 17 additions and 3 deletions

View File

@@ -39,7 +39,8 @@
var reCAPTCHACallback = () => {
const el = document.getElementsByClassName("g-recaptcha")[0];
grecaptcha.render(el, {
"sitekey": window.reCAPTCHASiteKey
"sitekey": window.reCAPTCHASiteKey,
"theme": document.documentElement.classList.contains("dark") ? "dark" : "light"
});
}
</script>