feat: add cursor settings, enhance setup wizard and loading animations

This commit is contained in:
HorizonCode committed 2025-07-01 14:13:40 +02:00
1 parent ba211641a6
commit 50f6812054
10 files changed
+374 -130

No files matched your search

+20
View File
@@ -0,0 +1,20 @@
export function estimateRefreshRate(): Promise<number> {
return new Promise((resolve) => {
let last = performance.now();
let frames = 0;
function loop() {
const now = performance.now();
frames++;
if (now - last >= 1000) {
console.log(`Estimated Refresh Rate: ${frames} FPS`);
resolve(frames); // estimated Hz
} else {
requestAnimationFrame(loop);
}
}
requestAnimationFrame(loop);
});
}