diff --git a/client/src/templates/Challenges/redux/create-question-epic.js b/client/src/templates/Challenges/redux/create-question-epic.js index 9eedf5cab9..1d654ada91 100644 --- a/client/src/templates/Challenges/redux/create-question-epic.js +++ b/client/src/templates/Challenges/redux/create-question-epic.js @@ -4,7 +4,8 @@ import { types, closeModal, challengeFilesSelector, - challengeMetaSelector + challengeMetaSelector, + projectFormValuesSelector } from '../redux'; import { tap, mapTo } from 'rxjs/operators'; import { forumLocation } from '../../../../../config/env.json'; @@ -35,7 +36,9 @@ function createQuestionEpic(action$, state$, { window }) { navigator: { userAgent }, location: { href } } = window; - + const projectFormValues = Object.entries( + projectFormValuesSelector(state) + ); const endingText = dedent( `**Your browser information:** @@ -48,8 +51,18 @@ function createQuestionEpic(action$, state$, { window }) { ); let textMessage = dedent( - `**Tell us what's happening:**\n\n\n\n**Your code so far** - ${filesToMarkdown(files)}\n${endingText}` + `**Tell us what's happening:** + \n\n + ${ + projectFormValues.length + ? `**Your project link(s)**\n` + : `**Your code so far**` + } + ${projectFormValues + ?.map(([key, val]) => `${key}: ${val}\n`) + ?.join('') || filesToMarkdown(files)} + \n + ${endingText}` ); const altTextMessage = dedent(