about summary refs log tree commit diff
path: root/cgit.css
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2021-01-17 19:27:59 +0000
committerJune McEnroe <june@causal.agency>2022-02-13 11:56:12 -0500
commitbe6a526a74199d1ff1cf69e5dff3171a63ffc7f7 (patch)
treea5acb376ca4f9928f76a3b65528e5588236c63c8 /cgit.css
parentUse buffered stdio (diff)
downloadcgit-pink-be6a526a74199d1ff1cf69e5dff3171a63ffc7f7.tar.gz
cgit-pink-be6a526a74199d1ff1cf69e5dff3171a63ffc7f7.zip
Use <pre> and <span> to print diffs
This correctly preserves whitespace in browsers without CSS, as an
alternative to [1].

[1]: https://80x24.org/cgit.git/commit/?id=7c692e6137697de8a8473c4de5c3de4fb03a2989
Diffstat (limited to 'cgit.css')
-rw-r--r--cgit.css14
1 files changed, 4 insertions, 10 deletions
diff --git a/cgit.css b/cgit.css
index dac791b..36826b0 100644
--- a/cgit.css
+++ b/cgit.css
@@ -533,26 +533,20 @@ div#cgit table.diff {
 	width: 100%;
 }
 
-div#cgit table.diff td {
-	font-family: monospace;
-	white-space: pre;
-}
-
-div#cgit table.diff td div.head {
+div#cgit table.diff td span.head {
 	font-weight: bold;
-	margin-top: 1em;
 	color: black;
 }
 
-div#cgit table.diff td div.hunk {
+div#cgit table.diff td span.hunk {
 	color: #009;
 }
 
-div#cgit table.diff td div.add {
+div#cgit table.diff td span.add {
 	color: green;
 }
 
-div#cgit table.diff td div.del {
+div#cgit table.diff td span.del {
 	color: red;
 }
 
td>Switch to jorts Install scriptJune McEnroe 2022-06-08Indicate if still reading or no resultsJune McEnroe 2022-06-08Add Maiden, Mother, CroneJune McEnroe 2022-06-05FIRST SHOW IN 2.5 YEARS BABEY!!!June McEnroe 2022-06-03Set line number on File linesJune McEnroe 2022-06-03Stop polling stdin after EOFJune McEnroe 2022-06-02Set TABSIZE=4June McEnroe 2022-06-02Do basic match highlightingJune McEnroe 2022-06-02Clean up parsing a littleJune McEnroe 2022-06-02Don't duplicate path stringJune McEnroe 2022-06-02Use stderr instead of /dev/tty, realloc buffer if lines too longJune McEnroe 2022-06-02Add initial working version of qfJune McEnroe 2022-05-29Set prompt for okshJune McEnroe