1
0
Fork 0

Support meta.comment as <aside>

This commit is contained in:
Tim Van Baak 2023-09-12 12:08:04 -07:00
parent 76f688b591
commit 584463a5a1
2 changed files with 22 additions and 5 deletions

View File

@ -100,6 +100,12 @@ def main():
p.append(a) p.append(a)
page.header.append(p) page.header.append(p)
if meta_comment := meta.get("comment"):
for comment in meta_comment:
aside = page.new_tag("aside")
aside.string = comment
page.header.append(aside)
# Write the fully templated page # Write the fully templated page
print("Writing ", dest) print("Writing ", dest)
dest.write_text(str(page)) dest.write_text(str(page))

View File

@ -18,6 +18,22 @@ header .metadata {
font-size: small; font-size: small;
margin-block: 0; margin-block: 0;
} }
header aside {
margin: 1em;
font-size: smaller;
font-style: italic;
}
header aside::before {
content: "/* ";
}
header aside::after {
content: " */"
}
header::after {
content: "";
display: block;
border-top: 1px solid gray;
}
h1 { h1 {
line-height: 1em; line-height: 1em;
} }
@ -36,11 +52,6 @@ sup {
:target { :target {
background: palegoldenrod; background: palegoldenrod;
} }
header::after {
content: "";
display: block;
border-top: 1px solid gray;
}
</style> </style>
</head> </head>
<body> <body>