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 selection is broken by inline code #801

Closed
bluetech opened this issue Oct 6, 2018 · 1 comment
Closed

Paragraph selection is broken by inline code #801

bluetech opened this issue Oct 6, 2018 · 1 comment
Labels
A-Style Area: Style (CSS, etc.) C-papercut Category: A small usability bug E-Easy Experience: Easy

Comments

@bluetech
Copy link

bluetech commented Oct 6, 2018

Scenario:

Consider the first paragraph here https://doc.rust-lang.org/book/second-edition/ch06-02-match.html.

Triple click somewhere in the middle of the paragraph (e.g. the word "wildcards").

Expected:

The entire paragraph is selected ("Rust has [...] are handled.").

This is how e.g. GitHub behaves, try triple-clicking in the following for example:

Lorem ipsum dolor sit amet, consectetur match adipiscing. Ut enim ad minim veniam, quis nostrud exercitation match ullamco laboris nisi.

Actual:

Only the text between the preceding and subsequent inline code blocks are selected (match in this case).

This happens because inline code blocks are specified to have inline-block display:

https://github.com/rust-lang-nursery/mdBook/blob/8ba183075076b4ef871d442e74b5e53d7d78ed36/src/theme/css/chrome.css#L175-L181

Changing this to inline fixes the problem (tested with browser's developer tools). However, I don't know if there are any downsides to that. Is the inline-block intentional?

@ehuss ehuss added A-Style Area: Style (CSS, etc.) E-Easy Experience: Easy C-papercut Category: A small usability bug labels May 17, 2019
@bluetech
Copy link
Author

bluetech commented Nov 4, 2019

This was fixed in #1058.

@bluetech bluetech closed this as completed Nov 4, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Style Area: Style (CSS, etc.) C-papercut Category: A small usability bug E-Easy Experience: Easy
Projects
None yet
Development

No branches or pull requests

2 participants