Initial commit

This commit is contained in:
unknown
2026-05-18 22:26:10 +02:00
commit db92ad2f88
34 changed files with 2158 additions and 0 deletions

View File

@@ -0,0 +1,16 @@
import { useState, useEffect } from 'react'
export function useReducedMotion(): boolean {
const [reducedMotion, setReducedMotion] = useState(false)
useEffect(() => {
const mq = window.matchMedia('(prefers-reduced-motion: reduce)')
setReducedMotion(mq.matches)
const handler = (e: MediaQueryListEvent) => setReducedMotion(e.matches)
mq.addEventListener('change', handler)
return () => mq.removeEventListener('change', handler)
}, [])
return reducedMotion
}