diff options
author | Alberto Bertogli <albertito@blitiri.com.ar> | 2021-05-15 02:04:19 +0200 |
---|---|---|
committer | Alberto Bertogli <albertito@blitiri.com.ar> | 2021-05-15 02:24:58 +0200 |
commit | 9f3df4899fbb736d77ae1ded8104d8a8b83594c6 (patch) | |
tree | 18f0b06708670d10521b517783312b628e8ada25 | |
parent | bc1ee87dfeece93c92bf14f5af1008278fe05e46 (diff) | |
download | git-arr-fork-9f3df4899fbb736d77ae1ded8104d8a8b83594c6.zip |
css: Improve handling of text overflow in <pre>
When a <pre> section (commit message, blob, diff) has a very long line,
today it makes the entire page very wide, causing usability issues.
This patch makes <pre> have a horizontal scroll in those cases, which is
easier to use.
-rw-r--r-- | static/git-arr.css | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/static/git-arr.css b/static/git-arr.css index 2e4dcf8..e9533c7 100644 --- a/static/git-arr.css +++ b/static/git-arr.css @@ -147,6 +147,14 @@ div.toggable-title { margin-bottom: 0.3em; } +pre { + /* Sometimes, <pre> elements (commit messages, diffs, blobs) have very + * long lines. In those case, use automatic overflow, which will + * introduce a horizontal scroll bar for this element only (more + * comfortable than stretching the page, which is the default). */ + overflow: auto; +} + /* Commit message and diff. */ pre.commit-message { |