@kubit-ui-web/react-components
Version:
Kubit React Components is a customizable, accessible library of React web components, designed to enhance your application's user experience
11 lines • 349 B
JavaScript
export const viewportHeight = () => {
if (!window.CSS.supports) {
return '100vh';
}
if (!window.CSS.supports('height: 100dvh') || !window.CSS.supports('max-height: 100dvh')) {
const { innerHeight } = window;
return `${innerHeight}px`;
}
return '100dvh';
};
//# sourceMappingURL=viewportHeight.mixin.js.map