Compare commits
6 Commits
feature/pa
...
a80945bf0b
| Author | SHA1 | Date | |
|---|---|---|---|
| a80945bf0b | |||
| 03b06632f9 | |||
| f7c867e13c | |||
| 2f2b7866c6 | |||
| f85b596a66 | |||
| 9b8c273c21 |
@@ -15,14 +15,21 @@ document.addEventListener('DOMContentLoaded', () => {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
const cursor = document.getElementById('custom-cursor');
|
window.addEventListener('load', () => {
|
||||||
|
const cursor = document.getElementById('custom-cursor');
|
||||||
|
const gsapInstance = window.gsap;
|
||||||
|
|
||||||
document.addEventListener('mousemove', (e) => {
|
if (!cursor || !gsapInstance) {
|
||||||
gsap.to(cursor, {
|
return;
|
||||||
duration: 0.2,
|
}
|
||||||
x: e.clientX + 20,
|
|
||||||
y: e.clientY - 15,
|
document.addEventListener('mousemove', (e) => {
|
||||||
ease: 'power2.out'
|
gsapInstance.to(cursor, {
|
||||||
|
duration: 0.2,
|
||||||
|
x: e.clientX + 20,
|
||||||
|
y: e.clientY - 15,
|
||||||
|
ease: 'power2.out'
|
||||||
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||||
<meta name="csrf-token" content="{{ csrf_token() }}">
|
<meta name="csrf-token" content="{{ csrf_token() }}">
|
||||||
|
|
||||||
<title>Laravel</title>
|
<title>{{ config('app.name') }}</title>
|
||||||
|
|
||||||
<!-- Fonts -->
|
<!-- Fonts -->
|
||||||
<link rel="preconnect" href="https://fonts.bunny.net">
|
<link rel="preconnect" href="https://fonts.bunny.net">
|
||||||
@@ -179,7 +179,8 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
const visitorKey = 'cv_visitor_id';
|
const visitorKey = 'cv_visitor_id';
|
||||||
const createVisitorId = () => window.crypto?.randomUUID?.() ?? `${Date.now()}-${Math.random().toString(36).slice(2)}`;
|
const createVisitorId = () => window.crypto?.randomUUID?.() ??
|
||||||
|
`${Date.now()}-${Math.random().toString(36).slice(2)}`;
|
||||||
let visitorId = createVisitorId();
|
let visitorId = createVisitorId();
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|||||||
Reference in New Issue
Block a user