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

docs(socks): same block as other sections #6553

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

magsen
Copy link

@magsen magsen commented Oct 18, 2023

@sigmavirus24
Copy link
Contributor

The current formatting looks correct to me. What looks wrong to you?

@magsen
Copy link
Author

magsen commented Oct 18, 2023

i have some kind of strange underscore

image

In a private firefox without dark theme
image
image


https://github.com/psf/requests/blob/main/docs/user/advanced.rst

In the rst preview you can see that this bash code block is not the same as the other bash code bloc

@sigmavirus24
Copy link
Contributor

I cannot replicate that on Firefox on macOS or Linux

@sigmavirus24
Copy link
Contributor

I cannot replicate that on Firefox on macOS or Linux.

I would be willing to entertain a PR, however that adds sphinx-prompt to our docs dependencies and switches this to using .. prompt:: instead because that's more correct

@nateprewitt
Copy link
Member

nateprewitt commented Oct 18, 2023

I am actually able to replicate this on macOS in Firefox 115.3.1esr (64-bit). It appears whitespace in these blocks are being replaced with span tags with the w CSS class from pygments. This adds a faint white (#f8f8f8) underline to each whitespace.

Screenshot 2023-10-18 at 12 26 22 PM

I don't however immediately see why this is being added specifically for the bash codeblock. I'm fine moving to the simplified syntax (::) (or .. prompt:: as Ian noted) in this case since the bash formatting doesn't materially change the output, but it would be interesting to understand why it's happening.

@sigmavirus24
Copy link
Contributor

To find out why it's happening I suspect we'll need a pygments bug to investigate.

The span doesn't change what you copy out of the text though

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.

None yet

3 participants