Files
dpl/theme/Fuc/assets/layout.mjs
T

8 lines
315 B
JavaScript

// Match the CSS layout viewport. iOS innerWidth can shrink when the visual
// viewport is zoomed, even though the CSS breakpoint has not changed.
export function isDesktopLayout() {
return typeof window.matchMedia === 'function'
? window.matchMedia('(min-width: 1200px)').matches
: innerWidth >= 1200;
}