Regression 8.8: code display no longer scrolls horizontally
We are using code view to post lo
g snippets that can contain quite lon
g lines. The way GitLab breaks these l
ines since EE 8.9 makes it totally wei
rd. Pre 8.9 it had a horizontal scrol
l bar.
Is there an option to revert to th
e old behavior? Th
anks!
Not sure if this is EE only or CE, posting to CE, as both are likely affected.
This is simply a CSS issue. The old way was to allow horizontal scrolling, now the box word wraps.
ADD: Here's the problematic change: https://gitlab.com/gitlab-org/gitlab-ce/commit/25f592cf9c2d126625404df140dc5d958e8822cc (file detail_page.scss overrides white-space
for <code>
from pre
to pre-wrap
). It's title does not however suggest that the wrapping of code snippets was intended.
Verify fix:
This is a very long line that should scroll horizontally, not line-wrap. This is a very long line that should scroll horizontally, not line-wrap. This is a very long line that should scroll horizontally, not line-wrap. This is a very long line that should scroll horizontally, not line-wrap. This is a very long line that should scroll horizontally, not line-wrap. This is a very long line that should scroll horizontally, not line-wrap.