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

Skip to content

Commit 7ef89e6

Browse files
committed
Add a link to the markdown in help text
1 parent a2cff8e commit 7ef89e6

File tree

5 files changed

+7
-6
lines changed

5 files changed

+7
-6
lines changed

src/components/goals/EditGoal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ export default function EditGoal({
9797
label="Goal description"
9898
rows={5}
9999
placeholder="I will code for atleast 2 hours everyday."
100-
helpText="Basic markdown is supported."
100+
helpText="[Basic Markdown](/markdown) is supported."
101101
hasError={Boolean(errors.description)}
102102
errorMessage="Something went wrong!!!"
103103
onKeyDown={async (e) => {

src/components/goals/NewComment.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ export default function NewComment({ updateId }: { updateId: string }) {
7777
placeholder="Give suggestions or ask questions related to the update."
7878
hasError={Boolean(errors.description)}
7979
errorMessage="Comment is required!!!"
80-
helpText="Basic markdown is supported."
80+
helpText="[Basic Markdown](/markdown) is supported."
8181
onKeyDown={(e) => {
8282
if (e.code === 'Enter' && (e.metaKey || e.ctrlKey)) {
8383
handleSubmit(onSubmit)()

src/components/goals/NewGoal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ export default function NewGoal() {
8585
label="Goal description"
8686
rows={3}
8787
placeholder="I will code for atleast 2 hours everyday."
88-
helpText="Basic markdown is supported."
88+
helpText="[Basic Markdown](/markdown) is supported."
8989
hasError={Boolean(errors.description)}
9090
errorMessage="Something went wrong!!!"
9191
onKeyDown={async (e) => {

src/components/goals/NewUpdate.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ export default function NewUpdate({
9090
placeholder="What did you do today to move towards your goal?"
9191
hasError={Boolean(errors.description)}
9292
errorMessage="Update is required!!!"
93-
helpText="Basic markdown is supported."
93+
helpText="[Basic Markdown](/markdown) is supported."
9494
onKeyDown={(e) => {
9595
if (e.code === 'Enter' && (e.metaKey || e.ctrlKey)) {
9696
handleSubmit(onSubmit)()

src/components/ui/form/TextArea.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import * as React from 'react'
22
import classNames from 'classnames'
3+
import Markdown from 'src/components/Markdown'
34

45
export type TextAreaProps = {
56
label?: string
@@ -74,12 +75,12 @@ const TextArea = React.forwardRef(
7475
{help && (
7576
<p
7677
className={classNames(
77-
'mt-2 text-sm',
78+
'mt-2 text-sm prose prose-sm',
7879
hasError ? ' text-red-600' : ' text-gray-500'
7980
)}
8081
id={`${id}-${hasError ? 'error' : 'description'}`}
8182
>
82-
{help}
83+
<Markdown>{help}</Markdown>
8384
</p>
8485
)}
8586
</div>

0 commit comments

Comments
 (0)