Skip to content

Conversation

@CAM-Gerlach
Copy link
Member

As reported by @encukou and confirmed by @hugovk in #2439 , the current approach of wrapping code/literal blocks at narrow viewport widths makes them difficult to read, especially if they are particularly wide, include multiple columns of text, and are not correct syntax-highlighted, all of which is the case for, e.g., at least one example block in PEP 678.

A better approach, as discussed there, is to simply allow scrolling overly-wide code blocks instead of wrapping them, which is what GitHub and other sites do (as well as most editors by default, if soft-wrap is not enabled). This PR implements that approach, resolving the issue.

Before and after on a simulated iPhone SE (2nd gen), a particularly narrow device:

image

Copy link
Member

@hugovk hugovk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks!

Copy link
Member

@encukou encukou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@CAM-Gerlach
Copy link
Member Author

As this is a straightforward fix, its been 24 hours and it seems all involved have 👍 ed it, I'll go ahead and merge now.

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

Labels

CLA signed infra Core infrastructure for building and rendering PEPs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants