boxons/app/shared/theme/layout.ts

24 lines
478 B
TypeScript
Raw Permalink Normal View History

2024-10-13 11:29:36 +00:00
import { Dimensions, StyleSheet } from 'react-native';
const width = Dimensions.get('window').width;
const height = Dimensions.get('window').height;
export const layout = {
window: {
width,
height,
},
isSmallDevice: width < 375, // 375 but with added 5 px
isRegularDevice: width >= 375 && width <= 420,
isLargeDevice: width > 420,
gridUnit: 4,
iconSize: {
xxl: 80,
larger: 40,
large: 32,
medium: 24,
small: 16,
xsmall: 10
},
};