diff --git a/sites/smartin3.de/index.html b/sites/smartin3.de/index.html
index ac416d7..8736fe1 100644
--- a/sites/smartin3.de/index.html
+++ b/sites/smartin3.de/index.html
@@ -93,6 +93,7 @@
margin: 0 auto 40px;
display: flex; justify-content: center;
padding: 60px 40px;
+ touch-action: pan-y;
}
.text3d {
@@ -670,8 +671,9 @@
// Interactive 3D text
(function() {
var hero = document.querySelector('.hero');
+ var wrapper = document.querySelector('.text3d-wrapper');
var text = document.querySelector('.text3d');
- if (!hero || !text) return;
+ if (!hero || !wrapper || !text) return;
function handleMove(x, y) {
var w = window.innerWidth;
@@ -684,10 +686,9 @@
}
hero.addEventListener('mousemove', function(e) { handleMove(e.clientX, e.clientY); });
- hero.addEventListener('touchmove', function(e) {
- e.preventDefault();
+ wrapper.addEventListener('touchmove', function(e) {
handleMove(e.touches[0].clientX, e.touches[0].clientY);
- }, {passive: false});
+ }, {passive: true});
hero.addEventListener('mouseleave', function() {
text.style.animation = '';
text.style.transform = '';