Skip to content

Code blocks are not contained #263

@JacksonChen666

Description

@JacksonChen666

Describe the bug
Code blocks, when very long, are allowed to overflow outside of the contain class.

Reproduction steps
Steps to reproduce the behavior:

  1. Create a code block with a really really long line, so long that the text is larger than the container (maybe copy this line?)
  2. Look at code block

Expected behavior
The code block does not overflow outside of the box

Screenshots
A cState status page. The code block goes outside of where the usual content is.
A cState status page. The code block is not overflowing, and is scrolled a little bit.

Desktop (please complete the following information):

  • OS: macOS
  • Browser LibreWolf (Firefox fork)
  • Version 111.0.1-1

Additional context
The solution was included in the picture, and also below:

pre {
    overflow-x: scroll;
}

Make sure to test it a variety of cases. (I also might make a PR myself to fix this issue since you know, I already got the solution right above)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions