Style diff a little bit better
This commit is contained in:
parent
4ae2637192
commit
2042e5e7fe
2 changed files with 12 additions and 9 deletions
|
@ -418,14 +418,17 @@ input[type="search"] {
|
|||
}
|
||||
}
|
||||
|
||||
.removed {
|
||||
background: red;
|
||||
.diff {
|
||||
background: none;
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
.same {
|
||||
background: white;
|
||||
.removed {
|
||||
color: #866;
|
||||
background: #fdd;
|
||||
text-decoration: line-through;
|
||||
}
|
||||
.added {
|
||||
background: green;
|
||||
background: #ceb;
|
||||
}
|
||||
|
||||
@media print {
|
||||
|
|
|
@ -4,10 +4,10 @@
|
|||
</header>
|
||||
|
||||
<article>
|
||||
<pre>{{#lines}}{{#.removed}}<div class="removed">{{.}}
|
||||
</div>{{/.removed}}{{#.same}}<div class="same">{{.}}
|
||||
</div>{{/.same}}{{#.added}}<div class="added">{{.}}
|
||||
</div>{{/.added}}{{/lines}}</pre>
|
||||
<pre class="diff">{{#lines}}{{#.removed}}<span class="removed">{{.}}
|
||||
</span>{{/.removed}}{{#.same}}<span class="same">{{.}}
|
||||
</span>{{/.same}}{{#.added}}<span class="added">{{.}}
|
||||
</span>{{/.added}}{{/lines}}</pre>
|
||||
</article>
|
||||
</div>
|
||||
|
||||
|
|
Loading…
Reference in a new issue