diff --git a/presentation/react/components/HabitCreateForm/HabitCreateForm.tsx b/presentation/react/components/HabitCreateForm/HabitCreateForm.tsx index 65d0b6f..363ef29 100644 --- a/presentation/react/components/HabitCreateForm/HabitCreateForm.tsx +++ b/presentation/react/components/HabitCreateForm/HabitCreateForm.tsx @@ -5,6 +5,7 @@ import { Button, HelperText, SegmentedButtons, + Text, TextInput, } from "react-native-paper" import { SafeAreaView } from "react-native-safe-area-context" @@ -14,11 +15,11 @@ import ColorPicker, { Preview, } from "reanimated-color-picker" +import type { GoalFrequency, GoalType } from "@/domain/entities/Goal" +import { GOAL_FREQUENCIES, GOAL_TYPES } from "@/domain/entities/Goal" import type { HabitCreateData } from "@/domain/entities/Habit" import { HabitCreateSchema } from "@/domain/entities/Habit" import type { User } from "@/domain/entities/User" -import type { GoalFrequency, GoalType } from "@/domain/entities/Goal" -import { GOAL_FREQUENCIES, GOAL_TYPES } from "@/domain/entities/Goal" import { capitalize } from "@/presentation/presenters/utils/strings" export interface HabitCreateFormProps { @@ -154,17 +155,20 @@ export const HabitCreateForm: React.FC = ({ user }) => { control={control} render={({ field: { onChange, value } }) => { return ( - { - return { - label: capitalize(frequency), - value: frequency, - icon: frequenciesIcons[frequency], - } - })} - /> + <> + Habit frequency + { + return { + label: capitalize(frequency), + value: frequency, + icon: frequenciesIcons[frequency], + } + })} + /> + ) }} name="goal.frequency" @@ -174,17 +178,20 @@ export const HabitCreateForm: React.FC = ({ user }) => { control={control} render={({ field: { onChange, value } }) => { return ( - { - return { - label: habitTypesTranslations[type].label, - value: type, - icon: habitTypesTranslations[type].icon, - } - })} - /> + <> + Habit type + { + return { + label: habitTypesTranslations[type].label, + value: type, + icon: habitTypesTranslations[type].icon, + } + })} + /> + ) }} name="goal.target.type"