${questionText}
${errorText}
`;
}
-function documentRegex(text: string): string {
- const newText = text
- .split(/\r?\n/)
- .map((comment) => comment.replace(/(^[ \\t]+)?(^)((\/\/))(.*)/gm, ''))
- .join('');
+// function documentRegex(text: string): string {
+// const newText = text
+// .split(/\r?\n/)
+// .map((comment) => comment.replace(/(^[ \\t]+)?(^)((\/\/))(.*)/gm, ''))
+// .join('');
- const newLineAnswer = /([^\\]|[^\S\r\n][^=])(=|~)/g;
- const correctAnswer = /([^\\]|^{)(([^\\]|^|\\s*)=(.*)(?=[=~}]|\\n))/g;
- const incorrectAnswer = /([^\\]|^{)(([^\\]|^|\\s*)~(.*)(?=[=~}]|\\n))/g;
+// const newLineAnswer = /([^\\]|[^\S\r\n][^=])(=|~)/g;
+// const correctAnswer = /([^\\]|^{)(([^\\]|^|\\s*)=(.*)(?=[=~}]|\\n))/g;
+// const incorrectAnswer = /([^\\]|^{)(([^\\]|^|\\s*)~(.*)(?=[=~}]|\\n))/g;
- return newText
- .replace(newLineAnswer, `\n$2`)
- .replace(correctAnswer, `$1