Skip to content

Commit

Permalink
fix: rendering multiple line in markdown
Browse files Browse the repository at this point in the history
Previously, the join method used in `user_input` concatenates the lines
using '\n', which will not displayed correctly in markdown, so another
additional line break is added.
  • Loading branch information
efJerryYang committed Mar 27, 2023
1 parent 0f13332 commit 214af90
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/utils/io.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ def user_input(prompt="\nUser: ") -> str:
# Update the prompt using readline
prompt = "\r" + " " * len(prompt) + "\r" + " .... "
# Print a message indicating that the input has been submitted
msg = "\n".join(lines).strip()
msg = "\n\n".join(lines).strip()
if not msg:
printmd("**[Empty Input Skipped]**")
return msg
Expand Down

0 comments on commit 214af90

Please sign in to comment.