WEBLEB
Início
Editor
Entrar
Pro
Português
English
Français
Español
Português
Deutsch
Italiano
हिंदी
Site
14
kevekıbhack
Abrir no Editor
Video
Publique Seu Código
0
Recomendado
13 December 2025
Modelo HTML para site de portfólio holográfico
3 March 2025
Site do sistema de registro de eventos HTML CSS
9 November 2024
Modelo de site de produto HTML
HTML
Copy
window.addEventListener('mousemove', (e) => { mouse.x = (e.clientX / window.innerWidth) * 2 - 1; mouse.y = -(e.clientY / window.innerHeight) * 2 + 1; }); function updateUI(scrollX) { const rawIndex = Math.round(scrollX / CONFIG.spacingX); const safeIndex = ((rawIndex % CONFIG.slideCount) + CONFIG.slideCount) % CONFIG.slideCount; for(let i=0; i
{ const originalX = i * CONFIG.spacingX; const distFromCam = currentScroll - originalX; const shift = Math.round(distFromCam / totalGalleryWidth) * totalGalleryWidth; group.position.x = originalX + shift; }); camera.rotation.x = mouse.y * 0.05; camera.rotation.y = -mouse.x * 0.05; updateUI(currentScroll); renderer.render(scene, camera); } window.addEventListener('resize', () => { camera.aspect = window.innerWidth / window.innerHeight; camera.updateProjectionMatrix(); renderer.setSize(window.innerWidth, window.innerHeight); }); animate();