almost there for function

This commit is contained in:
Michael Freno
2025-12-18 01:18:38 -05:00
parent 1142d6f126
commit a19ad0cb36
5 changed files with 184 additions and 19 deletions

14
src/lib/client-utils.ts Normal file
View File

@@ -0,0 +1,14 @@
/**
* Client-side utility functions
* Note: These utilities should only run in the browser
*/
/**
* Triggers haptic feedback on mobile devices
* @param duration - Duration in milliseconds (default 50ms for a light tap)
*/
export function hapticFeedback(duration: number = 50) {
if (typeof window !== "undefined" && "vibrate" in navigator) {
navigator.vibrate(duration);
}
}