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

Implement <br> #2362

Closed
SimonSapin opened this issue May 7, 2014 · 2 comments
Closed

Implement <br> #2362

SimonSapin opened this issue May 7, 2014 · 2 comments
Assignees
Labels

Comments

@SimonSapin
Copy link
Member

@SimonSapin SimonSapin commented May 7, 2014

Based on what the HTML spec says as of this writing, I previously said that the <br> element could be implemented as br { content: '\A'; white-space: pre; } the user-agent stylesheet and not require any specific Rust code.

It turns out that what other browsers do is slightly more complicated, so this is still an open issue at the spec level. Discussion starts here:

http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2014-January/211267.html

Although maybe we don’t need to get all the details of this behavior right, for a first approximation.

@SimonSapin
Copy link
Member Author

@SimonSapin SimonSapin commented May 7, 2014

#1638 adds a hack to the user-agent stylesheet to kind of simulate <br> without the content property. (It looks like it could break in all kinds of interesting ways in corner cases.) It should be removed once we have something better.

@mbrubeck
Copy link
Contributor

@mbrubeck mbrubeck commented Sep 10, 2014

#3163 added a pure CSS implementation that's similar to the one in the HTML spec. However, depending on how the spec issue is resolved, we may still need to change this to match other browsers' behavior.

@mbrubeck mbrubeck closed this Sep 10, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.