Jump to content

Template:Compact description list/styles.css

From Wikipedia, the free encyclopedia
.compact-dl-wrapper > dl > dt,
.compact-dl-wrapper > dl > div > dt,
.compact-dl-wrapper > dl > dd,
.compact-dl-wrapper > dl > div > dd {
	display: inline;
	margin: 0;
}

.compact-dl-wrapper > dl > dt::after,
.compact-dl-wrapper > dl > div > dt::after {
	content: ": ";
}

/* It would have been nice to use something like a comma or semicolon here;
   however, without control over whitespace in the markup, we likely would
   end up with unwanted spaces before the punctuation. :has() should work
   for selecting the preceding dd::after, though as of 2024, only recent
   browsers support it. So use interpunct like hlist does, though apply it
   to the following dd::before instead. */
.compact-dl-wrapper > dl > dd + dd::before,
.compact-dl-wrapper > dl > div > dd + dd::before {
	content: " · ";
	font-weight: bold;
}

.compact-dl-wrapper > dl > dd + dt::before,
.compact-dl-wrapper > dl > div > dd + dt::before {
	content: "\a";
	white-space: pre;
}