AutarkLabs / open-enterprise

A suite of apps that includes allocation, dot voting, issue curation, and other planning tools so organizations can collectively budget and design custom reward & bounty systems.
GNU General Public License v3.0
92 stars 54 forks source link

Markdown formatting fixes #1831

Closed chadoh closed 4 years ago

chadoh commented 4 years ago

See "before" screenshot in #1822. Here's how it looks now:

Screen Shot 2019-12-23 at 12 57 07

I also spent some time researching why our solution formats some text blocks differently than GitHub. Example text block:

**To Reproduce**
Steps to reproduce the behavior:
1. Go to 'rewards'
2. Click on 'New Reward.'
3. Scroll down to 'Recurring Dividend'
4. See error once go to the voting and attempt to execute

Here's how GitHub renders this:

Screen Shot 2019-12-23 at 12 57 16

Here's how react-markdown renders it:

Screen Shot 2019-12-23 at 12 57 28

Note, however, that this is ill-formatted markdown! Well-formatted markdown would put an extra line break below the first and second lines of text, like this:

**To Reproduce**

Steps to reproduce the behavior:

1. Go to 'rewards'
2. Click on 'New Reward.'
3. Scroll down to 'Recurring Dividend'
4. See error once go to the voting and attempt to execute

If formatted like this, our renderer matches GitHub's:

Screen Shot 2019-12-23 at 13 00 19

I tried to find some options to pass to react-markdown to make it render more like GitHub. Surprisingly, "GitHub-Flavored Markdown" is the default setting, but it does not match GitHub in this regard.

I could find no easy setting after about a half hour of research, and didn't think it was worth more time to support ill-formatted markdown, at this time.