Skip to content

Commit e495582

Browse files
authored
Infra: CSS: Show borders around merged cells (GH-4817)
Showing all borders around cells fixes the presentation for "merged" cells (rowspan/colspan, like in PEP 393). `<table>` elements already have `border-collapse` set, which means that adjacent borders are merged. It's not necessary to set inside borders only on cells & outside ones on the table.
1 parent e03cc90 commit e495582

File tree

1 file changed

+1
-8
lines changed
  • pep_sphinx_extensions/pep_theme/static

1 file changed

+1
-8
lines changed

pep_sphinx_extensions/pep_theme/static/style.css

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,6 @@ div.table-wrapper {
236236
table {
237237
width: 100%;
238238
border-collapse: collapse;
239-
border: 1px solid var(--colour-background-accent-strong);
240239
}
241240
table caption {
242241
margin: 1rem 0 .75rem;
@@ -245,22 +244,16 @@ table thead tr {
245244
background-color: var(--colour-background-accent-medium);
246245
color: var(--colour-text-strong);
247246
}
248-
table tbody tr {
249-
border-top: 1px solid var(--colour-background-accent-strong);
250-
}
251247
table th,
252248
table td {
253249
text-align: left;
254250
padding: 0.25rem 0.5rem 0.2rem;
251+
border: 1px solid var(--colour-background-accent-strong);
255252
}
256253
table.pep-zero-table tr td:nth-child(1),
257254
table.pep-zero-table tr td:nth-child(2) {
258255
white-space: nowrap;
259256
}
260-
table th + th,
261-
table td + td {
262-
border-left: 1px solid var(--colour-background-accent-strong);
263-
}
264257
/* Common column widths for PEP status tables */
265258
table.pep-zero-table tr td:nth-child(1) {
266259
width: 5%;

0 commit comments

Comments
 (0)