mirror of
https://github.com/phil-opp/blog_os.git
synced 2025-12-16 14:27:49 +00:00
Create the “Table of Contents” heading in javascript
This commit is contained in:
@@ -54,6 +54,11 @@
|
||||
prefix: 'toc'
|
||||
});
|
||||
|
||||
var heading = document.createElement("H2");
|
||||
var heading_text = document.createTextNode("Table of Contents");
|
||||
heading.appendChild(heading_text);
|
||||
|
||||
container.appendChild(heading);
|
||||
container.appendChild(toc);
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -130,9 +130,9 @@ aside#toc {
|
||||
line-height: 1.1;
|
||||
}
|
||||
|
||||
aside#toc:before {
|
||||
content: "Table of Contents";
|
||||
font-weight: bold;
|
||||
aside#toc h2 {
|
||||
font-size: 110%;
|
||||
margin-bottom: .2rem;
|
||||
}
|
||||
|
||||
aside#toc ol {
|
||||
|
||||
Reference in New Issue
Block a user