diff --git a/.prettierrc.js b/.prettierrc.js index 365bbc4..893dd06 100644 --- a/.prettierrc.js +++ b/.prettierrc.js @@ -5,5 +5,5 @@ semi: true, singleQuote: true, bracketSpacing: true, - printWidth: 1200, + printWidth: 100, } diff --git a/src/components/core/Button.tsx b/src/components/core/Button.tsx index 6cca554..816440d 100644 --- a/src/components/core/Button.tsx +++ b/src/components/core/Button.tsx @@ -3,12 +3,12 @@ import { Text, TouchableOpacity } from 'react-native'; type Props = { title: string; - onPress?: () => object; + onPress?: () => void; }; const Button = ({ title, onPress }: Props) => ( - - {title} + + {title} ); diff --git a/src/components/core/Input.tsx b/src/components/core/Input.tsx new file mode 100644 index 0000000..6d640ec --- /dev/null +++ b/src/components/core/Input.tsx @@ -0,0 +1,20 @@ +import { TextInput } from 'react-native'; + +type Props = { + value?: string; + placeholder?: string; + containerClass?: string; + onPressClose?: () => void; + onChangeText: (value: string) => void; +}; + +const Input = ({ value, containerClass, placeholder, onChangeText }: Props) => ( + +); + +export default Input; diff --git a/src/navigators/MainNavigator.tsx b/src/navigators/MainNavigator.tsx index 9563cb9..ca5de14 100644 --- a/src/navigators/MainNavigator.tsx +++ b/src/navigators/MainNavigator.tsx @@ -1,6 +1,6 @@ import { NavigationContainer } from '@react-navigation/native'; import { createNativeStackNavigator } from '@react-navigation/native-stack'; -import TestScreen from '@screens/Test'; +import WelcomeScreen from '@screens/Welcome'; export type MainNavigatorParamList = { Welcome: undefined; @@ -11,7 +11,7 @@ const Stack = createNativeStackNavigator(); const MainNavigator = () => ( - + ); diff --git a/src/screens/Welcome/index.tsx b/src/screens/Welcome/index.tsx new file mode 100644 index 0000000..f1c0aa0 --- /dev/null +++ b/src/screens/Welcome/index.tsx @@ -0,0 +1,36 @@ +import Button from '@components/core/Button'; +import Input from '@components/core/Input'; +import { text } from '@theme/text'; +import { useState } from 'react'; +import { Text, View } from 'react-native'; + +const WelcomeScreen = () => { + const [wordpressSite, setWordpressSiteUrl] = useState('https://blog.ted.com/'); + + return ( + + + + Wo + + Mob + + + + Wordpress to Mobile App + + + + +