Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit afbaa55

Browse files
committed
Update labels when setting/editing goal
1 parent 3915fa8 commit afbaa55

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

src/components/goals/EditGoal.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ export default function EditGoal({
7575
ref={register({ required: true, maxLength: 50 })}
7676
defaultValue={goal.title}
7777
name="title"
78-
label="Goal Title"
78+
label="What is your goal?"
7979
type="text"
8080
placeholder="Participate in #100DaysOfCode"
8181
hasError={Boolean(errors.title)}
@@ -88,7 +88,7 @@ export default function EditGoal({
8888

8989
<Input
9090
type="date"
91-
label="Goal Deadline"
91+
label="By what time do you want to achieve this goal?"
9292
ref={register({ valueAsDate: true, required: true })}
9393
name="deadline"
9494
defaultValue={goal.deadline.toISODate()}
@@ -100,7 +100,7 @@ export default function EditGoal({
100100
ref={register}
101101
defaultValue={goal.description}
102102
name="description"
103-
label="Goal description"
103+
label="What is your plan to achieve this goal?"
104104
rows={5}
105105
placeholder="I will code for atleast 2 hours everyday."
106106
helpText="[Basic Markdown](/markdown) is supported."

src/components/goals/NewGoal.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,11 @@ export default function NewGoal() {
6161
<div className="mt-6">
6262
<div className="flex space-x-3">
6363
<div className="min-w-0 flex-1">
64-
<form onSubmit={handleSubmit(onSubmit)}>
64+
<form onSubmit={handleSubmit(onSubmit)} className="space-y-3">
6565
<Input
6666
ref={register({ required: true, maxLength: 50 })}
6767
name="title"
68-
label="Goal Title"
68+
label="What is your goal?"
6969
type="text"
7070
placeholder="Participate in #100DaysOfCode"
7171
hasError={Boolean(errors.title)}
@@ -78,7 +78,7 @@ export default function NewGoal() {
7878

7979
<Input
8080
type="date"
81-
label="Goal Deadline"
81+
label="By what time do you want to achieve this goal?"
8282
ref={register({ valueAsDate: true, required: true })}
8383
name="deadline"
8484
hasError={Boolean(errors.deadline)}
@@ -88,7 +88,7 @@ export default function NewGoal() {
8888
<TextArea
8989
ref={register}
9090
name="description"
91-
label="Goal description"
91+
label="What is your plan to achieve this goal?"
9292
rows={3}
9393
placeholder="I will code for atleast 2 hours everyday."
9494
helpText="[Basic Markdown](/markdown) is supported."

src/components/ui/form/TextArea.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ const TextArea = React.forwardRef(
5050
<label
5151
htmlFor={id}
5252
className={classNames(
53-
'block text-sm font-medium text-gray-700 sm:mt-px sm:pt-2',
53+
'block text-sm font-medium text-gray-700',
5454
hideLabel && 'sr-only'
5555
)}
5656
>

0 commit comments

Comments
 (0)