debian-mirror-gitlab/app/assets/stylesheets/mailers/highlighted_diff_email.scss

259 lines
6 KiB
SCSS
Raw Normal View History

2019-07-07 11:18:12 +05:30
@import 'framework/variables';
2017-08-17 22:00:37 +05:30
// This file is largely copied from `highlight/white.scss`, but modified to
// avoid all descendant selectors (`table td`). This is because the CSS inlining
// we use performs dramatically worse on descendant selectors than the
// alternatives.
2019-12-04 20:38:33 +05:30
// <https://gitlab.com/gitlab-org/gitlab/issues/490#note_12283632>
2017-08-17 22:00:37 +05:30
//
// DO NOT ADD ANY DESCENDANT SELECTORS TO THIS FILE. Instead, use (in order of
// preference): plain class selectors, type (element name) selectors, or
// explicit child selectors.
/*
* Highlighted Diff Email Syntax Colors
*/
$highlighted-highlight-word: #fafe3d;
$highlighted-hll-bg: #f8f8f8;
$highlighted-c: #998;
$highlighted-err: #a61717;
$highlighted-err-bg: #e3d2d2;
$highlighted-cm: #998;
$highlighted-cp: #999;
$highlighted-c1: #998;
$highlighted-cs: #999;
$highlighted-gd: #000;
$highlighted-gd-bg: #fdd;
$highlighted-gd-x: #000;
$highlighted-gd-x-bg: #faa;
$highlighted-gr: #a00;
$highlighted-gh: #999;
$highlighted-gi: #000;
$highlighted-gi-bg: #dfd;
$highlighted-gi-x: #000;
$highlighted-gi-x-bg: #afa;
$highlighted-go: #888;
$highlighted-gp: #555;
$highlighted-gu: #800080;
$highlighted-gt: #a00;
$highlighted-kt: #458;
$highlighted-m: #099;
$highlighted-s: #d14;
$highlighted-n: #333;
2019-07-07 11:18:12 +05:30
$highlighted-na: #008080;
2017-08-17 22:00:37 +05:30
$highlighted-nb: #0086b3;
$highlighted-nc: #458;
2019-07-07 11:18:12 +05:30
$highlighted-no: #008080;
$highlighted-ni: #800080;
2017-08-17 22:00:37 +05:30
$highlighted-ne: #900;
$highlighted-nf: #900;
$highlighted-nn: #555;
2019-07-07 11:18:12 +05:30
$highlighted-nt: #000080;
$highlighted-nv: #008080;
2017-08-17 22:00:37 +05:30
$highlighted-w: #bbb;
$highlighted-mf: #099;
$highlighted-mh: #099;
$highlighted-mi: #099;
$highlighted-mo: #099;
$highlighted-sb: #d14;
$highlighted-sc: #d14;
$highlighted-sd: #d14;
$highlighted-s2: #d14;
$highlighted-se: #d14;
$highlighted-sh: #d14;
$highlighted-si: #d14;
$highlighted-sx: #d14;
$highlighted-sr: #009926;
$highlighted-s1: #d14;
$highlighted-ss: #990073;
$highlighted-bp: #999;
2019-07-07 11:18:12 +05:30
$highlighted-vc: #008080;
$highlighted-vg: #008080;
$highlighted-vi: #008080;
2017-08-17 22:00:37 +05:30
$highlighted-il: #099;
$highlighted-gc: #999;
$highlighted-gc-bg: #eaf2f5;
.code {
2020-04-22 19:07:51 +05:30
background-color: $white;
2017-08-17 22:00:37 +05:30
font-family: monospace;
2018-11-18 11:00:15 +05:30
font-size: $code-font-size;
2017-08-17 22:00:37 +05:30
-premailer-cellpadding: 0;
-premailer-cellspacing: 0;
-premailer-width: 100%;
> tr {
2018-11-18 11:00:15 +05:30
line-height: $code-line-height;
2017-08-17 22:00:37 +05:30
}
}
.diff-line-num {
padding: 0 5px;
text-align: right;
width: 35px;
background-color: $gray-light;
color: $black-transparent;
border-right: 1px solid $white-normal;
&.old {
background-color: $line-number-old;
border-right-color: $line-removed-dark;
}
&.new {
background-color: $line-number-new;
border-right-color: $line-added-dark;
}
}
.line_content {
padding-left: 0.5em;
padding-right: 0.5em;
&.old {
background-color: $line-removed;
> .line > span.idiff,
> .line > span > span.idiff {
background-color: $line-removed-dark;
}
}
&.new {
background-color: $line-added;
> .line > span.idiff,
> .line > span > span.idiff {
background-color: $line-added-dark;
}
}
&.match {
color: $black-transparent;
background-color: $gray-light;
}
}
pre {
margin: 0;
}
2018-11-08 19:23:39 +05:30
blockquote,
.blockquote {
2017-08-17 22:00:37 +05:30
color: $gl-grayish-blue;
padding: 0 0 0 15px;
margin: 0;
border-left: 3px solid $white-dark;
}
span.highlight_word {
background-color: $highlighted-highlight-word !important;
}
.hll { background-color: $highlighted-hll-bg; }
2019-07-07 11:18:12 +05:30
.c { color: $highlighted-c;
font-style: italic; }
.err { color: $highlighted-err;
background-color: $highlighted-err-bg; }
2018-03-17 18:26:18 +05:30
.k { font-weight: $gl-font-weight-bold; }
.o { font-weight: $gl-font-weight-bold; }
2019-07-07 11:18:12 +05:30
.cm { color: $highlighted-cm;
font-style: italic; }
.cp { color: $highlighted-cp;
font-weight: $gl-font-weight-bold; }
.c1 { color: $highlighted-c1;
font-style: italic; }
.cs { color: $highlighted-cs;
font-weight: $gl-font-weight-bold;
font-style: italic; }
2018-03-17 18:26:18 +05:30
.gd {
color: $highlighted-gd;
background-color: $highlighted-gd-bg;
.x {
color: $highlighted-gd;
background-color: $highlighted-gd-x-bg;
}
}
2017-08-17 22:00:37 +05:30
.ge { font-style: italic; }
.gr { color: $highlighted-gr; }
.gh { color: $highlighted-gh; }
2018-03-17 18:26:18 +05:30
.gi {
color: $highlighted-gi;
background-color: $highlighted-gi-bg;
.x {
color: $highlighted-gi;
background-color: $highlighted-gi-x-bg;
}
}
2017-08-17 22:00:37 +05:30
.go { color: $highlighted-go; }
.gp { color: $highlighted-gp; }
2018-03-17 18:26:18 +05:30
.gs { font-weight: $gl-font-weight-bold; }
2019-07-07 11:18:12 +05:30
.gu { color: $highlighted-gu;
font-weight: $gl-font-weight-bold; }
2017-08-17 22:00:37 +05:30
.gt { color: $highlighted-gt; }
2018-03-17 18:26:18 +05:30
.kc { font-weight: $gl-font-weight-bold; }
.kd { font-weight: $gl-font-weight-bold; }
.kn { font-weight: $gl-font-weight-bold; }
.kp { font-weight: $gl-font-weight-bold; }
.kr { font-weight: $gl-font-weight-bold; }
2019-07-07 11:18:12 +05:30
.kt { color: $highlighted-kt;
font-weight: $gl-font-weight-bold; }
2017-08-17 22:00:37 +05:30
.m { color: $highlighted-m; }
.s { color: $highlighted-s; }
.n { color: $highlighted-n; }
.na { color: $highlighted-na; }
.nb { color: $highlighted-nb; }
2019-07-07 11:18:12 +05:30
.nc { color: $highlighted-nc;
font-weight: $gl-font-weight-bold; }
2017-08-17 22:00:37 +05:30
.no { color: $highlighted-no; }
.ni { color: $highlighted-ni; }
2019-07-07 11:18:12 +05:30
.ne { color: $highlighted-ne;
font-weight: $gl-font-weight-bold; }
.nf { color: $highlighted-nf;
font-weight: $gl-font-weight-bold; }
2017-08-17 22:00:37 +05:30
.nn { color: $highlighted-nn; }
.nt { color: $highlighted-nt; }
.nv { color: $highlighted-nv; }
2018-03-17 18:26:18 +05:30
.ow { font-weight: $gl-font-weight-bold; }
2017-08-17 22:00:37 +05:30
.w { color: $highlighted-w; }
.mf { color: $highlighted-mf; }
.mh { color: $highlighted-mh; }
.mi { color: $highlighted-mi; }
.mo { color: $highlighted-mo; }
.sb { color: $highlighted-sb; }
.sc { color: $highlighted-sc; }
.sd { color: $highlighted-sd; }
.s2 { color: $highlighted-s2; }
.se { color: $highlighted-se; }
.sh { color: $highlighted-sh; }
.si { color: $highlighted-si; }
.sx { color: $highlighted-sx; }
.sr { color: $highlighted-sr; }
.s1 { color: $highlighted-s1; }
.ss { color: $highlighted-ss; }
.bp { color: $highlighted-bp; }
.vc { color: $highlighted-vc; }
.vg { color: $highlighted-vg; }
.vi { color: $highlighted-vi; }
.il { color: $highlighted-il; }
2019-07-07 11:18:12 +05:30
.gc { color: $highlighted-gc;
background-color: $highlighted-gc-bg; }