Skip to content

Instantly share code, notes, and snippets.

@AWtnb
Last active May 31, 2022 05:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AWtnb/2fa67f6c775a24fc4b9b5ab4a6a177a0 to your computer and use it in GitHub Desktop.
Save AWtnb/2fa67f6c775a24fc4b9b5ab4a6a177a0 to your computer and use it in GitHub Desktop.
Stylesheet to decorate Python HtmlDiff-generated html
* {font-family: "PlemolJP";}
table {
margin: 20px auto;
border: 1px solid #aaa;
}
thead, th, tbody {border: 1px solid #aaa;}
th {background:#e0e0e0;}
td {
border-left: 1px solid #aaa;
border-right: 1px solid #aaa;
vertical-align: top;
padding: .4em;
}
td[nowrap="nowrap"] {
white-space: pre-line !important;
word-break: break-word;
max-width: 400px;
}
td.diff_header {
background: none;
font-weight: bold;
color: #aaa;
text-align:right;
font-size: .95em;
max-width: 20px;
}
tr.filler td {line-height: 0.5;}
tr.filler td.diff_header::after {
content: "\fe19";
font-size: .8em;
}
.diff_next {display: none;}
.diff_add {background-color:#4ccc78;}
.diff_chg {background-color:#ffdd33;}
.diff_sub {
background-color:#ed7a7a;
color: #fff;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment