Skip to content

Commit

Permalink
move a and TOC styles from book to article since they are not spe…
Browse files Browse the repository at this point in the history
…cific to book
  • Loading branch information
yihui committed May 5, 2024
1 parent ab640ee commit 6dcf863
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 20 deletions.
18 changes: 18 additions & 0 deletions css/article.css
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ body, blockquote, .side, .menu { background: #fafafa; }
.article-meta .terms, .appendix, .footnotes, main .side > *, .body .side, figcaption, .caption { font-size: .9em; }
.single .appendix, .body ~ .appendix, .frontmatter { background: none; }
.appendix h2 { border-bottom: 1px dashed #666; }
a { color: steelblue; }
#TOC { top: 0; }
#TOC ul { list-style-position: inside; }
#TOC > ul {
Expand All @@ -17,6 +18,23 @@ body, blockquote, .side, .menu { background: #fafafa; }
}
#TOC li > ul { padding-left: 1em; }
#TOC .numbered { list-style: none; }
#TOC a {
text-decoration: none;
}
#TOC ul ul {
border-left: 1px solid lightsteelblue;
}
#TOC .active {
color: limegreen;
}
#TOC li li .active {
border-left: 3px solid;
margin-left: calc(-1em - 3px);
padding-left: 1em;
}
#TOC li:not(.open) ul {
display: none;
}
.bg-number {
padding: 1px 5px;
border-radius: 5px;
Expand Down
20 changes: 0 additions & 20 deletions css/book.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@ body {
.footnotes, code, .side, .body .side {
font-size: .85em;
}
a {
color: steelblue;
}
.frontmatter, .chapter {
min-height: calc(100vh - 1em);
}
Expand All @@ -26,21 +23,4 @@ a {
padding: 20vh 1em 1em;
margin-top: -1em;
}
#TOC a {
text-decoration: none;
}
#TOC ul ul {
border-left: 1px solid lightsteelblue;
}
#TOC .active {
color: limegreen;
}
#TOC li li .active {
border-left: 3px solid;
margin-left: calc(-1em - 3px);
padding-left: 1em;
}
#TOC li:not(.open) ul {
display: none;
}
/* TODO: style for h1.part and printing */

0 comments on commit 6dcf863

Please sign in to comment.