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

<button> is both and neither a block and a span element #173

Closed
morandat opened this Issue Oct 9, 2014 · 7 comments

Comments

Projects
None yet
2 participants
@morandat
Contributor

morandat commented Oct 9, 2014

< button > tags are almost always expanded as text (sorry I can't anymore figure out the only case where there are well interpreted).

It comes from the fact that button is both in HTML_SPAN_ELEMENTS/HTML_BLOCK_ELEMENTS and in HTML_CONTENT_MODEL_SPAN/HTML_CONTENT_MODEL_BLOCK.
Removing button from HTML_BLOCK_ELEMENTS seems to fix everything ... but I'm not sure about all side-effects.

@gettalong gettalong self-assigned this Oct 9, 2014

@gettalong

This comment has been minimized.

Owner

gettalong commented Oct 24, 2014

Thanks for the input! I will have to do some research before changing this - does anybody else have experience with this stuff?

@gettalong

This comment has been minimized.

Owner

gettalong commented Oct 25, 2014

@morandat Do you have a test case for this? I.e. what doesn't work for you?

@morandat

This comment has been minimized.

Contributor

morandat commented Oct 25, 2014

@gettalong It's not minimal, but close to. It's actually supposed to render some bootstrappy thing.

https://gist.github.com/morandat/64031638f916b2e0a1c6

@gettalong

This comment has been minimized.

Owner

gettalong commented Oct 25, 2014

@morandat Okay, but what is the input and what is the output?

@gettalong

This comment has been minimized.

Owner

gettalong commented Oct 25, 2014

If I take the gist as input, the <button> element is rendered incorrectly - this is fixed with your proposed change.

Note that the second <div>...</div> block is not valid in kramdown as the closing tag needs to be on a separate line.

@morandat

This comment has been minimized.

Contributor

morandat commented Oct 25, 2014

Yep, the button tag is rendered incorrectly ...
Yep sorry, I wrote the example very quickly.

@gettalong gettalong added the bug label Oct 25, 2014

@gettalong

This comment has been minimized.

Owner

gettalong commented Oct 25, 2014

Thanks for your input and the report, this is fixed now with commit d656641!

Just one note: If possible, only open a pull request if you already have code that corrects a bug, this avoids having two open issues with the same problem.

@gettalong gettalong closed this Oct 25, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment