deskripsi:
- tampilan edit profile
- resourcing stack
- fix text input & buttom
This commit is contained in:
2025-07-03 16:35:39 +08:00
parent 101c9053d8
commit 7b58e3315f
8 changed files with 99 additions and 17 deletions

View File

@@ -1,17 +1,64 @@
/* eslint-disable @typescript-eslint/no-unused-vars */
import { TextInputCustom, ViewWrapper } from "@/components";
import { StackCustom } from "@/components/Stack";
import {
ButtonCustom,
StackCustom,
TextCustom,
TextInputCustom,
ViewWrapper,
} from "@/components";
import { useLocalSearchParams } from "expo-router";
import { useState } from "react";
import { Text } from "react-native";
export default function ProfileEdit() {
const { id } = useLocalSearchParams();
const [nama, setNama] = useState("Bagas Banuna");
const [email, setEmail] = useState("bagasbanuna@gmail.com");
const [alamat, setAlamat] = useState("Bandar Lampung");
return (
<ViewWrapper>
<StackCustom>
<TextInputCustom label="Nama" value="Nama" required />
<TextInputCustom label="Email" value="Email" required />
<TextInputCustom label="Alamat" value="Alamat" required />
<ViewWrapper
bottomBarComponent={
<ButtonCustom
radius={30}
disabled={!nama || !email || !alamat}
onPress={() => {
console.log("data >>", nama, email, alamat);
}}
>
Simpan
</ButtonCustom>
}
>
<StackCustom gap={"xs"}>
<TextInputCustom
label="Nama"
placeholder="Nama"
value={nama}
onChangeText={(text) => {
setNama(text);
}}
required
/>
<TextInputCustom
label="Email"
placeholder="Email"
value={email}
onChangeText={(text) => {
setEmail(text);
}}
required
/>
<TextInputCustom
label="Alamat"
placeholder="Alamat"
value={alamat}
onChangeText={(text) => {
setAlamat(text);
}}
required
/>
</StackCustom>
</ViewWrapper>
);