summaryrefslogtreecommitdiffstats
path: root/src/app
diff options
context:
space:
mode:
authorAlberto Duarte Delgado <alberto@albertoduarte.com>2026-04-21 12:41:25 +0100
committerAlberto Duarte Delgado <alberto@albertoduarte.com>2026-04-21 12:41:25 +0100
commitb86d7fbb27f6758d1c90b05b034d8f27fbf039c3 (patch)
treeca41f304f50e5130e61aa434b5f2913283d630b4 /src/app
parent7ec457dd65244da4a87b2b6b14867ac06ed0324b (diff)
fix(layout): respetar safe area en dispositivos
Diffstat (limited to 'src/app')
-rw-r--r--src/app/(protected)/(tabs)/_layout.tsx7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/app/(protected)/(tabs)/_layout.tsx b/src/app/(protected)/(tabs)/_layout.tsx
index c19cbff..a211459 100644
--- a/src/app/(protected)/(tabs)/_layout.tsx
+++ b/src/app/(protected)/(tabs)/_layout.tsx
@@ -1,12 +1,15 @@
import { Tabs } from 'expo-router';
import { Feather } from '@expo/vector-icons';
import { MaterialIcons } from '@expo/vector-icons';
+import { useSafeAreaInsets } from 'react-native-safe-area-context';
import theme from '@/theme';
// accesos cortos al theme de estilos
const { colors, typography, fontWeight, layout } = theme;
export default function TabsLayout() {
+ const insets = useSafeAreaInsets();
+
return (
<Tabs
screenOptions={{
@@ -18,8 +21,8 @@ export default function TabsLayout() {
fontWeight: fontWeight.regular,
},
tabBarStyle: {
- height: layout.tabBarHeight,
- paddingBottom: 2,
+ height: layout.tabBarHeight + insets.bottom,
+ paddingBottom: Math.max(insets.bottom, 2),
paddingTop: 6,
// ancho acotado igual que el container del home
width: '100%',