mirror of
https://github.com/RGBCube/Site
synced 2025-08-01 21:47:46 +00:00
Format JS CSS MD
This commit is contained in:
parent
edd579b1b8
commit
9a8df66d89
9 changed files with 85 additions and 83 deletions
|
@ -13,7 +13,7 @@ a {
|
||||||
|
|
||||||
width: min-content;
|
width: min-content;
|
||||||
|
|
||||||
padding: 0 .3em;
|
padding: 0 0.3em;
|
||||||
border-radius: 1em;
|
border-radius: 1em;
|
||||||
|
|
||||||
user-select: none;
|
user-select: none;
|
||||||
|
|
|
@ -28,7 +28,7 @@ nav {
|
||||||
overflow-x: auto;
|
overflow-x: auto;
|
||||||
|
|
||||||
background-color: white;
|
background-color: white;
|
||||||
padding: .3em .6em;
|
padding: 0.3em 0.6em;
|
||||||
|
|
||||||
/* Rotated 180deg so it's top instead of bottom. */
|
/* Rotated 180deg so it's top instead of bottom. */
|
||||||
border-top-left-radius: 1em;
|
border-top-left-radius: 1em;
|
||||||
|
@ -38,7 +38,7 @@ nav {
|
||||||
nav a {
|
nav a {
|
||||||
color: black;
|
color: black;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
margin-right: .6em;
|
margin-right: 0.6em;
|
||||||
}
|
}
|
||||||
|
|
||||||
a {
|
a {
|
||||||
|
@ -50,7 +50,7 @@ a:hover {
|
||||||
}
|
}
|
||||||
|
|
||||||
footer {
|
footer {
|
||||||
border-top: .15em solid white;
|
border-top: 0.15em solid white;
|
||||||
|
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
|
@ -58,5 +58,5 @@ footer {
|
||||||
font-size: small;
|
font-size: small;
|
||||||
|
|
||||||
margin-bottom: 1em;
|
margin-bottom: 1em;
|
||||||
padding-top: .5em;
|
padding-top: 0.5em;
|
||||||
}
|
}
|
|
@ -1,3 +1,4 @@
|
||||||
|
---
|
||||||
title: About
|
title: About
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
---
|
||||||
title: Contact
|
title: Contact
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|
|
@ -26,15 +26,15 @@ pub static PAGES: LazyLock<HashMap<String, (Metadata, Markup)>> = LazyLock::new(
|
||||||
|
|
||||||
let content = String::from_utf8(file.content().to_vec()).unwrap();
|
let content = String::from_utf8(file.content().to_vec()).unwrap();
|
||||||
|
|
||||||
let (metadata, content) = content.split_once("---").unwrap();
|
let mut parts = content.splitn(2, "---").skip(1);
|
||||||
|
|
||||||
let metadata: Metadata = serde_yaml::from_str(metadata).unwrap();
|
let metadata: Metadata = serde_yaml::from_str(parts.next().unwrap()).unwrap();
|
||||||
|
|
||||||
log::info!("Adding page {path}");
|
log::info!("Adding page {path}");
|
||||||
|
|
||||||
Some((
|
Some((
|
||||||
path.strip_suffix(".md").unwrap().to_string(),
|
path.strip_suffix(".md").unwrap().to_string(),
|
||||||
(metadata, markdown::parse(content)),
|
(metadata, markdown::parse(parts.next().unwrap())),
|
||||||
))
|
))
|
||||||
}))
|
}))
|
||||||
});
|
});
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue