diff --git a/mobile/tradeverse/services/oldPage.jsx b/mobile/tradeverse/services/oldPage.jsx deleted file mode 100644 index 4b8bfb7d..00000000 --- a/mobile/tradeverse/services/oldPage.jsx +++ /dev/null @@ -1,151 +0,0 @@ -import { View, Text } from 'react-native' -import React from 'react' -import GlobalScreen from '../../components/ui/global-screen' -import FullScrollView from '../../components/ui/full-scroll-view' -import RHFTextArea from '../../components/inputs/RHFTextArea' -import RHFTextField from '../../components/inputs/RHFTextField' -import { FormProvider, useForm } from 'react-hook-form' -import { z } from 'zod' -import { zodResolver } from '@hookform/resolvers/zod' -import { COLORS, SIZE_CONSTANT } from '../../constants/theme' -import ProfileImage from '../../components/images/profile-image' -import { IconPencil } from '@tabler/icons-react-native' -import { Stack } from 'expo-router' -import { useContext } from 'react' -import { AuthContext } from '../../auth/context' -import { TAGS } from '../../constants' -import MainButton from '../../components/buttons/main-button' -import {setProfile} from '../../services/user' -export default function AccountProfileScreen() { - const validationSchema = z.object({ - name: z.string().min(1, { message: 'Bu alan gerekli.' }), - description: z.string().min(1, { message: 'Bu alan gerekli.' }), - }) - - const form = useForm({ - defaultValues: { - name: '', - surname: '', - tag: '', - description: '', - }, - resolver: zodResolver(validationSchema), - }) - - const { user } = useContext(AuthContext) - - const [isSubmitLoading, setIsSubmitLoading] = useState(false) - const [username, setUsername] = useState('') - - async function handleSubmit (){ - try { - setIsSubmitLoading(true) - const response = await setProfile({ - - }) - } catch (error) { - - } - finally { - setIsSubmitLoading(false) - } - } - - return ( - - - - - - - - - - - - - @{user?.username ?? 'username'} - - - - tag.value === user?.tag)[0].label - } - defaultValue={user?.tag ?? 'Beginner'} - /> - - - - - - - - ) -} \ No newline at end of file