Skip to content

Commit f23f17a

Browse files
committed
Style for inline code
1 parent da1291b commit f23f17a

File tree

1 file changed

+8
-11
lines changed

1 file changed

+8
-11
lines changed

style.css

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -48,24 +48,21 @@ kbd {
4848
/*********************************************
4949
* Inline code
5050
*********************************************/
51-
:not(pre) > code {
52-
background-color: darkgray!important;
53-
padding: 4px 4px 4px 4px;
54-
border-radius: 4px;
55-
text-shadow: none;
56-
font-family: courier;
57-
}
51+
5852
/*
5953
Inline code is also used to escape math blocks.
6054
The rendered math is then embedded within a span
6155
and should not receive the code background.
6256
*/
63-
:not(pre) > code > span {
64-
background-color: var(--r-background-color);
65-
padding: 0;
66-
border-radius: 0px;
57+
code:not(:empty):not(:has(*)):not(pre code) {
58+
background-color: darkgray;
59+
padding: 4px 4px 4px 4px;
60+
border-radius: 4px;
61+
text-shadow: none;
62+
font-family: courier;
6763
}
6864

65+
6966
/*********************************************
7067
* Fragments
7168
*********************************************/

0 commit comments

Comments
 (0)