Skip to content
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

Paragraph inside listing #227

Open
botzill opened this issue Feb 7, 2017 · 0 comments
Open

Paragraph inside listing #227

botzill opened this issue Feb 7, 2017 · 0 comments

Comments

@botzill
Copy link
Contributor

botzill commented Feb 7, 2017

Currently if we want to do smth like this:

screen shot 2017-02-07 at 8 15 52 pm

We end up with:

screen shot 2017-02-07 at 8 16 54 pm

Because currently, when we parse listings, we just add the paragraphs separated by <br/>.

Generated html is:

<p>Paragraph 1</p>
<ul>
    <li>AAA</li>
    <li>BBB <br/>Paragraph 2</li>
    <li>CCC</li>
    <li>DDD</li>
</ul>

Of course we may have other more complex cases including nested lists and so on.

One solution for this would be to properly detect such cases and add some negative margin left to the paragraph depending on the position of the paragraph in the lists hierarchy. For this we need also to take into account the default <li> left margin and properly adjust it for the paragraphs(I did similar to listing margins here #225).

Let me know, please, what you think about this and maybe you have a better alternative.

Thx!

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

No branches or pull requests

1 participant