2025-01-28 08:19:46 -06:00
|
|
|
import { StyleSheet, Image, Platform } from 'react-native';
|
|
|
|
|
|
|
|
import { Collapsible } from '@/components/Collapsible';
|
|
|
|
import { ExternalLink } from '@/components/ExternalLink';
|
|
|
|
import ParallaxScrollView from '@/components/ParallaxScrollView';
|
|
|
|
import { ThemedText } from '@/components/ThemedText';
|
|
|
|
import { ThemedView } from '@/components/ThemedView';
|
|
|
|
import { IconSymbol } from '@/components/ui/IconSymbol';
|
|
|
|
|
|
|
|
export default function TabTwoScreen() {
|
|
|
|
return (
|
|
|
|
<ParallaxScrollView
|
|
|
|
headerBackgroundColor={{ light: '#D0D0D0', dark: '#353636' }}
|
|
|
|
headerImage={
|
|
|
|
<IconSymbol
|
|
|
|
size={310}
|
2025-01-28 08:45:02 -06:00
|
|
|
color='#808080'
|
|
|
|
name='chevron.left.forwardslash.chevron.right'
|
2025-01-28 08:19:46 -06:00
|
|
|
style={styles.headerImage}
|
|
|
|
/>
|
2025-01-28 08:45:02 -06:00
|
|
|
}
|
|
|
|
>
|
2025-01-28 08:19:46 -06:00
|
|
|
<ThemedView style={styles.titleContainer}>
|
2025-01-28 08:45:02 -06:00
|
|
|
<ThemedText type='title'>Explore</ThemedText>
|
2025-01-28 08:19:46 -06:00
|
|
|
</ThemedView>
|
|
|
|
<ThemedText>This app includes example code to help you get started.</ThemedText>
|
2025-01-28 08:45:02 -06:00
|
|
|
<Collapsible title='File-based routing'>
|
2025-01-28 08:19:46 -06:00
|
|
|
<ThemedText>
|
|
|
|
This app has two screens:{' '}
|
2025-01-28 08:45:02 -06:00
|
|
|
<ThemedText type='defaultSemiBold'>app/(tabs)/index.tsx</ThemedText> and{' '}
|
|
|
|
<ThemedText type='defaultSemiBold'>app/(tabs)/explore.tsx</ThemedText>
|
2025-01-28 08:19:46 -06:00
|
|
|
</ThemedText>
|
|
|
|
<ThemedText>
|
2025-01-28 08:45:02 -06:00
|
|
|
The layout file in <ThemedText type='defaultSemiBold'>app/(tabs)/_layout.tsx</ThemedText>{' '}
|
2025-01-28 08:19:46 -06:00
|
|
|
sets up the tab navigator.
|
|
|
|
</ThemedText>
|
2025-01-28 08:45:02 -06:00
|
|
|
<ExternalLink href='https://docs.expo.dev/router/introduction'>
|
|
|
|
<ThemedText type='link'>Learn more</ThemedText>
|
2025-01-28 08:19:46 -06:00
|
|
|
</ExternalLink>
|
|
|
|
</Collapsible>
|
2025-01-28 08:45:02 -06:00
|
|
|
<Collapsible title='Android, iOS, and web support'>
|
2025-01-28 08:19:46 -06:00
|
|
|
<ThemedText>
|
|
|
|
You can open this project on Android, iOS, and the web. To open the web version, press{' '}
|
2025-01-28 08:45:02 -06:00
|
|
|
<ThemedText type='defaultSemiBold'>w</ThemedText> in the terminal running this project.
|
2025-01-28 08:19:46 -06:00
|
|
|
</ThemedText>
|
|
|
|
</Collapsible>
|
2025-01-28 08:45:02 -06:00
|
|
|
<Collapsible title='Images'>
|
2025-01-28 08:19:46 -06:00
|
|
|
<ThemedText>
|
2025-01-28 08:45:02 -06:00
|
|
|
For static images, you can use the <ThemedText type='defaultSemiBold'>@2x</ThemedText> and{' '}
|
|
|
|
<ThemedText type='defaultSemiBold'>@3x</ThemedText> suffixes to provide files for
|
2025-01-28 08:19:46 -06:00
|
|
|
different screen densities
|
|
|
|
</ThemedText>
|
|
|
|
<Image source={require('@/assets/images/react-logo.png')} style={{ alignSelf: 'center' }} />
|
2025-01-28 08:45:02 -06:00
|
|
|
<ExternalLink href='https://reactnative.dev/docs/images'>
|
|
|
|
<ThemedText type='link'>Learn more</ThemedText>
|
2025-01-28 08:19:46 -06:00
|
|
|
</ExternalLink>
|
|
|
|
</Collapsible>
|
2025-01-28 08:45:02 -06:00
|
|
|
<Collapsible title='Custom fonts'>
|
2025-01-28 08:19:46 -06:00
|
|
|
<ThemedText>
|
2025-01-28 08:45:02 -06:00
|
|
|
Open <ThemedText type='defaultSemiBold'>app/_layout.tsx</ThemedText> to see how to load{' '}
|
2025-01-28 08:19:46 -06:00
|
|
|
<ThemedText style={{ fontFamily: 'SpaceMono' }}>
|
|
|
|
custom fonts such as this one.
|
|
|
|
</ThemedText>
|
|
|
|
</ThemedText>
|
2025-01-28 08:45:02 -06:00
|
|
|
<ExternalLink href='https://docs.expo.dev/versions/latest/sdk/font'>
|
|
|
|
<ThemedText type='link'>Learn more</ThemedText>
|
2025-01-28 08:19:46 -06:00
|
|
|
</ExternalLink>
|
|
|
|
</Collapsible>
|
2025-01-28 08:45:02 -06:00
|
|
|
<Collapsible title='Light and dark mode components'>
|
2025-01-28 08:19:46 -06:00
|
|
|
<ThemedText>
|
|
|
|
This template has light and dark mode support. The{' '}
|
2025-01-28 08:45:02 -06:00
|
|
|
<ThemedText type='defaultSemiBold'>useColorScheme()</ThemedText> hook lets you inspect
|
2025-01-28 08:19:46 -06:00
|
|
|
what the user's current color scheme is, and so you can adjust UI colors accordingly.
|
|
|
|
</ThemedText>
|
2025-01-28 08:45:02 -06:00
|
|
|
<ExternalLink href='https://docs.expo.dev/develop/user-interface/color-themes/'>
|
|
|
|
<ThemedText type='link'>Learn more</ThemedText>
|
2025-01-28 08:19:46 -06:00
|
|
|
</ExternalLink>
|
|
|
|
</Collapsible>
|
2025-01-28 08:45:02 -06:00
|
|
|
<Collapsible title='Animations'>
|
2025-01-28 08:19:46 -06:00
|
|
|
<ThemedText>
|
|
|
|
This template includes an example of an animated component. The{' '}
|
2025-01-28 08:45:02 -06:00
|
|
|
<ThemedText type='defaultSemiBold'>components/HelloWave.tsx</ThemedText> component uses
|
|
|
|
the powerful <ThemedText type='defaultSemiBold'>react-native-reanimated</ThemedText>{' '}
|
2025-01-28 08:19:46 -06:00
|
|
|
library to create a waving hand animation.
|
|
|
|
</ThemedText>
|
|
|
|
{Platform.select({
|
|
|
|
ios: (
|
|
|
|
<ThemedText>
|
2025-01-28 08:45:02 -06:00
|
|
|
The <ThemedText type='defaultSemiBold'>components/ParallaxScrollView.tsx</ThemedText>{' '}
|
2025-01-28 08:19:46 -06:00
|
|
|
component provides a parallax effect for the header image.
|
|
|
|
</ThemedText>
|
|
|
|
),
|
|
|
|
})}
|
|
|
|
</Collapsible>
|
|
|
|
</ParallaxScrollView>
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
const styles = StyleSheet.create({
|
|
|
|
headerImage: {
|
|
|
|
color: '#808080',
|
|
|
|
bottom: -90,
|
|
|
|
left: -35,
|
|
|
|
position: 'absolute',
|
|
|
|
},
|
|
|
|
titleContainer: {
|
|
|
|
flexDirection: 'row',
|
|
|
|
gap: 8,
|
|
|
|
},
|
|
|
|
});
|