We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 23f00a2 + cbe8e75 commit f22017eCopy full SHA for f22017e
resources/views/components/turnstile.blade.php
@@ -34,6 +34,20 @@
34
}
35
36
$wire.on('reset-captcha', () => resetCaptcha())
37
+
38
+ const observer = new IntersectionObserver((entries) => {
39
+ entries.forEach(entry => {
40
+ if (entry.isIntersecting &&
41
+ window.turnstile &&
42
+ !$refs.turnstile.querySelector('.cf-turnstile')) {
43
+ turnstile.render($refs.turnstile, options);
44
+ }
45
+ });
46
+ }, { threshold: 0.1 })
47
48
+ if ($refs.turnstile) {
49
+ observer.observe($refs.turnstile);
50
51
})()"
52
>
53
<div data-sitekey="{{config('turnstile.turnstile_site_key')}}"
0 commit comments