código partido en src/: la app no cambia ni un byte

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YA7U5k2DMU8ZdD6MztyVYS
This commit is contained in:
2026-10-20 04:49:54 +02:00
co-authored by Claude Opus 5.5
parent 104d83087b
commit b486f04427
58 changed files with 11525 additions and 11421 deletions
+17
View File
@@ -0,0 +1,17 @@
const { useState, useEffect, useCallback, useMemo, useRef } = React;
// Detecta pantalla estrecha (móvil) y se reajusta al rotar/redimensionar.
// Reutilizable para adaptar cualquier vista a móvil sin media queries CSS.
function useIsMobile(breakpoint) {
const bp = breakpoint || 560;
const [isMobile, setIsMobile] = useState(
typeof window !== "undefined" ? window.innerWidth <= bp : false
);
useEffect(() => {
const onResize = () => setIsMobile(window.innerWidth <= bp);
window.addEventListener("resize", onResize);
return () => window.removeEventListener("resize", onResize);
}, [bp]);
return isMobile;
}