Skip to content

Commit 33076dc

Browse files
committed
fix: Add review suggestions
1 parent 2d4c293 commit 33076dc

File tree

1 file changed

+11
-14
lines changed

1 file changed

+11
-14
lines changed

src/ui/css/diff2html.css

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -96,27 +96,30 @@
9696
.d2h-code-line {
9797
display: inline-block;
9898
white-space: nowrap;
99+
user-select: none;
100+
width: 100%;
99101
/* Compensate for the absolute positioning of the line numbers */
100102
padding: 0 8em;
101103
}
102104

103105
.d2h-code-side-line {
104106
display: inline-block;
105107
white-space: nowrap;
106-
/* Compensate for the absolute positioning of the line numbers */
107-
padding: 0 4.5em;
108-
}
109-
110-
.d2h-code-line,
111-
.d2h-code-side-line {
112108
user-select: none;
113109
width: 100%;
110+
/* Compensate for the absolute positioning of the line numbers */
111+
padding: 0 4.5em;
114112
}
115113

116114
.d2h-code-line-ctn {
117115
display: inline-block;
116+
background: none;
117+
padding: 0;
118+
word-wrap: normal;
119+
white-space: pre;
118120
user-select: text;
119121
width: 100%;
122+
vertical-align: middle;
120123
}
121124

122125
.d2h-code-line del,
@@ -126,6 +129,7 @@
126129
text-decoration: none;
127130
background-color: #ffb6ba;
128131
border-radius: 0.2em;
132+
vertical-align: middle;
129133
}
130134

131135
.d2h-code-line ins,
@@ -136,6 +140,7 @@
136140
background-color: #97f295;
137141
border-radius: 0.2em;
138142
text-align: left;
143+
vertical-align: middle;
139144
}
140145

141146
.d2h-code-line-prefix {
@@ -146,14 +151,6 @@
146151
white-space: pre;
147152
}
148153

149-
.d2h-code-line-ctn {
150-
display: inline;
151-
background: none;
152-
padding: 0;
153-
word-wrap: normal;
154-
white-space: pre;
155-
}
156-
157154
.line-num1 {
158155
box-sizing: border-box;
159156
float: left;

0 commit comments

Comments
 (0)