Skip to content

Add paragraph wrapper to table rows #128

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

martinagvilas
Copy link
Contributor

Closes #127

I added a paragraph wrapper to render_table_row, and modified the existing tests to capture this wrapper.

Let me know if a new test should be added to this PR, making sure urls inside the table are rendered as references, or something of the sort.

@chrisjsewell
Copy link
Member

Thanks @martinagvilas looks good (well apart from the currently failing tests lol)
While you are at it, could I also ask you to add one or two more tests; primarily to test links in table cells.

Cheers, Chris

@codecov
Copy link

codecov bot commented Apr 15, 2020

Codecov Report

Merging #128 into master will increase coverage by 0.01%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #128      +/-   ##
==========================================
+ Coverage   91.68%   91.70%   +0.01%     
==========================================
  Files           9        9              
  Lines         974      976       +2     
==========================================
+ Hits          893      895       +2     
  Misses         81       81              
Flag Coverage Δ
#pytests 91.70% <100.00%> (+0.01%) ⬆️
Impacted Files Coverage Δ
myst_parser/docutils_renderer.py 96.00% <100.00%> (+0.01%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c92b457...92c8500. Read the comment docs.

@martinagvilas
Copy link
Contributor Author

I fixed the failing tests, but I still have to add the new ones

@martinagvilas
Copy link
Contributor Author

I added some tests, let me know if they are enough

Also, I noticed that when using to_html with the MyST API it is still rendered without the paragraphs, but if I understand correctly in this case you are using directly the renderer of markdown_it

@choldgraf
Copy link
Member

@martinagvilas amazing!

yep, the docutils writer is different, and IMO it's probably fine to have the outputs of both slightly different, though maybe @chrisjsewell has thoughts if we want to enforce that HTML outputs are equal for both docutils -> sphinx -> html and for the direct "to html" functionality.

@chrisjsewell
Copy link
Member

@martinagvilas
Copy link
Contributor Author

Great! Just wanted to make sure I wasn't missing anything

@chrisjsewell
Copy link
Member

btw @choldgraf you can see here that with on: [push, pull_request] only runs the tests once for forked PRs

@chrisjsewell chrisjsewell merged commit a24d7b2 into executablebooks:master Apr 15, 2020
@choldgraf
Copy link
Member

wooo congrats @martinagvilas on your first pull request merged in the ExecutableBookProject! :-)

@chrisjsewell - thanks for pointing it out - I'll just start forking and making PRs that way from now on

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Issue with urls inside markdown tables
3 participants